56 wxT(
" * [INFO] Destroying Appearance node with %zu children, %zu"
57 "references, and %zu back pointers." ),
94 wxCHECK_MSG( aNode,
false, wxT(
"Invalid node." ) );
102 " * [INFO] bad file format; unexpected child node '%s'." ),
114 " * [INFO] bad file format; multiple material nodes." ),
115 __FILE__, __FUNCTION__, __LINE__ );
130 " * [INFO] bad file format; multiple textureTransform nodes." ),
131 __FILE__, __FUNCTION__, __LINE__ );
144 " * [INFO] bad file format; multiple texture nodes." ),
145 __FILE__, __FUNCTION__, __LINE__ );
157 wxCHECK_MSG( aNode,
false, wxT(
"Invalid node." ) );
165 " * [INFO] bad file format; unexpected child node '%s'." ),
177 " * [INFO] bad file format; multiple material nodes." ),
178 __FILE__, __FUNCTION__, __LINE__ );
193 " * [INFO] bad file format; multiple textureTransform nodes." ),
194 __FILE__, __FUNCTION__, __LINE__ );
207 " * [INFO] bad file format; multiple texture nodes." ),
208 __FILE__, __FUNCTION__, __LINE__ );
220 wxCHECK_MSG( aTopNode,
false, wxT(
"Invalid top node." ) );
222 char tok = proc.
Peek();
227 " * [INFO] bad file format; unexpected eof %s." ),
237 " * [INFO] bad file format; expecting '{' but got '%s' %s." ),
248 if( proc.
Peek() ==
'}' )
258 __FILE__, __FUNCTION__, __LINE__ , proc.
GetError() );
268 if( !glob.compare(
"material" ) )
270 if( !aTopNode->
ReadNode( proc,
this,
nullptr ) )
274 " * [INFO] could not read material information." ),
275 __FILE__, __FUNCTION__, __LINE__ );
280 else if( !glob.compare(
"texture" ) )
282 if( !aTopNode->
ReadNode( proc,
this,
nullptr ) )
286 " * [INFO] could not read texture information." ),
287 __FILE__, __FUNCTION__, __LINE__ );
292 else if( !glob.compare(
"textureTransform" ) )
294 if( !aTopNode->
ReadNode( proc,
this,
nullptr ) )
298 " * [INFO] could not read textureTransform information." ),
299 __FILE__, __FUNCTION__, __LINE__ );
307 " * [INFO] bad Appearance %s.\n"
308 " * [INFO] file: '%s'" ),
328 wxString::Format( wxT(
" * [BUG] Appearance does not have a Shape parent "
329 "(parent ID: %d)." ), ptype ) );
332 wxT(
" * [INFO] Translating Appearance node with %zu children, %zu"
333 "references, and %zu back pointers." ),
338 if(
nullptr != aParent )
379 if(
nullptr == aNode )
399 if(
nullptr == aNode )
bool SetDiffuse(float aRVal, float aGVal, float aBVal)
bool SetEmissive(float aRVal, float aGVal, float aBVal)
bool SetSpecular(float aRVal, float aGVal, float aBVal)
bool SetShininess(float aShininess) noexcept
bool SetTransparency(float aTransparency) noexcept
SGNODE * GetRawPtr(void) noexcept
Return the raw internal SGNODE pointer.
The base class of all Scene Graph nodes.
bool AddRefNode(WRL2NODE *aNode) override
bool checkNodeType(WRL2NODES aType)
Return true if the node type is a material description class.
bool Read(WRLPROC &proc, WRL2BASE *aTopNode) override
WRL2NODE * textureTransform
void unlinkRefNode(const WRL2NODE *aNode) override
Remove pointers to a referenced node.
SGNODE * TranslateToSG(SGNODE *aParent) override
Produce a representation of the data using the intermediate scenegraph structures of the kicad_3dsg l...
bool isDangling(void) override
Determine whether an object should be moved to a different parent during the VRML to SG* translation.
virtual ~WRL2APPEARANCE()
void unlinkChildNode(const WRL2NODE *aNode) override
Remove references to an owned child.
bool AddChildNode(WRL2NODE *aNode) override
The top node of a VRML2 model.
bool ReadNode(WRLPROC &proc, WRL2NODE *aParent, WRL2NODE **aNode)
std::list< WRL2NODE * > m_BackPointers
WRL2NODE * GetParent(void) const
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)
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)