Batch apply unique materials/textures to all faces in sketchup 2019

Hello,
First time poster here, and new to sketchup. Was looking for a way to assign a unique material to each face on a model all at once, instead of having to click on each face manually to do it.

I literally just need each piece of my model to just have its own material assignment and not be merged or grouped together. I’m going to be exporting this model when I’m done, so I can manipulate my model in other programs more easily.

Are there any automatic buttons for this or plugins? I’ve been looking every where but google hasn’t been much help :frowning:

To clarify, I am looking for something like this, but compatible with 2019

https://sketchucation.com/forums/viewtopic.php?f=323&t=41441

@Aerilius This one’s for you. :slight_smile: Did you fold the batch material uniquer feature into Texture Resizer ?

  1. Can you describe how does it make it easier to handle the model in other programs? Do you really want an image file for every face (models of people who come to this forum can have a very high polycount, and exporting thousands of 5-10px images would kill their harddrive/SSD and performance)? Usually people find it an annoyance that SketchUp’s exporters split non-affine textures into many unique files, and would instead prefer the functionality to join textures into a single texture atlas (which is more efficiently handled by GPUs).

  2. Maybe you are trying to solve a problem that can be solved differently? What is the actual problem?


Texture Resizer includes that part of functionality of Make Unique Texture++ which serves the use case of reducing texture and file size:

  • Makes a single unique copy of a texture if applied to a selection (so not to affect materials outside of the selection).
    → This unique copy comprises all texture regions of all affected faces (not per face) because the same texture region could be used by multiple faces, and splitting/duplicating would lead to more files of less quality.
  • Crops a texture and rotates it (what native Make Unique does not) to a rectangular bounding box that is optimal for all affected faces.
    → It does not bake texture distortion into a texture image.

For rather unconventional use cases it is not worth to develop a plugin up front (that nobody should need) in the hope that once in some years someone will use it. For specialized needs, it is cheaper if you directly use the Ruby API yourself to solve a task when the need arises.

It is true, SketchUp’s Ruby API should have a counter-part for every GUI action and should make it easier to run GUI actions in batch.

In my case, we’re using Sketchup in a very unconventional way to take my source material and texture map it. I guess I’ve been misusing your plugin then /u/Aerilius. However, when I tried to use it previously, it didnt seem to work. I used it, but didn’t see the textures actually get generated for the object or get listed under the materials section under In-Model. Maybe I installed it incorrectly?

I am literally hitting explode, selecting all faces, and hitting the paint tool with the same texture. I then use your resize tool to try and generate the textures, but nothing seems to happen?

The reason why I’m doing it this way is because sketchup saves a lot of steps on the UV mapping / texture mapping process for simple geometry for what I’m trying to do. I am trying to export this to UE4 for a level I’m trying to build. I’m using simple models for now, and nothing with an excessive poly count, and in my use case, this is perfect. My big thing is trying to get each room to take it’s own ‘wall’ texture and look at least somewhat correct.

Basically, what you’re describing is exactly what I’m looking for. If the ruby scripting aspect is what you describe, that sounds like something I could pick up and do with some time and research.

EDIT: Added verbage for clarification.

I suppose I should also mention that the textures that do get generated by the process I practically throw out anyway because they’re just being used as placeholders coming from Sketchup going into Unreal.

So just figured out I’ve been doing this entirely wrong, and not utilizing groups/components correctly to accomplish what I wanted. We’re good now lol.

I appreciate the responses, as they were instrumental to me figuring out what was going on.

Thank you all!