The Traits class
The osg::GraphicsContext::Traits
class can set up properties of a specific graphics context. This is different from the osg::DisplaySettings
class, which manages the characteristics of all newly-created cameras' graphics contexts. Instead of a number of setting and getting property methods, the traits class uses public class member variables to indicate a property. This will take effect once the createGraphicsContext()
is called. The main components of the traits are listed in the following table:
Member attribute |
Data type |
Default value |
Description |
---|---|---|---|
|
|
0 |
The initial horizontal position of the graphics context |
|
|
0 |
The initial vertical position of the graphics context |
|
|
0 |
The width of the graphics context ... |
Get OpenSceneGraph 3.0 now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.