Ambient Occlusion Fields and Decals in Infamous 2




Infanous2
 - deferred- shadering
  - vertex-baked AO

AO - large or small scale
Baked-great but

SSAO great but...


Hybrid approach


 - complement AO . SSAO
 - medium sscale
-  in world space: precompute AO




AO Fields
   - precomputing
      - volume texture
      - voxel is occlusion cone
      - render geometry into 32x32 cube map
      -  read back
   - Applying
            - draw bounding box, pixel shader retrieve world pos
             - blending result into G buffer AO channel using mutltuitive blending
   - Texture details
       size chosen by artist
        format: 8bit RGBA, not DXT
   - Visible Boundary
        - remap alpha values at build time
                - find max alpha value of all voxel
    - incorrect self- occlusion
            - ideally detect interior voxels and fix up



AO decal
    : planar ver. of AO field
    - use cased: thin objects embedded
   - precomputing: store as 2d texture
    - render height map of source geometry
            - parallel projection looking at/floor from front
           
    - applying
         - same as AO field.
          - rgba, depth channel
    - details
         - BB size use 0.7 epsilon instead of 0.25
         - tex size is 64-128 each axis
          - DXT5 format
    - Halos around height changes
           - sol:
     - Edges too soft
            - sol: bake wall-occlusion onto vertices

Fields/ Decals memory used

Fields/ Decals  performance

Future enhancement
    - faster precompute
    - on character
   - undersampling better



Comments

Popular posts from this blog

董事長您好

After reading Steve Jobs Autobiography

Drawing textured cube with Vulkan on Android