diff --git a/Changes.md b/Changes.md index 46a489c11f4..66c805ffc14 100644 --- a/Changes.md +++ b/Changes.md @@ -13,7 +13,9 @@ Improvements - Added the ability to edit the scale of node icons. - Improved layout of Box node plug creator visibility toggles. - ArnoldShader : Moved the `toon` shader's `*_tonemap_hue_saturation` parameters to appropriate sections in the UI. -- Arnold : Added `deep_alpha` and `deep_beauty` output presets demonstrating outputs that produce deep images. +- Arnold : + - Added `deep_alpha` and `deep_beauty` output presets demonstrating outputs that produce deep images. + - Added `lpe` output preset demonstrating an output using a light path expression. API --- diff --git a/startup/gui/outputs.py b/startup/gui/outputs.py index 31999129871..7701cb70fc0 100644 --- a/startup/gui/outputs.py +++ b/startup/gui/outputs.py @@ -120,6 +120,7 @@ "depth", "deep_alpha", "deep_beauty", + "lpe", ] : label = aov.replace( "_", " " ).title().replace( " ", "_" ) @@ -129,6 +130,8 @@ data = "float Z" elif aov == "normal": data = "color N" + elif aov == "lpe" : + data = "lpe C.*" else: data = "color " + aov @@ -142,7 +145,7 @@ if aov == "depth": parameters["layerName"] = "Z" - if aov not in { "motionvector", "emission", "background", "deep_alpha" } : + if aov not in { "motionvector", "emission", "background", "deep_alpha", "lpe" } : parameters["layerPerLightGroup"] = False if aov.startswith( "deep_" ) : @@ -164,6 +167,9 @@ } ) + if aov == "lpe" : + interactiveParameters["layerName"] = "lpe" + GafferScene.Outputs.registerOutput( "Interactive/Arnold/" + label, IECoreScene.Output(