- Home /
Mesh UV Properties
Hi guys, I'm starting to mess around with procedural mesh generation in Unity. I have a question that I hope someone here can help me with. What are the differences between mesh.uv, mesh.uv1 and mesh.uv2 ? I know that Uvs are used to map the textures coordinates for a 3D object, but why do I need a uv1 and a uv2 for?
Answer by Eric5h5 · Mar 24, 2013 at 11:44 PM
uv and uv1 are the same. Any 3D app has the ability to have multiple uv sets per object, so uv and uv2 are the first two uv sets. Light mapping is a typical use for a second UV set.
@Eric5h5 I have applied a uv2 to my mesh and used a self-illum diffuse shader. Do you have any idea why the shader is ignoring uv2 for the lightmap and uses uv to set the light?
I'm currently playing around with meshes too - I thought I'd post here because it is the top hit on Google, excluding the manual pages.
From what I've seen $$anonymous$$esh.uv is not the same as $$anonymous$$esh.uv1. $$anonymous$$esh.uv1 is, however, identical to $$anonymous$$esh.uv2 (as of Unity 4.3, anyhow). The manual page for $$anonymous$$esh doesn't actually list uv1 as being part of the official interface, so I suspect it is supposed to be deprecated.