Sign in to follow this  
urgrund

WorldSpace - Texels? Ambient Occlusion Map

Recommended Posts

I'm not very experienced in graphics programming, but i recently got a per-vertex ambient occlusion tool working in an engine project I muck around in... what I'd like to do is make a per-pixel (texture map) version of it. I need some help in how to approach this. So far, I'm able to create a new texture and run it through a D3DXFillTexture() function and output the file to disk.. no problems there. Now, I'm thinking that for each texel the function runs over, I will need to know it's relative worldspace position in order to ray cast and resolve a final value... this is where I need some help! How would you approach this? How do you map world positions of a texel to it's RGB values? Is this even needed for what I'm after? So - just a few pointers in the right direction would be great as I've never worked with textures like this before! Thanks!

Share this post


Link to post
Share on other sites
The topic is quite complicated, look at radiosity and lightmaps, the notions are basically the same.
Are you sure you need per pixel AO in the first place? AO simply varies slowly, a smart tassellation will probably be more than enough. AO is well suited for interpolation.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this