diff --git a/Changes.md b/Changes.md index 8fa36fe5612..d22dba41bbf 100644 --- a/Changes.md +++ b/Changes.md @@ -5,6 +5,7 @@ Fixes ----- - GraphEditor : Removed dynamic raster-space sizing of focus icon, as it caused excessive overlap with other nodes at certain zoom levels and on certain high resolution displays (#5435). +- ShaderUI : Fixed bug causing identical but independent shaders in a shader network from being included in the shader browser. 1.2.10.3 (relative to 1.2.10.2) ======== diff --git a/python/GafferSceneUI/ShaderUI.py b/python/GafferSceneUI/ShaderUI.py index 38799b5bd33..63b3b86dcd8 100644 --- a/python/GafferSceneUI/ShaderUI.py +++ b/python/GafferSceneUI/ShaderUI.py @@ -549,7 +549,7 @@ def _children( self, canceller ) : shaderNetwork, shaderHandle = stack.popleft() shader = shaderNetwork.shaders()[shaderHandle] - h = shaderNetwork.hash().append( shader.hash() ) + h = shaderNetwork.hash().append( shaderHandle ) if h not in visited : visited.add( h ) @@ -600,7 +600,7 @@ def __parameters( self ) : def __shaders( self ) : if len( self ) > 0 : - uniqueShaders = { n.shaders()[ self[0] ].hash() : n.shaders()[ self[0] ] for n in self.__shaderNetworks if self[0] in n.shaders() } + uniqueShaders = { n.hash().append( self[0] ) : n.shaders()[ self[0] ] for n in self.__shaderNetworks if self[0] in n.shaders() } return list( uniqueShaders.values() ) return None