Download presentation
Presentation is loading. Please wait.
Published byMatilda Owen Modified over 8 years ago
1
Atmospheric Effects Interactive Rendering of Atmospheric Scattering Effects Using Graphics Hardware Tsuyoshi Yamamoto Tomoyuki Nishita Tokyo University Yoshinori Dobashi Hokkaido University
2
Atmospheric Effects Overview Introduction Rendering Light Beams Rendering the Earth’s Atmosphere - motivation - previous work - basic Idea - problems - high quality rendering - rendering sky - rendering the earth viewed from space Results Conclusion
3
Atmospheric Effects Overview Introduction Rendering Light Beams Rendering the Earth’s Atmosphere - motivation - previous work - basic Idea - problems - high quality rendering - rendering sky - rendering the earth viewed from space Results Conclusion Introduction - motivation - previous work Rendering Light Beams - basic Idea - problems - high quality rendering Rendering the Earth’s Atmosphere - rendering sky - rendering the earth viewed from space Results Conclusion
4
Atmospheric Effects Overview Introduction Rendering Light Beams Rendering the Earth’s Atmosphere - motivation - previous work - basic Idea - problems - high quality rendering - rendering sky - rendering the earth viewed from space Results Conclusion
5
Atmospheric Effects Real-time rendering of realistic images Real-time rendering of realistic images Atmospheric Scattering Effects Motivation - spotlights - sunlight through windows - earth’s atmosphere Real-time rendering of atmospheric effects Real-time rendering of atmospheric effects Our Goal: requires long computation time - scattering and absorption of light due to small particles
6
Atmospheric Effects Previous Work - use of voxels to store the intensity of light Volume rendering [e.g. Behrens98, Westermann98] - consuming texture memory for volume data - difficult to capture the edges of shafts of light edges of spotlight edges of shadows
7
Atmospheric Effects Previous Work Interleaved sampling [Keller01] - a general and efficient solution to the sampling problem - not optimal for rendering atmospheric scattering 2D texture based approach [Dobashi01, Everitt99] Earth’s atmosphere - no methods for real-time rendering of realistic images - use of shadow and projective texture mapping - artifacts due to sampling errors
8
Atmospheric Effects Proposed Method Rendering light beams - point/infinite light sources - uniform density of atmospheric particles Rendering earth’s atmosphere - sky - density decreases exponentially according to the height from the ground - the earth viewed from space Precise and efficient rendering of atmospheric effects
9
Atmospheric Effects Overview Introduction Rendering Light Beams Rendering the Earth’s Atmosphere - motivation - previous work - basic Idea - problems - high quality rendering - rendering sky - rendering the earth viewed from space Results Conclusion
10
Atmospheric Effects point source I eye viewpoint scattered light T ls dttgtHtII 0 ),()(),()( Intensity at viewpoint Shading Model for Light Beams
11
Atmospheric Effects IsIs t point light viewpoint P IlIl tH)( : visibility function Shading Model for Light Beams T ls dttgtHtII 0 ),()(),()( : intensity of light l tI),( : attenuation function tg),( Intensity at viewpoint
12
Atmospheric Effects Basic Idea Intensity at viewpoint [Dobashi00] T ls dttgtHtII 0 ),()(),()( n k1 l tI),( tg),( tH)( screen sampling plane viewpoint point light computed at lattices
13
Atmospheric Effects n k1 Basic Idea l tI),( tg),( Intensity at viewpoint T ls dttgtHtII 0 ),()(),()( tH)( light map texture mapping light map viewpoint point light [Dobashi00]
14
Atmospheric Effects n k1 Basic Idea l tI),( tg),( Intensity at viewpoint T ls dttgtHtII 0 ),()(),()( tH)( viewpoint point light [Dobashi00] object shadow mapping
15
Atmospheric Effects n k1 Basic Idea l tI),( tg),( Intensity at viewpoint T ls dttgtHtII 0 ),()(),()( tH)( viewpoint point light render sampling planes with additive blending [Dobashi00] object shadow mapping
16
Atmospheric Effects accumulation of errors in proportion to number of sampling planes quantization with 8 bit precision in most hardware - artifacts due to quantization errors Problems Many planes/lattices for high quality image Accuracy number of planes number of lattice points - increase in rendering time rendering time number of planes number of lattice points sampling errors pseudo-contours
17
Atmospheric Effects High Quality Rendering n k1 s t II ),( T ls dttgtHtII 0 ),()(),()( tt t lks k k dttgtHtItI),()(),(),( IsIs t point light P IlIl tt Intensity at viewpoint
18
Atmospheric Effects High Quality Rendering n k1 s t II ),( T ls dttgtHtII 0 ),()(),()( tt t lks k k dttgtHtItI),()(),(),( IsIs t point light P IlIl tt Intensity at viewpoint changes severely changes smoothly const. in t
19
Atmospheric Effects High Quality Rendering n k1 s t II ),( T ls dttgtHtII 0 ),()(),()( tt t lks k k dttgtHtItI),()(),(),( IsIs t point light P IlIl tt Intensity at viewpoint fhfh flfl tt t l k k dttHtI)(),( tt t k k dttg),( x
20
Atmospheric Effects High Quality Rendering n k1 s t II ),( T ls dttgtHtII 0 ),()(),()( tt t lks k k dttgtHtItI),()(),(),( IsIs point light IlIl Intensity at viewpoint fhfh flfl tt t l k k dttHtI)(),( tt t k k dttg),( x = 1.0 scattered light scattering component
21
Atmospheric Effects High Quality Rendering n k1 s t II ),( T ls dttgtHtII 0 ),()(),()( tt t lks k k dttgtHtItI),()(),(),( IsIs point light IlIl Intensity at viewpoint fhfh flfl tt t l k k dttHtI)(),( tt t k k dttg),( x scattering component ratio of reached light object Illumination component
22
Atmospheric Effects sub-planes for accurate sampling use of texture to store pre-integrated values High Quality Rendering Illumination component fh:fh: tt t l k k dttHtI)(),( Scattering component fl:fl: tt t k k dttg),( - changes smoothly - can be sampled at a large interval - includes visibility H and intensity distribution I l - must be sampled at a short interval
23
Atmospheric Effects sub-planes for accurate sampling use of texture to store pre-integrated values High Quality Rendering - changes smoothly - can be sampled at a large interval - includes visibility H and intensity distribution I l - must be sampled at a short interval Illumination component fh:fh: tt t l k k dttHtI)(),( Scattering component fl:fl: tt t k k dttg),(
24
Atmospheric Effects Textures for Scattering Component tt t c ckl k k dt s ts Ftf 2 ))(exp( ),(),( (point light) tktk viewpoint point light s t P’ tt P : phase function )( , F cc : density : attenuation ratio : phase angle s : distance between light and P’ t : distance between viewpoint and P’ tktk : distance between viewpoint and P sampling plane k sampling plane k+1
25
Atmospheric Effects P’ P tt t c ckl k k dt s ts Ftf 2 ))(exp( ),(),( s point light (point light) sampling plane k sampling plane k+1 tktk viewpoint t tt - local coordinate UV P(u, v) Q P’(u’, v) U V k tuut ' su/'cos 222 'vus Textures for Scattering Component
26
Atmospheric Effects s point light P’(u’, v) sampling plane k sampling plane k+1 tktk viewpoint t tt P(u, v) ),,(),,( vuqcvuf kl )exp( kck tc ' ' ))''(exp( )),'/'((cos),,( 22 22 221 du vu uuvu vuuFvuq c tu u c x k c : constant for each sampling plane vuq),,( : 2D texture f l is evaluated precisely since texture stores integrated values Q U V reducing quantization errors Textures for Scattering Component
27
Atmospheric Effects sub-planes for accurate sampling use of texture to store pre-integrated values High Quality Rendering - changes smoothly - can be sampled at a large interval - includes visibility H and intensity distribution I l - must be sampled at a short interval Illumination component fh:fh: tt t l k k dttHtI)(),( Scattering component fl:fl: tt t k k dttg),(
28
Atmospheric Effects light Computation of Illumination Component tt t lkh k k dttHtItf)(),(),( viewpoint sampling plane sub-plane - m k sub-planes between sampling planes k and k+1 - m k is determined adaptively strong intensity many sub-planes 1 0 )(),( 1 ),( k m j jjl k kh rHrI m tf r j : distance between viewpoint and sub-plane j
29
Atmospheric Effects light viewpoint sampling plane sub-plane Determining number of sub-planes, m k Determining number of sub-planes, m k 1. shoot a ray 2. compute intensity of scattered light 3. generate sub-planes in proportion to intensity use textures for scattering component Intensity of scattered light mkmk :user-specified threshold same contribution of each sub-plane to pixel intensity Computation of Illumination Component
30
Atmospheric Effects Overview Introduction Rendering Light Beams Rendering the Earth’s Atmosphere - motivation - previous work - basic Idea - problems - high quality rendering - rendering sky - rendering the earth viewed from space Results Conclusion
31
Atmospheric Effects Rendering Earth’s Atmosphere No shadows of objects Rendering Sky - extending method for light beams Rendering the earth viewed from space earth viewpoint atmosphere
32
Atmospheric Effects Rendering Earth’s Atmosphere No shadows of objects Rendering Sky - extending method for light beams Rendering the earth viewed from space atmosphere viewpoint earth - atmosphere is very thin layer covering the earth
33
Atmospheric Effects Rendering Earth’s Atmosphere No shadows of objects Rendering Sky - extending method for light beams Rendering the earth viewed from space atmosphere viewpoint earth sampling spheres - use of sampling spheres instead of sampling plane - atmosphere is very thin layer covering the earth
34
Atmospheric Effects Rendering Earth’s Atmosphere No shadows of objects Rendering Sky - extending method for light beams Rendering the earth viewed from space - atmosphere is very thin layer covering the earth - use of sampling spheres instead of sampling plane atmosphere viewpoint earth sampling spheres
35
Atmospheric Effects Intensity at viewpoint Intensity at viewpoint Rendering Sky T vlsunv dttgsgt FII 0 ),(),(),(),()()( sun I)( : intensity of sunlight l sg),( : attenuation ratio between P s and P v tg),( : attenuation ratio between P and P v F),( : phase function : density of particles t ),( s t P viewpoint earth PsPs atmosphere PvPv sun I
36
Atmospheric Effects Rendering Sky Intensity at viewpoint Intensity at viewpoint T vlsunv dttgsgt FII 0 ),(),(),(),()()( sun I)( : intensity of sunlight v tg),( : attenuation ratio between P s and P l sg),( : attenuation ratio between P and P v F),( : phase function : density of particles t ),( earth viewpoint atmosphere PvPv
37
Atmospheric Effects Rendering Sky Intensity at viewpoint Intensity at viewpoint earth viewpoint atmosphere PvPv n k k j jvlsunv tgsgtFII 1 1 1 ),(),()(),()()( R P PsPs k k+1 sun I)( : intensity of sunlight l sg),( : attenuation ratio between P s and P F),( : phase function ),( kv tg : attenuation between sampling planes k and k+1 t)( R : cumulative density of particles between sampling planes k and k+1 sun I
38
Atmospheric Effects earth Rendering Sky Algorithm Algorithm create textures of g l, g v, R for k = n to 1, repeat: - map g l, g v, R textures onto sampling plane k Intensity at viewpoint Intensity at viewpoint n k k j jvlsunv tgsgtFII 1 1 1 ),(),()(),()()( R viewpoint PvPv
39
Atmospheric Effects earth Rendering Sky Algorithm Algorithm create textures of g l, g v, R for k = n to 1, repeat: - map g l, g v, R textures onto sampling plane k Intensity at viewpoint Intensity at viewpoint n k k j jvlsunv tgsgtFII 1 1 1 ),(),()(),()()( R - compute I sun F at lattice points viewpoint PvPv
40
Atmospheric Effects earth Rendering Sky Algorithm Algorithm create textures of g l, g v, R for k = n to 1, repeat: - map g l, g v, R textures onto sampling plane k - draw plane with blending: FB = FB x g v + F x R x g l ( FB : frame buffer) intensity of scattered light attenuation Intensity at viewpoint Intensity at viewpoint n k k j jvlsunv tgsgtFII 1 1 1 ),(),()(),()()( R viewpoint PvPv - compute I sun F at lattice points
41
Atmospheric Effects earth Rendering Sky Algorithm Algorithm create textures of g l, g v, R for k = n to 1, repeat: - map g l, g v, R textures onto sampling plane k - draw plane with blending: FB = FB x g v + F x R x g l ( FB : frame buffer) intensity of scattered light attenuation Intensity at viewpoint Intensity at viewpoint n k k j jvlsunv tgsgtFII 1 1 1 ),(),()(),()()( R viewpoint PvPv - compute I sun F at lattice points
42
Atmospheric Effects Rendering Sky Textures of Textures of g l, g v, R sun I P viewpoint earth PsPs s atmosphere : extinction coefficient (constant) : density of particles )exp()(ahh ( a : const) s PP dll 0 ))()(exp( sl PPg),( PvPv h
43
Atmospheric Effects Rendering Sky sun I P viewpoint earth PsPs atmosphere h ll s Textures of Textures of g l, g v, R PvPv : extinction coefficient (constant) : density of particles )exp()(ahh ( a : const) s PP dll 0 ))()(exp( sl PPg),( ),,(),( llsl hgPPg
44
Atmospheric Effects ),,(),( vvvv hgPPg ),,(),( vv hRPPR ),,(),( llsl hgPPg Rendering Sky sun I P viewpoint earth PsPs atmosphere h vv Textures of Textures of g l, g v, R store as 2D textures PvPv : extinction coefficient (constant) : density of particles )exp()(ahh ( a : const) s PP dll 0 ))()(exp( sl PPg),(
45
Atmospheric Effects Overview Introduction Rendering Light Beams Rendering the Earth’s Atmosphere - motivation - previous work - basic Idea - problems - high quality rendering - rendering sky - rendering the earth viewed from space Results Conclusion
46
Atmospheric Effects Experimental Results #planes: 40 mesh: 60x60 #planes: 160 mesh: 60x60 #planes: 30 #sub-planes: 120 (ave.) mesh: 10x10 previous method proposed method computer: Athlon 1.7GHz, GeForce3
47
Atmospheric Effects Experimental Results Image size: 300x450 computer: Athlon 1.7GHz, GeForce3 # of planes (sub- planes) time result method 40 0.13 [sec.] previous ray-tracing 29 [sec.] - interleaved [Keller01] 0.12 [sec.] 160 mesh 60x9010x15 - 23 (174) 0.08 [sec.] proposed 10x15
48
Atmospheric Effects Experimental Results # of planes (sub- planes) time result method 40 0.13 [sec.] previous ray-tracing 29 [sec.] - interleaved [Keller01] 0.12 [sec.] 160 Image size: 300x450 computer: Athlon 1.7GHz, GeForce3 mesh 60x9010x15 - 23 (174) 0.08 [sec.] proposed 10x15
49
Atmospheric Effects Results sampling plane: 9 sub-plane:309 sampling plane: 30 sub-plane:263 Image size: 720x480 computer: Athlon 1.7GHz, GeForce3 time: 0.32 [sec.] time: 0.12 [sec.]
50
Atmospheric Effects sampling plane: 100(sky) 30(shaft) sub-plane:135 time: 0.16 [sec.] Results Image size: 720x480 computer: Athlon 1.7GHz, GeForce3 sampling sphere: 10 time: 0.06 [sec.]
51
Atmospheric Effects DEMO Real-time Animation Using Note PC Pentium III (1.2 GHz) Nvidia GeForce 2 Go
52
Atmospheric Effects Conclusion Fast rendering of atmospheric effects - 2D textures to store intensities of scattered light - sub-planes for precise sampling of shadows - rendering of sky Rendering of light beams Extension to rendering earth’s atmosphere - rendering of earth viewed from space
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.