Modify UV mapping

The screenshots below show a recent scan of mine. The red material is glossy and did even tough Artec Studio is quite good with reducing glare, it never looks perfect. I replaced the red material texture with filters and remapped clean labels in KeyShot.

I’d like to change the UV mapping so it follows closer to how the individual parts of the red suit would be cut by a tailor. How is that done?

1 Like

I don’t think that for this type of object you will be able to do that. Not without a huge amount of work. You’ll have to unwrap the model, please seams where there needs to be, pretty much along cut lines. But for this type of model the problem is going to be that lots of geometry is missing, like.

I’d try doing a second UV map in Blender, and when that is done use that to bake a new texture to that new uv map and texture. Be prepared to have to do a lot of manual work, though.

2 Likes

Thanks for your reply, Nathan. Looks like I finally have to start using blender…

Hi @martinsiegrist , There is a hidden command in the Rhino 8 WIP called BakeMapping that will allow you to take an object with two mapping channels and use one projection, e.g. Cylindrical or the default ‘Surface’ mapping from your scan, and bake that into a second custom channel. That unwrap will be used to bake the result from the original channel into a new image aligned with it’s islands giving you the look of the scan with the unwrapped islands of a blocking pattern. Aside from the missing geometry, as Nathan mentioned, that should work for you too if you had a custom unwrap as a second mapping channel on the object… that seam selection and unwrap is the time consuming part.

2 Likes

Thanks Brian. I’ll give it a try with a simple example.

PS: Artec confirmed they are working on a new unwrap solution which should result in less scattered texture files.

1 Like

Ok, so I have a test file with a scan of a small cardboard box. Unfortunately I do not understand the logic of the command just yet. I’ve tried a few things but couldn’t get the texture to adapt to the new mapping.

The Rhino 8 file below contains two meshes. The scan with its original seams and a copy which I welded and split at the creases. I unwrapped the copied mesh and was able to align the parts in the UV editor.

I selected the original mesh and added a second mapping channel using the copied mesh.

I’m not sure what the Fill pixels around option means.

I’ve managed to get a resulting texture file that showed all zix sides of the box once but don’t understand what I’m doing wrong.

This is how the texture file looks like. Something isn’t working:

I’d really appreciate if you could take a look at my file:

test_bake_mapping.3dm (15.4 MB)

Hi @martinsiegrist,

You were really close, the issue was the custom mapping object not being directly over the source when that custom channel was created. I made a video covering the details here… BakeMapping in the Rhino 8 WIP - YouTube

8 Likes

Wow Brian, that for sure helps. Thank you for the video with all the explanations!

I’ll try this on a more complex scan soon.

1 Like

Related to all this - what the heck is a mapping channel? I’ve always wondered that!

Hi @sgreenawalt ,

A mapping channel is an object property indicating how a 2D image would wrap around a 3D form.

did a trial in Rhino 8. On an mesh objects channel 1, I have a planar mapping of a picture and on channel 2 the mesh is unwrapped. Tried to bake from cannel 1 to 2, but the baked image gets only black.

Hi @Detlef_Muller ,

Thanks for this report. After some experimentation it appears that the BakeMapping command is not working on SubDs. I suspect it is a render mesh issue. I’ve filed this bug as https://mcneel.myjetbrains.com/youtrack/issue/RH-80242 for future reference but in the meantime the workaround I found was to ExtractRenderMesh on the SubD first and use BakeMapping on that mesh object instead.

Does this work with objects with udims and if not is there any future plans to have udims supported in rhino?

UDIM support is currently filed as a request, RH-69319 for future reference. I’ll add your comment to the item but at this time I don’t believe this has been looked into yet.

Hi @BrianJ I tried this BakeMapping command on a new example file but couldn’t get it to work yet.

I’d appreciate if you could take a look and help me again.

The goal is to map the scan texture to a QuadRemesh and if possible SubD

Is BakeMapping supposed to work with SubD by now?

gockel.3dm (19.0 MB)

Hi @martinsiegrist , The color you see on the scan mesh that looks correct is not a texture map. It’s vertex colors. You can delete the material and it still shows up. You’d have to use TestShowPrivateContent to get a Cycles vertex color material type to Raytrace or Render it. So there isn’t an actual mapping method here to bake from one channel to another.

1 Like