You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-09 12:50:35 +00:00
Use radial distance for making LOD decisions.
Previously, only forward basis distance from the camera was used. This means that unnecessarily high LOD levels were used for objects located to the side of the camera. The distance from the camera origin is now used, independently of direction.
This commit is contained in:
@@ -1101,7 +1101,6 @@ void RendererSceneRenderRD::render_scene(const Ref<RenderSceneBuffers> &p_render
|
||||
|
||||
// this should be the same for all cameras..
|
||||
scene_data.lod_distance_multiplier = p_camera_data->main_projection.get_lod_multiplier();
|
||||
scene_data.lod_camera_plane = Plane(-p_camera_data->main_transform.basis.get_column(Vector3::AXIS_Z), p_camera_data->main_transform.get_origin());
|
||||
|
||||
if (get_debug_draw_mode() == RS::VIEWPORT_DEBUG_DRAW_DISABLE_LOD) {
|
||||
scene_data.screen_mesh_lod_threshold = 0.0;
|
||||
|
||||
Reference in New Issue
Block a user