Jump to content

  • Log In with Google      Sign In   
  • Create Account


#ActualAshaman73

Posted 29 October 2012 - 01:38 AM

In short, sperical harmonics are way to compress incoming light. A very simple spherical harmonic would be a vector and a cone (4 parameters) which could be used to tell from which direction light up to a certain angle (cone) is coming. The vector AO version is therefore more or less a spherical harmonic, but the issue is, that it can only describe the incoming light from a single direction.

Now, you can increase the accuracy of this by increasing the resolution of a spherical harmonic and this is memory intensive (+more arithmetic). So, if you want to keep it at a sane level (i.e 9 parameters) you only have a resolution which can handle low-frequency distribution of incoming light in a satisfying way.

Taking a cube map into account you could map the incoming light on this cube map instead of a sphere, which would give you an incredible resolution (=light probe).

The issue is now the task you want to solve. A single spherical harmonic at a single point saved as cube map is a great way to adjust the lighting of a character etc. but for global illumination you want it for each texel, much like AO. Simple precalculated AO has only a value of 1 byte, a 9 component SH with 16bit floats has 18x memory consumption of a simple AO term which is quite heavy.

Hope it helps you to get a better feeling for SH.

#2Ashaman73

Posted 29 October 2012 - 01:36 AM

In short, sperical harmonics are way to compress incoming light. A very simple spherical harmonic would be a vector and a cone (4 parameters) which could be used to tell from which direction light up to a certain angel (cone) is coming. The vector AO version is therefore more or less a spherical harmonic, but the issue is, that it can only describe the incoming light from a single direction.

Now, you can increase the accuracy of this by increasing the resolution of a spherical harmonic and this is memory intensive (+more arithmetic). So, if you want to keep it at a sane level (i.e 9 parameters) you only have a resolution which can handle low-frequency distribution of incoming light in a satisfying way.

Taking a cube map into account you could map the incoming light on this cube map instead of a sphere, which would give you an incredible resolution (=light probe).

The issue is now the task you want to solve. A single spherical harmonic at a single point saved as cube map is a great way to adjust the lighting of a character etc. but for global illumination you want it for each texel, much like AO. Simple precalculated AO has only a value of 1 byte, a 9 component SH with 16bit floats has 18x memory consumption of a simple AO term which is quite heavy.

Hope it helps you to get a better feeling for SH.

#1Ashaman73

Posted 29 October 2012 - 01:35 AM

In short, sperical harmonics are way to compress incoming light. A very simple spherical harmonic would be a vector and a cone (4 parameters) which could be used to tell from which direction light up to a certain angel (cone) is coming. The vector AO version is therefore more or less a spherical harmonic, but the issue is, that it can only describe the incoming light from a single direction.

Now, you can increase the accuracy of this by increasing the resolution of a spherical harmonic and this is memory intensive (+more arithmetic). So, if you want to keep it at a sane level (i.e 9 parameters) you only have a resolution which can handle low-frequency distribution of incoming light in a satisfying way.

Taking a cube map into account you could map the incoming light on this cube map instead of a sphere, which would give you increadible resolution.

The issue is now the task you want to solve. A single spherical harmonic at a single point (light probe) saved as cube map is a great way to adjust the lighting of a character etc. but for global illumination you want it for each texel, much like AO. Simple precalculated AO has only a value of 1 byte, a 9 component SH with 16bit floats has 18x memory consumption of a simple AO term which is quite heavy.

Hope it helps you to get a better feeling for SH.

PARTNERS