ClassesClasses | | Operators

select_object_model_3dselect_object_model_3dSelectObjectModel3dSelectObjectModel3d (Operator)

Name

select_object_model_3dselect_object_model_3dSelectObjectModel3dSelectObjectModel3d — Select 3D object models from an array of 3D object models according to global features.

Signature

select_object_model_3d( : : ObjectModel3D, Feature, Operation, MinValue, MaxValue : ObjectModel3DSelected)

Herror select_object_model_3d(const Hlong ObjectModel3D, const char* Feature, const char* Operation, double MinValue, double MaxValue, Hlong* ObjectModel3DSelected)

Herror T_select_object_model_3d(const Htuple ObjectModel3D, const Htuple Feature, const Htuple Operation, const Htuple MinValue, const Htuple MaxValue, Htuple* ObjectModel3DSelected)

void SelectObjectModel3d(const HTuple& ObjectModel3D, const HTuple& Feature, const HTuple& Operation, const HTuple& MinValue, const HTuple& MaxValue, HTuple* ObjectModel3DSelected)

static HObjectModel3DArray HObjectModel3D::SelectObjectModel3d(const HObjectModel3DArray& ObjectModel3D, const HTuple& Feature, const HString& Operation, const HTuple& MinValue, const HTuple& MaxValue)

HObjectModel3D HObjectModel3D::SelectObjectModel3d(const HString& Feature, const HString& Operation, double MinValue, double MaxValue) const

HObjectModel3D HObjectModel3D::SelectObjectModel3d(const char* Feature, const char* Operation, double MinValue, double MaxValue) const

static void HOperatorSet.SelectObjectModel3d(HTuple objectModel3D, HTuple feature, HTuple operation, HTuple minValue, HTuple maxValue, out HTuple objectModel3DSelected)

static HObjectModel3D[] HObjectModel3D.SelectObjectModel3d(HObjectModel3D[] objectModel3D, HTuple feature, string operation, HTuple minValue, HTuple maxValue)

HObjectModel3D HObjectModel3D.SelectObjectModel3d(string feature, string operation, double minValue, double maxValue)

Description

select_object_model_3dselect_object_model_3dSelectObjectModel3dSelectObjectModel3dSelectObjectModel3d selects 3D object models from an array of 3D object models for which the values of specified global features lie within a specified range. The list of possible features that may be specified in FeatureFeatureFeatureFeaturefeature are:

'mean_points_x'"mean_points_x""mean_points_x""mean_points_x""mean_points_x":

The mean x-coordinate of the points in the 3D object model.

'mean_points_y'"mean_points_y""mean_points_y""mean_points_y""mean_points_y":

The mean y-coordinate of the points in the 3D object model.

'mean_points_z'"mean_points_z""mean_points_z""mean_points_z""mean_points_z":

The mean z-coordinate of the points in the 3D object model.

'diameter_axis_aligned_bounding_box'"diameter_axis_aligned_bounding_box""diameter_axis_aligned_bounding_box""diameter_axis_aligned_bounding_box""diameter_axis_aligned_bounding_box":

The diameter of the set of 3D points, defined as the length of the diagonal of the smallest enclosing axis-parallel cuboid.

'diameter_bounding_box'"diameter_bounding_box""diameter_bounding_box""diameter_bounding_box""diameter_bounding_box":

The diameter of the set of 3D points, defined as the length of the diagonal of the smallest enclosing oriented cuboid. This feature has a high calculation complexity.

'diameter_object'"diameter_object""diameter_object""diameter_object""diameter_object":

The diameter of the set of 3D points, defined as the length of the distance between two points.

'volume'"volume""volume""volume""volume":

The volume of the triangulation of the 3D object model over the x-y plane in the coordinate origin. This corresponds to the default parametrization of volume_object_model_3d_relative_to_planevolume_object_model_3d_relative_to_planeVolumeObjectModel3dRelativeToPlaneVolumeObjectModel3dRelativeToPlaneVolumeObjectModel3dRelativeToPlane with the plane [0,0,0,0,0,0,0]. The plane con not be changed here.

