Presentation is loading. Please wait.

Presentation is loading. Please wait.

CSCE 441 Computer Graphics: Radiosity

Similar presentations


Presentation on theme: "CSCE 441 Computer Graphics: Radiosity"— Presentation transcript:

1 CSCE 441 Computer Graphics: Radiosity
Jinxiang Chai

2 Rendering: Illumination Computing
Direct (local) illumination Light directly from light sources No shadows Indirect (global) illumination Transparent, reflective surfaces, and hard shadows (Ray tracing) Diffuse interreflections, color bleeding, and soft shadow (radiosity) The goal is to compute all possible light interactions in a given scene, and thus obtain a truely photorealistic image. All combinations of diffuse and specular reflections and transmissions must be accounted for. Effects such as colour bleeding and caustics must be included in a global illumination simulation.

3 Rendering: Illumination Computing
Direct (local) illumination Light directly from light sources No shadows Indirect (global) illumination Transparent, reflective surfaces, and hard shadows (Ray tracing) Diffuse interreflections, color bleeding, and soft shadow (radiosity) The goal is to compute all possible light interactions in a given scene, and thus obtain a truely photorealistic image. All combinations of diffuse and specular reflections and transmissions must be accounted for. Effects such as colour bleeding and caustics must be included in a global illumination simulation.

4 Review: Ray Tracing Assumption
The illumination of a point is determined by - illumination/shadow ray (direct lighting from light sources)

5 Review: Ray Tracing Assumption
The illumination of a point is determined by - illumination/shadow ray (direct lighting from light sources)

6 Review: Ray Tracing Assumption
The illumination of a point is determined by - illumination/shadow ray (direct lighting from light sources) - reflection ray (light reflected by an object)

7 Review: Ray Tracing Assumption
The illumination of a point is determined by - illumination/shadow ray (direct lighting from light sources) - reflection ray (light reflected by an object) - transparent ray (light passing through an object)

8 Review: Ray Tracing Assumption
The illumination of a point is determined by - illumination/shadow ray (direct lighting from light sources) - reflection ray (light reflected by an object) - transparent ray (light passing through an object)

9 Ray Tracing Assumption
The illumination of a point is determined by - illumination/shadow ray (direct lighting from light sources) - reflection ray (light reflected by an object) - transparent ray (light passing through an object)

10 Pros and Cons of Ray Tracing
Advantages of ray tracing All the advantages of the local illumination model Also handles shadows, reflection, and refraction Disadvantages of ray tracing Computational expense No diffuse inter-reflection between surfaces (i.e., color bleeding) Not physically accurate Radiosity handles these shortcomings for diffuse surfaces! 10

11 Radiosity vs. Local Illumination

12 Radiosity

13 Physical Image vs. Radiosity Rendering

14 Radiostiy Definition: The radiant (luminous) exitance is the radiant flux/power per unit area leaving a surface. Question: should I use B or M? Better diagram?

15 Radiosity Model light effects by considering the physical laws governing the radiant energy transfer; The radiosity model computes radiant-energy interactions between all the surfaces in a scene

16 Radiosity: Key Idea #1

17 Diffuse Surface

18 Radiosity: Key Idea #2

19 Constant Surface Approximation

20 Radiosity Equation

21 Radiosity Equation

22 Radiosity Algorithm

23 Energy Conservation Equation

24 Energy Conservation Equation
The total rate of radiant energy leaving surface i per unit square

25 Energy Conservation Equation
The rate of energy emitted from surface i per unit area - zero if surface i is not a light source

26 Energy Conservation Equation
Reflectivity factor Percent of incident light that is reflected in all directions

27 Energy Conservation Equation
Form factor Fractional amount of radiant energy from surface j that reaches surface i

28 Compute Form Factors The form factor specifies the fraction of the energy leaving one patch and arrives at the other. In other words, it is an expression of radiant exchange between two surface patchesl The form factor specifies the fraction of the energy leaving one patch and arriving at the other. In other words, it is an expression of radiant exchange between two surface patches!

29 Compute Form Factors Radiant energy reaching Ax from Ay Radiant energy leaving Ay in all directions The form factor specifies the fraction of the energy leaving one patch and arrives at the other. In other words, it is an expression of radiant exchange between two surface patchesl The form factor specifies the fraction of the energy leaving one patch and arriving at the other. In other words, it is an expression of radiant exchange between two surface patches!

30 Form Factor: Reciprocity

31 Radiosity Equation Radiosity for each polygon Linear system:
- : radiosity of patch I (unknown) : emission of patch I (known) - : reflectivity of patch I (known) : form-factor (known)

32 Linear System X = B A

33 Radiosity Algorithm

34 Form Factors for Infinitesimal Surfaces
Visibility - if not visible, receive zero power

35 Form Factors for Subdivided Patches
Visibility - if not visible, receive zero power

36 Form Factor: How to compute?
Closed Form - analytical Hemicube

37 Form Factor: Analytical

38 Form Factor: How to compute?
Closed Form - analytical Hemicube

39 Form Factor: Nusselt Analog
Nusselt developed a geometric analog which allows the simple and accurate calculation of the form factor between a surface and a point on a second surface. Differentiation of the basic form factor equation is difficult even for simple surfaces. Nusselt developed a geometric analog which allows the simple and accurate calculation of the form factor between a surface and a point on a second surface. The "Nusselt analog" involves placing a hemispherical projection body, with unit radius, at a point on a surface. The second surface is spherically projected onto the projection body, then cylindrically projected onto the base of the hemisphere. The form factor is, then, the area projected on the base of the hemisphere divided by the area of the base of the hemisphere 3D diagram

