sprk_exchange.h
165 TranslationNotifier Translate(Units in_units, TranslationOptionsKit const & in_translation_options);
173 ReloadNotifier Reload(TessellationOptionsKit const & in_tessellation_options = TessellationOptionsKit(), TranslationOptionsKit const & in_translation_options = TranslationOptionsKit());
368 /* Gets a list of sheets for this CADModel (if any). Only formats which support the concept of sheets can return a non-empty array.
383 ReloadNotifier Reload(TessellationOptionsKit const & in_options = TessellationOptionsKit(), TranslationOptionsKit const & in_translation_options = TranslationOptionsKit());
513 static Component CreateComponent(HPS::Component const & in_owner, HPS::Component::ComponentType in_type, A3DEntity * in_entity = nullptr);
520 static CADModel CreateCADModel(Model const & in_model = HPS::Factory::CreateModel(), A3DAsmModelFile * in_entity = nullptr, bool in_owns_entity = false);
533 static Capture CreateCapture(HPS::Component const & in_owner, A3DEntity * in_entity = nullptr, bool in_is_default = false);
1072 Configuration(char const * in_name, size_t in_count, Configuration const in_subconfigurations[]);
1203 static void GetInformation(const char * in_file_name, Format & out_format, UTF8 & out_model_name, UTF8 & out_version, UTF8 & out_author, UTF8 & out_organization, UTF8 & out_time_stamp);
1226 static ImportNotifier Import(A3DAsmModelFile const * in_model_file, ModelFileImportOptionsKit const & in_options);
1235 static ImportNotifier Import(size_t in_byte_count, byte const in_prc_data[], ModelFileImportOptionsKit const & in_options);
1243 static ImportNotifier Import(ByteArray const & in_prc_data, ModelFileImportOptionsKit const & in_options);
1252 static TranslationNotifier Translate(char const * in_file_name, ImportOptionsKit const & in_options, TranslationOptionsKit const & in_translation_options);
1259 static ExportNotifier Export3MF(CADModel const & in_cad_model, char const * in_file_name, Export3MFOptionsKit const & in_options);
1266 static ExportNotifier Export3MF(KeyPathArray const & in_source, char const * in_file_name, Export3MFOptionsKit const & in_options);
1274 static ExportNotifier Export3MF(size_t in_count, KeyPath const in_source[], char const * in_file_name, Export3MFOptionsKit const & in_options);
1281 static ExportNotifier Export3MF(KeyPath in_source, char const * in_file_name, Export3MFOptionsKit const & in_options);
1287 static void ExportACIS(CADModel const & in_cad_model, char const * in_file_name, ExportACISOptionsKit const & in_options);
1293 static void ExportJT(CADModel const & in_cad_model, char const * in_file_name, ExportJTOptionsKit const & in_options);
1300 static ExportNotifier ExportPRC(CADModel const & in_cad_model, char const * in_file_name, ExportPRCOptionsKit const & in_options);
1307 static ExportNotifier ExportPRC(KeyPathArray const & in_source, char const * in_file_name, bool in_compress_tessellation = false);
1315 static ExportNotifier ExportPRC(size_t in_count, KeyPath const in_source [], char const * in_file_name, bool in_compress_tessellation = false);
1323 static ExportNotifier ExportPRC(KeyPath const & in_source, char const * in_file_name, bool in_compress_tessellation = false);
1345 static void ExportSTL(CADModel const & in_cad_model, char const * in_file_name, ExportSTLOptionsKit const & in_options);
1351 static void ExportU3D(CADModel const & in_cad_model, char const * in_file_name, ExportU3DOptionsKit const & in_options);
1362 static void ExportXML(CADModel const & in_cad_model, char const * in_file_name, ExportXMLOptionsKit const & in_options);
1370 static void ExportIGES(CADModel const & in_cad_model, char const * in_file_name, ExportIGESOptionsKit const & in_options);
1376 static void ExportParasolid(CADModel const & in_cad_model, char const * in_file_name, ExportParasolidOptionsKit const & in_options);
1382 static void ExportSTEP(CADModel const & in_cad_model, char const * in_file_name, ExportSTEPOptionsKit const & in_options);
1469 NURBSConversionOptionsKit & SetUVCurvesComputation(bool in_state, bool in_allow_cross_seam_curves);
1508 NURBSConversionOptionsKit & SetAllowedSurfaces(size_t in_count, SurfaceType const in_allowed_surfaces []);
1523 NURBSConversionOptionsKit & SetAllowedCurves(size_t in_count, CurveType const in_allowed_curves []);
1785 ImportOptionsKit & SetPMISubstitutionFont(char const * in_font_name, bool in_always_substitute = false);
1817 ImportOptionsKit & SetPMIDefaultColor(RGBColor const & in_color, bool in_override_color = false);
1839 ImportOptionsKit & SetTessellationLevel(Tessellation::Chord::Limit in_limit_type, double in_limit, double in_angle_tolerance);
1848 ImportOptionsKit & SetTessellationAccuracy(Tessellation::Accuracy in_type, bool in_accurate_normals = true);
1883 ImportOptionsKit & SetSearchDirectories(size_t in_count, UTF8 const in_directories[], bool const in_recurse_flags[]);
1890 ImportOptionsKit & SetSearchDirectories(UTF8Array const & in_directories, BoolArray const & in_recurse_flags);
1900 ImportOptionsKit & SetSearchDirectories(size_t in_count, UTF8 const in_directories[], UTF8 const in_logical_names[], bool const in_recurse_flags[]);
1910 ImportOptionsKit & SetSearchDirectories(UTF8Array const & in_directories, UTF8Array const & in_logical_names, BoolArray const & in_recurse_flags);
1982 ImportOptionsKit & SetUnigraphicsPreferredReferenceSets(size_t in_count, UTF8 const in_reference_sets[], bool in_apply_to_all_levels);
1990 ImportOptionsKit & SetUnigraphicsPreferredReferenceSets(UTF8Array const & in_reference_sets, bool in_apply_to_all_levels);
2223 ImportOptionsKit & SetLocation(ComponentPath const & in_path, MatrixKit const & in_transform = MatrixKit());
2256 ImportOptionsKit & SetIncrementalComponentPaths(size_t in_count, HPS::ComponentPath const in_paths[]);
2269 ImportOptionsKit & SetNURBSConversion(HPS::Exchange::NURBSConversionOptionsKit const & in_nurbs_conversion_options);
2652 bool ShowTessellationLevel(Tessellation::Type & out_type, Tessellation::Level & out_level, Tessellation::Chord::Limit & out_limit_type, double & out_limit, double & out_angle_tolerance) const;
2658 bool ShowTessellationAccuracy(Tessellation::Accuracy & out_type, bool & out_accurate_normals) const;
2690 bool ShowSearchDirectories(UTF8Array & out_directories, UTF8Array & out_logical_names, BoolArray & out_recurse_flags) const;
2728 bool ShowUnigraphicsPreferredReferenceSets(UTF8Array & out_reference_sets, bool & out_apply_to_all_levels) const;
2899 bool ShowNURBSConversion(HPS::Exchange::NURBSConversionOptionsKit & out_nurbs_conversion_options) const;
3267 /* Dictates whether Visualize will flip pmi when rotating so that text / symbols remain readable.
3268 * \note If exchange reports that a markup does not contain leader lines, but the tessellation does contain lines that markup will not be
3269 * flipped. This is a precaution for models where the leader line geometry was included as part of the markup tessellation and
3289 ModelFileImportOptionsKit & SetTessellationLevel(Tessellation::Chord::Limit in_limit_type, double in_limit, double in_angle_tolerance);
3298 ModelFileImportOptionsKit & SetTessellationAccuracy(Tessellation::Accuracy in_type, bool in_accurate_normals = true);
3300 /* Dictates whether Exchange tesselation data will be released from their parent representation items during import.
3301 * \warning Setting this option to true will cause future exports to output without tessellation data.
3346 ModelFileImportOptionsKit & SetLocation(ComponentPath const & in_path, MatrixKit const & in_transform = MatrixKit());
3358 ModelFileImportOptionsKit & SetNURBSConversion(HPS::Exchange::NURBSConversionOptionsKit const & in_nurbs_conversion_options);
3427 bool ShowTessellationLevel(Tessellation::Type & out_type, Tessellation::Level & out_level, Tessellation::Chord::Limit & out_limit_type, double & out_limit, double & out_angle_tolerance) const;
3433 bool ShowTessellationAccuracy(Tessellation::Accuracy & out_type, bool & out_accurate_normals) const;
3479 bool ShowNURBSConversion(HPS::Exchange::NURBSConversionOptionsKit & out_nurbs_conversion_options) const;
3561 Export3MFOptionsKit & SetAdditionalKeyPaths(size_t in_count, KeyPath const in_additional_key_paths[]);
3576 Export3MFOptionsKit & SetCurrentTessellationRetention(bool in_state, TessellationOptionsKit const & in_tessellation_kit = TessellationOptionsKit());
3586 bool ShowCurrentTessellationRetention(bool & out_state, Exchange::TessellationOptionsKit & out_tessellation_kit) const;
3974 ExportPRCOptionsKit & SetAdditionalKeyPaths(size_t in_count, KeyPath const in_additional_key_paths []);
4111 ExportSTLOptionsKit & SetTessellationLevel(Tessellation::Chord::Limit in_limit_type, double in_limit, double in_angle_tolerance);
4188 bool ShowTessellationLevel(Tessellation::Type & out_type, Tessellation::Level & out_level, Tessellation::Chord::Limit & out_limit_type, double & out_limit, double & out_angle_tolerance) const;
5035 TessellationOptionsKit & SetLevel(Tessellation::Chord::Limit in_limit_type, double in_limit, double in_angle_tolerance);
5042 TessellationOptionsKit & SetAccuracy(Tessellation::Accuracy in_type, bool in_accurate_normals = true);
5083 bool ShowLevel(Tessellation::Type & out_type, Tessellation::Level & out_level, Tessellation::Chord::Limit & out_limit_type, double & out_limit, double & out_angle_tolerance) const;
5123 CommonMeasurementOperator(Exchange::CADModel const & in_cad_model, MouseButtons in_mouse_trigger = MouseButtons::ButtonLeft(), ModifierKeys in_modifier_trigger = ModifierKeys());
5174 MeasurementInsertedEvent(HPS::Key const & in_measurement_key, HPS::View const & in_view) : Event()
5220 MeasurementDeletedEvent(HPS::UTF8 const & in_measurement_name, HPS::View const & in_view) : Event()
5282 void PositionLinearMeasurementGeometry(WindowPoint const & window_cursor_location, KeyPath const & event_path, LineKey & leader_line_one, LineKey & leader_line_two,
5283 LineKey & measurement_line, LineKey & line_to_cursor, Point & original_point_one, Point & original_point_two, TextKey & text, UTF8 const & text_string,
5284 Point & distance_point_one, Point & distance_point_two, SegmentKey & current_measurement_segment, Plane const & measurement_plane = Plane(), Vector const & explicit_direction = Vector());
5286 void SetMaterialsOnMeasurementSegment(HPS::SegmentKey const & set_materials_here, HPS::MaterialMappingKit const & materials_to_apply);
5354 MeasurementOperator(Exchange::CADModel const & in_cad_model, MouseButtons in_mouse_trigger = MouseButtons::ButtonLeft(), ModifierKeys in_modifier_trigger = ModifierKeys());
5412 * \param in_highlighting Whether measurable geometry should be highlighted when mousing over it. */
5416 * \param in_highlighting Whether measurable geometry should be highlighted when mousing over it.
5418 void SetMouseOverHighlighting(bool in_highlighting, HighlightOptionsKit const & in_highlight_options_kit);
5421 * \return <span class='code'>true</span> if measurable geometry is highlighted on mouse over, <span class='code'>false</span> otherwise. */
5429 * \return <span class='code'>true</span> if a measurement is being inserted or manipulated, <span class='code'>false</span> otherwise. */
5432 /* Delete the current measurement and brings the operator back to a state to start a new measurement */
5436 enum class EdgeType //used to determine the type of edge measured when using the EdgeAndRadius measurement type
5443 class Surface //helper class containing surfaces properties. Used for the FeatureToFeature measurement type
5458 LineKey normal_points; //the line representing the center line of surfaces of type Cylinder or Cone
5490 bool use_explicit_direction; //if true, we are moving the measurement along a specific vector, called explicit_direction
5514 bool inverted_measurement; //the smallest of the two possible angles is always chosen. If the user wants the other angle, the measurement is marked as 'inverted'
5526 bool highlight_on_mouse_over; //whether measurable geometry should be highlighted on mouse over
5527 HighlightOptionsKit mouse_over_highlight_options; //the options used for mouse over highlighting
5528 HighlightOptionsKit edit_measurement_highlight_options; //the options used for highlighting measurements while editing them
5529 UpdateNotifier highlight_update_notifier; //notifier used to know if the last highlight update has completed
5531 bool disable_highlighting; //in some situation we temporarily disable highlighting to improve performance
5532 bool Highlight(MeasurementType in_measurement_type, WindowPoint const & in_location, WindowKey & in_window, KeyPath const & in_path);
5535 bool InputDown(WindowPoint const & in_location, WindowKey & in_window, KeyPath const & in_path, size_t number_of_clicks);
5542 bool InsertEdgeRadiusMeasurement(KeyPath const & in_selection_path, WindowPoint & in_selection_position, Key const & in_edge_key);
5543 bool InsertFeatureToFeatureMeasurement(KeyPath const & in_selection_path, WindowPoint & in_selection_position, Key const & in_face_key, WindowKey & in_window);
5544 void InsertFeatureToFeatureGeometry(Point const & point_one, Point const & point_two, float distance);
5545 bool InsertAngleMeasurement(KeyPath const & in_selection_path, WindowPoint & in_selection_position, Key const & in_face_key, WindowKey & in_window, SelectionResults const & in_selection_results);
5574 float LineSegmentDistance(Point & p0, Point & p1, Point & q0, Point & q1, LineKey & normal_one, LineKey & normal_two, Point & out_point_on_edge, Point & out_point_on_center_line, bool clamp = true);
5575 Point ClosestPointOnTriangleToPoint(Point const & p, Point const & a, Point const & b, Point const & c);
5576 float ClosestPointSegmentSegment(Point const & p1, Point const & q1, Point const & p2, Point const & q2, Point & c1, Point & c2);
5578 Point GetPlaneIntersection(Plane const & in_plane, KeyPath const & in_key_path, WindowPoint const & in_window_point);
Definition: hps.h:6208
Definition: sprk_exchange.h:3872
Definition: sprk_exchange.h:44
Definition: sprk_exchange.h:5210
Definition: sprk_exchange.h:976
Definition: sprk.h:267
Definition: sprk_exchange.h:1142
Definition: sprk_exchange.h:5107
An InvalidSpecificationException is thrown when a method is called with non-sensical or contradictory...
Definition: hps.h:5823
Definition: sprk.h:66
Definition: sprk.h:100
virtual HPS::UTF8 GetName() const override
Definition: sprk_exchange.h:5126
Definition: sprk_exchange.h:607
Definition: sprk_exchange.h:3204
Definition: sprk_exchange.h:875
Definition: sprk_exchange.h:708
Definition: hps.h:1732
Definition: sprk_exchange.h:4313
Definition: sprk.h:236
std::vector< KeyPath, Allocator< KeyPath > > KeyPathArray
Array of type HPS::KeyPath.
Definition: hps.h:6674
std::vector< byte, Allocator< byte > > ByteArray
Array of type HPS::byte.
Definition: hps.h:6650
Definition: hps.h:47626
Definition: hps.h:7714
std::vector< bool, Allocator< bool > > BoolArray
Array of type bool.
Definition: hps.h:6644
Definition: hps.h:16084
Definition: sprk_exchange.h:461
Definition: sprk_exchange.h:546
Definition: sprk_exchange.h:302
MeasurementInsertedEvent(Event const &in_event)
Definition: sprk_exchange.h:5184
Definition: sprk_exchange.h:1391
Definition: sprk_exchange.h:242
Definition: sprk_exchange.h:5164
Definition: sprk_exchange.h:3738
Definition: hps.h:47524
Definition: hps.h:41116
Definition: sprk_exchange.h:3636
Definition: sprk_exchange.h:2953
Definition: hps.h:4509
MeasurementInsertedEvent()
Definition: sprk_exchange.h:5168
Definition: sprk_exchange.h:851
Definition: sprk_exchange.h:4029
Definition: sprk_exchange.h:113
Definition: sprk_exchange.h:948
Definition: hps.h:4448
Definition: hps.h:7085
Definition: hps.h:46995
Definition: sprk_exchange.h:415
Definition: hps.h:43108
Definition: hps.h:47411
Definition: sprk_dwg.h:43
Definition: sprk_exchange.h:4212
Definition: sprk_exchange.h:913
Definition: hps.h:15474
Event * Clone() const
Definition: sprk_exchange.h:5246
Definition: sprk_exchange.h:1041
Definition: sprk.h:1739
Definition: hps.h:47733
Definition: hps.h:44237
Definition: hps.h:46502
Definition: sprk_exchange.h:506
Definition: hps.h:6292
Definition: hps.h:13721
std::vector< UTF8, Allocator< UTF8 > > UTF8Array
Array of type HPS::UTF8.
Definition: hps.h:6642
Definition: sprk_exchange.h:5341
Definition: sprk.h:481
Definition: sprk_parasolid.h:39
Definition: sprk.h:2065
Definition: sprk_exchange.h:3489
Definition: sprk_exchange.h:4433
MeasurementDeletedEvent(Event const &in_event)
Definition: sprk_exchange.h:5230
Definition: sprk.h:2447
Definition: sprk_exchange.h:1616
Definition: sprk.h:2547
virtual HPS::UTF8 GetName() const override
Definition: sprk_exchange.h:5357
Definition: hps.h:7632
Definition: sprk_exchange.h:995
Event * Clone() const
Definition: sprk_exchange.h:5200
Definition: hps.h:9328
Definition: sprk_exchange.h:661
Definition: hps.h:23944
Definition: sprk.h:2634
Definition: hps.h:30377
Definition: sprk_exchange.h:1058
Definition: hps.h:511
Definition: sprk.h:1104
Definition: sprk_exchange.h:2908
MeasurementDeletedEvent()
Definition: sprk_exchange.h:5214
static Model CreateModel(char const *in_name="")
Definition: sprk_exchange.h:4611
Definition: sprk_exchange.h:176
Definition: hps.h:40612
Definition: sprk_exchange.h:4962
Definition: hps.h:41731
Definition: sprk_exchange.h:4757