Multiple UV Channels


Is it possible to get the multiple UV channel UV coordinates for a mesh which has it’s “Texture Mapping” → “Use multiple mapping channels” checkbox enabled please? I am using RhinoCommon Mesh.TextureCoordinates to get the coordinates.



1 Like

If you’re not using the change queue mechanism you’ll have to query the RhinoObject the mesh is from for texture mapping channel ids RhinoObject.GetTextureChannels Method, then get each texture mapping separately RhinoObject.GetTextureMapping Method. Then for each mapping set the mapping to the mesh text coordinates Mesh.SetTextureCoordinates Method and get the texture ccordinates Mesh.TextureCoordinates Property for that mapping.

For a mesh from the change queue you get the mapping collection Mesh.Mapping Property, then do the same procedure: for each mapping set texture coordinates, then retrieve.

disclaimer: I am not 100% certain it works like this. I haven’t implemented support for multiple UV mappings in Rhino Cycles yet. But this is what I’d start with when I get to it soon-ish.

Thanks @nathanletwory - I will try this out when I get some time for R&D. I guess the downside to this approach is that the meshes need to be processed for each texture mapping method, so it is potentially slower than just processing once.


Hi @pkinnane,

I’ve just recently finished this part in RhinoCycles. In my implementation the work starts here:

So loop over each channel, set the texture coordinates, then read those freshly set coordinates.

Awesome - thanks @nathanletwory!