mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 10:54:24 -04:00
fix LP bug 1219422: fix ShaderGenerator errors when LightRampAttrib is in use but no diffuse is present
This commit is contained in:
parent
321555d888
commit
89b824597c
@ -1160,7 +1160,7 @@ synthesize_shader(const RenderState *rs) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
const LightRampAttrib *light_ramp = DCAST(LightRampAttrib, rs->get_attrib_def(LightRampAttrib::get_class_slot()));
|
const LightRampAttrib *light_ramp = DCAST(LightRampAttrib, rs->get_attrib_def(LightRampAttrib::get_class_slot()));
|
||||||
if(_auto_ramp_on) {
|
if (_auto_ramp_on && _have_diffuse) {
|
||||||
switch (light_ramp->get_mode()) {
|
switch (light_ramp->get_mode()) {
|
||||||
case LightRampAttrib::LRT_single_threshold:
|
case LightRampAttrib::LRT_single_threshold:
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user