MCPcopy Create free account
hub / github.com/Aloshi/EmulationStation / init

Function init

src/Renderer_init_sdlgl.cpp:113–135  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

111 }
112
113 bool init(int w, int h)
114 {
115 if(w)
116 display_width = w;
117 if(h)
118 display_height = h;
119
120 bool createdSurface = createSurface();
121
122 if(!createdSurface)
123 return false;
124
125 glViewport(0, 0, display_width, display_height);
126
127 glMatrixMode(GL_PROJECTION);
128 glOrtho(0, display_width, display_height, 0, -1.0, 1.0);
129 glMatrixMode(GL_MODELVIEW);
130 glClearColor(1.0f, 1.0f, 1.0f, 1.0f);
131
132 onInit();
133
134 return true;
135 }
136
137 void deinit()
138 {

Callers

nothing calls this directly

Calls 2

onInitFunction · 0.85
createSurfaceFunction · 0.70

Tested by

no test coverage detected