if(c)
set_camera(*c);
+ else
+ standard_shdata.uniform("projection_matrix", Matrix());
}
Renderer::~Renderer()
bool camera_changed = (state->camera!=old_camera);
if(camera_changed)
{
- standard_shdata.uniform("projection_matrix", state->camera->get_projection_matrix());
+ if(state->camera)
+ standard_shdata.uniform("projection_matrix", state->camera->get_projection_matrix());
+ else
+ standard_shdata.uniform("projection_matrix", Matrix());
changed |= STANDARD_SHDATA|LEGACY_PROJECTION;
}
/* This actually should compare the relevant matrices rather than check for