MCPcopy Create free account
hub / github.com/atraczyk/2d-engine / setOrthoMatrix

Method setOrthoMatrix

engine/src/camera.cpp:40–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38}
39
40void Camera::setOrthoMatrix()
41{
42 glMatrixMode(GL_PROJECTION);
43 glLoadIdentity();
44 glOrtho((int)(position.x), (int)(position.x + size.x), (int)(position.y),
45 (int)(position.y + size.y), -1.0f, 1.0f);
46}
47
48void Camera::reshape(float w, float h)
49{

Callers 2

R_drawWorldDebugFunction · 0.80
R_renderFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected