[REQ]: Select All Objects With 'Default Material'
-
Hi Ruby masters,
This is bothering me for a very long time now.
By context clicking, we can easily do 'select all with same material', but it doesn't work for geometry that has the 'Default Material'. It almost feels like a bug, so I was wondering if a ruby could be made for it.Thank you in advance.
Kwistenbiebel
-
Sketchup.active_model.active_entities.each {|e| Sketchup.active_model.selection.add(e) if e.material==nil}
-
Thank you Whaat ...and such a fast reply .
I don't know what to do with the code, but I'll find out. It must have something to do with copy pasting it in the ruby console right ?
Would it difficult for me to make it into a ruby that I can use by context clicking geometry?
(I am such a ruby noob ) -
Someone at work asked me about this on friday. I did the same thing as Whaat posted, typing it into the ruby console.
(it was to assign a colour to all default materials so it could be rendered properly in V-Ray)I was planning on writing it into a ruby on monday.
-
WHen you do can you post the ruby file here?
-
I added selection filter for entities with default materials to my Selection Toys plugin. http://www.sketchucation.com/forums/scf/viewtopic.php?f=180&t=14975
You'll find the commands from the context menu when you do a selection.
Advertisement