Home Technical Talk

Creating Ambient Occlusion maps and using them

kevingamerartist
polycounter lvl 6
Offline / Send Message
kevingamerartist polycounter lvl 6
Hi all,
I have a question about Ambient Occlusion maps. So I know you can use them on your models, however if you are using UDK/Unreal or a game engine that renders Ambient Occlusion automatically, do you still need to create Ambient Occlusion maps and apply them to your models?

I'm using UDK 2013 for a game engine, not Unreal 4.

I use Crazybump to create Ambient Occlusion maps, but I don't know if that's a good program to use to create them. Should I try to create one through Photoshop,Maya, or ZBrush? I would probably use PBR programs for this instead, however that option is not available to me at this time.

I feel like it's probably a good habit to create Ambient Occlusion maps for your 3D models, however I don't know if I need to create them if the game engine already renders the Ambient Occlusion for me. Should I create Ambient Occlusion maps to put them in my portfolio so that I know how to create them when I apply for Junior Environment Artist/Prop Artist positions?

Any feedback on this question is greatly appreciated. Thank you! :)

Replies

  • Farfarer
    Options
    Offline / Send Message
    The automatic ambient occlusion will generally only be based off the raw geometry (whether it be lightmapped or a depth-buffer based ambient occlusion post effect like SSAO). So it doesn't take into account any details of the texture.

    So you'll probably want to have an ambient occlusion texture, which captures AO from texture detail.

    If you can, it's worth baking it from a high polygon mesh, as you'll get the most accurate results. If you're unable to, then generating it through CrazyBump will probably do (although I'd recommend Knald for that).

    Ambient occlusion's role has changed slightly with PBR. Where before you'd tend to include it into your diffuse texture and specular textures, to try and fake the occlusion of ambient light (but the downside of that is that it occludes ALL lights, not just the ambient light), with PBR it's generally kept as a separate texture and it's used to only occlude the actual ambient light, rather than all light sources.

    As for just generating things for the sake of including the texture in your portfolio... if you're not actually using the texture, I wouldn't include it.
  • kevingamerartist
    Options
    Offline / Send Message
    kevingamerartist polycounter lvl 6
    Farfarer: Thank you for the information :)
    So when I create the Ambient Occlusion map, do I bring it into Photoshop and set to Multiply over the Diffuse texture, or do I add an Ambient Occlusion node to my shader in Maya and apply the AO map there?
  • Farfarer
    Options
    Offline / Send Message
    You can plug it in on Maya if there's a place for it. Not sure that'll carry over to a game engine though.
  • kevingamerartist
    Options
    Offline / Send Message
    kevingamerartist polycounter lvl 6
    Farfarer: I tried rendering Ambient Occlusion in ZBrush with some of the objects that I have created, but some of them just don't seem to render Ambient Occlusion at all. Is that the situation where you suggested to use the Ambient Occlusion map that can made from CrazyBump?
  • Farfarer
    Options
    Offline / Send Message
    I'm not certain.

    I'd recommend using xNormal to bake stuff, rather than ZBrush.
  • WaYWO
    Options
    Offline / Send Message
    WaYWO greentooth
    Also if you bake your normal map fine, your AO will be bake fine too. You can render ambient occlusion using transfer map in maya or you can render ao on mesh itself with mib amb occlusion shader not sure how its called? from mental ray texture bake set :poly121:
  • kevingamerartist
    Options
    Offline / Send Message
    kevingamerartist polycounter lvl 6
    Farfarer: I have seen with some of my objects that Ambient Occlusion is not rendering any shadows sometimes, will some objects not have AO maps depending on what the Diffuse map is, or does it just depend on what you are modeling?

    WaYWO: Thank you for the information :)
    I have done AO renders for some of my objects in Maya, however it seems that some objects that I have made or Diffuse maps that I have made do not produce any AO maps, unless AO does not apply to every object or Diffuse map that you create.
  • Farfarer
    Options
    Offline / Send Message
    Ambient occlusion has nothing to do with the diffuse texture, it's purely geometry based.

    If you're seeing that there isn't any ambient occlusion being baked, it's possible you have a very simple convex mesh or there's something going wrong with the baking process.
  • kevingamerartist
    Options
    Offline / Send Message
    kevingamerartist polycounter lvl 6
    Farfarer: One more thing I forgot to mention is that with a lamp that I have, I do know that it can have an AO map, however when I'm using xNormal to bake the AO map, the map will look fine when it's about done, but then when it's completely finished rendering, or when it says it's Rendering Data, then the shapes of the textures come out in some sort of blocky texture/render or something. I don't know what it is, but I know when I first started using xNormal again and tried it with one object, it worked just fine, but then something went wrong and I don't know what the issue is. Do you know what could be causing that issue?
  • Farfarer
    Options
    Offline / Send Message
    I can't say unless you showed pics of the meshes, UVs and resulting bake.

    My first suspicion would be that you've got overlapping UVs on your mesh.
  • malcolm
    Options
    Offline / Send Message
    malcolm polycount sponsor
    To add a bit more detail to this discussion Unreal 4 can auto generate AO in screen space taking the normal map texture into account that's applied to your object so you don't have to bake high frequency AO into a texture. That being said it costs frame rate to do this as I believe you need a full res render buffer pass or whatever that's called to keep it looking nice. If anyone is interested here is a link to the technique with images. Depending on how you want to spend your frame rate this could be practical.

    Open the file and then look at page 39-40
    http://advances.realtimerendering.com/s2012/Epic/The%20Technology%20Behind%20the%20Elemental%20Demo%2016x9.pptx
  • kevingamerartist
    Options
    Offline / Send Message
    kevingamerartist polycounter lvl 6
    Farfarer: I don't think I have overlapping UVs on my mesh. I'll try to show images of what I'm talking about, but this will be the first time I'm trying to show an image on Polycount.

    On the left is my Diffuse map, and on the right is the AO map I rendered from xNormal. I don't know if it's a result that I didn't align them properly in Maya and that caused the result with the AO map, or if it's something else. Are you asking to see images of my actual mesh?
  • BagelHero
    Options
    Offline / Send Message
    BagelHero interpolator
    Without seeing your mesh, that looks like the correct AO output. Are you talking about the Edge Padding? Seriously, though, before worrying about things like that, apply it to your mesh in engine. Are there any visible problems there?
Sign In or Register to comment.