|  | GL Studio C++ Runtime API
    | 
#include <runtime_display_frame.h>
 
  
 | Public Member Functions | |
| RuntimeDisplayFrame (const char *name, int width, int height) | |
| virtual | ~RuntimeDisplayFrame () | 
| virtual void | Clear (void) | 
| virtual GlsEyePoint * | CurrentEyePoint () | 
| virtual void | CurrentEyePoint (GlsEyePoint *eye) | 
| virtual void | Scale (float scale) | 
| virtual float | Scale (void) | 
| virtual DisplayObject * | handle (DisplayEvent *ev) | 
| virtual void | BackgroundColor (unsigned char r, unsigned char g, unsigned char b, unsigned char a) | 
| virtual void | GetBackgroundColor (unsigned char &r, unsigned char &g, unsigned char &b, unsigned char &a) | 
| virtual void | BackgroundColor (const GlsColor &color) | 
| const char * | Name (void) | 
| void | Name (char *name) | 
| virtual GlsColor | BackgroundColor (void) | 
| virtual int | FrameInterval (void) | 
| virtual void | FrameInterval (int interval) | 
| virtual Statistics * | Stats () | 
| virtual void | RecordCalculateStart (void) | 
| virtual void | RecordCalculateEnd (void) | 
| virtual void | ClearDragAndFocus () | 
| virtual bool | UpdateAnimate () | 
| virtual bool | FrameAnimate () | 
| virtual void | WaitForNextFrame () | 
| virtual void | Paint () | 
| virtual void | WidthOffset (float offset) | 
| virtual float | WidthOffset (void) | 
| virtual void | HeightOffset (float offset) | 
| virtual float | HeightOffset (void) | 
| virtual void | DepthFactor (float factor) | 
| virtual float | DepthFactor () | 
| virtual void | FOV (double fov) | 
| virtual double | FOV () | 
| virtual void | CurrentView (const int view) | 
| virtual int | CurrentView (void) const | 
| void | Invalidate () override | 
| bool | IsInvalidated () const override | 
|  Public Member Functions inherited from DisplayFrame | |
| DisplayFrame (int width, int height, bool allocateObjects=true) | |
| void | ClearBitfield (GLbitfield bitField) | 
| GLbitfield | ClearBitfield () | 
| virtual void | DragObject (DisplayObject *obj) | 
| virtual DisplayObject * | DragObject (void) | 
| virtual void | ClearDrag () | 
| virtual void | FocusObject (DisplayObject *obj) | 
| virtual DisplayObject * | FocusObject (void) | 
| virtual void | ClearFocus () | 
| virtual void | MultitouchEnabled (bool enabled) | 
| virtual bool | MultitouchEnabled (void) | 
| virtual InputHandler * | GetInputHandler () | 
| virtual DisplayObject * | HandleDisplayEvent (DisplayEvent *ev) | 
| virtual void | WriteResources (const char *filename, GlsResourceFilter *filter=NULL) | 
| virtual void | ReadResources (const char *filename) | 
| virtual DistiAttributeBase & | Resource (const char *name) | 
| virtual void | GetResources (std::ostream &outstr, GlsResourceFilter *filter=NULL) | 
| virtual void | SetResources (std::istream &instr) | 
| void | SetResource (const std::string &resourceName, const std::string &resourceVal) | 
| std::string | GetResource (const std::string &resourceName) | 
| virtual char * | GetResource_CRTClean (const char *name) | 
| virtual void | GetResourceFree_CRTClean (char *memoryToFree) | 
| virtual char * | GetResources_CRTClean (GlsResourceFilter *filter) | 
| virtual void | GetResourcesFree_CRTClean (char *memoryToFree) | 
| virtual void | SetResource_CRTClean (const char *name, const char *value) | 
| virtual void | SetResources_CRTClean (const char *buf) | 
| virtual void | NotifyAttributeChanged (const AttributeName &name) override | 
| virtual InterfaceListType * | GetCppInterfaceDescription (InterfaceListType *addToThisList=NULL) | 
| virtual void | GetCppInterfaceDescriptionFree (InterfaceListType *array) | 
| void | SetTexturePaletteSize (int cnt) | 
| void | Draw (void) | 
| void | InsertObject (DisplayObject *obj, int loc) | 
| void | PushObject (DisplayObject *obj) | 
| int | Width (void) | 
| int | Height (void) | 
| void | SetWidth (int w) | 
| void | SetHeight (int h) | 
| virtual void | SetRedraw (void) | 
| bool | CullingEnabled (void) | 
| void | CullingEnabled (const bool enabled) | 
| DistiAttribDict & | FrameAttribDict (void) | 
| const DistiAttribDict & | FrameAttribDict (void) const | 
| DynamicMaterialArray & | MaterialPalette (void) | 
| ComponentLightMgr * | LightMgr (void) | 
| void | LightMgr (ComponentLightMgr *val) | 
|  Public Member Functions inherited from AttributeChangedNotifier | |
| virtual | ~AttributeChangedNotifier () | 
|  Public Member Functions inherited from WeakReferenceableMixin | |
| void | AddWeakReference (WeakReference *weakRef) override | 
| void | NotifyWeakReferenceDestroyed (WeakReference *ref) override | 
| Public Attributes | |
| GlsColor | _backgroundColor | 
|  Public Attributes inherited from DisplayFrame | |
| TexturePalette * | texturePalette | 
| SoundSystem * | _sound_player | 
| Group * | objects | 
| Protected Attributes | |
| Timer | _frameTimer | 
| float | _smoothedFrameDelay | 
| float | _width_offset | 
| float | _height_offset | 
| float | _depthFactor | 
| double | _fov | 
| double | _nearZ | 
| bool | _autoCalcNearZ | 
| double | _farZ | 
| bool | _autoCalcFarZ | 
| int | _current_view | 
| std::string | _name | 
| float | _scale | 
| unsigned int | frameInterval | 
| GlsEyePoint * | _currentEyePoint | 
| bool | _redraw | 
|  Protected Attributes inherited from DisplayFrame | |
| bool | _cullingEnabled | 
| int | _width | 
| int | _height | 
| float | _lastPickedDepth | 
| DynamicMaterialArray | _materialPalette | 
| ComponentLightMgr * | _lightMgr | 
| GLbitfield | _clearBitfield | 
| std::string | _componentHeaderFileName | 
| unsigned int | _currentCursor | 
| bool | _multitouchEnabled | 
| unsigned int | _cursorsDown | 
|  Protected Attributes inherited from WeakReferenceableMixin | |
| DynamicArray< WeakReference * > * | _weakRefs | 
| Additional Inherited Members | |
|  Static Public Member Functions inherited from DisplayFrame | |
| static void | SetOpenGLDefaultState (bool saveVal) | 
| static void | RestoreOpenGLState (void) | 
|  Protected Member Functions inherited from DisplayFrame | |
| virtual void | CurrentCursor (unsigned int cursor_id) | 
| void | CleanupDragMap () | 
| DisplayObject * | GetDragObjectForCursor (unsigned int cursorID) | 
| DisplayObject * | FindDragObject () | 
|  Protected Member Functions inherited from WeakReferenceableMixin | |
| WeakReferenceableMixin (void) | |
| virtual | ~WeakReferenceableMixin () | 
Provides basic support for runtime display frames
| RuntimeDisplayFrame | ( | const char * | name, | 
| int | width, | ||
| int | height | ||
| ) | 
Ctor for RuntimeDisplayFrame
| name | The title of the display frame. Shown in the window title bar. | 
| width | The width of the display frame window, in pixels. | 
| height | The height of the display frame window, in pixels. | 
| 
 | virtual | 
