mirror of
https://git.mirrors.martin98.com/https://github.com/prusa3d/PrusaSlicer.git
synced 2025-08-15 10:05:53 +08:00
Fix lightning when move above surface and view from bottom
This commit is contained in:
parent
bcb3603d5d
commit
fdf1c2fc71
@ -461,7 +461,8 @@ void GLGizmoEmboss::on_render() {
|
|||||||
const Transform3d matrix = camera.get_view_matrix() * (*m_temp_transformation);
|
const Transform3d matrix = camera.get_view_matrix() * (*m_temp_transformation);
|
||||||
shader->set_uniform("view_model_matrix", matrix);
|
shader->set_uniform("view_model_matrix", matrix);
|
||||||
shader->set_uniform("projection_matrix", camera.get_projection_matrix());
|
shader->set_uniform("projection_matrix", camera.get_projection_matrix());
|
||||||
shader->set_uniform("view_normal_matrix", (Matrix3d) (*m_temp_transformation).matrix().block(0, 0, 3, 3).inverse().transpose());
|
shader->set_uniform("view_normal_matrix", (Matrix3d) (matrix).matrix().block(0, 0, 3, 3).inverse().transpose());
|
||||||
|
shader->set_uniform("emission_factor", 0.0f);
|
||||||
#endif // ENABLE_LEGACY_OPENGL_REMOVAL
|
#endif // ENABLE_LEGACY_OPENGL_REMOVAL
|
||||||
|
|
||||||
// dragging object must be selected so draw it with correct color
|
// dragging object must be selected so draw it with correct color
|
||||||
|
Loading…
x
Reference in New Issue
Block a user