Page 1 of 1

UV Set setting in Baking Camera

Posted: Mon Jan 09, 2023 7:22 pm
by Hoffguy
I know the UV set field does not function inside of materials, the help file says as much. But according to the help file, the UV Set in the octane camera tag baking camera section should be able to set which UV to bake to. When I change UV set in the tag, the render output just goes black. Is this UV set functional?


I'm trying to have 1 UV tag that is being used to map a texture onto geometry, and the baking camera bake this out to 2nd UV tag on the same geometry's UVs.
Image
Image

Re: UV Set setting in Baking Camera

Posted: Mon Jan 09, 2023 8:53 pm
by jayroth2020
A corresponding UV set needs to be present in the object. How are you defining your UV sets?

Re: UV Set setting in Baking Camera

Posted: Mon Jan 09, 2023 10:18 pm
by Hoffguy
jayroth2020 wrote:A corresponding UV set needs to be present in the object. How are you defining your UV sets?
Two different c4d UV Tags. Is there another way?

Re: UV Set setting in Baking Camera

Posted: Mon Jan 09, 2023 11:45 pm
by jayroth2020
That is what Octane expects, so I recommend you submit a ticket and we will take a look: [email protected] Make sure you do a File > Save Project with Assets... archive the results and send it in.

Re: UV Set setting in Baking Camera

Posted: Tue Jan 10, 2023 1:09 pm
by jobigoud
There might be some confusion because this sentence is confusing to me: "the baking camera bake this out to 2nd UV tag on the same geometry's UVs", and the fact that you used UV set = 1 and Baking group ID = 2 makes me think there is maybe something misunderstood.

The baking camera creates a texture. To create that texture it needs to map the geometry to the camera pixels, as if the camera was a texture. This mapping uses the "UV set" parameter. So if you want the baking camera to use the second UV set you should set it here UV set = 2. This implies that when you use the result of this baking somewhere else you will have to use that second UV set to map the texture created onto the geometry.

The baking group ID is completely different and makes sense if you also have an object layer attached to the geometry with the corresponding value in its Baking group ID field. It lets you bake a very specific object if you have several in the scene. If you don't have any object with baking group ID = 2 you will get a black picture.

Note that the mapping of UV to camera is the inverse operation as typical texture mapping (it goes from a given UV on the output image to the corresponding polygon) and so it can only work if you have non-overlapping triangles in your UV map. If your UVs have coordinates outside the unit square you also need to specify it here in UV region.

Re: UV Set setting in Baking Camera

Posted: Tue Jan 10, 2023 3:39 pm
by Hoffguy
jobigoud wrote:There might be some confusion because this sentence is confusing to me: "the baking camera bake this out to 2nd UV tag on the same geometry's UVs", and the fact that you used UV set = 1 and Baking group ID = 2 makes me think there is maybe something misunderstood.

The baking camera creates a texture. To create that texture it needs to map the geometry to the camera pixels, as if the camera was a texture. This mapping uses the "UV set" parameter. So if you want the baking camera to use the second UV set you should set it here UV set = 2. This implies that when you use the result of this baking somewhere else you will have to use that second UV set to map the texture created onto the geometry.

The baking group ID is completely different and makes sense if you also have an object layer attached to the geometry with the corresponding value in its Baking group ID field. It lets you bake a very specific object if you have several in the scene. If you don't have any object with baking group ID = 2 you will get a black picture.

Note that the mapping of UV to camera is the inverse operation as typical texture mapping (it goes from a given UV on the output image to the corresponding polygon) and so it can only work if you have non-overlapping triangles in your UV map. If your UVs have coordinates outside the unit square you also need to specify it here in UV region.
Sorry for the confusion. I'm using the baking group id for a different function than my question. The file is baking 5 different UV sets out from 5 different pieces of geometry, in 5 different takes, hence the Baking Group ID to differentiate.

Simply put, I want to texture an object using UV tag 1, and baking-camera render that texture out to UV tag 2. My final output UV texture layout needs to stay constant, but I want to use a different UV tags for texturing to allow for different mapping.

Re: UV Set setting in Baking Camera

Posted: Tue Jan 10, 2023 4:31 pm
by Hoffguy
jayroth2020 wrote:That is what Octane expects, so I recommend you submit a ticket and we will take a look: [email protected] Make sure you do a File > Save Project with Assets... archive the results and send it in.
I've submitted a ticket with a simplified example c4d project highlighting the issue. Appreciate the help!