Skip to content

Commit f8a8b63

Browse files
Omit specular_weight from metal edge tint in OpenPBR
This changelist removes `specular_weight` from the computation of metal edge tint in OpenPBR Surface, aligning the behavior of this shading model with a [proposed fix](AcademySoftwareFoundation/OpenPBR#240) for OpenPBR 1.2. As described in the proposed fix, the edge-tint color for the `generalized_schlick_bsdf` should not be multiplied by `specular_weight`, as the whole lobe is multiplied by `specular_weight` as well.
1 parent 18a1b7a commit f8a8b63

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

libraries/bxdf/open_pbr_surface.mtlx

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -424,22 +424,18 @@
424424
<input name="in1" type="color3" interfacename="base_color" />
425425
<input name="in2" type="float" interfacename="base_weight" />
426426
</multiply>
427-
<multiply name="metal_edgecolor" type="color3">
428-
<input name="in1" type="color3" interfacename="specular_color" />
429-
<input name="in2" type="float" interfacename="specular_weight" />
430-
</multiply>
431427
<generalized_schlick_bsdf name="metal_bsdf" type="BSDF">
432428
<input name="weight" type="float" interfacename="specular_weight" />
433429
<input name="color0" type="color3" nodename="metal_reflectivity" />
434-
<input name="color82" type="color3" nodename="metal_edgecolor" />
430+
<input name="color82" type="color3" interfacename="specular_color" />
435431
<input name="roughness" type="vector2" nodename="main_roughness" />
436432
<input name="normal" type="vector3" interfacename="geometry_normal" />
437433
<input name="tangent" type="vector3" interfacename="geometry_tangent" />
438434
</generalized_schlick_bsdf>
439435
<generalized_schlick_bsdf name="metal_bsdf_tf" type="BSDF">
440436
<input name="weight" type="float" interfacename="specular_weight" />
441437
<input name="color0" type="color3" nodename="metal_reflectivity" />
442-
<input name="color82" type="color3" nodename="metal_edgecolor" />
438+
<input name="color82" type="color3" interfacename="specular_color" />
443439
<input name="roughness" type="vector2" nodename="main_roughness" />
444440
<input name="normal" type="vector3" interfacename="geometry_normal" />
445441
<input name="tangent" type="vector3" interfacename="geometry_tangent" />

0 commit comments

Comments
 (0)