40 Form Factor: Nusselt Analog
The form factor is, then, the area projected on the base of the hemisphere divided by the area of the base of the hemisphere, or (A/B) Differentiation of the basic form factor equation is difficult even for simple surfaces. Nusselt developed a geometric analog which allows the simple and accurate calculation of the form factor between a surface and a point on a second surface. The "Nusselt analog" involves placing a hemispherical projection body, with unit radius, at a point on a surface. The second surface is spherically projected onto the projection body, then cylindrically projected onto the base of the hemisphere. The form factor is, then, the area projected on the base of the hemisphere divided by the area of the base of the hemisphere A B 2D diagram

41 Form Factor: Nusselt Analog
It follows from this that any patch has the same projection of the surface of hemisphere has the same form factor. This means we can project onto the face of a cube rather than a hemisphere. This enables us to derive a more efficient solution.

42 Form Factor: Nusselt Analog
It follows from this that any patch has the same projection of the surface of hemisphere has the same form factor. This means we can project onto the face of a cube rather than a hemisphere. This enables us to derive a more efficient solution. So how can we use Nusselt Analog to compute the form factor?

43 Form Factor: Nusselt Analog
It follows from this that any patch has the same projection of the surface of hemisphere has the same form factor. This means we can project onto the face of a cube rather than a hemisphere. This enables us to derive a more efficient solution. So how can we use Nusselt Analog to compute the form factor? - answer: precomputing

44 Form Factor: HemiCube The "hemicube" form factor calculation method involves placing the center of a cube at a point on a surface, and using the upper half of the cube (the "hemicube" which is visible above the surface) as a projection body as defined by the "Nusselt analog." Each face of the hemicube is subdivided into a set of small, usually square ("discrete") areas, each of which has a pre-computed form factor value. When a surface is projected onto the hemicube, the sum of the form factor values of the discrete areas of the hemicube faces which are covered by the projection of the surface is the form factor between the point on the first surface (about which the cube is placed) and the second surface (the one which was projected). The speed and accuracy of this method of form factor calculation can be affected by changing the size and number of discrete areas on the faces of the hemicube.

45 Form Factor: HemiCube Project path on hemicube
Add hemicube cells to compute form factors Differentiation of the basic form factor equation is difficult even for simple surfaces. Nusselt developed a geometric analog which allows the simple and accurate calculation of the form factor between a surface and a point on a second surface. The "Nusselt analog" involves placing a hemispherical projection body, with unit radius, at a point on a surface. The second surface is spherically projected onto the projection body, then cylindrically projected onto the base of the hemisphere. The form factor is, then, the area projected on the base of the hemisphere divided by the area of the base of the hemisphere A B 2D diagram

46 Precomputing Form Factor
How to calculate the form factor for each cell?

47 Delta Form Factor: Top Face
Top of hemicube

48 Delta Form Factors: Side Faces
Side of hemicube

49 The Hemicube in Action Stop here! 11/8
This illustration demonstrates the calculation of form factors between a particular surface on the wall of a room and several surfaces of objects in the room. A standard radiosity image generation algorithm will compute the form factors from a point on a surface to all other surfaces, by projecting all other surfaces onto the hemicube and storing, at each discrete area, the identifying index of the surface that is closest to the point. When all surfaces have been projected onto the hemicube, the discrete areas contain the indices of the surfaces which are ultimately visible to the point. From there the form factors between the point and the surfaces are calculated. For greater accuracy, a large surface would typically be broken into a set of small surfaces before any form factor calculation is performed.

50 Form Factors: HemiCube

51 Form Factors

52 Radiosity Algorithm

53 How to Solve Linear System?
Matrix conversion Iterative approaches - Jacobian (gathering) - Gauss-Seidel (gathering) - progressive refinement (shooting)

54 Matrix Conversion - Computational cost: O(N3)
- Very slow for a large set of polygons

55 Iterative Approaches

56 Jacobian Iterations For all patches i, i=1,…,N, While not converged:
for all patches i=1,…,N

57 Jacobian Iterations For all patches i, i=1,…,N, While not converged:
for all patches i=1,…,N Update of one patch requires evaluation of N Form Factors What’s the computational cost?

58 Successive Approximation

59 Rendering - The final Φi's can be used in place of intensities in a standard renderer (Gouraud, per-veretx shading) - Radiosities are constant over the extent of a patch - A standard renderer requires vertex intensities (or radiosities) - If the radiosities of surrounding patches are know, vertex radiosities can be estimated using bilinear interpolation

60 Vertex Intensity: Bilinear Interpolation

61 Consolation Room

62 Theatre

63 Steel Mills

64 Radiosity: Benefit Global illumination method: modeling diffuse inter-reflection Color bleeding: a red wall next to a white one casts a reddish glow on the white wall near the corner Soft shadows – an “area” light source casts a soft shadow from a polygon No ambient term hack, so when you want to look at your object in low light, you don’t have to adjust parameters of the objects – just the intensities of the lights! View independent: it assigns a brightness to every surface

65 Radiosity: Limitation
Radiation is uniform in all directions Radiosity is piecewise constant – usual renderings make this assumption, but then interpolate cheaply to fake a nice-looking answer – this introduces quantifiable errors No surface is transparent or translucent Reflectivity is independent of directions to source and destination


Download ppt "CSCE 441 Computer Graphics: Radiosity"

Similar presentations


Ads by Google