Add AP214/203 support to the hierarchical STEP Importer/Exporter
This commit is contained in:
committed by
Yorik van Havre
parent
d27426b814
commit
7832a16af1
@@ -343,13 +343,9 @@ private:
|
||||
Handle(XCAFApp_Application) hApp = XCAFApp_Application::GetApplication();
|
||||
Handle(TDocStd_Document) hDoc;
|
||||
bool optionReadShapeCompoundMode_status;
|
||||
bool optionScheme_214;
|
||||
bool optionScheme_203;
|
||||
hApp->NewDocument(TCollection_ExtendedString("MDTV-CAF"), hDoc);
|
||||
ParameterGrp::handle hGrp = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/Mod/Import/hSTEP");
|
||||
optionReadShapeCompoundMode_status = hGrp->GetBool("ReadShapeCompoundMode",false);
|
||||
optionScheme_214 = hGrp->GetBool("Scheme_214",true);
|
||||
optionScheme_203 = hGrp->GetBool("Scheme_203",false);
|
||||
|
||||
if (file.hasExtension("stp") || file.hasExtension("step")) {
|
||||
try {
|
||||
@@ -522,6 +518,17 @@ private:
|
||||
Base::FileInfo file(Utf8Name.c_str());
|
||||
if (file.hasExtension("stp") || file.hasExtension("step")) {
|
||||
//Interface_Static::SetCVal("write.step.schema", "AP214IS");
|
||||
bool optionScheme_214;
|
||||
bool optionScheme_203;
|
||||
hApp->NewDocument(TCollection_ExtendedString("MDTV-CAF"), hDoc);
|
||||
ParameterGrp::handle hGrp_stp = App::GetApplication().GetParameterGroupByPath("User parameter:BaseApp/Preferences/Mod/Import/hSTEP");
|
||||
optionScheme_214 = hGrp_stp->GetBool("Scheme_214",true);
|
||||
optionScheme_203 = hGrp_stp->GetBool("Scheme_203",false);
|
||||
if ( optionScheme_214 )
|
||||
Interface_Static::SetCVal("write.step.schema", "AP214CD");
|
||||
if ( optionScheme_203 )
|
||||
Interface_Static::SetCVal("write.step.schema", "AP203");
|
||||
|
||||
STEPCAFControl_Writer writer;
|
||||
writer.Transfer(hDoc, STEPControl_AsIs);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user