1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-12 13:20:55 +00:00

Rasterizers are now in sync with engine

The rasterisers (both GLES3 and GLES2) were calculating their own frame delta time
This fix lets the rasterizers get the frame delta through the draw call
That way any regulations to the frame step from the main script will not cause particle systems to process at a different step than the rest of the Engine.

Remove unused rasterizer storage variable

frame.prev_tick variable were not used anywhere and has been removed
This commit is contained in:
Gustav Lund
2018-05-09 08:11:43 +02:00
parent 6a69f92370
commit 35eb7f2d6a
17 changed files with 33 additions and 58 deletions

View File

@@ -93,11 +93,11 @@ void VisualServerRaster::request_frame_drawn_callback(Object *p_where, const Str
frame_drawn_callbacks.push_back(fdc);
}
void VisualServerRaster::draw(bool p_swap_buffers) {
void VisualServerRaster::draw(bool p_swap_buffers, double frame_step) {
changes = 0;
VSG::rasterizer->begin_frame();
VSG::rasterizer->begin_frame(frame_step);
VSG::scene->update_dirty_instances(); //update scene stuff