Dtor for RuntimeDisplayFrame
| 
 | virtual | 
Sets the background color of the window to the given value
| r | New red color (0-255 range) | 
| g | New green color (0-255 range) | 
| b | New blue color (0-255 range) | 
| a | New alpha color (0-255 range) | 
| 
 | virtual | 
Sets the background color of the window to the given value
| color | The new color | 
| 
 | virtual | 
Gets the background color of the window to the given value
| 
 | virtual | 
Clears the window associated with the display frame. The current _clearBitfield is used
| 
 | virtual | 
Call this before deleting objects which may be being kept by the drag or focus objects
Reimplemented from DisplayFrame.
| 
 | virtual | 
| 
 | virtual | 
Sets the current eyepoint for the display frame.
| eye | The eyepoint to use for the display frame. | 
| 
 | inlinevirtual | 
Sets the current view mode for the window
| view | The new view mode for the window. Acceptable view types are: [VIEW_EYEPOINT - The application will be viewed through an eyepoint] [VIEW_XY - The application will be viewed through a 2D orthographic view of the XY plane] [VIEW_PERSPECTIVE - The application will be viewed through a perspective projection] | 
| 
 | inlinevirtual | 
Gets the current view mode for the window.
| 
 | virtual | 
Sets the Depth Factor for the window
| factor | The depth factor. Used for autocalculating clipping planes | 
| 
 | virtual | 