'volume_axis_aligned_bounding_box'"volume_axis_aligned_bounding_box""volume_axis_aligned_bounding_box""volume_axis_aligned_bounding_box""volume_axis_aligned_bounding_box":

The volume of the smallest enclosing axis-parallel cuboid.

'area'"area""area""area""area":

The area of the triangulation of the 3D object model.

'central_moment_2_x'"central_moment_2_x""central_moment_2_x""central_moment_2_x""central_moment_2_x":

The x-value of the second central moment of the 3D object model.

'central_moment_2_y'"central_moment_2_y""central_moment_2_y""central_moment_2_y""central_moment_2_y":

The y-value of the second central moment of the 3D object model.

'central_moment_2_z'"central_moment_2_z""central_moment_2_z""central_moment_2_z""central_moment_2_z":

The z-value of the second central moment of the 3D object model.

'central_moment_2_xy'"central_moment_2_xy""central_moment_2_xy""central_moment_2_xy""central_moment_2_xy":

The xy-value of the second central moment of the 3D object model.

'central_moment_2_xz'"central_moment_2_xz""central_moment_2_xz""central_moment_2_xz""central_moment_2_xz":

The xz-value of the second central moment of the 3D object model.

'central_moment_2_yz'"central_moment_2_yz""central_moment_2_yz""central_moment_2_yz""central_moment_2_yz":

The yz-value of the second central moment of the 3D object model.

'num_points'"num_points""num_points""num_points""num_points":

The number of points.

'num_triangles'"num_triangles""num_triangles""num_triangles""num_triangles":

The number of triangles.

'num_faces'"num_faces""num_faces""num_faces""num_faces":

The number of faces.

'num_lines'"num_lines""num_lines""num_lines""num_lines":

The number of polylines.

'has_points'"has_points""has_points""has_points""has_points":

The existence of 3D points.

'has_point_normals'"has_point_normals""has_point_normals""has_point_normals""has_point_normals":

The existence of 3D point normals.

'has_triangles'"has_triangles""has_triangles""has_triangles""has_triangles":

The existence of triangles.

'has_faces'"has_faces""has_faces""has_faces""has_faces":

The existence of faces or polygons.

'has_lines'"has_lines""has_lines""has_lines""has_lines":

The existence of lines.

'has_xyz_mapping'"has_xyz_mapping""has_xyz_mapping""has_xyz_mapping""has_xyz_mapping":

The existence of a mapping of the 3D points to image coordinates.

'has_shape_based_matching_3d_data'"has_shape_based_matching_3d_data""has_shape_based_matching_3d_data""has_shape_based_matching_3d_data""has_shape_based_matching_3d_data":

The existence of a shape model for shape-based 3D matching.

'has_surface_based_matching_data'"has_surface_based_matching_data""has_surface_based_matching_data""has_surface_based_matching_data""has_surface_based_matching_data":

The existence of data for the surface-based 3D matching.

'has_segmentation_data'"has_segmentation_data""has_segmentation_data""has_segmentation_data""has_segmentation_data":

The existence of data for a 3D segmentation.

'has_primitive_data'"has_primitive_data""has_primitive_data""has_primitive_data""has_primitive_data":

The existence of a 3D primitive.

For all features listed in FeatureFeatureFeatureFeaturefeature a minimal and maximal threshold must be specified in MinValueMinValueMinValueMinValueminValue and MaxValueMaxValueMaxValueMaxValuemaxValue. This range is then used to select all given 3D object models that fulfill the given conditions. These are copied to ObjectModel3DSelectedObjectModel3DSelectedObjectModel3DSelectedObjectModel3DSelectedobjectModel3DSelected. For logical parameters (e.g., 'has_points'"has_points""has_points""has_points""has_points", 'has_point_normals'"has_point_normals""has_point_normals""has_point_normals""has_point_normals", ...), MinValueMinValueMinValueMinValueminValue and MaxValueMaxValueMaxValueMaxValuemaxValue can both be set to 'true'"true""true""true""true" to select all 3D object models that have the respective attribute or to 'false'"false""false""false""false" to select all that do not have it. MinValueMinValueMinValueMinValueminValue and MaxValueMaxValueMaxValueMaxValuemaxValue can be set to 'min'"min""min""min""min" and 'max'"max""max""max""max" accordingly to ignore the respective threshold.

