#include <OSGVRMLNodeDescs.h>
Inheritance diagram for osg::VRMLGroupDesc:

Member | |
| Field * | getField (FieldContainerPtr pFC1, FieldContainerPtr pFC2, GenericAttPtr pGenAtt, const Char8 *szFieldname) |
| FieldNameTypeHash | _mFieldTypes |
| GenericAttPtr | _pGenAtt |
| FieldContainerPtr | _pNodeProto |
| FieldContainerPtr | _pNodeCoreProto |
| Field * | _pCurrField |
| std::string | _szCurrentName |
| bool | _bSaveOnEnd |
| *static UInt32 | _uiIndent = 0 |
Public Member Functions | |
Constructors | |
| * | VRMLGroupDesc (void) |
Destructor | |
| *virtual | ~VRMLGroupDesc (void) |
Helper | |
| *virtual void | init (const Char8 *szName) |
Field | |
| *virtual bool | prototypeAddField (const Char8 *szFieldType, const UInt32 uiFieldTypeId, const Char8 *szFieldName) |
| virtual void | endProtoInterface (void) |
| virtual void | getFieldAndDesc (FieldContainerPtr pFC, const Char8 *szFieldname, Field *&pField, const FieldDescription *&pDesc) |
Node | |
| *virtual FieldContainerPtr | beginNode (const Char8 *szTypename, const Char8 *szName, FieldContainerPtr pCurrentFC) |
| virtual void | endNode (FieldContainerPtr) |
Dump | |
| *virtual void | dump (const Char8 *szNodeName) |
Helper | |
| virtual void | reset (void) |
| virtual void | setOnEndSave (const Char8 *szName) |
| virtual void | clearOnEndSave (void) |
| virtual bool | getOnEndSave (void) |
| virtual const Char8 * | getSavename (void) |
| virtual FieldContainerPtr | getSaveFieldContainer (void) |
Field | |
| *virtual Field * | getField (const Char8 *szFieldname) |
Prototypes | |
| virtual void | prototypeAddFieldValue (const Char8 *szFieldVal) |
FieldValue | |
| *virtual void | addFieldValue (Field *pField, const Char8 *szFieldVal) |
| virtual bool | use (FieldContainerPtr) |
Static Public Member Functions | |
Class Get | |
| *static UInt32 | getIndent (void) |
| static void | incIndent (void) |
| static void | decIndent (void) |
| static void | resetIndent (void) |
Protected Types | |
| typedef std::map< const Char8 *, UInt32, LTString > | FieldNameTypeHash |
Protected Attributes | |
Member | |
| *SFVec3f | _defaultBoxCenter |
| SFVec3f | _defaultBoxSize |
| SFVec3f | _boxCenter |
| SFVec3f | _boxSize |
Private Types | |
| typedef VRMLNodeDesc | Inherited |
Private Member Functions | |
| VRMLGroupDesc (const VRMLGroupDesc &source) | |
| prohibit default function (move to 'public' if needed) | |
| void | operator= (const VRMLGroupDesc &source) |
| prohibit default function (move to 'public' if needed) | |
Definition at line 1479 of file OSGVRMLNodeDescs.h.
|
|
Definition at line 1556 of file OSGVRMLNodeDescs.h. |
|
|
Definition at line 298 of file OSGVRMLNodeDescs.h. |
|
|
Definition at line 4310 of file OSGVRMLNodeDescs.cpp. 04310 : 04311 Inherited(), 04312 04313 _defaultBoxCenter(), 04314 _defaultBoxSize (), 04315 04316 _boxCenter (), 04317 _boxSize () 04318 { 04319 }
|
|
|
Definition at line 4324 of file OSGVRMLNodeDescs.cpp.
|
|
|
|
|
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4331 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_pGenAtt, osg::VRMLNodeDesc::_pNodeCoreProto, osg::VRMLNodeDesc::_pNodeProto, osg::DynFieldAttachment< AttachmentDescT >::create(), osg::GroupBase::create(), osg::Node::create(), osg::VRMLNodeDesc::getIndent(), osg::indentLog(), and PINFO. 04332 { 04333 #ifdef OSG_DEBUG_VRML 04334 indentLog(getIndent(), PINFO); 04335 PINFO << "GroupDesc::init : " << szName << std::endl; 04336 #endif 04337 04338 _pNodeProto = Node::create(); 04339 _pNodeCoreProto = Group::create(); 04340 04341 _pGenAtt = GenericAtt::create(); 04342 _pGenAtt->setInternal(true); 04343 }
|
|
||||||||||||||||
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4348 of file OSGVRMLNodeDescs.cpp. References _defaultBoxCenter, _defaultBoxSize, osg::VRMLNodeDesc::_pCurrField, osg::VRMLNodeDesc::prototypeAddField(), and osg::stringcasecmp(). 04351 { 04352 bool bFound = false; 04353 04354 _pCurrField = NULL; 04355 04356 if(stringcasecmp("bboxCenter", szFieldname) == 0) 04357 { 04358 _pCurrField = &_defaultBoxCenter; 04359 bFound = true; 04360 } 04361 else if(stringcasecmp("bboxSize", szFieldname) == 0) 04362 { 04363 _pCurrField = &_defaultBoxSize; 04364 bFound = true; 04365 } 04366 else if(stringcasecmp("children", szFieldname) == 0) 04367 { 04368 bFound = true; 04369 } 04370 04371 if(bFound == true) 04372 { 04373 return true; 04374 } 04375 else 04376 { 04377 return Inherited::prototypeAddField(szFieldType, 04378 uiFieldTypeId, 04379 szFieldname); 04380 } 04381 }
|
|
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4383 of file OSGVRMLNodeDescs.cpp.
|
|
||||||||||||||||||||
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4387 of file OSGVRMLNodeDescs.cpp. References _boxCenter, _boxSize, osg::AttachmentContainerPtr::dcast(), osg::NodePtr::dcast(), osg::VRMLNodeDesc::decIndent(), osg::NodePtr::getCore(), osg::VRMLNodeDesc::getFieldAndDesc(), osg::VRMLNodeDesc::getIndent(), osg::VRMLNodeDesc::incIndent(), osg::indentLog(), osg::NullFC, PINFO, PWARNING, and osg::stringcasecmp(). 04392 { 04393 if(szFieldname == NULL) 04394 return; 04395 04396 if(pFC == NullFC) 04397 return; 04398 04399 NodePtr pNode = NodePtr::dcast(pFC); 04400 04401 #ifdef OSG_DEBUG_VRML 04402 indentLog(getIndent(), PINFO); 04403 PINFO << "VRMLGroupDesc::getFieldAndDesc : looking for " 04404 << szFieldname 04405 << std::endl; 04406 #endif 04407 04408 if(pNode == NullFC) 04409 { 04410 PWARNING << "VRMLGroupDesc::getFieldAndDesc : No Node" << std::endl; 04411 return; 04412 } 04413 04414 NodeCorePtr pNodeCore = pNode->getCore(); 04415 04416 GroupPtr pGroup = GroupPtr::dcast(pNodeCore); 04417 04418 if(pGroup == NullFC) 04419 { 04420 PWARNING << "VRMLGroupDesc::getFieldAndDesc : No Group" << std::endl; 04421 return; 04422 } 04423 04424 incIndent(); 04425 04426 if(stringcasecmp("bboxCenter", szFieldname) == 0) 04427 { 04428 #ifdef OSG_DEBUG_VRML 04429 indentLog(getIndent(), PINFO); 04430 PINFO << "VRMLGroupDesc::getFieldAndDesc : : request internal " 04431 << szFieldname 04432 << std::endl; 04433 #endif 04434 04435 pField = &_boxCenter; 04436 pDesc = NULL; 04437 } 04438 else if(stringcasecmp("bboxSize", szFieldname) == 0) 04439 { 04440 #ifdef OSG_DEBUG_VRML 04441 indentLog(getIndent(), PINFO); 04442 PINFO << "VRMLGroupDesc::getFieldAndDesc : : request internal " 04443 << szFieldname 04444 << std::endl; 04445 #endif 04446 04447 pField = &_boxSize; 04448 pDesc = NULL; 04449 } 04450 else if(stringcasecmp("children", szFieldname) == 0) 04451 { 04452 #ifdef OSG_DEBUG_VRML 04453 indentLog(getIndent(), PINFO); 04454 PINFO << "VRMLGroupDesc::getFieldAndDesc : : request internal " 04455 << szFieldname 04456 << std::endl; 04457 #endif 04458 04459 pField = pNode->getField("children"); 04460 04461 if(pField != NULL) 04462 pDesc = pNode->getType().findFieldDescription("children"); 04463 } 04464 else 04465 { 04466 VRMLNodeDesc::getFieldAndDesc(pGroup, 04467 szFieldname, 04468 pField, 04469 pDesc); 04470 } 04471 04472 #ifdef OSG_DEBUG_VRML 04473 decIndent(); 04474 #endif 04475 }
|
|
||||||||||||||||
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4480 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_pGenAtt, osg::VRMLNodeDesc::_pNodeCoreProto, osg::VRMLNodeDesc::_pNodeProto, osg::beginEditCP(), osg::AttachmentContainerPtr::dcast(), osg::NodePtr::dcast(), osg::endEditCP(), osg::VRMLNodeDesc::getIndent(), osg::VRMLNodeDesc::incIndent(), osg::indentLog(), osg::NullFC, and PINFO. 04484 { 04485 FieldContainerPtr pFC = NullFC; 04486 NodePtr pNode = NullFC; 04487 NodeCorePtr pNodeCore = NullFC; 04488 GenericAttPtr pAtt = NullFC; 04489 04490 if(_pNodeProto != NullFC) 04491 { 04492 FieldContainerPtr pAttClone = _pGenAtt->emptyCopy(); 04493 04494 pAtt = GenericAttPtr::dcast(pAttClone); 04495 04496 if(pAtt != NullFC) 04497 { 04498 pAtt->setInternal(true); 04499 } 04500 04501 pFC = _pNodeProto->shallowCopy(); 04502 04503 pNode = NodePtr::dcast(pFC); 04504 04505 pFC = _pNodeCoreProto->shallowCopy(); 04506 04507 pNodeCore = NodeCorePtr::dcast(pFC); 04508 04509 beginEditCP(pNode); 04510 { 04511 pNode ->setCore (pNodeCore); 04512 pNodeCore->addAttachment(pAtt); 04513 } 04514 endEditCP (pNode); 04515 } 04516 04517 #ifdef OSG_DEBUG_VRML 04518 indentLog(getIndent(), PINFO); 04519 PINFO << "Begin Group " << &(*pNode) << std::endl; 04520 04521 incIndent(); 04522 #endif 04523 04524 return pNode; 04525 }
|
|
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4527 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::decIndent(), osg::VRMLNodeDesc::getIndent(), osg::indentLog(), and PINFO. 04528 { 04529 #ifdef OSG_DEBUG_VRML 04530 decIndent(); 04531 04532 indentLog(getIndent(), PINFO); 04533 PINFO << "End Group " 04534 << &(*pFC) << std::endl; 04535 #endif 04536 }
|
|
|
Reimplemented from osg::VRMLNodeDesc. Definition at line 4541 of file OSGVRMLNodeDescs.cpp.
|
|
|
|
|
|
|
|
|
Definition at line 150 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_uiIndent. Referenced by osg::VRMLFile::createStandardPrototypes(), osg::VRMLFile::scanFile(), osg::VRMLFile::scanStandardPrototypes(), and osg::VRMLFile::scanStream(). 00151 { 00152 _uiIndent = 0; 00153 }
|
|
|
Reimplemented in osg::VRMLMaterialDesc, osg::VRMLTextureTransformDesc, osg::VRMLImageTextureDesc, osg::VRMLPixelTextureDesc, and osg::VRMLViewpointDesc. Definition at line 205 of file OSGVRMLNodeDescs.cpp. Referenced by osg::VRMLFile::beginNode().
|
|
|
Definition at line 209 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_bSaveOnEnd, and osg::VRMLNodeDesc::_szCurrentName. Referenced by osg::VRMLFile::beginNode(). 00210 { 00211 _szCurrentName = szName; // does that make a copy? I expect it to... 00212 _bSaveOnEnd = true; 00213 }
|
|
|
Definition at line 215 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_bSaveOnEnd. Referenced by osg::VRMLFile::endNode(). 00216 { 00217 _bSaveOnEnd = false; 00218 }
|
|
|
Definition at line 220 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_bSaveOnEnd. Referenced by osg::VRMLFile::endNode(). 00221 { 00222 return _bSaveOnEnd; 00223 }
|
|
|
Definition at line 225 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_szCurrentName. Referenced by osg::VRMLFile::endNode(). 00226 { 00227 return _szCurrentName.c_str(); 00228 }
|
|
|
Reimplemented in osg::VRMLAppearanceDesc. Definition at line 230 of file OSGVRMLNodeDescs.cpp. References osg::NullFC. Referenced by osg::VRMLFile::endNode(). 00231 { 00232 return NullFC; 00233 }
|
|
|
Definition at line 238 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_pGenAtt, osg::VRMLNodeDesc::_pNodeCoreProto, and osg::VRMLNodeDesc::_pNodeProto. Referenced by osg::VRMLNodeDesc::prototypeAddField(). 00239 { 00240 return getField(_pNodeProto, _pNodeCoreProto, _pGenAtt, szFieldname); 00241 }
|
|
||||||||||||||||||||
|
Definition at line 604 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::decIndent(), osg::VRMLNodeDesc::getIndent(), osg::VRMLNodeDesc::incIndent(), osg::indentLog(), osg::NullFC, and PINFO. 00608 { 00609 Field *returnValue = NULL; 00610 00611 if(szFieldname == NULL) 00612 { 00613 return returnValue; 00614 } 00615 00616 #ifdef OSG_DEBUG_VRML 00617 indentLog(getIndent(), PINFO); 00618 PINFO << "VRMLNodeDesc::getField " << std::endl; 00619 00620 incIndent(); 00621 00622 indentLog(getIndent(), PINFO); 00623 PINFO << "Trying to find field : " << szFieldname << std::endl; 00624 #endif 00625 00626 if(pFC1 != NullFC) 00627 { 00628 returnValue = pFC1->getField(szFieldname); 00629 } 00630 00631 #ifdef OSG_DEBUG_VRML 00632 incIndent(); 00633 00634 indentLog(getIndent(), PINFO); 00635 PINFO << "Got this from node : " << returnValue << std::endl; 00636 #endif 00637 00638 if(returnValue != NULL) 00639 return returnValue; 00640 00641 if(pFC2 != NullFC) 00642 { 00643 returnValue = pFC2->getField(szFieldname); 00644 00645 #ifdef OSG_DEBUG_VRML 00646 indentLog(getIndent(), PINFO); 00647 PINFO << "Got this from nodecore : " << returnValue << std::endl; 00648 #endif 00649 } 00650 else 00651 { 00652 #ifdef OSG_DEBUG_VRML 00653 indentLog(getIndent(), PINFO); 00654 PINFO << "No core to check" << std::endl; 00655 #endif 00656 } 00657 00658 00659 if(returnValue != NULL) 00660 return returnValue; 00661 00662 if(pGenAtt != NullFC) 00663 { 00664 returnValue = pGenAtt->getField(szFieldname); 00665 } 00666 00667 #ifdef OSG_DEBUG_VRML 00668 indentLog(getIndent(), PINFO); 00669 PINFO << "Got this from attachment : " << returnValue << std::endl; 00670 00671 decIndent(); 00672 decIndent(); 00673 #endif 00674 00675 return returnValue; 00676 }
|
|
|
Definition at line 474 of file OSGVRMLNodeDescs.cpp. References osg::VRMLNodeDesc::_pCurrField, and osg::Field::pushValueByStr(). 00475 { 00476 if(_pCurrField != NULL) 00477 { 00478 _pCurrField->pushValueByStr(szFieldVal); 00479 } 00480 }
|
|
||||||||||||
|
Reimplemented in osg::VRMLGeometryDesc, osg::VRMLGeometryPointSetDesc, and osg::VRMLPixelTextureDesc. Definition at line 548 of file OSGVRMLNodeDescs.cpp. References osg::Field::pushValueByStr(). Referenced by osg::VRMLFile::addFieldValue(). 00550 { 00551 if(pField != NULL) 00552 { 00553 pField->pushValueByStr(szFieldVal); 00554 } 00555 }
|
|
|
Reimplemented in osg::VRMLAppearanceDesc. Definition at line 557 of file OSGVRMLNodeDescs.cpp. Referenced by osg::VRMLFile::use().
|
|
|
Definition at line 1546 of file OSGVRMLNodeDescs.h. Referenced by prototypeAddField(). |
|
|
Definition at line 1547 of file OSGVRMLNodeDescs.h. Referenced by prototypeAddField(). |
|
|
Definition at line 1549 of file OSGVRMLNodeDescs.h. Referenced by getFieldAndDesc(). |
|
|
Definition at line 1550 of file OSGVRMLNodeDescs.h. Referenced by getFieldAndDesc(). |
|
|
Definition at line 123 of file OSGVRMLNodeDescs.cpp. Referenced by osg::VRMLNodeDesc::decIndent(), osg::VRMLNodeDesc::getIndent(), osg::VRMLNodeDesc::incIndent(), and osg::VRMLNodeDesc::resetIndent(). |
|
|
Definition at line 307 of file OSGVRMLNodeDescs.h. |
|
|
|
|
|
|
Definition at line 316 of file OSGVRMLNodeDescs.h. Referenced by osg::VRMLNodeDesc::getSavename(), and osg::VRMLNodeDesc::setOnEndSave(). |
|
|
Definition at line 317 of file OSGVRMLNodeDescs.h. Referenced by osg::VRMLNodeDesc::clearOnEndSave(), osg::VRMLNodeDesc::getOnEndSave(), and osg::VRMLNodeDesc::setOnEndSave(). |
1.4.3