VoltAir
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Groups Pages
PointerDeclarations.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2014 Google Inc.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 #ifndef POINTERDECLARATIONS_H
18 #define POINTERDECLARATIONS_H
19 
20 #include <memory>
21 
31 struct Attribute;
32 template<typename T> class AttributeArray;
33 struct AttributeSet;
34 class DebugRenderer;
35 class DirectTexture;
36 class InstancedShader;
37 template<typename TShaderImpl> class InstancedShaderBase;
38 class Mesh;
39 class MeshInstance;
40 class RenderList;
41 struct RenderNode;
42 class Renderer;
43 class Shader;
44 class ShaderBase;
45 template<typename TShaderImpl> class SingletonInstancedShaderBase;
46 class SpriteShader;
47 class Texture;
48 
53 typedef std::shared_ptr<Attribute> AttributePtr;
58 typedef std::weak_ptr<Attribute> AttributeWeakPtr;
63 typedef std::shared_ptr<AttributeSet> AttributeSetPtr;
68 typedef std::weak_ptr<AttributeSet> AttributeSetWeakPtr;
73 typedef std::shared_ptr<DebugRenderer> DebugRendererPtr;
78 typedef std::weak_ptr<DebugRenderer> DebugRendererWeakPtr;
83 typedef std::shared_ptr<DirectTexture> DirectTexturePtr;
88 typedef std::weak_ptr<DirectTexture> DirectTextureWeakPtr;
93 typedef std::shared_ptr<InstancedShader> InstancedShaderPtr;
98 typedef std::weak_ptr<InstancedShader> InstancedShaderWeakPtr;
103 typedef std::shared_ptr<Mesh> MeshPtr;
108 typedef std::weak_ptr<Mesh> MeshWeakPtr;
113 typedef std::shared_ptr<MeshInstance> MeshInstancePtr;
118 typedef std::weak_ptr<MeshInstance> MeshInstanceWeakPtr;
123 typedef std::shared_ptr<RenderList> RenderListPtr;
128 typedef std::weak_ptr<RenderList> RenderListWeakPtr;
133 typedef std::shared_ptr<RenderNode> RenderNodePtr;
138 typedef std::weak_ptr<RenderNode> RenderNodeWeakPtr;
143 typedef std::shared_ptr<Shader> ShaderPtr;
148 typedef std::weak_ptr<Shader> ShaderWeakPtr;
153 typedef std::shared_ptr<ShaderBase> ShaderBasePtr;
158 typedef std::weak_ptr<ShaderBase> ShaderBaseWeakPtr;
163 typedef std::shared_ptr<SpriteShader> SpriteShaderPtr;
168 typedef std::weak_ptr<SpriteShader> SpriteShaderWeakPtr;
173 typedef std::shared_ptr<Texture> TexturePtr;
178 typedef std::weak_ptr<Texture> TextureWeakPtr;
179 
180 #endif // POINTERDECLARATIONS_H
std::weak_ptr< Texture > TextureWeakPtr
Weak shared pointer typedef for Texture.
Definition: PointerDeclarations.h:178
std::shared_ptr< DirectTexture > DirectTexturePtr
Shared pointer typedef for DirectTexture.
Definition: PointerDeclarations.h:83
Implementation of Shader which compiles itself from shader code.
Definition: ShaderBase.h:37
A class with helper methods for rendering primitives like lines, for debug visualization.
Definition: DebugRenderer.h:36
Shader which has instanced values for uniforms and other GL state.
Definition: InstancedShader.h:46
Class managing GL state switches and draw calls.
Definition: Renderer.h:50
A texture which points to a user managed GL texture object.
Definition: DirectTexture.h:30
std::weak_ptr< Mesh > MeshWeakPtr
Weak shared pointer typedef for Mesh.
Definition: PointerDeclarations.h:108
std::shared_ptr< Attribute > AttributePtr
Shared pointer typedef for Attribute.
Definition: PointerDeclarations.h:47
std::shared_ptr< SpriteShader > SpriteShaderPtr
Shared pointer typedef for SpriteShader.
Definition: PointerDeclarations.h:163
Texture abstract base class.
Definition: Texture.h:32
Shader program abstract base class.
Definition: Shader.h:47
std::shared_ptr< ShaderBase > ShaderBasePtr
Shared pointer typedef for ShaderBase.
Definition: PointerDeclarations.h:153
Mesh composed of vertices, and attributes for each vertex.
Definition: Mesh.h:36
std::weak_ptr< RenderList > RenderListWeakPtr
Weak shared pointer typedef for RenderList.
Definition: PointerDeclarations.h:128
The definition of a vertex attribute, such as a position vector, or a texture coordinate.
Definition: Attribute.h:31
std::weak_ptr< Attribute > AttributeWeakPtr
Weak shared pointer typedef for Attribute.
Definition: PointerDeclarations.h:58
std::shared_ptr< RenderNode > RenderNodePtr
Shared pointer typedef for RenderNode.
Definition: PointerDeclarations.h:133
Shader use by Renderer to draw textured rectangles (sprites).
Definition: SpriteShader.h:33
std::shared_ptr< AttributeSet > AttributeSetPtr
Shared pointer typedef for AttributeSet.
Definition: PointerDeclarations.h:63
Mesh bound to a specific Shader.
Definition: MeshInstance.h:35
std::shared_ptr< Texture > TexturePtr
Shared pointer typedef for Texture.
Definition: PointerDeclarations.h:173
std::shared_ptr< DebugRenderer > DebugRendererPtr
Shared pointer typedef for DebugRenderer.
Definition: PointerDeclarations.h:73
std::shared_ptr< Shader > ShaderPtr
Shared pointer typedef for Shader.
Definition: PointerDeclarations.h:143
A list of vertex attributes.
Definition: AttributeSet.h:36
std::weak_ptr< Shader > ShaderWeakPtr
Weak shared pointer typedef for Shader.
Definition: PointerDeclarations.h:148
std::shared_ptr< InstancedShader > InstancedShaderPtr
Shared pointer typedef for InstancedShader.
Definition: PointerDeclarations.h:93
Node which queues a callback (RenderableInterface) or MeshInstance for rendering. ...
Definition: RenderNode.h:33
std::weak_ptr< SpriteShader > SpriteShaderWeakPtr
Weak shared pointer typedef for SpriteShader.
Definition: PointerDeclarations.h:168
std::weak_ptr< RenderNode > RenderNodeWeakPtr
Weak shared pointer typedef for RenderNode.
Definition: PointerDeclarations.h:138
std::shared_ptr< MeshInstance > MeshInstancePtr
Shared pointer typedef for MeshInstance.
Definition: PointerDeclarations.h:113
std::shared_ptr< Mesh > MeshPtr
Shared pointer typedef for Mesh.
Definition: PointerDeclarations.h:103
std::weak_ptr< AttributeSet > AttributeSetWeakPtr
Weak shared pointer typedef for AttributeSet.
Definition: PointerDeclarations.h:68
std::weak_ptr< ShaderBase > ShaderBaseWeakPtr
Weak shared pointer typedef for ShaderBase.
Definition: PointerDeclarations.h:158
List of RenderNodes, sorted by z-depth for rendering.
Definition: RenderList.h:36
std::weak_ptr< InstancedShader > InstancedShaderWeakPtr
Weak shared pointer typedef for InstancedShader.
Definition: PointerDeclarations.h:98
std::weak_ptr< DebugRenderer > DebugRendererWeakPtr
Weak shared pointer typedef for DebugRenderer.
Definition: PointerDeclarations.h:78
std::weak_ptr< DirectTexture > DirectTextureWeakPtr
Weak shared pointer typedef for DirectTexture.
Definition: PointerDeclarations.h:88
Helper class to implement InstancedShader subclasses, by managing a shared Shader.
Definition: InstancedShaderBase.h:44
A helper to define singletons for InstancedShaders.
Definition: PointerDeclarations.h:45
A helper class to access and iterate over an interleaved vertex attribute array.
Definition: AttributeArray.h:31
std::weak_ptr< MeshInstance > MeshInstanceWeakPtr
Weak shared pointer typedef for MeshInstance.
Definition: PointerDeclarations.h:118
std::shared_ptr< RenderList > RenderListPtr
Shared pointer typedef for RenderList.
Definition: PointerDeclarations.h:123