The parameter OperationOperationOperationOperationoperation defines the logical operation that is used to combine different features in FeatureFeatureFeatureFeaturefeature. It can be either a logical 'or'"or""or""or""or" or 'and'"and""and""and""and".

Note that if a 3D object model is no longer needed or should be overwritten, the memory has to be freed first by calling the operator clear_object_model_3dclear_object_model_3dClearObjectModel3dClearObjectModel3dClearObjectModel3d.

Execution Information

Parameters

ObjectModel3DObjectModel3DObjectModel3DObjectModel3DobjectModel3D (input_control)  object_model_3d(-array) HObjectModel3D, HTupleHTupleHtuple (integer) (IntPtr) (Hlong) (Hlong)

Handles of the available 3D object models to select.

FeatureFeatureFeatureFeaturefeature (input_control)  string(-array) HTupleHTupleHtuple (string) (string) (HString) (char*)

List of features a test is performed on.

Default value: 'has_triangles' "has_triangles" "has_triangles" "has_triangles" "has_triangles"

List of values: 'area'"area""area""area""area", 'central_moment_2_x'"central_moment_2_x""central_moment_2_x""central_moment_2_x""central_moment_2_x", 'central_moment_2_xy'"central_moment_2_xy""central_moment_2_xy""central_moment_2_xy""central_moment_2_xy", 'central_moment_2_xz'"central_moment_2_xz""central_moment_2_xz""central_moment_2_xz""central_moment_2_xz", 'central_moment_2_y'"central_moment_2_y""central_moment_2_y""central_moment_2_y""central_moment_2_y", 'central_moment_2_yz'"central_moment_2_yz""central_moment_2_yz""central_moment_2_yz""central_moment_2_yz", 'central_moment_2_z'"central_moment_2_z""central_moment_2_z""central_moment_2_z""central_moment_2_z", 'diameter_axis_aligned_bounding_box'"diameter_axis_aligned_bounding_box""diameter_axis_aligned_bounding_box""diameter_axis_aligned_bounding_box""diameter_axis_aligned_bounding_box", 'diameter_bounding_box'"diameter_bounding_box""diameter_bounding_box""diameter_bounding_box""diameter_bounding_box", 'diameter_object'"diameter_object""diameter_object""diameter_object""diameter_object", 'has_faces'"has_faces""has_faces""has_faces""has_faces", 'has_lines'"has_lines""has_lines""has_lines""has_lines", 'has_point_normals'"has_point_normals""has_point_normals""has_point_normals""has_point_normals", 'has_point_normals'"has_point_normals""has_point_normals""has_point_normals""has_point_normals", 'has_primitive_data'"has_primitive_data""has_primitive_data""has_primitive_data""has_primitive_data", 'has_segmentation_data'"has_segmentation_data""has_segmentation_data""has_segmentation_data""has_segmentation_data", 'has_shape_based_matching_3d_data'"has_shape_based_matching_3d_data""has_shape_based_matching_3d_data""has_shape_based_matching_3d_data""has_shape_based_matching_3d_data", 'has_surface_based_matching_data'"has_surface_based_matching_data""has_surface_based_matching_data""has_surface_based_matching_data""has_surface_based_matching_data", 'has_triangles'"has_triangles""has_triangles""has_triangles""has_triangles", 'has_xyz_mapping'"has_xyz_mapping""has_xyz_mapping""has_xyz_mapping""has_xyz_mapping", 'mean_points_x'"mean_points_x""mean_points_x""mean_points_x""mean_points_x", 'mean_points_y'"mean_points_y""mean_points_y""mean_points_y""mean_points_y", 'mean_points_z'"mean_points_z""mean_points_z""mean_points_z""mean_points_z", 'num_faces'"num_faces""num_faces""num_faces""num_faces", 'num_lines'"num_lines""num_lines""num_lines""num_lines", 'num_points'"num_points""num_points""num_points""num_points", 'num_triangles'"num_triangles""num_triangles""num_triangles""num_triangles", 'volume'"volume""volume""volume""volume", 'volume_axis_aligned_bounding_box'"volume_axis_aligned_bounding_box""volume_axis_aligned_bounding_box""volume_axis_aligned_bounding_box""volume_axis_aligned_bounding_box"

