mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-29 08:15:18 -04:00
shader: default fog exponential density to 0 if fog is disabled
This commit is contained in:
parent
8672054e30
commit
c81bfb09b7
@ -1017,7 +1017,8 @@ fetch_specified_part(Shader::ShaderMatInput part, InternalName *name,
|
|||||||
_target_rs->get_attrib_def(FogAttrib::get_class_slot());
|
_target_rs->get_attrib_def(FogAttrib::get_class_slot());
|
||||||
Fog *fog = target_fog->get_fog();
|
Fog *fog = target_fog->get_fog();
|
||||||
if (fog == nullptr) {
|
if (fog == nullptr) {
|
||||||
return &LMatrix4::ones_mat();
|
t.set(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1);
|
||||||
|
return &t;
|
||||||
}
|
}
|
||||||
PN_stdfloat start, end;
|
PN_stdfloat start, end;
|
||||||
fog->get_linear_range(start, end);
|
fog->get_linear_range(start, end);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user