GlistEngine
Loading...
Searching...
No Matches
gRenderObject.h
Go to the documentation of this file.
1/*
2 * gRenderObject.h
3 *
4 * Created on: May 9, 2020
5 * Author: noyan
6 */
7
8#pragma once
9
10#ifndef ENGINE_BASE_GRENDEROBJECT_H_
11#define ENGINE_BASE_GRENDEROBJECT_H_
12
13#include "gRenderer.h"
14
15#if defined(ANDROID)
16using gIndex = unsigned short;
17#define G_INDEX_SIZE GL_UNSIGNED_SHORT
18#else
19using gIndex = unsigned int;
20#define G_INDEX_SIZE GL_UNSIGNED_INT
21#endif
22
23extern gRenderer* renderer;
24
25class gRenderObject : public gObject {
26public:
28
29 static void setScreenSize(int screenWidth, int screenHeight);
30 static void setUnitScreenSize(int unitWidth, int unitHeight);
31 static void setScreenScaling(int screenScaling);
34
35 void pushMatrix();
36 void popMatrix();
37
38 static void enableShadowMapping();
39 static void disableShadowMapping();
41
43
44 static void destroyRenderer();
45 static void createRenderer();
46protected:
47 friend class gRenderer;
49};
50
51#endif /* ENGINE_BASE_GRENDEROBJECT_H_ */
Definition gObject.h:33
Definition gRenderObject.h:25
static void createRenderer()
static bool isShadowMappingEnabled()
static bool isshadowmappingenabled
Definition gRenderObject.h:48
static gRenderer * getRenderer()
static void setScreenScaling(int screenScaling)
int getScreenHeight()
static void enableShadowMapping()
int getScreenWidth()
static void disableShadowMapping()
static void setScreenSize(int screenWidth, int screenHeight)
void pushMatrix()
static void destroyRenderer()
static void setUnitScreenSize(int unitWidth, int unitHeight)
void popMatrix()
Definition gRenderer.h:123
gRenderer * renderer
unsigned int gIndex
Definition gRenderObject.h:19