| GL Studio C++ Runtime API

display_frame.h
Go to the documentation of this file.
1/*! \file
2 \brief The disti::DisplayFrame class.
3
4 \par Copyright Information
5
6 Copyright (c) 2017 by The DiSTI Corporation.<br>
7 11301 Corporate Blvd; Suite 100<br>
8 Orlando, Florida 32817<br>
9 USA<br>
10 <br>
11 All rights reserved.<br>
12
13 This Software contains proprietary trade secrets of DiSTI and may not be
14 reproduced, in whole or part, in any form, or by any means of electronic,
15 mechanical, or otherwise, without the written permission of DiSTI. Said
16 permission may be derived through the purchase of applicable DiSTI product
17 licenses which detail the distribution rights of this content and any
18 Derivative Works based on this or other copyrighted DiSTI Software.
19
20 NO WARRANTY. THE SOFTWARE IS PROVIDED "AS-IS," WITHOUT WARRANTY OF ANY KIND,
21 AND ANY USE OF THIS SOFTWARE PRODUCT IS AT YOUR OWN RISK. TO THE MAXIMUM EXTENT
22 PERMITTED BY APPLICABLE LAW, DISTI AND ITS SUPPLIERS DISCLAIM ALL WARRANTIES
23 AND CONDITIONS, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
24 IMPLIED WARRANTIES AND CONDITIONS OF MERCHANTABILITY AND/OR FITNESS FOR A
25 PARTICULAR PURPOSE, TITLE, AND NON-INFRINGEMENT, WITH REGARD TO THE SOFTWARE.
26
27 LIMITATION OF LIABILITY. TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW,
28 IN NO EVENT SHALL DISTI OR ITS SUPPLIERS BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
29 INDIRECT, OR CONSEQUENTIAL DAMAGES WHATSOEVER (INCLUDING, WITHOUT LIMITATION,
30 DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS OF BUSINESS
31 INFORMATION, OR ANY OTHER PECUNIARY LOSS) ARISING OUT OF THE USE OF OR
32 INABILITY TO USE THE SOFTWARE, EVEN IF DISTI HAS BEEN ADVISED OF THE POSSIBILITY
33 OF SUCH DAMAGES. DISTI'S ENTIRE LIABILITY AND YOUR EXCLUSIVE REMEDY SHALL NOT
34 EXCEED FIVE DOLLARS (US$5.00).
35
36 The aforementioned terms and restrictions are governed by the laws of the
37 State of Florida and the United States of America.
38
39*/
40#ifndef INCLUDED_DISTI_DISPLAY_FRAME_H
41#define INCLUDED_DISTI_DISPLAY_FRAME_H
42
43#include "display.h"
44#include "gls_include.h"
45#include "gls_painter.h"
46#include "image.h"
47#include "texture_palette.h"
48#include "util.h"
49#include "vertex.h"
50#include <string.h>
51#ifndef GLS_EDITOR_CODE
52# include "message.h"
53#endif
54
55#include "disti_metadata.h"
56#include "dynamic_array.h"
57#include "input_handler.h"
58#include "material.h"
59#include "scoped_ptr.h"
60#include "sound.h"
61#include "weak_referenceable_mixin.h"
62
63 struct DragObjectMap;
64
65 namespace disti
66{
67 static const int MAX_PLAYABLE = 20; /**< Max. Number of sound files that can be played */
68
69 const char META_COMPONENT_HEADER_FILE_NAME[] = "ComponentHeaderFile"; ///< Attribute name for ComponentHeaderFile.
70
71 typedef DynamicArray<Material> DynamicMaterialArray; /**< Typedef for dynamic array of materials */
72
73 class Group;
74 class ComponentLightMgr;
75
76 template<class>
77 class EventCompressor;
78
79/** The base class for associating a display device with an object list.
80 *
81 * DisplayFrame contains all of the display objects, texture, and fonts for
82 * an application.
83 *
84 */
85 class DisplayFrame : virtual public AttributeChangedNotifier
86 , virtual public WeakReferenceableMixin
87{
88 private:
89 DistiAttribDict* _frameAttribDict; /**< Stores all of the attributes specific to the DisplayFrame */
90 ScopedPtr<InputHandler> _inputHandler;
91
92 protected:
93 bool _cullingEnabled; /**< True if culling is enabled for this DisplayFrame */
94 int _width; /**< The width of the window for this display frame */
95 int _height; /**< The height of the window for this display frame */
96 float _lastPickedDepth; /**< Keeps previous picks depth for use when no pick is performed (dragging) */
97 DynamicMaterialArray _materialPalette; /**< A Dynamic array for keeping the materials for this frame */
98 ComponentLightMgr* _lightMgr; /**< The _lightMgr is used to setup lighting for the DisplayFrame */
99 GLbitfield _clearBitfield; /**< The OpenGL bitfield to use when clearing. /see glClear */
100
101 std::string _componentHeaderFileName; /**< backing store for META_COMPONENT_HEADER_FILE_NAME attribute */
102
103 DragObjectMap* _dragObjectMap; ///< Holds a focus object for each cursor.
104 unsigned int _currentCursor; /**< the current cursor being processed */
105 bool _multitouchEnabled; /**< whether or not multitouch is enabled */
106 unsigned int _cursorsDown; /**< The number of cursors (touches) that are currently down */
107
108 /** Changes the current cursor to the specified cursor id. Needed by multitouch, so that DragObject and FocusObject will return
109 * the correct objects for the current cursor.
110 * \param cursor_id the cursor id
111 */
112 virtual GLS_EXPORT void CurrentCursor( unsigned int cursor_id );
113
114 /** Cleanup unused entries from the drag map */
115 void CleanupDragMap();
116
117 /** Get the drag object that corresponds to the curosr
118 * \param cursorID the cursor
119 * \return the drag object or null if none exists
120 */
121 DisplayObject* GetDragObjectForCursor( unsigned int cursorID );
122
123 /** Find a non-null drag object from the _dragObjectMap if on exists
124 * \return a drag object, or null if there aren't any in the map
125 */
126 DisplayObject* FindDragObject();
127
128 /// Get the event compressor for this display frame, if it exists
129 /// \return The event compressor.
130 virtual GLS_EXPORT EventCompressor<DisplayFrame>* GetEventCompressor() { return NULL; };
131
132 /** \return The current scale for the display frame
133 */
134 virtual GLS_EXPORT float Scale() { return 1.0f; }
135
136 public:
137 TexturePalette* texturePalette; /**< An array of textures allocated for display on objects */
138 SoundSystem* _sound_player; /**< Sound file player for this DisplayFrame */
139 Group* objects; /**< The object hierarchy for this display frame */
140
141 /** Creates a new display frame
142 * \param width The width of this display frame in pixels
143 * \param height The height of this display frame in pixels
144 * \param allocateObjects
145 */
146 GLS_EXPORT DisplayFrame( int width, int height, bool allocateObjects = true );
147
148 virtual GLS_EXPORT ~DisplayFrame();
149
150 /** Sets the OpenGL clear bitmask that will be used when the window is cleared
151 * \param bitField The OpenGL bitfield to use when clearing. /see glClear
152 */
153 inline void ClearBitfield( GLbitfield bitField ) { _clearBitfield = bitField; }
154
155 /** Gets the OpenGL clear bitmask that will be used when the window is cleared
156 * \return The OpenGL bitfield to use when clearing. /see glClear
157 */
158 inline GLbitfield ClearBitfield() { return _clearBitfield; }
159
160 /** Sets the current "Drag" object for the current cursor
161 * \param obj The new DragObject
162 */
163 virtual GLS_EXPORT void DragObject( DisplayObject* obj );
164
165 /** Gets the current "Drag" object for the current cursor
166 * \return The current DragObject
167 */
168 virtual GLS_EXPORT DisplayObject* DragObject();
169
170 /** Clears the drag objects for all cursors.*/
171 virtual GLS_EXPORT void ClearDrag();
172
173 /// Sets the current focus object for the current cursor.
174 /// \param obj The new focus object to set.
175 virtual GLS_EXPORT void FocusObject( DisplayObject* obj );
176
177 /** Gets the current "Focus" object for the current cursor
178 * \return The current FocusObject
179 */
180 virtual GLS_EXPORT DisplayObject* FocusObject();
181
182 /** Clears the focus objects for all cursors.*/
183 virtual GLS_EXPORT void ClearFocus();
184
185 /// Enables/Disables multitouch on the display frame. Multitouch is enabled by default.
186 /// This function has no effect on platforms that do not support multitouch.
187 /// \param enabled The new multitouch state to set.
188 virtual GLS_EXPORT void MultitouchEnabled( bool enabled );
189
190 /// \return Whether or not multitouch is enabled on the display frame.
191 virtual GLS_EXPORT bool MultitouchEnabled();
192
193 /// \return The input handler for this component.
194 virtual GLS_EXPORT InputHandler* GetInputHandler();
195
196 /// Handles a display event.Picks an object and also tracks focus.
197 /// \param ev The display event to be handled.
198 /// \return A pointer to the object that received the event, otherwise NULL.
199 virtual GLS_EXPORT DisplayObject* HandleDisplayEvent( DisplayEvent* ev );
200
201 /** Write the resources (attributes) of the objects in this display frame to the specified file
202 * \param filename Name of the file to write to
203 * \param filter A filter to specify which attributes to write
204 */
205 virtual GLS_EXPORT void WriteResources( const char* filename, GlsResourceFilter* filter = NULL );
206
207 /** Read the resources (attributes) of the objects in this display frame from the specified file
208 * \param filename Name of the file to read from
209 */
210 virtual GLS_EXPORT void ReadResources( const char* filename );
211
212 /// Gets a reference to the specified attribute for reading and writing.
213 /// This reference can be streamed into and out of variables.
214 /// This can access different levels of objects.
215 /// For example:
216 /// The DisplayFrame:
217 /// Resource("ComponentHeaderFile") >> someStdString;
218 /// An object in the DisplayFrame:
219 /// Resource("SomeObject.Visible") << someBool;
220 /// An object in a Component in this DisplayFrame:
221 /// Resource("SomeComponentObject.SomeObject.Visible") >> someBool;
222 /// \param name The name of the attribute to get.
223 /// \return A reference to the requested attribute if available, otherwise DistiEmptyAttribute.
224 virtual GLS_EXPORT DistiAttributeBase& Resource( const char* name );
225
226 /** Get the resources for this display frame and all it's children acording to the filter
227 * \param outstr The stream to write to
228 * \param filter The filter to control what gets written.
229 */
230 virtual GLS_EXPORT void GetResources( std::ostream& outstr, GlsResourceFilter* filter = NULL );
231
232 /** Parse a stream of resource value pairs.
233 * \param instr Stream containing the resource data
234 */
235 virtual GLS_EXPORT void SetResources( std::istream& instr );
236
237 /** Sets a DisplayFrame resource value.
238 * \param resourceName Name of the resource to set.
239 * \param resourceVal Value of the resource to set
240 */
241 inline void SetResource( const std::string& resourceName, const std::string& resourceVal )
242 {
243 SetResource_CRTClean( resourceName.c_str(), resourceVal.c_str() );
244 }
245
246 /// Sets a DisplayFrame resource value.
247 /// \param resourceName Name of the resource to set.
248 /// \param resourceVal Value of the resource to set.
249 inline void SetResource( const char* resourceName, const char* resourceVal )
250 {
251 SetResource_CRTClean( resourceName, resourceVal );
252 }
253
254 /// Gets a DisplayFrame resource value.
255 /// \param resourceName Name of the resource to set.
256 /// \return The string value of the requested resource, empty string if not available.
257 inline std::string GetResource( const std::string& resourceName )
258 {
259 char* value = GetResource_CRTClean( resourceName.c_str() );
260 std::string stringVal = value;
261 GetResourceFree_CRTClean( value );
262 return stringVal;
263 }
264
265 /// Gets a DisplayFrame resource value.
266 /// \param resourceName Name of the resource to set.
267 /// \return The string value of the requested resource, empty string if not available.
268 inline std::string GetResource( const char* resourceName )
269 {
270 char* value = GetResource_CRTClean( resourceName );
271 std::string stringVal = value;
272 GetResourceFree_CRTClean( value );
273 return stringVal;
274 }
275
276 /** CRT Insensitive version of GetResource()
277 * Version with streams can not be called from differently compiled code.
278 * \param name name of resource
279 * \return The requested value allocated as a char array.
280 * The user MUST call GetResourceFree() when finished using returned value.
281 */
282 virtual GLS_EXPORT char* GetResource_CRTClean( const char* name );
283
284 /** Frees the memory allocated by a previous GetResource_CRTClean call
285 * \param memoryToFree Pointer to memory allocated by GetResource_CRTClean
286 */
287 virtual GLS_EXPORT void GetResourceFree_CRTClean( char* memoryToFree );
288
289 /** CRT Insensitive version of GetResources()
290 * \param filter The filter to control what gets written
291 * \return A null terminated char* containing the requested resources
292 * The user MUST call GetResourcesFree() on the returned value.
293 */
294 virtual GLS_EXPORT char* GetResources_CRTClean( GlsResourceFilter* filter );
295
296 /** Frees the memory allocated by a previous GetResources_CRTClean call
297 * \param memoryToFree Pointer to memory allocated by GetResource_CRTClean
298 */
299 virtual GLS_EXPORT void GetResourcesFree_CRTClean( char* memoryToFree );
300
301 /** CRT Insensitive version of SetResource()
302 * Version with streams can not be called from differently compiled code.
303 * \param name name of resource
304 * \param value new value for resource
305 */
306 virtual GLS_EXPORT void SetResource_CRTClean( const char* name, const char* value );
307
308 /** CRT Insensitive version of SetResources()
309 * Parse a buffer of resource value pairs.
310 * \param buf String containing resource data
311 */
312 virtual GLS_EXPORT void SetResources_CRTClean( const char* buf );
313
314 /** Implements AttributeChangedNotifier::NotifyAttributeChanged.
315 * Notify the class that the attribute has changed. Observers of the attribute will have their callbacks called
316 * \param name the name of the attribute
317 */
318 virtual GLS_EXPORT void NotifyAttributeChanged( const AttributeName& name ) DISTI_METHOD_OVERRIDE;
319
320#ifndef GLES
321 /** Get the details of the Cpp Interface
322 * The actual interface is exposed in compiled code.
323 * \param addToThisList A list to add to and then return. Creates a new one if NULL.
324 * \return A templated list.
325 * The caller must call the corresponding free method to
326 * safely free the memory.
327 */
328 virtual GLS_EXPORT InterfaceListType* GetCppInterfaceDescription( InterfaceListType* addToThisList = NULL );
329
330 /** Frees the memory allocated by a previous GetCppInterfaceDescription call
331 * \param array Pointer to memory allocated by GetCppInterfaceDescription
332 */
333 virtual GLS_EXPORT void GetCppInterfaceDescriptionFree( InterfaceListType* array );
334#endif
335
336 /** Sets the texture palette size for this display frame
337 * \param cnt The number of entries to have in the display frame
338 */
339 GLS_EXPORT void SetTexturePaletteSize( int cnt );
340
341 /** Draw the objects contained in this display frame */
342 GLS_EXPORT void Draw();
343
344 /** Adds the specified object into the group, at the end of the list
345 * \param obj A pointer to the object to add
346 * \param reparent Whether or not the object parent should be set to this group
347 * \param recalculateBoundingbox Whether or not to recalculate the bounding box
348 * \param loc Where to insert it (defaults to -1 which means at the end of the list)
349 */
350 GLS_EXPORT void InsertObject( DisplayObject* obj, bool reparent = true, bool recalculateBoundingbox = true, int loc = -1 );
351
352 /** Inserts a display object into this display frame at the specified
353 * index in the object list.
354 * \param obj The object to insert
355 * \param loc Where to insert the object
356 */
357 GLS_EXPORT void InsertObject( DisplayObject* obj, int loc );
358
359 /** Inserts a display object into this display frame at the end
360 * of the object list.
361 * \param obj The object to insert
362 */
363 GLS_EXPORT void PushObject( DisplayObject* obj );
364
365 /** Gets the width in pixels of this display frame
366 * \return The width in pixels of this display frame
367 */
368 GLS_EXPORT int Width();
369
370 /** Gets the height in pixels of this display frame
371 * \return The height in pixels of this display frame
372 */
373 GLS_EXPORT int Height();
374
375 /** Sets the width in pixels of this display frame
376 * \param w The new width in pixels of this display frame
377 */
378 GLS_EXPORT void SetWidth( int w );
379
380 /** Sets the height in pixels of this display frame
381 * \param h The new height in pixels of this display frame
382 */
383 GLS_EXPORT void SetHeight( int h );
384
385 /** Does nothing here in the base class. Allows other display
386 * frames to add functionality.
387 * \deprecated Should not be called by new code.
388 */
389 virtual GLS_EXPORT void SetRedraw() {}
390
391 /** Gets the whether or not culling is enabled for this display frame
392 * \return whether or not culling is enabled for this display frame
393 */
394 GLS_EXPORT bool CullingEnabled();
395
396 /** Sets the whether or not culling is enabled for this display frame
397 * \param enabled whether or not culling is enabled for this display frame
398 */
399 GLS_EXPORT void CullingEnabled( const bool enabled );
400
401 /** Sets up the OpenGL Pipeline to the state expected by GL Studio drawing.
402 * resetTemplate is used to not reset certain catagories. For example, it may
403 * be desirable for a GL Studio object to receive lighting from it's VegaPrime scene.
404 * \param saveVal Whether or not to save values. If true, this will call
405 * glPushClientAttrib(GL_CLIENT_ALL_ATTRIB_BITS) and glPushAttrib(GL_ALL_ATTRIB_BITS). You should call
406 * RestoreOpenGLState() after drawing to pop the attributes.
407 */
408 static GLS_EXPORT void SetOpenGLDefaultState( bool saveVal );
409
410 /** Call this after calling SetOpenGLDefaultState with saveVal == true.
411 * DO NOT call this after calling SetOpenGLDefaultState with saveVal == false
412 * because this will pop the attribute stack.
413 */
414 static GLS_EXPORT void RestoreOpenGLState();
415
416 /** \return A reference to the Attribute dictionary for this display frame */
417 inline DistiAttribDict& FrameAttribDict() { return *_frameAttribDict; }
418
419 /** \return A const reference to the Attribute dictionary for this display frame */
420 inline const DistiAttribDict& FrameAttribDict() const { return *_frameAttribDict; }
421
422 /** \return A reference to the material palette for this display frame */
423 inline DynamicMaterialArray& MaterialPalette() { return _materialPalette; }
424
425 /** \return A pointer to the light manager for this display frame */
426 inline ComponentLightMgr* LightMgr() { return _lightMgr; }
427
428 /** Sets the light manager for this display frame.
429 * This is used only for very special cases.
430 * The current LightMgr is NOT deleted when the new one is set.
431 * If this is used, it is recommended to restore the value to
432 * the original value.
433 * \param val The pointer to the new light manger.
434 */
435 inline void LightMgr( ComponentLightMgr* val ) { _lightMgr = val; }
436
437 /** Call this before deleting objects which may be being kept
438 * by the drag or focus objects.
439 * If an object is to be deleted. The user must ensure that it is not
440 * being used as the drag or focus object. If it is, a leave event may
441 * be sent to it after it has been deleted, causing a crash.
442 * To avoid this the user can either ensure that the object never handles mouse events,
443 * or call ClearDragAndFocus() imediatly before deleting them */
444 virtual GLS_EXPORT void ClearDragAndFocus();
445};
446
447} // namespace disti
448
449#endif
disti::AttributeChangedNotifier
Definition: disti_metadata.h:521
disti::AttributeName
Definition: disti_metadata.h:87
disti::ComponentLightMgr
Definition: component_light_mgr.h:56
disti::DisplayEvent
Definition: events.h:113
disti::DisplayFrame
Definition: display_frame.h:87
disti::DisplayFrame::texturePalette
TexturePalette * texturePalette
Definition: display_frame.h:137
disti::DisplayFrame::DragObject
virtual DisplayObject * DragObject()
disti::DisplayFrame::_currentCursor
unsigned int _currentCursor
Definition: display_frame.h:104
disti::DisplayFrame::PushObject
void PushObject(DisplayObject *obj)
disti::DisplayFrame::MultitouchEnabled
virtual bool MultitouchEnabled()
disti::DisplayFrame::FocusObject
virtual void FocusObject(DisplayObject *obj)
disti::DisplayFrame::DisplayFrame
DisplayFrame(int width, int height, bool allocateObjects=true)
disti::DisplayFrame::ClearDragAndFocus
virtual void ClearDragAndFocus()
disti::DisplayFrame::_dragObjectMap
DragObjectMap * _dragObjectMap
Holds a focus object for each cursor.
Definition: display_frame.h:103
disti::DisplayFrame::NotifyAttributeChanged
virtual void NotifyAttributeChanged(const AttributeName &name) override
disti::DisplayFrame::SetWidth
void SetWidth(int w)
disti::DisplayFrame::RestoreOpenGLState
static void RestoreOpenGLState()
disti::DisplayFrame::CullingEnabled
bool CullingEnabled()
disti::DisplayFrame::LightMgr
ComponentLightMgr * LightMgr()
Definition: display_frame.h:426
disti::DisplayFrame::_clearBitfield
GLbitfield _clearBitfield
Definition: display_frame.h:99
disti::DisplayFrame::_materialPalette
DynamicMaterialArray _materialPalette
Definition: display_frame.h:97
disti::DisplayFrame::Draw
void Draw()
disti::DisplayFrame::SetOpenGLDefaultState
static void SetOpenGLDefaultState(bool saveVal)
disti::DisplayFrame::Height
int Height()
disti::DisplayFrame::GetDragObjectForCursor
DisplayObject * GetDragObjectForCursor(unsigned int cursorID)
disti::DisplayFrame::_cullingEnabled
bool _cullingEnabled
Definition: display_frame.h:93
disti::DisplayFrame::SetResource_CRTClean
virtual void SetResource_CRTClean(const char *name, const char *value)
disti::DisplayFrame::SetHeight
void SetHeight(int h)
disti::DisplayFrame::objects
Group * objects
Definition: display_frame.h:139
disti::DisplayFrame::LightMgr
void LightMgr(ComponentLightMgr *val)
Definition: display_frame.h:435
disti::DisplayFrame::DragObject
virtual void DragObject(DisplayObject *obj)
disti::DisplayFrame::FrameAttribDict
const DistiAttribDict & FrameAttribDict() const
Definition: display_frame.h:420
disti::DisplayFrame::InsertObject
void InsertObject(DisplayObject *obj, int loc)
disti::DisplayFrame::CleanupDragMap
void CleanupDragMap()
disti::DisplayFrame::GetResources
virtual void GetResources(std::ostream &outstr, GlsResourceFilter *filter=NULL)
disti::DisplayFrame::_lightMgr
ComponentLightMgr * _lightMgr
Definition: display_frame.h:98
disti::DisplayFrame::GetResource
std::string GetResource(const char *resourceName)
Definition: display_frame.h:268
disti::DisplayFrame::SetResources_CRTClean
virtual void SetResources_CRTClean(const char *buf)
disti::DisplayFrame::GetResourceFree_CRTClean
virtual void GetResourceFree_CRTClean(char *memoryToFree)
disti::DisplayFrame::GetEventCompressor
virtual EventCompressor< DisplayFrame > * GetEventCompressor()
Definition: display_frame.h:130
disti::DisplayFrame::SetRedraw
virtual void SetRedraw()
Definition: display_frame.h:389
disti::DisplayFrame::GetResource
std::string GetResource(const std::string &resourceName)
Definition: display_frame.h:257
disti::DisplayFrame::SetResources
virtual void SetResources(std::istream &instr)
disti::DisplayFrame::GetResource_CRTClean
virtual char * GetResource_CRTClean(const char *name)
disti::DisplayFrame::WriteResources
virtual void WriteResources(const char *filename, GlsResourceFilter *filter=NULL)
disti::DisplayFrame::GetResourcesFree_CRTClean
virtual void GetResourcesFree_CRTClean(char *memoryToFree)
disti::DisplayFrame::ClearBitfield
GLbitfield ClearBitfield()
Definition: display_frame.h:158
disti::DisplayFrame::FindDragObject
DisplayObject * FindDragObject()
disti::DisplayFrame::MaterialPalette
DynamicMaterialArray & MaterialPalette()
Definition: display_frame.h:423
disti::DisplayFrame::SetResource
void SetResource(const std::string &resourceName, const std::string &resourceVal)
Definition: display_frame.h:241
disti::DisplayFrame::ClearBitfield
void ClearBitfield(GLbitfield bitField)
Definition: display_frame.h:153
disti::DisplayFrame::CurrentCursor
virtual void CurrentCursor(unsigned int cursor_id)
disti::DisplayFrame::Scale
virtual float Scale()
Definition: display_frame.h:134
disti::DisplayFrame::CullingEnabled
void CullingEnabled(const bool enabled)
disti::DisplayFrame::ClearFocus
virtual void ClearFocus()
disti::DisplayFrame::FrameAttribDict
DistiAttribDict & FrameAttribDict()
Definition: display_frame.h:417
disti::DisplayFrame::InsertObject
void InsertObject(DisplayObject *obj, bool reparent=true, bool recalculateBoundingbox=true, int loc=-1)
disti::DisplayFrame::ClearDrag
virtual void ClearDrag()
disti::DisplayFrame::_multitouchEnabled
bool _multitouchEnabled
Definition: display_frame.h:105
disti::DisplayFrame::_sound_player
SoundSystem * _sound_player
Definition: display_frame.h:138
disti::DisplayFrame::Width
int Width()
disti::DisplayFrame::SetTexturePaletteSize
void SetTexturePaletteSize(int cnt)
disti::DisplayFrame::Resource
virtual DistiAttributeBase & Resource(const char *name)
disti::DisplayFrame::_componentHeaderFileName
std::string _componentHeaderFileName
Definition: display_frame.h:101
disti::DisplayFrame::_height
int _height
Definition: display_frame.h:95
disti::DisplayFrame::FocusObject
virtual DisplayObject * FocusObject()
disti::DisplayFrame::ReadResources
virtual void ReadResources(const char *filename)
disti::DisplayFrame::MultitouchEnabled
virtual void MultitouchEnabled(bool enabled)
disti::DisplayFrame::GetInputHandler
virtual InputHandler * GetInputHandler()
disti::DisplayFrame::HandleDisplayEvent
virtual DisplayObject * HandleDisplayEvent(DisplayEvent *ev)
disti::DisplayFrame::_width
int _width
Definition: display_frame.h:94
disti::DisplayFrame::_lastPickedDepth
float _lastPickedDepth
Definition: display_frame.h:96
disti::DisplayFrame::_cursorsDown
unsigned int _cursorsDown
Definition: display_frame.h:106
disti::DisplayFrame::SetResource
void SetResource(const char *resourceName, const char *resourceVal)
Definition: display_frame.h:249
disti::DisplayFrame::GetResources_CRTClean
virtual char * GetResources_CRTClean(GlsResourceFilter *filter)
disti::DisplayObject
Definition: display.h:96
disti::DistiAttribDict
Definition: disti_metadata.h:750
disti::DistiAttributeBase
Definition: disti_metadata.h:220
disti::DynamicArray< Material >
disti::EventCompressor
Definition: events.h:662
disti::GlsResourceFilter
Definition: gls_resources.h:51
disti::Group
Definition: group.h:53
disti::InputHandler
Definition: input_handler.h:186
disti::ScopedPtr
Definition: scoped_ptr.h:54
disti::SoundSystem
Definition: sound.h:51
disti::TexturePalette
Definition: texture_palette.h:186
disti::WeakReferenceableMixin
Definition: weak_referenceable_mixin.h:53
display.h
The disti::DisplayObject class and global enumerations.
disti_metadata.h
The disti metadata.
dynamic_array.h
The disti::DynamicArray class. A templated array of objects capable of dynamically growing.
DISTI_METHOD_OVERRIDE
#define DISTI_METHOD_OVERRIDE
Macro to wrap the override keyword, removed on compilers that don't support it.
Definition: gls_cpp_lang_support.h:222
gls_include.h
A file for all GL Studio files to include.
GLS_EXPORT
#define GLS_EXPORT
Macro denoting which functions should be visible from the runtime library.
Definition: gls_include.h:52
gls_painter.h
The GlsPainter interface.
image.h
The Image class. All textures are converted internally into Images.
input_handler.h
The input handler interface.
material.h
The disti::Material class.
message.h
The Message functions. Implements Messages to the user in the form of pop-up dialog boxes,...
disti
Definition: bmpimage.h:47
disti::DynamicMaterialArray
DynamicArray< Material > DynamicMaterialArray
Definition: display_frame.h:71
disti::META_COMPONENT_HEADER_FILE_NAME
const char META_COMPONENT_HEADER_FILE_NAME[]
Attribute name for ComponentHeaderFile.
Definition: display_frame.h:69
scoped_ptr.h
A smart pointer with unique ownership – poor man's std::unique_ptr.
sound.h
The SoundSystem class for playback of audio files.
texture_palette.h
The disti::TexturePalette class.
util.h
Generally useful defines, macros, enumerations and function prototypes.
vertex.h
The disti::Vertex class. A class for manipulating 3D vertices.
weak_referenceable_mixin.h
weak reference and related classes