#include <OSGXWindowBase.h>
Inheritance diagram for osg::XWindowBase:

Extension handling | |
| bool | hasExtension (UInt32 id) |
| bool | hasExtension (const Char8 *s) |
| void * | getFunction (UInt32 id) |
| void * | getFunctionNoCheck (UInt32 id) |
| void | dumpExtensions (void) |
| GLExtensionFunction | getFunctionByName (const Char8 *s) |
| Real32 | getConstantValue (GLenum val) |
| const Vec2f & | getConstantValuev (GLenum val) |
| const std::vector< std::string > & | getRegisteredFunctions (void) |
| const std::vector< std::string > & | getExtensions (void) |
| const std::vector< std::string > & | getIgnoredExtensions (void) |
| *static void | setGLLibraryName (const Char8 *s) |
| static Int32 | getExtensionId (const Char8 *s) |
| static bool | hasCommonExtension (UInt32 id) |
| static const std::vector< std::string > & | getRegisteredExtensions (void) |
GL object handling | |
| *void | validateGLObject (UInt32 id) |
| void | validateAllGLObjects (void) |
| GLObjectStatusE | getGLObjectStatus (UInt32 id) |
| void | setGLObjectId (UInt32 id, UInt32 id2) |
| UInt32 | getGLObjectId (UInt32 id) |
| static void | refreshGLObject (UInt32 id) |
| static void | reinitializeGLObject (UInt32 id) |
| static void | destroyGLObject (UInt32 id, UInt32 num=1) |
| static void | unpackIdStatus (UInt32 idstatus, UInt32 &id, GLObjectStatusE &status) |
GL object handling | |
| void | doInitRegisterGLObject (UInt32 id, UInt32 num) |
| *static void | initRegisterGLObject (UInt32 id, UInt32 num) |
| static UInt32 | packIdStatus (UInt32 id, GLObjectStatusE status) |
Public Types | |
| typedef XWindowPtr | Ptr |
| enum | { DisplayFieldId = Inherited::NextFieldId, WindowFieldId = DisplayFieldId + 1, ContextFieldId = WindowFieldId + 1, NextFieldId = ContextFieldId + 1 } |
| typedef ArgsCollector< UInt32 > | GLObjectFunctorArgs |
| typedef TypedVoidFunctor2Base< PtrCallArg< Window >, GLObjectFunctorArgs > | GLObjectFunctor |
| typedef void(* | GLExtensionFunction )(void) |
| enum | GLObjectStatusE { notused = 1, initialize, reinitialize, initialized, needrefresh, destroy, finaldestroy } |
| enum | { statusShift = 3, statusMask = 7 } |
Public Member Functions | |
FieldContainer Get | |
| *virtual FieldContainerType & | getType (void) |
| virtual const FieldContainerType & | getType (void) const |
| virtual UInt32 | getContainerSize (void) const |
Field Get | |
| *SFDisplayP * | getSFDisplay (void) |
| Get the XWindow::_sfDisplay field. | |
| SFX11Window * | getSFWindow (void) |
| Get the XWindow::_sfWindow field. | |
| SFGLXContext * | getSFContext (void) |
| Get the XWindow::_sfContext field. | |
| DisplayP & | getDisplay (void) |
| Get the value of the XWindow::_sfDisplay field. | |
| const DisplayP & | getDisplay (void) const |
| Get the value of the XWindow::_sfDisplay field. | |
| X11Window & | getWindow (void) |
| Get the value of the XWindow::_sfWindow field. | |
| const X11Window & | getWindow (void) const |
| Get the value of the XWindow::_sfWindow field. | |
| GLXContext & | getContext (void) |
| Get the value of the XWindow::_sfContext field. | |
| const GLXContext & | getContext (void) const |
| Get the value of the XWindow::_sfContext field. | |
Field Set | |
| *void | setDisplay (const DisplayP &value) |
| Set the value of the XWindow::_sfDisplay field. | |
| void | setWindow (const X11Window &value) |
| Set the value of the XWindow::_sfWindow field. | |
| void | setContext (const GLXContext &value) |
| Set the value of the XWindow::_sfContext field. | |
Binary Access | |
| *virtual UInt32 | getBinSize (const BitVector &whichField) |
| virtual void | copyToBin (BinaryDataHandler &pMem, const BitVector &whichField) |
| virtual void | copyFromBin (BinaryDataHandler &pMem, const BitVector &whichField) |
Copy | |
| *virtual FieldContainerPtr | shallowCopy (void) const |
Static Public Member Functions | |
Class Get | |
| *static FieldContainerType & | getClassType (void) |
| access the type of the class | |
| static UInt32 | getClassTypeId (void) |
| access the numerical type of the class | |
Construction | |
| *static XWindowPtr | create (void) |
| create a new instance of the class | |
| static XWindowPtr | createEmpty (void) |
| create an empty new instance of the class, do not copy the prototype | |
Static Public Attributes | |
| static const osg::BitVector | DisplayFieldMask |
| static const osg::BitVector | WindowFieldMask |
| static const osg::BitVector | ContextFieldMask |
| static const osg::BitVector | MTInfluenceMask |
| static const Real32 | unknownConstant = -1e100 |
| static const osg::BitVector | WidthFieldMask |
| static const osg::BitVector | HeightFieldMask |
| static const osg::BitVector | PortFieldMask |
| static const osg::BitVector | ResizePendingFieldMask |
| static const osg::BitVector | GlObjectEventCounterFieldMask |
| static const osg::BitVector | GlObjectLastRefreshFieldMask |
| static const osg::BitVector | GlObjectLastReinitializeFieldMask |
| static const BitVector | AttachmentsFieldMask |
| static const BitVector | NextFieldMask |
Protected Member Functions | |
Constructors | |
| * | XWindowBase (void) |
| XWindowBase (const XWindowBase &source) | |
Destructors | |
| *virtual | ~XWindowBase (void) |
Sync | |
| *void | executeSyncImpl (XWindowBase *pOther, const BitVector &whichField) |
| virtual void | executeSync (FieldContainer &other, const BitVector &whichField) |
Protected Attributes | |
Fields | |
| *SFDisplayP | _sfDisplay |
| SFX11Window | _sfWindow |
| SFGLXContext | _sfContext |
Private Types | |
| typedef Window | Inherited |
Private Member Functions | |
| void | operator= (const XWindowBase &source) |
Static Private Attributes | |
| static FieldDescription * | _desc [] |
| XWindow description. | |
| static FieldContainerType | _type |
Friends | |
| class | FieldContainer |
Definition at line 83 of file OSGXWindowBase.h.
|
|
Reimplemented from osg::Window. Reimplemented in osg::XWindow, osg::QTWindow, and osg::QTWindowBase. Definition at line 87 of file OSGXWindowBase.h. |
|
|
Reimplemented from osg::WindowBase. Definition at line 92 of file OSGXWindowBase.h. |
|
|
Definition at line 96 of file OSGWindow.h. |
|
|
Definition at line 99 of file OSGWindow.h. |
|
|
Definition at line 101 of file OSGWindow.h. |
|
|
Reimplemented from osg::Window. Definition at line 94 of file OSGXWindowBase.h. 00095 { 00096 DisplayFieldId = Inherited::NextFieldId, 00097 WindowFieldId = DisplayFieldId + 1, 00098 ContextFieldId = WindowFieldId + 1, 00099 NextFieldId = ContextFieldId + 1 00100 };
|
|
|
Enumeration values for the status of the GL objects. This is primarily used to signal the object's callback functions what to do. See OpenGL Objects & Extension Handling for a description.
Definition at line 78 of file OSGWindow.h. 00079 { 00080 notused = 1, 00081 initialize, 00082 reinitialize, 00083 initialized, 00084 needrefresh, 00085 destroy, 00086 finaldestroy 00087 };
|
|
|
Definition at line 92 of file OSGWindow.h. 00092 { statusShift = 3, statusMask = 7 };
|
|
|
Definition at line 186 of file OSGXWindowBase.cpp. 00186 : 00187 _sfDisplay (DisplayP(NULL)), 00188 _sfWindow (), 00189 _sfContext (), 00190 Inherited() 00191 { 00192 }
|
|
|
Definition at line 198 of file OSGXWindowBase.cpp. 00198 : 00199 _sfDisplay (source._sfDisplay ), 00200 _sfWindow (source._sfWindow ), 00201 _sfContext (source._sfContext ), 00202 Inherited (source) 00203 { 00204 }
|
|
|
Definition at line 208 of file OSGXWindowBase.cpp.
|
|
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 58 of file OSGXWindowBase.inl. References _type. Referenced by create(). 00059 { 00060 return _type; 00061 }
|
|
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 65 of file OSGXWindowBase.inl. References _type, and osg::TypeBase::getId(). 00066 { 00067 return _type.getId(); 00068 }
|
|
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 128 of file OSGXWindowBase.cpp. References _type. 00129 { 00130 return _type; 00131 }
|
|
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 133 of file OSGXWindowBase.cpp. References _type. 00134 { 00135 return _type; 00136 }
|
|
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 148 of file OSGXWindowBase.cpp. 00149 { 00150 return sizeof(XWindow); 00151 }
|
|
|
Definition at line 101 of file OSGXWindowBase.inl. References _sfDisplay. 00102 { 00103 return &_sfDisplay; 00104 }
|
|
|
Definition at line 108 of file OSGXWindowBase.inl. References _sfWindow. 00109 { 00110 return &_sfWindow; 00111 }
|
|
|
Definition at line 115 of file OSGXWindowBase.inl. References _sfContext. 00116 { 00117 return &_sfContext; 00118 }
|
|
|
Definition at line 123 of file OSGXWindowBase.inl. References _sfDisplay, and osg::SField< FieldTypeT, fieldNameSpace >::getValue(). Referenced by osg::XWindow::activate(), osg::XWindow::deactivate(), osg::XWindow::init(), osg::QTWindow::init(), and osg::XWindow::swap(). 00124 { 00125 return _sfDisplay.getValue(); 00126 }
|
|
|
Definition at line 130 of file OSGXWindowBase.inl. References _sfDisplay, and osg::SField< FieldTypeT, fieldNameSpace >::getValue(). 00131 { 00132 return _sfDisplay.getValue(); 00133 }
|
|
|
Definition at line 144 of file OSGXWindowBase.inl. References _sfWindow, and osg::SField< FieldTypeT, fieldNameSpace >::getValue(). Referenced by osg::XWindow::activate(), osg::XWindow::init(), and osg::XWindow::swap(). 00145 { 00146 return _sfWindow.getValue(); 00147 }
|
|
|
Definition at line 151 of file OSGXWindowBase.inl. References _sfWindow, and osg::SField< FieldTypeT, fieldNameSpace >::getValue(). 00152 { 00153 return _sfWindow.getValue(); 00154 }
|
|
|
Definition at line 165 of file OSGXWindowBase.inl. References _sfContext, and osg::SField< FieldTypeT, fieldNameSpace >::getValue(). Referenced by osg::XWindow::activate(), and osg::XWindow::init(). 00166 { 00167 return _sfContext.getValue(); 00168 }
|
|
|
Definition at line 172 of file OSGXWindowBase.inl. References _sfContext, and osg::SField< FieldTypeT, fieldNameSpace >::getValue(). 00173 { 00174 return _sfContext.getValue(); 00175 }
|
|
|
Definition at line 137 of file OSGXWindowBase.inl. References _sfDisplay, and osg::SField< FieldTypeT, fieldNameSpace >::setValue(). Referenced by osg::XWindow::init(), and osg::QTWindow::init(). 00138 { 00139 _sfDisplay.setValue(value); 00140 }
|
|
|
Definition at line 158 of file OSGXWindowBase.inl. References _sfWindow, and osg::SField< FieldTypeT, fieldNameSpace >::setValue(). Referenced by osg::QTWindow::init().
|
|
|
Definition at line 179 of file OSGXWindowBase.inl. References _sfContext, and osg::SField< FieldTypeT, fieldNameSpace >::setValue(). Referenced by osg::XWindow::init(), and osg::QTWindow::init(). 00180 { 00181 _sfContext.setValue(value); 00182 }
|
|
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 214 of file OSGXWindowBase.cpp. References _sfContext, _sfDisplay, _sfWindow, ContextFieldMask, DisplayFieldMask, osg::SField< FieldTypeT, fieldNameSpace >::getBinSize(), osg::WindowBase::getBinSize(), osg::FieldBits::NoField, and WindowFieldMask. Referenced by osg::QTWindowBase::getBinSize(). 00215 { 00216 UInt32 returnValue = Inherited::getBinSize(whichField); 00217 00218 if(FieldBits::NoField != (DisplayFieldMask & whichField)) 00219 { 00220 returnValue += _sfDisplay.getBinSize(); 00221 } 00222 00223 if(FieldBits::NoField != (WindowFieldMask & whichField)) 00224 { 00225 returnValue += _sfWindow.getBinSize(); 00226 } 00227 00228 if(FieldBits::NoField != (ContextFieldMask & whichField)) 00229 { 00230 returnValue += _sfContext.getBinSize(); 00231 } 00232 00233 00234 return returnValue; 00235 }
|
|
||||||||||||
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 237 of file OSGXWindowBase.cpp. References _sfContext, _sfDisplay, _sfWindow, ContextFieldMask, osg::SField< FieldTypeT, fieldNameSpace >::copyToBin(), osg::WindowBase::copyToBin(), DisplayFieldMask, osg::FieldBits::NoField, and WindowFieldMask. Referenced by osg::QTWindowBase::copyToBin(). 00239 { 00240 Inherited::copyToBin(pMem, whichField); 00241 00242 if(FieldBits::NoField != (DisplayFieldMask & whichField)) 00243 { 00244 _sfDisplay.copyToBin(pMem); 00245 } 00246 00247 if(FieldBits::NoField != (WindowFieldMask & whichField)) 00248 { 00249 _sfWindow.copyToBin(pMem); 00250 } 00251 00252 if(FieldBits::NoField != (ContextFieldMask & whichField)) 00253 { 00254 _sfContext.copyToBin(pMem); 00255 } 00256 00257 00258 }
|
|
||||||||||||
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 260 of file OSGXWindowBase.cpp. References _sfContext, _sfDisplay, _sfWindow, ContextFieldMask, osg::SField< FieldTypeT, fieldNameSpace >::copyFromBin(), osg::WindowBase::copyFromBin(), DisplayFieldMask, osg::FieldBits::NoField, and WindowFieldMask. Referenced by osg::QTWindowBase::copyFromBin(). 00262 { 00263 Inherited::copyFromBin(pMem, whichField); 00264 00265 if(FieldBits::NoField != (DisplayFieldMask & whichField)) 00266 { 00267 _sfDisplay.copyFromBin(pMem); 00268 } 00269 00270 if(FieldBits::NoField != (WindowFieldMask & whichField)) 00271 { 00272 _sfWindow.copyFromBin(pMem); 00273 } 00274 00275 if(FieldBits::NoField != (ContextFieldMask & whichField)) 00276 { 00277 _sfContext.copyFromBin(pMem); 00278 } 00279 00280 00281 }
|
|
|
Reimplemented in osg::QTWindowBase. Definition at line 72 of file OSGXWindowBase.inl. References osg::AttachmentContainerPtr::dcast(), getClassType(), osg::FieldContainerType::getPrototype(), osg::NullFC, and shallowCopy(). 00073 { 00074 XWindowPtr fc; 00075 00076 if(getClassType().getPrototype() != OSG::NullFC) 00077 { 00078 fc = XWindowPtr::dcast( 00079 getClassType().getPrototype()-> shallowCopy()); 00080 } 00081 00082 return fc; 00083 }
|
|
|
Reimplemented in osg::QTWindowBase. Definition at line 87 of file OSGXWindowBase.inl. References osg::FieldContainer::newPtr(). 00088 { 00089 XWindowPtr returnValue; 00090 00091 newPtr(returnValue); 00092 00093 return returnValue; 00094 }
|
|
|
Implements osg::FieldContainer. Reimplemented in osg::QTWindowBase. Definition at line 139 of file OSGXWindowBase.cpp. References osg::FieldContainer::newPtr(). Referenced by create(). 00140 { 00141 XWindowPtr returnValue; 00142 00143 newPtr(returnValue, dynamic_cast<const XWindow *>(this)); 00144 00145 return returnValue; 00146 }
|
|
||||||||||||
|
Definition at line 284 of file OSGXWindowBase.cpp. References _sfContext, _sfDisplay, _sfWindow, ContextFieldMask, DisplayFieldMask, osg::WindowBase::executeSyncImpl(), osg::FieldBits::NoField, osg::SField< FieldTypeT, fieldNameSpace >::syncWith(), and WindowFieldMask. Referenced by executeSync(), and osg::QTWindowBase::executeSyncImpl(). 00286 { 00287 00288 Inherited::executeSyncImpl(pOther, whichField); 00289 00290 if(FieldBits::NoField != (DisplayFieldMask & whichField)) 00291 _sfDisplay.syncWith(pOther->_sfDisplay); 00292 00293 if(FieldBits::NoField != (WindowFieldMask & whichField)) 00294 _sfWindow.syncWith(pOther->_sfWindow); 00295 00296 if(FieldBits::NoField != (ContextFieldMask & whichField)) 00297 _sfContext.syncWith(pOther->_sfContext); 00298 00299 00300 }
|
|
||||||||||||
|
Reimplemented from osg::WindowBase. Reimplemented in osg::QTWindowBase. Definition at line 155 of file OSGXWindowBase.cpp. References executeSyncImpl(). 00157 { 00158 this->executeSyncImpl((XWindowBase *) &other, whichField); 00159 }
|
|
|
|
|
|
Definition at line 107 of file OSGWindow.h.
|
|
||||||||||||
|
react to field changes Reimplemented from osg::AttachmentContainer. Reimplemented in osg::ClusterWindow, osg::MultiDisplayWindow, osg::SortFirstWindow, osg::PassiveWindow, osg::XWindow, and osg::QTWindow. Definition at line 399 of file OSGWindow.cpp. References osg::AttachmentContainer::changed(). Referenced by osg::XWindow::changed(), osg::PassiveWindow::changed(), and osg::ClusterWindow::changed(). 00400 { 00401 Inherited::changed(whichField, origin); 00402 }
|
|
|
Definition at line 406 of file OSGWindow.cpp. References osg::WindowBase::_mfPort, osg::MField< FieldTypeT, fieldNameSpace >::back(), osg::beginEditCP(), osg::endEditCP(), osg::NullFC, osg::ViewportBase::ParentFieldMask, and osg::MField< FieldTypeT, fieldNameSpace >::push_back(). 00407 { 00408 if(portP != NullFC) 00409 { 00410 _mfPort.push_back(portP); 00411 // CHECK CHECK 00412 // _mfPort.back()->setParent(FieldContainer::getPtr<WindowPtr>(*this)); 00413 00414 beginEditCP(portP, Viewport::ParentFieldMask); 00415 { 00416 _mfPort.back()->setParent(WindowPtr(*this)); 00417 } 00418 endEditCP (portP, Viewport::ParentFieldMask); 00419 } 00420 }
|
|
||||||||||||
|
Definition at line 422 of file OSGWindow.cpp. References osg::WindowBase::_mfPort, osg::MField< FieldTypeT, fieldNameSpace >::begin(), osg::beginEditCP(), osg::endEditCP(), osg::MField< FieldTypeT, fieldNameSpace >::insert(), osg::NullFC, and osg::ViewportBase::ParentFieldMask. 00423 { 00424 MFViewportPtr::iterator portIt = _mfPort.begin(); 00425 00426 if(portP != NullFC) 00427 { 00428 portIt += portIndex; 00429 00430 // CHECK CHECK 00431 // (*(_mfPort.insert(portIt, portP)))->setParent( 00432 // FieldContainer::getPtr<WindowPtr>(*this)); 00433 00434 beginEditCP(portP, Viewport::ParentFieldMask); 00435 { 00436 (*(_mfPort.insert(portIt, portP)))->setParent( 00437 WindowPtr(*this)); 00438 } 00439 endEditCP (portP, Viewport::ParentFieldMask); 00440 00441 } 00442 }
|
|
||||||||||||
|
Definition at line 445 of file OSGWindow.cpp. References osg::WindowBase::_mfPort, and osg::NullFC. 00446 { 00447 if(portP != NullFC) 00448 { 00449 _mfPort[portIndex]->setParent(NullFC); 00450 _mfPort[portIndex] = portP; 00451 // CHECK CHECK 00452 // _mfPort.getValue(portIndex)->setParent( 00453 // FieldContainer::getPtr<WindowPtr>(*this)); 00454 _mfPort[portIndex]->setParent( 00455 WindowPtr(*this)); 00456 } 00457 }
|
|
||||||||||||
|
|