55 wxT(
" * [INFO] Destroying Shape node with %zu children, %zu"
56 "references, and %zu back pointers." ),
78 wxCHECK_MSG( aNode,
false, wxT(
"Invalid node." ) );
86 " * [INFO] bad file format; unexpected child node '%s'." ),
98 " * [INFO] bad file format; multiple appearance nodes." ),
99 __FILE__, __FUNCTION__, __LINE__ );
112 " * [INFO] bad file format; multiple geometry nodes." ),
113 __FILE__, __FUNCTION__, __LINE__ );
125 wxCHECK_MSG( aNode,
false, wxT(
"Invalid node." ) );
133 " * [INFO] bad file format; unexpected child node '%s'." ),
145 " * [INFO] bad file format; multiple appearance nodes." ),
146 __FILE__, __FUNCTION__, __LINE__ );
159 " * [INFO] bad file format; multiple geometry nodes." ),
160 __FILE__, __FUNCTION__, __LINE__ );
198 wxCHECK_MSG( aTopNode,
false, wxT(
"Invalid top node." ) );
200 char tok = proc.
Peek();
205 " * [INFO] bad file format; unexpected eof %s." ),
215 " * [INFO] bad file format; expecting '{' but got '%s' %s." ),
226 if( proc.
Peek() ==
'}' )
236 __FILE__, __FUNCTION__, __LINE__ , proc.
GetError() );
244 if( !glob.compare(
"appearance" ) )
246 if( !aTopNode->
ReadNode( proc,
this,
nullptr ) )
250 " * [INFO] could not read appearance node information." ),
251 __FILE__, __FUNCTION__, __LINE__ );
256 else if( !glob.compare(
"geometry" ) )
258 if( !aTopNode->
ReadNode( proc,
this,
nullptr ) )
262 " * [INFO] could not read geometry node information." ),
263 __FILE__, __FUNCTION__, __LINE__ );
272 " * [INFO] invalid Shape %s.\n"
273 " * [INFO] file: '%s'\n" ),
305 wxT(
" * [INFO] Translating Shape with %zu children, %zu references, and"
306 "%zu back pointers." ),
309 bool vcolors =
false;
327 wxString::Format( wxT(
"Shape does not have a Transform parent (parent "
328 "ID: %d)." ), ptype ) );
332 if(
nullptr != aParent )
354 if(
nullptr == pGeom )
367 if(
nullptr !=
appearance &&
nullptr == pApp )
384 if(
nullptr == aNode )
398 if(
nullptr == aNode )
The wrapper for the SGFACESET class.
bool Attach(SGNODE *aNode) override
Associate a given SGNODE* with this wrapper.
SGNODE * GetRawPtr(void) noexcept
Return the raw internal SGNODE pointer.
void Destroy(void)
Delete the object held by this wrapper.
The wrapper for the SGSHAPE class.
The base class of all Scene Graph nodes.
The top node of a VRML2 model.
bool ReadNode(WRLPROC &proc, WRL2NODE *aParent, WRL2NODE **aNode)
std::list< WRL2NODE * > m_BackPointers
virtual void unlinkChildNode(const WRL2NODE *aNode)
Remove references to an owned child.
std::list< WRL2NODE * > m_Children
virtual bool AddRefNode(WRL2NODE *aNode)
virtual void unlinkRefNode(const WRL2NODE *aNode)
Remove pointers to a referenced node.
const char * GetNodeTypeName(WRL2NODES aNodeType) const
WRL2NODES GetNodeType(void) const
std::list< WRL2NODE * > m_Refs
virtual bool AddChildNode(WRL2NODE *aNode)
bool AddRefNode(WRL2NODE *aNode) override
bool checkNodeType(WRL2NODES aType)
SGNODE * TranslateToSG(SGNODE *aParent) override
Produce a representation of the data using the intermediate scenegraph structures of the kicad_3dsg l...
bool Read(WRLPROC &proc, WRL2BASE *aTopNode) override
bool AddChildNode(WRL2NODE *aNode) override
bool isDangling(void) override
Determine whether an object should be moved to a different parent during the VRML to SG* translation.
void unlinkRefNode(const WRL2NODE *aNode) override
Remove pointers to a referenced node.
void unlinkChildNode(const WRL2NODE *aNode) override
Remove references to an owned child.
std::string GetFileName(void)
std::string GetError(void)
bool ReadName(std::string &aName)
std::string GetFilePosition() const
const wxChar *const traceVrmlPlugin
Flag to enable VRML plugin trace output.
collects header files for all SG* wrappers and the API
SGLIB_API S3D::SGTYPES GetSGNodeType(SGNODE *aNode)
SGLIB_API SGNODE * GetSGNodeParent(SGNODE *aNode)
SGLIB_API bool AddSGNodeChild(SGNODE *aParent, SGNODE *aChild)
SGLIB_API bool AddSGNodeRef(SGNODE *aParent, SGNODE *aChild)