Fix: GPU: Implicit cast from int to bool in assert()
These are not valid in GLSL.
This commit is contained in:
@@ -51,7 +51,7 @@ float closure_evaluate_pdf(ClosureUndetermined cl, float3 L, float3 V, float thi
|
||||
case CLOSURE_NONE_ID:
|
||||
break;
|
||||
}
|
||||
assert(0);
|
||||
assert(false);
|
||||
return 0.0f;
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@ LightProbeRay bxdf_lightprobe_ray(ClosureUndetermined cl, float3 P, float3 V, fl
|
||||
case CLOSURE_BSDF_MICROFACET_GGX_REFLECTION_ID:
|
||||
break;
|
||||
case CLOSURE_NONE_ID:
|
||||
assert(0);
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -82,7 +82,7 @@ LightProbeRay bxdf_lightprobe_ray(ClosureUndetermined cl, float3 P, float3 V, fl
|
||||
case CLOSURE_BSDF_MICROFACET_GGX_REFRACTION_ID:
|
||||
return bxdf_ggx_lightprobe_transmission(to_closure_refraction(cl), V, thickness);
|
||||
case CLOSURE_NONE_ID:
|
||||
assert(0);
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -98,7 +98,7 @@ void main()
|
||||
specular_indirect += closure_indirect_light;
|
||||
break;
|
||||
case CLOSURE_NONE_ID:
|
||||
assert(0);
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -151,7 +151,7 @@ struct Layers {
|
||||
return this->layer[2];
|
||||
#endif
|
||||
}
|
||||
assert(0);
|
||||
assert(false);
|
||||
return this->layer[0];
|
||||
}
|
||||
|
||||
|
||||
@@ -87,7 +87,7 @@ ClosureUndetermined g_closure_get(uchar i)
|
||||
#endif
|
||||
}
|
||||
/* Unreachable. */
|
||||
assert(0);
|
||||
assert(false);
|
||||
return g_closure_bins[0];
|
||||
}
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@ BsdfSample ray_generate_direction(float2 noise, ClosureUndetermined cl, float3 V
|
||||
case CLOSURE_BSDF_DIFFUSE_ID:
|
||||
break;
|
||||
case CLOSURE_NONE_ID:
|
||||
assert(0);
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -73,7 +73,7 @@ BsdfSample ray_generate_direction(float2 noise, ClosureUndetermined cl, float3 V
|
||||
break;
|
||||
}
|
||||
case CLOSURE_NONE_ID:
|
||||
assert(0);
|
||||
assert(false);
|
||||
break;
|
||||
}
|
||||
samp.direction = tangent_to_world * float3(samp.direction);
|
||||
|
||||
@@ -84,7 +84,7 @@ void main()
|
||||
return;
|
||||
case BG_SOLID_CHECKER:
|
||||
/* Unreachable. */
|
||||
assert(0);
|
||||
assert(false);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user