GoB
GoB copied to clipboard
Uvs are flipped when sent to ZB
Discussed in https://github.com/JoseConseco/GoB/discussions/384
Originally posted by canderled December 8, 2022 Hello guys, is there an option or a way to avoid aving the UVs being flipped when sent to and imported from ZB using the GOB ? this is specially annoying when working with udim.
@canderled I changed the way meshes are flipped in the version linked (3.5.99), it would be great if you could give this a try and let me know if it still causes the same uv mirroring for you. Be aware that this is still work in progress and you most likely will encounter some issues with mesh translations. https://github.com/kromar/blender_GoB/tree/feature/keep-transfomrmations
Note: there are new options in the export/import tabs to specify the model transformations
@kromar Thanks for checking this issue. Still got the flipped UV in ZBrush.
I also discover another bug but I think it's on GoZ/Zbrush side. Look like GoZ rename - to _ when exporting(Cube-A to Cube_A) so when it got back to Blender, the mesh isn't replaced.
so as long as you transfer with GoB the UV map is ok but when you export a obj from zbrush to blender you get the flipped uv's? does not sound like its a GoB issue but rather a configuration issue on Zbrush, did you try changing the import/export flip options in zbrush to see if you can resolve this issue?
The renaming is a known issue of Zbrush, it can not handle the - and will rename those meshes, unfortunately there is nothing i can do about this since it is closed source from pixologic.
I think it's a GoZ issue then, not ZBrush. the IFlip will actually flip the mesh not the UVs. Not sure if it's hard to add but an option in the GoB addon to flip the UVs both at import and export on the Blender side would solve this issue. I tried to make a script/macro for this but I couldn't make it work in the UVeditor .
I'll check with the pixologic team for the - issue. Thanks
can you upload a .obj or better a .ztl where i can reproduce the issue? so i can export it from zbrush with .obj, import in blender and send it to zbrush again? If i can reproduce it i think it might be possible to fix it somehow
In the Zip^you can get the blender file and ZB file. In the ZB file, you'll find one folder with the GoB mesh (with flipped UV) and one folder with the correct mesh imported the regular way.
In case it can help, here is my workaround in the UVeditor. As I said, I tried to make a script with this but it doesn't work. From what I understood, UVeditor doesn't work like 3D viewport, you need extra line to make it work but it goes far beyond my skills...
bpy.ops.object.editmode_toggle() bpy.ops.uv.select_all(action='SELECT') bpy.context.space_data.cursor_location[1] = 0.5 bpy.context.scene.tool_settings.use_uv_select_sync = True bpy.context.space_data.pivot_point = 'CURSOR' bpy.ops.transform.resize(value=(1, -1, 1), orient_type='GLOBAL', orient_matrix=((1, 0, 0), (0, 1, 0), (0, 0, 1)), orient_matrix_type='GLOBAL', constraint_axis=(False, True, False), mirror=False, use_proportional_edit=False, proportional_edit_falloff='SMOOTH', proportional_size=1, use_proportional_connected=False, use_proportional_projected=False, snap=False, snap_elements={'INCREMENT'}, use_snap_project=False, snap_target='CLOSEST', use_snap_self=True, use_snap_edit=True, use_snap_nonedit=True, use_snap_selectable=False) bpy.ops.object.editmode_toggle()