How to make a uvpass?

Is there a way to render a UV pass with vray?
In mentalray you can use a mib_texture_vector node and set its projection to uv. Then render that out with a writeToCustomColorBuffer.
In Vray i guess i’ve to make a extraTexElement. But what can go in there to give me the UV information out?

Thanks!

extraTexElement with vraysamplerinfo set to UVW

You can use Maya’s “Sampler Info” node for this. More specifically, the uvCoord output. You’ll need to manually connect the uCoord and vCoord to the red and green inputs of the extra tex node.

There is no VRaySamplerInfo in V-Ray for Maya as far as I know, it’s Max only for now. Most of the VRaySamplerInfo outputs are part of Maya’s “Sampler Info” anyway.

Greetings,
Vladimir Nedev

Awesome, thanks.

It could be useful to set your output to 32bit float in case your uvs go far beyond 0-1 range…we have that very often…

Ok, thanks.

Ok, I tried that. For some reason vray doesn’t render the uv information, even if i apply the samplerInfo to a surface shader. Maya Software does. Any ideas?

Hm, there seems to be a bug there and I’m looking into it. In the meantime, you can use the V-Ray “UVWTex” texture instead of the samplerInfo one: go to Create > V-Ray > Create texture from V-Ray plugin and choose the “UVWTex”.

Best regards.
Vlado

EDIT: Doesn’t work as a element, either. Only as a color texture. Other values, such as the pointWorld and pointCamera get translated to the renderElements correct, btw.

Yep; this is now fixed for the next night build tomorrow. In the meantime you can use the UVWTex approach.

Best regards,
Vlado

Thanks, so it’s time for weekend now :slight_smile:

Both the samplerInfo and the UVWTex work now. Thank you!