【机器视觉】 if算子
00. 目錄
文章目錄
- 00. 目錄
- 01. 概述
- 02. 簽名
- 03. 描述
- 04. 注意
- 05. 參數
- 06. 結果
- 07. 附錄
01. 概述
if - 條件語句。
02. 簽名
if( : : Condition : )
03. 描述
if是一個條件語句,啟動一個if分段。 Condition參數必須計算為布爾值或整數表達式。
如果Condition判斷為’true’(非0),則執行它下面的分段直到下一個相應的分段語句elseif,else或endif。 到達分段的結尾處時,在相應的endif語句之后繼續運行。
如果Condition判斷為’'false(0),則繼續執行下一個相應的分段語句elseif,else或endif。
原文描述:
if is a conditional statement that starts an if block. The Condition parameter must evaluate to a boolean or integer expression.
If Condition evaluates to ‘true’ (not 0), the following block body up to the next corresponding block statement elseif, else, or endif is executed. Reaching the end of the block the execution continues after the corresponding endif statement.
If Condition evaluates to ‘false’ (0), the execution is continued at the next corresponding block statement elseif, else, or endif.
04. 注意
無
05. 參數
Condition (input_control) integer → (integer)
if語句的條件。
默認值: 1
06. 結果
如果條件正確,if(作為算子)返回2(H_MSG_TRUE)。 否則會引發異常并返回錯誤代碼。
HDevelop例程
print_check.hdev Perform a typical print quality inspection using a variation model
point_line_to_hom_mat2d.hdev Align image based on point-to-line correspondences for print quality inspection with a variation model
cbm_caliper.hdev Measure the setting of a caliper using component-based matching in a perspectively distorted image
cbm_bin_switch.hdev Locate a switch and test its state using component-based matching
3d_position_of_rectangle.hdev Estimate 3D pose of rectangular objects
程序示例
07. 附錄
7.1 機器視覺博客匯總
網址:https://dengjin.blog.csdn.net/article/details/116837497
總結
以上是生活随笔為你收集整理的【机器视觉】 if算子的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 【机器视觉】 for算子
- 下一篇: 【机器视觉】 ifelse算子(已废弃)