日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

【机器视觉】 dev_set_part算子

發(fā)布時間:2024/4/24 编程问答 35 豆豆
生活随笔 收集整理的這篇文章主要介紹了 【机器视觉】 dev_set_part算子 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

00. 目錄

文章目錄

    • 00. 目錄
    • 01. 概述
    • 02. 簽名
    • 03. 描述
    • 04. 注意
    • 05. 參數(shù)
    • 06. 結(jié)果
    • 07. 附錄

01. 概述

dev_set_part - 修改要顯示的圖像部分。

02. 簽名

dev_set_part( : : Row1, Column1, Row2, Column2 : )

03. 描述

dev_set_part用于設(shè)置圖形窗口中要顯示的圖像部分。 參數(shù)Row1和Column1指定左上角,Row2和Column2指定要顯示的圖像部分的右下角。

有關(guān)更多信息,請參閱算子set_part的說明。 另外,如果Row1比Row2大或Column1比Column2大,那么特定尺寸縮放將被重置,以顯示圖像的完整高度(和/或)寬度。 請注意,對于在HDevelop環(huán)境以外的此算子和算子set_part,此功能無效。

另外,請注意,如果加載新程序,程序復(fù)位或顯示圖像尺寸大小不同的新圖像,則會自動復(fù)位顯示部分。

原文描述

dev_set_part is used to set the part of the image that is displayed in the graphics window. The parameters Row1 and Column1 specify the upper left corner, Row2 and Column2 the lower right corner of the image part to display.

For more information see the description of the operator set_part. In addition, if Row1 is larger than Row2 or Column1 larger than Column2, the zooming in the particular dimension will be reset to show the complete height and/or width of the image. Please note that this is not possible with the operator set_part outside HDevelop.

In addition, note that the part is automatically reset, if a new program is loaded, a program reset is performed, or a new image with a different image size is displayed.

04. 注意

使用HDevelop的代碼導(dǎo)出功能,為該算子生成的代碼可能與相關(guān)的HALCON算子具有不同的行為。 有關(guān)將HDevelop圖形算子導(dǎo)出為不同編程語言的代碼的詳細說明,請參閱“HDevelop User’s Guide”中的 Code Export -> General Aspects of Code Generation -> Graphics Windows一章。

05. 參數(shù)

Row1 (input_control)   rectangle.origin.y → (integer)

Row of the upper left corner of the chosen image part.
  Default value: 0

Column1 (input_control)    rectangle.origin.x → (integer)
  Column of the upper left corner of the chosen image part.
  Default value: 0*

Row2 (input_control)    rectangle.corner.y → (integer)
  Row of the lower right corner of the chosen image part.
  Default value: 128*

Column2 (input_control) rectangle.corner.x → (integer)
  Column of the lower right corner of the chosen image part.
  Default value: 128*

HDevelop例程

roads.hdev Extract roads from aerial image
rim.hdev Inspect holes and characters on a rim
pm_measure_board.hdev Locate IC on a board and measure pin distances
measure_screw.hdev Measure several features of a screw
fit_ellipse_tooth_rim_xld.hdev Approximate the contour of a tooth rim with an ellipse to find its center
fill_interlace.hdev Interpolate video half images
edges_color_sub_pix.hdev Extract edges with sub-pixel precision using color information
edges_color.hdev Extract edges using color information
display_operators.hdev Visualize results
dev_set_part.hdev Set the part of an image to be displayed (zoomed) in a graphics window in HDevelop
dev_open_window.hdev Open graphics windows in HDevelop
critical_points_sub_pix.hdev Detect critical points with subpixel accuracy
clip_contours_xld.hdev Clip an XLD contour

程序示例

read_image (Image, 'fabrik') for i := 1 to 240 by 10dev_set_part (i, i, 511-i, 511-i)dev_display (Image) endfor dev_set_part (1, 1, -1, -1) dev_display (Image)

06. 結(jié)果

如果指定參數(shù)的值正確,則dev_set_paint返回2(H_MSG_TRUE)。 否則會引發(fā)異常并返回錯誤代碼。

07. 附錄

7.1 機器視覺博客匯總
網(wǎng)址:https://dengjin.blog.csdn.net/article/details/116837497

總結(jié)

以上是生活随笔為你收集整理的【机器视觉】 dev_set_part算子的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。