Computer graphics and virtual reality Flashcards
Describe three different visualization systems for VR. Mention advantages and disadvantages with the different systems.
Desktop (“Fisktank”) VR - Helmet (HMD) - Powerwall (Large volume display)
Desktop (“Fisktank”) VR:
High display resolution, cheap, simple to use
Narrow field of view (FOV), low degree of immersion, not natural scale (for e.g. cars)
Helmet (HMD):
Wider field of view (FOV), Stereo viewing (different for the 2 eyes), higher degree of immersion, relatively cheap, simple to install
Heavy, isolation from world, only one user, relatively low screen res.
Powerwall (Large volume display):
Wide FOV, Natural scale, multiple people, stereo display (with shutter or polarized glasses), high res.
Low degree of immersion, advanced computers, advanced tech to obtain invisible edges between projectors (since multiple are used),Really expensive
Describe how the Z-buffer algorithm for depth sorting of objects drawn on a computer screen works.
Initiate the video memory and a z-buffer for each pixel on the screen.
depth[x,y] = inf, refresh[x,y] = I_background
Polygons are rendered in an arbitrary sequence (random)
For each pixel, check if the z-coordinate of the current polygon is less than the stored one (use the plane equation)
In that case, update the video memory for the pixel, with color closest to observer
Describe (with, text, figures and equations) the four steps for collision detection between two objects defined by triangle surfaces
Bounding Spheres/rectangles (boxes), “Mini-max-test” see if any point touch (i.e a collision might be possible at all)
Test if any of the edges on body A intersects an infinite plane defined by some of the polygons on body B
If yes, calculate the intersection point between the edge and the plane
Check if the intersection point is on the polygon
Light from a point light source can be reflected in two ways from a surface in a computer model, diffuse and specular. Describe the difference between diffuse and specular reflection.
Diffuse spreads light (that hits the surface) equally in all directions, which means that the placement of the light source influences but not the placement of the observer. Specular light is dependent on the placement of the observer. Smooth polished surfaces.
Gouraud and Phong are two different methods to obtain smooth shading of triangulated surfaces. Why is Gouraud called vertex shading and Phong pixel shading?
Gouraud: The color of a triangle is calculated at each vertex (corner) with the normal at the corner. The color is then interpolated over the surface of the triangle.
Phong: The normal at the vertices (corners) are interpolated over the surface of the triangle and the color is calculated for each pixel.
Describe how Parallel and Perspective projections are calculated. What is the visible difference (on screen) between the two projections?
Perspective enhances the size of close features. In parallel, the objects have the same size independent of the distance to the observer.
Ray-Tracing and Radiosity are two different methods for advanced 3D computer graphics rendering.
Describe how these methods work.
Ray-Tracing
Follow the light rays from the observer, one for each pixel
Calculate how the ray is mirrored and refracted (if the object is transparent) when it hits surfaces in the
model, and save the way in a tree graph
Calculate the intensity at the initial points with illumination models
Use tree to calculate the intensities at each pixel
Handles automatically shadows, hidden surfaces and clipping
Radiosity
Based on the effect that light sources and surfaces are emitting light
Is done by iterating the emission of light
In the first step only surfaces with direct light are visible
In the next step these surfaces emits light to other surfaces
This is repeated until the result is satisfactory
Mention two advantages and two disadvantages of each of the two methods (ray-tracing, radiosity)
Ray-tracing
Good at transparent objects
Handles specular reflection well (shiny, mirror)
Good at point light sources
Radiosity
Good at diffuse reflection
Gives realistic shadows
Good at global light sources
The disadvantages is the others advantages. Both are slow
Describe how so called shutter glasses can be used to obtain stereo projection on an ordinary computer screen.
Gives 3D by “blocking” one eye at a time
This is synchronised with the computer which alternatives between views for the left and the right eye
respectively
The view is calculated with respective projection
The view for the left eye is calculated by moving the picture half of the distance of the eyes to the left
For the right eye the picture is moved the same distance to the right
Describe the RGB colour mode
The colour is accomplished with a mixture of three primary colours
Red [0 – 1] 0-255
Green [0 – 1] 0-255
Blue [0 – 1] 0-255
What are homogenous coordinates and why are they used in computer graphics?
Homogenous coordinates are created by adding an extra coordinate, w, to the Cartesian coordinates: P_cares[xyz] →
P_homogen[xyzw]
They are used in order to simplify the calculation of transformations. With homogenous coordinates all
transformations can be calculated as a matrix multiplication which can be optimised for speed in the graphics
processor
Bump-mapping is a way of using textures to give a smooth surface an irregular appearance. Describe how it works
It works by modifying the surface normal that is used in the illumination model. The value of the modification is
obtained from a texture
Describe how a shadow buffer can be used to create shadows
Create a buffer, corresponding to the depth buffer, containing the distance from the light source to the closest
surface
When drawing the point P on a surface
Find the corresponding position in the shadow buffer for the point that is being drawn
Compare the value in the shadow buffer with the distance from the light source to P
If the value is less than the distance: draw only with ambient light