Home Technical Talk

Manual LODs and matching UVs

nivao
polycounter lvl 6
Offline / Send Message
nivao polycounter lvl 6
I can't believe I'm still struggling with this after all these years :D

I'm working on a large prop and preparing to create the UVs, bake the base texture maps, and create the LODs. What I can't seem to figure out is the process of doing it. I'm using Houdini after switching from 3ds Max. The base model is pretty much done, and I intend to use UVLayout to make the UVs, and Substance Designer to bake and create the textures. So far so good.

But at this point I'm also trying to figure out how to set up the LODs. The thing is, automated LODs in UE4 work fine for at distance, but I still need one or two manual LODs for close up. The base model has quite a lot of tris and verts, as it's a Hero prop, so I intend to have at least one, maybe two, LODs that serves as the main in-game version. So I created LOD1 manually, which was a cinch with Houdini's workflow.

But that's just the mesh itself. Anything I do to simplify the base LOD will either remove or ruin the UVs anyway. Making the UVs is one thing, but how can I make sure that the UVs of the manual LODs match the UVs of the base LOD? Just unwrapping each LOD the same way (same seams), and then flatten, move, and align the different islands to the UVs of the base LOD? Is that practical?

How do other artists create manual LODs and unwrap them?

Replies

  • Violet
    Options
    Offline / Send Message
    Violet polycounter lvl 9
    Don't remove edges that are borders of UV islands, don't use tris, and keep edge loops flowing. Also using a small separate part of the texture map specifically for some parts of the LOD (ie. the front section of a truck might be made of separate elements) - I've always kept a small portion of the the texture space free for something that might crop up when the work is 99% done. It's just smart modelling in the first place if you're aware you're going to LOD them at a later stage.

    I did pure LOD'ing for a year, and never had much of a problem apart from realising the edge I had just removed was a border in the UV's (resulting in stretching).
  • Obscura
    Options
    Offline / Send Message
    Obscura grand marshal polycounter
    Hey. I'm using Unreals lod tool very often and I rarely have issues with automatically generating lod 1-2. They hold up very good from close too. So I would suggest to try it first and see if if can generate you acceptable lods. It could save you a lot of time.
  • poopipe
    Options
    Offline / Send Message
    poopipe grand marshal polycounter

    @Violet makes good points

    I've built / supervised the building of thousands of AAA assets with multiple (up to 7) manual LODs and am confident in saying that the quality and efficiency of your LODs is determined almost entirely by the UV layout. 

    I generally give this advice to new starters etc.. 

    Build a low LOD, UV it and follow that layout for the high one. ( You can shove the bits that aren't in the low off to one side) 

    This makes manual Lodding easy because you can simply tear geometry out without breaking UVs and also means autolodders can do a better job as they're not hamstrung by disparate UV layouts. 

    It also means your low LODs look good so you can bring them in earlier and make the game go fasterer


  • jRocket
    Options
    Offline / Send Message
    jRocket polycounter lvl 18
    Not sure  how this would be done in Houdini, but there should be a way to project your base UVs into your LOD UVs. Otherwise you can just manually make sure that they are lined up.
  • nivao
    Options
    Offline / Send Message
    nivao polycounter lvl 6
    Obscura said:
    Hey. I'm using Unreals lod tool very often and I rarely have issues with automatically generating lod 1-2. They hold up very good from close too. So I would suggest to try it first and see if if can generate you acceptable lods. It could save you a lot of time.
    I did try them. As I said, they work great for at a distance, but don't produce good results for close up. With my model, the tool doesn't make very good geometry, which is very noticeable at close range. Essentially, LOD1 will serve as the base LOD of the functional prop with maybe LOD2 for background props, while LOD0 will be a Hero model for close ups and cinematics or higher graphic settings.
    jRocket said:
    Not sure  how this would be done in Houdini, but there should be a way to project your base UVs into your LOD UVs. Otherwise you can just manually make sure that they are lined up.
    Yes there is a way with the GameDev toolset. There's a node to transfer UVs based on how the LODs overlap in world space. But it rarely produces good results, at least in this case, as it keeps collapsing edges (I have face-weighted normals with chamfered edges).

    Essentially, what I'm planning to experiment with the next time I can work on this, is to prepare base UVs (seams mostly) in Houdini, then unwrap LOD0 in UVLayout. Once those UVs are finished, I'll "lock" them and import each of the two other LODs to align all the UV islands. I can pin border vertices and snap them to the same points on the other UVs, then re-flatten them so they match up. I did some experiments after posting here, and it seems it can work; it'll just take a little more time. But I think by preparing as much as I can in Houdini (matching seams, and even pre-flattening) I can save some time.
  • poopipe
    Options
    Offline / Send Message
    poopipe grand marshal polycounter
    I'll attempt to make my point again...

    You will get shit and/or inefficient low LODs if you layout UVs based on the high LOD without planning for the structure of the low LOD. 

    Everything works better if you have the low lod in place before you start unwrapping. 

    Most of the problems you are trying to solve will simply disappear using this approach. 
  • nivao
    Options
    Offline / Send Message
    nivao polycounter lvl 6
    poopipe said:
    I'll attempt to make my point again...

    You will get shit and/or inefficient low LODs if you layout UVs based on the high LOD without planning for the structure of the low LOD. 

    Everything works better if you have the low lod in place before you start unwrapping. 

    Most of the problems you are trying to solve will simply disappear using this approach. 

    But it's already planned. That's what I'm saying. It only concerns the first one or two LODs after the base model. Both the LODs and UV seams were made with the LOD in mind. In fact, the original model has become LOD1 and I've created a slightly more detailed version for LOD0. The issue I was having had to do with how to get the UVs to match up when LODing manually. I don't see how unwrapping the lowest LOD first would make it easier, other than ensure the most critical edges that exist in all LODs are in place for the UV seams. If anything, I think trying to align the UVs of higher LODs to the lowest LOD will be harder because there's more geometry to manipulate.

    I do think your method works, but I just don't think it's necessary for my current model. However, one question about that method: how can you unwrap the lowest LOD when the higher LOD will have so much more geometry to unwrap and pack? If you complete the UVs of the lowest LOD, wouldn't there not be enough space for all the extra geometry of the higher LODs? The highest LOD is the one closest to the camera, so the UVs should be perfect, but the lower the LOD the further away the camera will be, so the less clean and non-distorted the UVs have to be (as long as the important seams still match up). Most low LODs I've seen are unwrapped in a sensible way over the texture, but they are nothing like the UVs of the base LOD. And texel size for the higher two LODs are fairly important, because the normal map will have important details that need to be visible, so the UVs need to maximize the UV space.
  • poopipe
    Options
    Offline / Send Message
    poopipe grand marshal polycounter
    I see you've thought it through further than I understood from the earlier posts - assumptions are risky, sorry :) 
    The main reason for using the low lod is to define the major seams - which you have identified. 

    Our priorities may differ a little - 
    My experience is that a player spends more of their time looking at medium and low LODs than they do high LODs - as such I tend to prioritise hiding lod transitions and maintaining quality in the middle of the lod chain over perfect, undistorted UVs on the higher LODs. 

    In terms of how I usually do it - I use the planar map gizmo on selected faces a lot and accept some distortion on bevels - using a constant sized mapping gizmo means texel density remains consistent so its easy to lay mapped sections over top of each other. 
    Any faces in the higher lod that are perpendicular or at steep angles to the planar gizmo get torn off and shoved into gaps where they fit - Ill try to overlap and reuse uv space on those as much as possible. Anything that significantly affects silhouette will be defined in the lower LOD so should already have some space allotted. 

    Mesh normals can be projected in the same way to minimise lighting artefacts during LOD transitions.

    I also work on the assumption that texel density will be constant across all similar assets so I'm not trying to fill the page, I'm making things the right size and taking a guess at how much extra space I'll need for the extra bits of high LOD when I decide how big my map needs to be. 

     
Sign In or Register to comment.