Gets the Depth Factor for the window
| 
 | virtual | 
Sets the FOV (Field of View) for the window. If fov is set to 0.0, a reasonable FOV will be calculated based on width and height.
| fov | New field of view in degrees | 
| 
 | virtual | 
Gets the FOV (Field of View) for the window.
| 
 | virtual | 
Redraw the window at the Hz rate set for the DisplayFrame, or at least try to. We might be slower if the hardware can't keep up.
Reimplemented in glsDisplayFrame.
| 
 | virtual | 
Returns the Frame Interval in microseconds
| 
 | virtual | 
Sets the target Frame Interval in microseconds
| interval | The frame interval in microseconds | 
| 
 | virtual | 
Gets the background color of the window to the given value
| r | Gets red color (0-255 range) | 
| g | Gets green color (0-255 range) | 
| b | Gets blue color (0-255 range) | 
| a | Gets alpha color (0-255 range) | 
| 
 | virtual | 
Handles keyboard and mouse events and dispatches them to the display objects.
| ev | A display event | 
| 
 | virtual | 
Pans the display vertically
| offset | The new Y position of the center of the window | 
| 
 | virtual | 
Gets the vertical position of the display at the center of the window
| 
 | overridevirtual | 
Implements GlsPainter.
| 
 | overridevirtual | 
Implements GlsPainter.
| const char* Name | ( | void | ) | 
Gets the title(name) of this display frame
| void Name | ( | char * | name | ) | 
Sets the name(title) for this display frame
| name | The new title for the display frame | 
| 
 | inlinevirtual | 
Redraws the window, using the platform specific mechanism. Place holder for base class implementations. Simple implementations may draw directly, while implementations that use a window manager may tell the window manager to redraw.
Reimplemented in glsDisplayFrame, and EmbeddedDisplayFrame.
| 
 | virtual | 
Part of display frame statistics, for recording time used in Calculate()
| 
 | virtual | 
Part of display frame statistics, for recording time used in Calculate()
| 
 | virtual | 
Set the scale for the display frame.
| scale | The new scale factor. Must be non-zero. A value of zero will be ignored. | 
| 
 | virtual | 
Reimplemented from DisplayFrame.
| 
 | virtual | 
Creates and returns a pointer to a statistics object
| 
 | virtual | 
Redraws the scene if the scene has changed since the last frame, and also calls WaitForNextFrame to ensure we are not drawing faster than the set frame interval allows.
| 
 | virtual | 
Sleeps based on the Hz rate set for the DisplayFrame.
| 
 | virtual | 
Pans the display horizontally
| offset | The new X position at the center of the window | 
| 
 | virtual | 
Gets the horizontal position of the display at the center of the window
| 
 | protected | 
When true a _farZ is automatically calculated.
| 
 | protected | 
When true a _nearZ is automatically calculated.
| GlsColor _backgroundColor | 
The background clear color
| 
 | protected | 
Current view of the canvas (e.g., ortho, perspective, eyepoint)
| 
 | protected | 
The current eyepoint for viewing the scene
| 
 | protected | 
Used for auto calculations
| 
 | protected | 
Far clipping plane. Only meaningfull if _autoCalcVarZ is false
| 
 | protected | 
Field Of View. If 0.0 (the default), fov will be auto calculated.
| 
 | protected | 
Current "height" offset of window. Used for panning of display vertically in ortho mode.
| 
 | protected | 
The title of this display frame's window, if applicable
| 
 | protected | 
Near clipping plane. Only meaningful if _autoCalcNearZ is false
| 
 | protected | 
Flag indicating if the window should be redrawn
| 
 | protected | 
Scale of the window
| 
 | protected | 
for backwards compatibility Frame interval, smoothed based on actual draw performance
| 
 | protected | 
For better control over clipping and field of view, use a GlsEyePoint, but some limited functionality is available here Current "width" offset of window. Used for panning of display horizontally in ortho mode.
| 
 | protected | 
The frame interval in microSeconds (inverse of frame rate)