41 #ifndef INCLUDED_GLS_MIMIC_GROUP_H
42 #define INCLUDED_GLS_MIMIC_GROUP_H
51 #if( defined( GLSGEN_EXPORT_GLSMIMICGROUP ) || defined( GLSGEN_IMPORT_GLSMIMICGROUP ) || defined( GLS_EXPORT_GENERATED ) || defined( GLS_IMPORT_GENERATED ) ) \
52 && defined( _MSC_VER )
53 # if defined( GLSGEN_EXPORT_GLSMIMICGROUP ) || defined( GLS_EXPORT_GENERATED )
54 # define GLSGEN_GLSMIMICGROUP_EXPORT __declspec( dllexport )
56 # define GLSGEN_GLSMIMICGROUP_EXPORT __declspec( dllimport )
59 # define GLSGEN_GLSMIMICGROUP_EXPORT
63 #define LIB_BASE_NAME "gls_mimic_group"
76 GLS_MIMIC_GROUP_STATE = GLS_LAST_INITIALIZER + 1,
77 GLS_MIMIC_GROUP_MIMIC_ACTIVE,
78 GLS_MIMIC_GROUP_BOTTOM_LEFT_CORNER,
79 GLS_MIMIC_GROUP_TOP_RIGHT_CORNER,
80 GLS_MIMIC_GROUP_SHOW_OUTLINE,
81 GLS_MIMIC_GROUP_TEXTURE_HEIGHT,
82 GLS_MIMIC_GROUP_TEXTURE_WIDTH,
83 GLS_MIMIC_GROUP_HAS_DEPTH_BUFFER,
84 GLS_MIMIC_GROUP_DEPTH_TEST,
85 GLS_MIMIC_GROUP_GENERATE_MIPMAPS,
86 GLS_MIMIC_GROUP_DRAW_MIMIC_POLYGON,
87 GLS_MIMIC_GROUP_ATTACHED_TEXTURE_INDEX,
88 GLS_MIMIC_GROUP_CLEAR_COLOR,
89 GLS_MIMIC_GROUP_USE_OPAQUE_TEXTURE,
90 GLS_MIMIC_GROUP_MIMIC_AUTO_REDRAW
127 friend class GlsMimicGroupEditor;
136 GLSGEN_GLSMIMICGROUP_EXPORT
GlsMimicGroup(
bool generateInstance =
false );
138 GLSGEN_GLSMIMICGROUP_EXPORT GlsMimicGroup(
const GlsMimicGroup& that,
const bool generateNames );
182 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void Draw(
void );
187 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void SetValue(
int spec, va_list& args );
198 virtual GLSGEN_GLSMIMICGROUP_EXPORT
unsigned int TextureWidth()
const {
return _textureWidth; }
205 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void TextureWidth(
unsigned int textureWidth );
212 virtual GLSGEN_GLSMIMICGROUP_EXPORT
unsigned int TextureHeight()
const {
return _textureHeight; }
219 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void TextureHeight(
unsigned int textureHeight );
226 virtual GLSGEN_GLSMIMICGROUP_EXPORT
bool HasDepthBuffer()
const {
return _hasDepthBuffer; }
233 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void HasDepthBuffer(
bool hasDepthBuffer );
240 virtual GLSGEN_GLSMIMICGROUP_EXPORT
bool GenerateMipMaps()
const {
return _generateMipMaps; }
247 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void GenerateMipMaps(
bool generate );
268 virtual GLSGEN_GLSMIMICGROUP_EXPORT
unsigned char MimicGroupDepthTest()
const {
return _mimicGroupDepthTest; }
275 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void MimicGroupDepthTest(
unsigned char depthSettings );
282 virtual GLSGEN_GLSMIMICGROUP_EXPORT
bool AutoRedraw()
const {
return _autoRedraw; }
289 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void AutoRedraw(
bool autoRedrawSetting );
368 GLSGEN_GLSMIMICGROUP_EXPORT
bool ShowOutline(
void )
const {
return _showOutline; }
375 GLSGEN_GLSMIMICGROUP_EXPORT
void ShowOutline(
bool showOutline );
382 GLSGEN_GLSMIMICGROUP_EXPORT
bool Redraw(
void )
const {
return _redraw; }
389 GLSGEN_GLSMIMICGROUP_EXPORT
void Redraw(
bool redraw );
396 GLSGEN_GLSMIMICGROUP_EXPORT
bool UseOpaqueTexture(
void )
const {
return _useOpaqueTexture; }
413 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void InsertObject(
DisplayObject* obj,
bool reparent =
true,
bool recalculateBoundingbox =
true,
int loc = -1 ) DISTI_METHOD_OVERRIDE;
423 GLSGEN_GLSMIMICGROUP_EXPORT
void Invalidate() DISTI_METHOD_OVERRIDE;
430 virtual GLSGEN_GLSMIMICGROUP_EXPORT
void SetMatrices();
539 bool _mimicGroupActive;
542 bool _hasDepthBuffer;
543 bool _generateMipMaps;
545 bool _drawMimicGroupPolygon;
546 unsigned char _mimicGroupDepthTest;
547 bool _textureIndexChanged;
551 int _attachedTextureIndex;
552 unsigned int _textureWidth;
553 unsigned int _textureHeight;
554 unsigned int _frameBufferHandle;
555 unsigned int _depthBufferHandle;
556 Image* _mimicGroupTexture;
557 unsigned int _vertexBufferHandle;
560 bool _useOpaqueTexture;
virtual GlsColor ClearColor() const
Definition: gls_mimic_group.h:296
void Invalidate() DISTI_METHOD_OVERRIDE
static DisplayObject * CreateInstance()
bool ShowOutline(void) const
Definition: gls_mimic_group.h:368
Definition: dynamic_array.h:62
virtual unsigned char MimicGroupDepthTest() const
Definition: gls_mimic_group.h:268
The disti::Group class. Implements groups of objects.
Class to contain current OpenGL view, projection and draw matrices.
Definition: util.h:301
void ApplyMimicGroupTextureSettings()
virtual bool AutoRedraw() const
Definition: gls_mimic_group.h:282
DisplayObject * handle(DisplayEvent *displayEvent)
void LogUnsupportedFeatures()
virtual void PreDrawMimicGroupChildren(const OpenGLMatrices &parentMatrices, Culler &culler)
virtual bool GenerateMipMaps() const
Definition: gls_mimic_group.h:240
void CreateDiffuseTexture()
Definition: gls_glo_file.h:982
Definition: gls_mimic_group.h:119
virtual void SetAvailableAttributes(unsigned int value)
The Image class. All textures are converted internally into Images.
Definition: gls_painter.h:51
bool _overrideMimicGroupActive
Definition: gls_mimic_group.h:559
virtual bool DrawMimicGroupPolygon() const
Definition: gls_mimic_group.h:254
void SetupMimicGroupDepthTest()
virtual bool HasDepthBuffer() const
Definition: gls_mimic_group.h:226
virtual void SetMatrices()
virtual void CopyProperties(DisplayObject *src)
virtual void GetCppInterfaceDescriptionFree(InterfaceListType *array)
virtual void InsertObject(DisplayObject *obj, bool reparent=true, bool recalculateBoundingbox=true, int loc=-1) DISTI_METHOD_OVERRIDE
virtual unsigned int TextureWidth() const
Definition: gls_mimic_group.h:198
Utility for common frame buffer support.
virtual void PushObject(DisplayObject *obj) DISTI_METHOD_OVERRIDE
bool Redraw(void) const
Definition: gls_mimic_group.h:382
Definition: gls_color.h:53
bool MimicGroupActive(void)
Definition: gls_mimic_group.h:325
Vector TopRightCorner(void) const
Definition: gls_mimic_group.h:361
void SetPainter(GlsPainter *painter) DISTI_METHOD_OVERRIDE
bool _frameBuffersEnabledAndAttached
Definition: gls_mimic_group.h:558
virtual unsigned int TextureHeight() const
Definition: gls_mimic_group.h:212
virtual void SetValue(int spec, va_list &args)
void CreateDepthTexture()
virtual InterfaceListType * GetCppInterfaceDescription(InterfaceListType *addToThisList=NULL)
bool RequiredGlFeaturesSupported()
Vector BottomLeftCorner(void)
Definition: gls_mimic_group.h:347
void CreateMimicGroupQuad()
virtual DisplayObject * CloneObject(bool generateNames=false)
Macros and helper code to determine what subset of C++11/14/17 is available.
bool VertexBuffersAreSupported()
Definition: bmpimage.h:46
bool UseOpaqueTexture(void) const
Definition: gls_mimic_group.h:396
virtual int AttachedTextureIndex() const
Definition: gls_mimic_group.h:310
void GetRegionCorners(Vector &topLeftCorner, Vector &topRightCorner, Vector &bottomRightCorner, Vector &bottomLeftCorner)
static bool _unsupportedLogged
Definition: gls_mimic_group.h:562