Halcon學習之一:查詢圖像參數

http://blog.csdn.net/xinrui_hhuc/article/details/6118113  

1、get_grayval ( Image : : Row, Column : Grayval )

   計算Image圖像中坐標為(RowColumn的點的灰度值Grayval

2、get_image_pointer1 ( Image : : : Pointer, Type, Width, Height )

   計算Image圖像的數據指針Pointer,圖像類型Type,圖像寬度Width和高度HeightPointer指向了Image data的起點位置。

3、get_image_pointer3 ( ImageRGB : : : PointerRed, PointerGreen,

PointerBlue, Type, Width, Height )

   計算彩色圖像ImageRGB的參數。

4、get_image_pointer1_rect ( Image : : : PixelPointer, Width, Height,

VerticalPitch, HorizontalBitPitch, BitsPerPixel )

   計算Image圖像中定義區域的最小的長方形的區域的指針Pointer,寬度Width,高度HeightVerticalPitch代表ImageWidth*(HorizontalBitPitch/8)兩個相鄰象素的水平距離(以比特計算)HorizontalBitPitch,每像素的比特數BitsPerPixel

5、get_image_time ( Image : : : MSecond, Second, Minute, Hour, Day, YDay, Month, Year )

   獲取圖像生成的時間。

 

程序::

可以通過上述查看參數深入了解各個函數的具體意義。

  1. dev_open_window (0, 0, 512, 512, 'black', Handle1)  
  2.   
  3. read_image (Image, 'G:/Halcon/機器視覺/images/autobahn.png')  
  4.   
  5. get_grayval (Image, 12, 66, Grayval)  
  6.   
  7. get_image_pointer1 (Image, Pointer, Type, Width, Height)  
  8.   
  9. draw_region (Region1, Handle1)  
  10.   
  11. reduce_domain (Image, Region1, ImageReduced)  
  12.   
  13. get_image_pointer1_rect (ImageReduced, PixelPointer, Width1, Height1, VerticalPitch, HorizontalBitPitch, BitsPerPixel)  
  14.   
  15. read_image (Image1, 'G:/Halcon/機器視覺/images/claudia.png')  
  16.   
  17. get_image_pointer3 (Image1, PointerRed, PointerGreen, PointerBlue, Type1, Width2, Height2)  
  18.   
  19. get_image_time (Image, MSecond, Second, Minute, Hour, Day, YDay, Month, Year)  
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值