Cubemap lookup with normalmap "bumps"

Posts: 1,199
Joined: 2004.10
Post: #16
The above code may not produce an accurate gaussian blur, but the results are optically speaking very good quality. No seams! Good smooth blur!

The following code loads an equirectangular panorama into a cubemap, and performs the blur for specular and diffuse. The following screenshots show the quality of those blurs.

TextureRef panorama = TEXTURE( PATH( IBL_PANORAMA ), Texture::RECT );
TextureInterfaceRef cube = GenerateCubemapFromPanorama( panorama, 512 );

_iblSpecular = BlurCubemap( cube, 15, 1 );
_iblDiffuse = BlurCubemap( cube, 30, 4 );

And here's the diffuse ( no lights! Just the heavily blurred diffuse map:
[Image: ibltest-2009-01-13-01.png]

And here's the specular:
[Image: ibltest-2009-01-13-03.png]

So while it might not be accurate, it looks pretty decent.
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Panorama -> CubeMap TomorrowPlusX 2 4,078 Jan 4, 2009 07:52 AM
Last Post: TomorrowPlusX
  cubemap always reflects same direction. NYGhost 6 5,303 Jul 6, 2006 05:56 PM
Last Post: NYGhost