Change color of part of model

I have created a terrain model colored by imagery.

I am trying to change the color of the extruded triangles on the mesh

I was using the method from https://www.youtube.com/watch?v=ZYlXW4WaYbY so i used the SelBrush tool to isolate the part of the mesh I want to recolor, added a layer which has the new color I want

According to the video I should be able to make the selection as per the above image, then right click on the new layer and select “change object layer”.

However, when I select the part of the mesh and right click “change object layer” is grayed out.

Am I using the wrong tool or method to recolor this mesh?

Hi @Sean_Dzafovic

The reason it’s not working is because in that video those different colored areas are distinct separate nurbs objects, made using the paneling tool.

What you have posted appears to be one mesh and not distinct different meshes. That change to layer option in the layers tab only appears for separate objects not joined mesh faces or nurbs surfaces that are joined that’s why it’s greyed out.

If you want to color those faces you’ll need to use the Command:
“ExtractMeshFaces” first
Then you can select them and put them on another layer and change their color.
You could use the copy option at the command line when extracting mesh faces and move them slightly higher in z axis to leave your original mesh intact.

One trick with nurbs objects to get different colors on one distinct object, is to first create the different colored materials in the materials tab, then use ctrl-shift to select the faces, then in the materials tab right click on the material and use the assign to selected objects option. In V7 this doesn’t work for meshes only nurbs faces maybe this trick works with meshes in V8?

RM

I tried this method, and it did not seem to work.

I have tried setting the MakeCopy property of ExtractMeshFaces to both values (Y/N), and I am able to select the faces and can move them. I can also add them to the new layer using the right click menu. (Selected meshes disappear when I turn them off in layer box, so they are being added).

However this does not change the color of the faces.

Am I missing a step somewhere?

Hi @Sean_Dzafovic

It’s easier to diagnose what’s wrong when you post the parts of your model you’re having trouble with, otherwise it’s a shot in the dark to help.

Do you have a material assigned to the model and thus its overriding the color by layer option? Look in the materials tab and see if there is a material there. Or could be vertex coloring?

RM

The model was originally exported from ArcGIS Pro as a gITF file. Imported that into Meshlab, then exported as OBJ. Then imported the OBJ into Rhino.

I created a new layer with the desired color, then selected the parts of the mesh with ExtractMeshFaces, then right clicked the layer in the dialog box and selected “copy objects to layer”.

There is a .mtl file corresponding to the imported OBJ.

I have saved a part of the OBJ file out as a Rhino file.

Mersey_S_10x_SurfColorTest.3dm (1.6 MB)

Hi @Sean_Dzafovic

Just as I thought you have materials assigned to your objects already, thus coloring them by layer won’t work in rendered mode. Notice in the “materials tab” all the materials you have assigned to your objects. Most likely coming in from your source object since you have a .mtl file as well. Rhino display, materials and layers have more options than you might know. Best to go over a few tutorials and check the help files because coloring by layer is one basic way to color objects out of many ways and doesn’t work for rendered display mode.

Open the “materials tab” create a red material, select your objects and assign that red material to your objects.

Edit:
I can understand your confusion. Why rhino doesn’t let one remove a material but gives a user only the ability to assign another material is challenging. You can also create a material in your layer by clicking that white box and changing it to the same color as your layer color. But you will notice it’s a material now and shows up in the material tab. When you use rendered mode you must have materials assigned, rhino does this under the hood by using a default material.

Here’s a thread concerning the issue…
How do I remove a material from an object? - Serengeti (Rhino BETA) - McNeel Forum

RM