1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-14 13:30:48 +03:00

0032820: Data Exchange - add VRML reader to XCAF document

Implementing VRML reader into XCAF document.
Updating DE_Wrapper according to VRML Reader.
This commit is contained in:
atychini
2022-07-12 23:48:02 +03:00
committed by smoskvin
parent b0f92d3d5c
commit 5bde4773f9
17 changed files with 551 additions and 21 deletions

View File

@@ -56,6 +56,15 @@ bool Vrml_ConfigurationNode::Load(const Handle(DE_ConfigurationContext)& theReso
{
TCollection_AsciiString aScope = THE_CONFIGURATION_SCOPE() + "." + GetFormat() + "." + GetVendor();
InternalParameters.ReadFileUnit =
theResource->RealVal("read.file.unit", InternalParameters.ReadFileUnit, aScope);
InternalParameters.ReadFileCoordinateSys = (RWMesh_CoordinateSystem)
theResource->IntegerVal("read.file.coordinate.system", InternalParameters.ReadFileCoordinateSys, aScope);
InternalParameters.ReadSystemCoordinateSys = (RWMesh_CoordinateSystem)
theResource->IntegerVal("read.system.coordinate.system", InternalParameters.ReadSystemCoordinateSys, aScope);
InternalParameters.ReadFillIncomplete =
theResource->BooleanVal("read.fill.incomplete", InternalParameters.ReadFillIncomplete, aScope);
InternalParameters.WriterVersion = (WriteMode_WriterVersion)
theResource->IntegerVal("writer.version", InternalParameters.WriterVersion, aScope);
InternalParameters.WriteRepresentationType = (WriteMode_RepresentationType)
@@ -75,19 +84,47 @@ TCollection_AsciiString Vrml_ConfigurationNode::Save() const
aResult = aResult + "!Configuration Node " + " Vendor: " + GetVendor() + " Format: " + GetFormat() + "\n";
TCollection_AsciiString aScope = THE_CONFIGURATION_SCOPE() + "." + GetFormat() + "." + GetVendor() + ".";
aResult += "!\n";
aResult += "!Read parameters:\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Set (override) file length units to convert from while reading the file, defined as scale factor for m (meters).\n";
aResult += "!Default value: 1. Available values: positive double\n";
aResult += aScope + "read.file.unit :\t " + InternalParameters.ReadFileUnit + "\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Set (override) file origin coordinate system to perform conversion during read.\n";
aResult += "!Default value: Yup (1). { Zup (0) | Yup (1) }\n";
aResult += aScope + "read.file.coordinate.system :\t " + InternalParameters.ReadFileCoordinateSys + "\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Set system origin coordinate system to perform conversion into during read.\n";
aResult += "!Default value: Zup (0). Available values: { Zup (0) | Yup (1) }\n";
aResult += aScope + "read.system.coordinate.system :\t " + InternalParameters.ReadSystemCoordinateSys + "\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Set flag allowing partially read file content to be put into the XDE document.\n";
aResult += "!Default value: 1(\"ON\"). Available values: 0(\"OFF\"), 1(\"ON\")\n";
aResult += aScope + "read.fill.incomplete :\t " + InternalParameters.ReadFillIncomplete + "\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Write parameters:\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Setting up writer version\n";
aResult += "!Setting up writer version.\n";
aResult += "!Default value: 2. Available values: 1, 2\n";
aResult += aScope + "writer.version :\t " + InternalParameters.WriterVersion + "\n";
aResult += "!\n";
aResult += "!\n";
aResult += "!Setting up representation\n";
aResult += "!Default value: 1. Available values: 0(shaded), 1(wireframe), 2(both)\n";
aResult += "!Default value: 1. Available values: 0(shaded), 1(wireframe), 2(both).\n";
aResult += aScope + "write.representation.type :\t " + InternalParameters.WriteRepresentationType + "\n";
aResult += "!\n";