get_shape_model_contoursT_get_shape_model_contoursGetShapeModelContoursGetShapeModelContoursget_shape_model_contours(算子)
名称
get_shape_model_contoursT_get_shape_model_contoursGetShapeModelContoursGetShapeModelContoursget_shape_model_contours — 返回形状模型的轮廓描述。
签名
def get_shape_model_contours(model_id: HHandle, level: int) -> HObject
描述
算子 get_shape_model_contoursget_shape_model_contoursGetShapeModelContoursGetShapeModelContoursGetShapeModelContoursget_shape_model_contours returns a
representation of the shape model ModelIDModelIDModelIDModelIDmodelIDmodel_id as XLD contours
in ModelContoursModelContoursModelContoursModelContoursmodelContoursmodel_contours. The parameter LevelLevelLevelLevellevellevel determines
for which pyramid level of the model the contour representation
should be returned. The contours can be used, for example, to
visualize the found instances of the model in an image. It should
be noted that the position of ModelContoursModelContoursModelContoursModelContoursmodelContoursmodel_contours is normalized
such that the reference point of the model (see
set_shape_model_originset_shape_model_originSetShapeModelOriginSetShapeModelOriginSetShapeModelOriginset_shape_model_origin) lies at the pixel position (0,0).
Hence, the contours simply need to be translated to the found
position in the image (and possibly rotated and scaled around this
point).
执行信息
- 多线程类型:可重入(与非独占算子并行运行)。
- 多线程作用域:全局(可从任何线程调用)。
- 未采用并行化处理。
参数
ModelContoursModelContoursModelContoursModelContoursmodelContoursmodel_contours (输出对象) xld_cont-array → objectHXLDContHObjectHXLDContHobject *
Contour representation of the shape model.
ModelIDModelIDModelIDModelIDmodelIDmodel_id (输入控制) shape_model → HShapeModel, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)
Handle of the model.
LevelLevelLevelLevellevellevel (输入控制) integer → HTupleintHTupleHtuple (integer) (int / long) (Hlong) (Hlong)
Pyramid level for which the contour representation
should be returned.
默认值:
1
建议值:
1, 2, 3, 4, 5, 6, 7, 8, 9, 10
限制:
Level >= 1
结果
如果模型的句柄有效,算子
get_shape_model_contoursget_shape_model_contoursGetShapeModelContoursGetShapeModelContoursGetShapeModelContoursget_shape_model_contours 返回值 2 (H_MSG_TRUE)。如有必要,则抛出异常。
可能的前趋
create_shape_modelcreate_shape_modelCreateShapeModelCreateShapeModelCreateShapeModelcreate_shape_model,
create_scaled_shape_modelcreate_scaled_shape_modelCreateScaledShapeModelCreateScaledShapeModelCreateScaledShapeModelcreate_scaled_shape_model,
create_aniso_shape_modelcreate_aniso_shape_modelCreateAnisoShapeModelCreateAnisoShapeModelCreateAnisoShapeModelcreate_aniso_shape_model,
read_shape_modelread_shape_modelReadShapeModelReadShapeModelReadShapeModelread_shape_model
替代
get_generic_shape_model_objectget_generic_shape_model_objectGetGenericShapeModelObjectGetGenericShapeModelObjectGetGenericShapeModelObjectget_generic_shape_model_object
另见
find_shape_modelfind_shape_modelFindShapeModelFindShapeModelFindShapeModelfind_shape_model,
find_scaled_shape_modelfind_scaled_shape_modelFindScaledShapeModelFindScaledShapeModelFindScaledShapeModelfind_scaled_shape_model,
find_aniso_shape_modelfind_aniso_shape_modelFindAnisoShapeModelFindAnisoShapeModelFindAnisoShapeModelfind_aniso_shape_model,
find_shape_modelsfind_shape_modelsFindShapeModelsFindShapeModelsFindShapeModelsfind_shape_models,
find_scaled_shape_modelsfind_scaled_shape_modelsFindScaledShapeModelsFindScaledShapeModelsFindScaledShapeModelsfind_scaled_shape_models,
find_aniso_shape_modelsfind_aniso_shape_modelsFindAnisoShapeModelsFindAnisoShapeModelsFindAnisoShapeModelsfind_aniso_shape_models
模块
匹配