OperationOperationOperationOperationoperation (input_control)  string HTupleHTupleHtuple (string) (string) (HString) (char*)

Logical operation to combine the features given in FeatureFeatureFeatureFeaturefeature.

Default value: 'and' "and" "and" "and" "and"

List of values: 'and'"and""and""and""and", 'or'"or""or""or""or"

MinValueMinValueMinValueMinValueminValue (input_control)  number(-array) HTupleHTupleHtuple (real / integer / string) (double / int / long / string) (double / Hlong / HString) (double / Hlong / char*)

Minimum value for the given feature.

Default value: 1

Suggested values: 0, 1, 100, 0.1, 'true'"true""true""true""true", 'false'"false""false""false""false", 'min'"min""min""min""min"

MaxValueMaxValueMaxValueMaxValuemaxValue (input_control)  number(-array) HTupleHTupleHtuple (real / integer / string) (double / int / long / string) (double / Hlong / HString) (double / Hlong / char*)

Maximum value for the given feature.

Default value: 1

Suggested values: 0, 1, 10, 100, 0.1, 'true'"true""true""true""true", 'false'"false""false""false""false", 'max'"max""max""max""max"

ObjectModel3DSelectedObjectModel3DSelectedObjectModel3DSelectedObjectModel3DSelectedobjectModel3DSelected (output_control)  object_model_3d(-array) HObjectModel3D, HTupleHTupleHtuple (integer) (IntPtr) (Hlong) (Hlong)

A subset of ObjectModel3DObjectModel3DObjectModel3DObjectModel3DobjectModel3D fulfilling the given conditions.

Example (HDevelop)

gen_object_model_3d_from_points (rand(20)-1.0, rand(20)-1.0,\
                                    rand(20)-1.0, ObjectModel3D1)
gen_object_model_3d_from_points (rand(20), rand(20),\
                                    rand(20), ObjectModel3D2)
select_object_model_3d ([ObjectModel3D1, ObjectModel3D2],\
                        'mean_points_x', 'and', 0, 1, ObjectModel3DSelected)

Result

select_object_model_3dselect_object_model_3dSelectObjectModel3dSelectObjectModel3dSelectObjectModel3d returns 2 (H_MSG_TRUE) if all parameters are correct. If necessary, an exception is raised.

Possible Predecessors

read_object_model_3dread_object_model_3dReadObjectModel3dReadObjectModel3dReadObjectModel3d, select_points_object_model_3dselect_points_object_model_3dSelectPointsObjectModel3dSelectPointsObjectModel3dSelectPointsObjectModel3d, connection_object_model_3dconnection_object_model_3dConnectionObjectModel3dConnectionObjectModel3dConnectionObjectModel3d

Possible Successors

project_object_model_3dproject_object_model_3dProjectObjectModel3dProjectObjectModel3dProjectObjectModel3d, object_model_3d_to_xyzobject_model_3d_to_xyzObjectModel3dToXyzObjectModel3dToXyzObjectModel3dToXyz

See also

volume_object_model_3d_relative_to_planevolume_object_model_3d_relative_to_planeVolumeObjectModel3dRelativeToPlaneVolumeObjectModel3dRelativeToPlaneVolumeObjectModel3dRelativeToPlane, area_object_model_3darea_object_model_3dAreaObjectModel3dAreaObjectModel3dAreaObjectModel3d, max_diameter_object_model_3dmax_diameter_object_model_3dMaxDiameterObjectModel3dMaxDiameterObjectModel3dMaxDiameterObjectModel3d, moments_object_model_3dmoments_object_model_3dMomentsObjectModel3dMomentsObjectModel3dMomentsObjectModel3d

Module

3D Metrology


ClassesClasses | | Operators