diff options
Diffstat (limited to 'servers/rendering/rendering_server_viewport.h')
-rw-r--r-- | servers/rendering/rendering_server_viewport.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/servers/rendering/rendering_server_viewport.h b/servers/rendering/rendering_server_viewport.h index 161ae94fb0..d00a06c5ee 100644 --- a/servers/rendering/rendering_server_viewport.h +++ b/servers/rendering/rendering_server_viewport.h @@ -70,6 +70,9 @@ public: bool disable_environment; bool measure_render_time; + bool snap_2d_transforms_to_pixel; + bool snap_2d_vertices_to_pixel; + uint64_t time_cpu_begin; uint64_t time_cpu_end; @@ -136,6 +139,9 @@ public: screen_space_aa = RS::VIEWPORT_SCREEN_SPACE_AA_DISABLED; use_debanding = false; + snap_2d_transforms_to_pixel = false; + snap_2d_vertices_to_pixel = false; + for (int i = 0; i < RS::VIEWPORT_RENDER_INFO_MAX; i++) { render_info[i] = 0; } @@ -220,6 +226,9 @@ public: float viewport_get_measured_render_time_cpu(RID p_viewport) const; float viewport_get_measured_render_time_gpu(RID p_viewport) const; + void viewport_set_snap_2d_transforms_to_pixel(RID p_viewport, bool p_enabled); + void viewport_set_snap_2d_vertices_to_pixel(RID p_viewport, bool p_enabled); + void viewport_set_default_canvas_item_texture_filter(RID p_viewport, RS::CanvasItemTextureFilter p_filter); void viewport_set_default_canvas_item_texture_repeat(RID p_viewport, RS::CanvasItemTextureRepeat p_repeat); |