oviam Posted June 25, 2004 Share Posted June 25, 2004 Can anyone tell me how to get object or objects name by material? example:i have one material in my scene which is assigned to some objects,i want to get those objets name(as an array or something) through this material. pls explain me how to do this. thanks -mani. Link to comment Share on other sites More sharing options...
sunet Posted June 25, 2004 Share Posted June 25, 2004 You can select the material and use the select by material from the material editor. Link to comment Share on other sites More sharing options...
Diego Rosales Posted June 26, 2004 Share Posted June 26, 2004 or you can... "myMatArray = for obj in $* where obj.material == collect obj" that's an array with all the objects with a material assigned to them. You can then use the array for whatever you wish. Diego Link to comment Share on other sites More sharing options...
oviam Posted June 26, 2004 Author Share Posted June 26, 2004 thanks Diego ,now my script works fine , for sunet, thanks for your reply sunet,but my idea was to rename all the scene materials to the corrseponding asigned object name so i have to get the object name through script(i don't want to select those objects)... thanks -mani. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now