scg3  0.6
Texture2DCore.h
Go to the documentation of this file.
1 
9 /*
10  * Copyright 2014 Volker Ahlers
11  *
12  * Licensed under the Apache License, Version 2.0 (the "License");
13  * you may not use this file except in compliance with the License.
14  * You may obtain a copy of the License at
15  *
16  * http://www.apache.org/licenses/LICENSE-2.0
17  *
18  * Unless required by applicable law or agreed to in writing, software
19  * distributed under the License is distributed on an "AS IS" BASIS,
20  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21  * See the License for the specific language governing permissions and
22  * limitations under the License.
23  */
24 
25 #ifndef TEXTURE2DCORE_H_
26 #define TEXTURE2DCORE_H_
27 
28 #include "scg_glew.h"
29 #include "scg_glm.h"
30 #include "scg_internals.h"
31 #include "TextureCore.h"
32 
33 namespace scg {
34 
35 
39 class Texture2DCore: public TextureCore {
40 
41 public:
42 
46  Texture2DCore();
47 
51  virtual ~Texture2DCore();
52 
56  static Texture2DCoreSP create();
57 
74  void setTexture(GLsizei width, GLsizei height, const unsigned char* rgbaData,
75  GLenum wrapModeS, GLenum wrapModeT, GLenum minFilter, GLenum magFilter);
76 
83  void rotate2D(GLfloat angleDeg);
84 
91  void scale2D(glm::vec2 scaling);
92 
97  virtual void render(RenderState* renderState);
98 
103  virtual void renderPost(RenderState* renderState);
104 
105 };
106 
107 
108 } /* namespace scg */
109 
110 #endif /* TEXTURE2DCORE_H_ */
virtual ~Texture2DCore()
Local header file for GLM OpenGL Mathematics library.
Base class for all texture cores (abstract).
Definition: TextureCore.h:39
2D texture core.
Definition: Texture2DCore.h:39
Local header file for GLEW library.
void rotate2D(GLfloat angleDeg)
Base class for all texture cores (abstract).
static Texture2DCoreSP create()
virtual void renderPost(RenderState *renderState)
virtual void render(RenderState *renderState)
The central render state that collects information about the current shader, transformations,...
Definition: RenderState.h:107
Definition: Animation.h:28
Internal definitions required by most classes.
void setTexture(GLsizei width, GLsizei height, const unsigned char *rgbaData, GLenum wrapModeS, GLenum wrapModeT, GLenum minFilter, GLenum magFilter)
void scale2D(glm::vec2 scaling)