Home Technical Talk

Baking normals in Modo: what could be the cause of those artifacts?

polycounter lvl 10
Offline / Send Message
bac9-flcl polycounter lvl 10
I'm a beginner with Modo so maybe I'm making some very basic mistake, since I was unable to find any mentions of a similar issue on Google. I'm trying to follow this very basic normal baking tutorial involving use of a single lowpoly mesh to bake normals. No high poly geometry, no cages, nothing special: https://www.youtube.com/watch?v=53UIMqL3ec8

Except I'm getting these strange artifacts on about half of my UV islands every time I attempt a normal bake:





As you can see, the artifacts look different every time - almost as if they were a product of z-fighting or something. Not sure how z-fighting can find it's way into the baking setup and produce those kinds of colors, though, so it's probably not it.

I'd appreciate any ideas. :)

Replies

  • igi
    Options
    Offline / Send Message
    igi polycounter lvl 12
    @bac9-flcl  run mesh cleanup command on your low-poly mesh a couple of times.
     make sure your hi-poly(source mesh) don't have any uv map. If it has an uv map then make sure it don't have same uv map name with low-poly uvs.
     hide all other meshes except the ones that are subject to bake
     make sure your normal map texture locator directed to correct uv map name. 
     As a side node normal maps must be saved with linear colorspace. Your normals are now saved with sRGB colorspace which is the default color output for Modo renderer.

  • bac9-flcl
    Options
    Offline / Send Message
    bac9-flcl polycounter lvl 10
    @igi Thanks for the quick response!

    I assume that you're referring to UV channels with "UV map name". As far as I'm aware, it's impossible to remove UV data from a mesh, the fields for those coords are always in place - at least in the FBX format I'm using to import the geometry to Modo. Would simply offsetting or otherwise corrupting (e.g. moving all vertices to 0,0) UV data of the source FBX acceptable, or there is a Modo tool for removing UV channels altogether, perhaps? Or maybe, if Modo is treating UV channels not as entries in an array accessed by index, but as standalone named entities, there is a field somewhere allowing you to rename the imported UV data sets? I can then locate the UV data from the source mesh and rename it, if that's the root of the issue.

    Edit: A-ha, found the Lists tab section where UV sets are presented - yup, they can be renamed and deleted there. Trying to bake in a min.


  • bac9-flcl
    Options
    Offline / Send Message
    bac9-flcl polycounter lvl 10
    @igi Unfortunately, removing UV channels from the highpoly bake made no difference.




    I've also tried renaming the highpoly UV maps (no effect) and various hiding/unhiding combinations (leaving both meshes hidden, leaving only LP visible, leaving only HP visible - no effect from that either). 

  • bac9-flcl
    Options
    Offline / Send Message
    bac9-flcl polycounter lvl 10
    Maybe I'm missing some obvious step that you'll see if I list my actions.

    - File -> Reset
    - File -> Import, choose an FBX file with existing UVs and normals (validated them as properly imported with Game vertex tool and UV view in Modo)
    - Drag the Mesh entity (thing with a cube icon) out of Items "folder" Modo creates for the imported FBX, remove now-empty folder.
    - Right click on the mesh in the Items list, choose Duplicate -> Duplicate
    - Rename original mesh "mesh_lowpoly", rename the duplicate "mesh_highpoly"
    - Select the mesh_highpoly in the list
    - Press "M" on the keyboard, Set Material dialog opens - type in "material_highpoly" into the name field, use Default material type, confirm creation/assignment of material
    - Go to Shading tab, in the list there select Render -> material_highpoly -> Material entry
    - Go to Properties, set Rounded Edge Width to some non-zero value (e.g. 10mm), validate that rounded edges are visible in the Render tab
    - Go to Bake Wizard, set some base filename and directory, choose UVChannel_1 in the "UV" field
    - Go to next step, check mesh_lowpoly as Target and mesh_highpoly as Source
    - Go to Shading tab, open Add Layer menu, choose Image map -> (new image), select a suitable file
    - Open Effect list on the newly created image entry now listed under Render in the Shading tab, choose Surface Shading -> Normal there
    - Return to Bake Wizard, go to next step, select your image map as Bake output
    - Go to next step, press Bake

    That's all I'm doing atm. Maybe I'm missing some important step? I'm aware that I should use a different color space and so on, but I'd like to solve those artifacts first.
  • igi
    Options
    Offline / Send Message
    igi polycounter lvl 12
    @bac9-flcl
    Your model might be corrupted. Use 'mesh cleanup' tool under 'mesh edit' tab to fix possible errors, use it a couple of times to be sure. 
    Do you have a cage? If you're using ray distance method, fiddle with different distance values. 
    Validate that your mesh isn't exported with too small or too big sizes. Go to 'Snap and Precision-->Absolute Scaling tool under 'Basic' tab. Select your mesh and then click 'grab size'. This tool will give you the dimensions of your mesh. Make sure it isn't absurdly small or big. 
     Sometimes Modo overlaps the datas of the meshes that share same UV names, usually happens when using no material(base material).
     There's options in baker wizard that overrides visibility of your meshes in the scene. If you checked bake hidden there then modo will bake it no matter what.
     Put your normal map texture item inside of your lowpoly material folder in shader tree.
     
     You can bake normal map without baker wizard too. In shader tree Add Layer-->New Image. Change image type to normal. Go to texture locator properties of your newly created blank normal map texture and assign the UV Map to be baked on. Set up your hi and low properly then right click on your normal map item and select 'Bake from Object to Texture'. It will open a dialogue box to enter your ray distance or specify a bake cage morph map. Then bake. 
     




Sign In or Register to comment.