Created
January 23, 2017 05:39
-
-
Save patwooky/6a117a6cae8c66ca09d078e216b0ae0a to your computer and use it in GitHub Desktop.
Search all file texture nodes in the scene and return nodes whole filenames contain a search texture file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pymel.core import * | |
findTextureStr = 'concreteBrightMask.png' # the name of an image to search file names from | |
candidateNodesList = [x for x in ls(type='file') if findTextureStr in x.fileTextureName.get()] | |
print 'texture file found in these file textures:\n{}'.format(candidateNodesList) | |
select(candidateNodesList, replace=True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment