Search Unity

  1. Unity 2018.3 is now released.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. Want more efficiency in your development work? Sign up to receive weekly tech and creative know-how from Unity experts.
    Dismiss Notice
  4. Build games and experiences that can load instantly and without install. Explore the Project Tiny Preview today!
    Dismiss Notice
  5. Nominations have been announced for this years Unity Awards. Celebrate the wonderful projects made by your peers this year and get voting! Vote here!
    Dismiss Notice
  6. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  7. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

ProBuilder What is causing these faces to have their UVs flipped?

Discussion in 'World Building' started by dgoyette, Nov 22, 2018.

  1. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    886
    Here's something that's happening as I adjust the UV offset of some faces:

    UV Offset.gif

    Note that the upper faces move in the opposite direction as the lower faces.

    What causes this? If I select the lower faces and choose "Flip U", then everything lines up perfectly. But those properties are very fragile. (If I later select two faces, one that has Flip U and one that doesn't, Flip U gets unchecked on all faces.) Is there a way to tell ProBuilder not to flip the faces like this, while still using Auto mode?
     
  2. gabrielw_unity

    gabrielw_unity

    Unity Technologies

    Joined:
    Feb 19, 2018
    Posts:
    230
    Hi! Sorry, this is definitely a bug. Can you repro it on any mesh at all, or is it just this one? I'll try to repro and get it ticketed here, also. Thanks for the headsup!
     
  3. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    886
    I'll see if I can get this into a test case. If so, I'll submit a ticket and include the bug report URL here.
     
  4. dgoyette

    dgoyette

    Joined:
    Jul 1, 2016
    Posts:
    886
    This was actually easy to reproduce. I've submitted bug #1103279 (https://fogbugz.unity3d.com/default.asp?1103279_39p00aoettd6huu1) about this, but here's the short version: Bridge Edges adds faces with a Texture Group of 0, rather than using the Texture Group associated with nearby faces. To reproduce:

    Create a new PB cube, and make it tall and wide (drag the top face up about 10 units, and the right face right about 10 units). Add some edges between the faces using the Connect Edges, creating a square in the middle of the face.

    upload_2018-11-22_21-38-38.png

    Note in in the UV editor that things look fine. Now delete that middle face (backspace with it selected), then select the edges above and below the gap, and choose "Bridge Edges":

    upload_2018-11-22_21-39-6.png

    Now note that the newly added face is on the opposite side of the UV chart. Adjust the X Offset will move the texture in the opposite direction it normally would. Clicking "Flip U" for this face will put it back where it "belongs" in the UV chart:

    upload_2018-11-22_21-39-20.png

    HOWEVER, one more issue is that Flip U won't "stick". After clicking Flip U on this face, shift-click any other face, so that the central face and another face are selected. The UI will show that Flip U is no longer even partially checked:

    upload_2018-11-22_21-39-41.png

    And the UV window is now lying, as it's still showing that central face where is "belongs". But now just adjust the X-offset any amount and the central face will pop back over to the right again:

    upload_2018-11-22_21-39-54.png

    So, two issues:
    • Bridge Edges is adding faces that are U-flipped. This can be corrected later by changing the Texture Group of those faces to match the texture group of its neighbors.
    • Selecting a U-Flipped face and then multi-selecting another non-U-Flipped face will clear the U-Flipped flag from the first face.
     
  5. gabrielw_unity

    gabrielw_unity

    Unity Technologies

    Joined:
    Feb 19, 2018
    Posts:
    230
    Thanks very much!! I'll look into this ASAP.
     
  6. gabrielw_unity

    gabrielw_unity

    Unity Technologies

    Joined:
    Feb 19, 2018
    Posts:
    230
    Hmm, ok, I've tested this in our latest internal, and it works fine actually, so there must have been some fixes that directly/indirectly affected it. However, I did find some other UV related issues (including the Flip U not sticking) that are still kicking around, and will get those logged. The main problem with UV stuff is...well, the entire system just needs an overhaul. That's yet another thing we're working towards :)

    Thanks for all the info!