2

I'm trying to get a high, medium and low poly version of a mesh working in my game, using the same diffuse and normal map texture. However my models don't maintain their UV coordinates when using Decimate modifier.

I'm very new to Blender but I've created an Asteroid object using Subdivision surface plus Displace modifier.

I apply these modifier once I get the shape I want and then use the sculpting tool to make a few modifications.

I have a rock texture which I set to a high X and Y repeat. It also has Coordinates set to Generated and Projection set to cube. When displaying in Rendered view it looks ok.

So I have a very high level source model with over 300,000 faces. In edit mode I select everything an do Smart UV Project. In the UV/Image editor I see the polys mapped to the texture.

I then use the Bake option to render out the high resolution diffuse map.

I duplicate the object and use the Decimate to reduce it down to 60,000 polys and Bake a normal map using the 300,000 poly version.

I then duplicate it again and create 10,000 poly and 500 poly versions.

However then I create materials that use the baked diffuse and normal maps they don't map correctly any more. It seems Decimate doesn't keep the UV's.

So how an I do this in Blender? I need to take a very high res model and create multiple levels of a mesh but use the same diffuse and normal map.

What am I doing wrong?

Martin
  • 21
  • 1
  • 2
  • 2
    Sounds like a good use case for a multi resolution modifier. That said, since you are using smart UV unwrap, could you duplicate the object, apply the modifier, and re-unwrap for each detail level? – gandalf3 Oct 20 '14 at 20:49
  • @someonewithpc Actually the decimate modifier does preserve UVs. – gandalf3 Oct 20 '14 at 20:57
  • @gandalf3 then what's the point of the question? – someonewithpc Oct 20 '14 at 20:59
  • @someonewithpc How should I know!? ;) – gandalf3 Oct 20 '14 at 21:01
  • @gandalf3 I could remap each lod, but I would need separate diffuse and normal map textures for every lod which is a bit of a waste of memory. – Martin Oct 20 '14 at 21:07
  • @Martin What version of blender are you using? – gandalf3 Oct 20 '14 at 21:13
  • @Martin if as gandalf3 said, the Decimate modifier maintains the UV, what exactly are you asking? – someonewithpc Oct 20 '14 at 21:13
  • @someonewithpc I have a feeling it's because the UVs don't match up exactly. With less geometry with which to define UV coordinates, this imprecision is kinda unavoidable.. – gandalf3 Oct 20 '14 at 21:21
  • Oh... Yes, that makes sense :D – someonewithpc Oct 20 '14 at 21:27
  • This is what I'm seeing. The original mesh is very detailed and has small triangles. When this unwraps it can put some polys by themselves. It can also make holes, which leaves a black area in the texture. However when decimated the UV's may still be in the correct place but the polys themselves can cross over black areas of the texture as they aren't as accurate. Not sure how to avoid this? – Martin Oct 20 '14 at 21:35
  • If you want to post the .blend file I'll go through a few methods I use to lower mesh resolution while preserving UV's and if I can find something for your particular case I'll post an answer that walks you through it. Just please leave out the textures for this one since they won't be needed for this. If it's too big for PastAll.org, you can load it to a DropBox account. – MarcClintDion Oct 21 '14 at 01:50
  • Thanks for the advice all. @MarcClintDion that's a very generous offer, but after a little more messing about I've found what I'm looking for. I can unwrap the initial cube and mark all the edges as seems. Then when using Decimate go into the mesh and move the edge UV's back to the very edge of the texture. This would take quite a bit of time and I now have a lot more appreciation for how complicated modelling is. I've decided to use Triplanar texturing in the game as this works really well and I can have destructible asteroids without the need to recalculate the UV mapping. – Martin Oct 23 '14 at 08:34

0 Answers0