09/11/03CS679 - Fall 2003 - Copyright Univ. of Wisconsin Last Time Graphics Pipeline Texturing Overview Cubic Environment Mapping.

Slides:



Advertisements
Similar presentations
Lecture 8 Transparency, Mirroring
Advertisements

Graphics Pipeline.
Environment Mapping CSE 781 – Roger Crawfis
Week 10 - Monday.  What did we talk about last time?  Global illumination  Shadows  Projection shadows  Soft shadows.
3D Graphics Rendering and Terrain Modeling
Real-Time Rendering TEXTURING Lecture 02 Marina Gavrilova.
Part I: Basics of Computer Graphics
Week 9 - Wednesday.  What did we talk about last time?  Fresnel reflection  Snell's Law  Microgeometry effects  Implementing BRDFs  Image based.
Computer graphics & visualization Pre-Computed Radiance Transfer PRT.
Advanced Texture and Lighting
X86 and 3D graphics. Quick Intro to 3D Graphics Glossary: –Vertex – point in 3D space –Triangle – 3 connected vertices –Object – list of triangles that.
Final Gathering on GPU Toshiya Hachisuka University of Tokyo Introduction Producing global illumination image without any noise.
Paper by Alexander Keller
Computer Graphics Inf4/MSc Computer Graphics Lecture 11 Texture Mapping.
09/18/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Bump Mapping Multi-pass algorithms.
9/20/2001CS 638, Fall 2001 Today Finishing Up Reflections More Multi-Pass Algorithms Shadows.
Shadows Computer Graphics. Shadows Shadows Extended light sources produce penumbras In real-time, we only use point light sources –Extended light sources.
Computer Graphics Mirror and Shadows
Direct Illumination with Lazy Visibility Evaluation David Hart Philip Dutré Donald P. Greenberg Cornell University SIGGRAPH 99.
CS 638, Fall 2001 Today Light Mapping (Continued) Bump Mapping with Multi-Texturing Multi-Pass Rendering.
COMP 175: Computer Graphics March 24, 2015
Technology and Historical Overview. Introduction to 3d Computer Graphics  3D computer graphics is the science, study, and method of projecting a mathematical.
Lightmaps from HDR Probes Bernhard Spanlang VECG Group University College London
CS 638, Fall 2001 Admin Grad student TAs may have had their accounts disabled –Please check and the lab if there is a problem If you plan on graduating.
Today More raytracing stuff –Soft shadows and anti-aliasing More rendering methods –The text book is good on this –I’ll be using images from the CDROM.
-Global Illumination Techniques
Texture Mapping (cont.) Jian Huang, CS 594, updated in Fall’08.
09/09/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Event management Lag Group assignment has happened, like it or not.
CS 376 Introduction to Computer Graphics 04 / 16 / 2007 Instructor: Michael Eckmann.
Game Programming (Mapping) Spring.
CS447/ Realistic Rendering -- Radiosity Methods-- Introduction to 2D and 3D Computer Graphics.
CS 638, Fall 2001 Today Project Stage 0.5 Environment mapping Light Mapping.
Emerging Technologies for Games Alpha Sorting and “Soft” Particles CO3303 Week 15.
CS 638, Fall 2001 Multi-Pass Rendering The pipeline takes one triangle at a time, so only local information, and pre-computed maps, are available Multi-Pass.
Rendering Overview CSE 3541 Matt Boggus. Rendering Algorithmically generating a 2D image from 3D models Raster graphics.
Week 10 - Wednesday.  What did we talk about last time?  Shadow volumes and shadow mapping  Ambient occlusion.
Multi-pass Rendering. © 2002 James K. Hahn, N.H. Baek2 Multi-pass Rendering Repeat: image  Rendering pass  result imageRepeat: image  Rendering pass.
Computer Graphics The Rendering Pipeline - Review CO2409 Computer Graphics Week 15.
CS-378: Game Technology Lecture #4: Texture and Other Maps Prof. Okan Arikan University of Texas, Austin V Lecture #4: Texture and Other Maps.
Photo-realistic Rendering and Global Illumination in Computer Graphics Spring 2012 Texturing K. H. Ko School of Mechatronics Gwangju Institute of Science.
Shadows. Shadows is important in scenes, consolidating spatial relationships “Geometric shadows”: the shape of an area in shadow Early days, just pasted.
Advanced Computer Graphics Advanced Shaders CO2409 Computer Graphics Week 16.
CS-378: Game Technology Lecture #7: More Mapping Prof. Okan Arikan University of Texas, Austin Thanks to James O’Brien, Steve Chenney, Zoran Popovic, Jessica.
Texture Mapping (cont.) Jian Huang, CS 594, Fall 2003.

10/07/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Spatial data structures.
09/16/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Environment mapping Light mapping Project Goals for Stage 1.
04/30/02(c) 2002 University of Wisconsin Last Time Subdivision techniques for modeling We are now all done with modeling, the standard hardware pipeline.
Graphics Graphics Korea University cgvr.korea.ac.kr 1 Surface Rendering Methods 고려대학교 컴퓨터 그래픽스 연구실.
Ray Tracing Fall, Introduction Simple idea  Forward Mapping  Natural phenomenon infinite number of rays from light source to object to viewer.
CSCE 441: Computer Graphics Ray Tracing
COMPUTER GRAPHICS CS 482 – FALL 2015 SEPTEMBER 29, 2015 RENDERING RASTERIZATION RAY CASTING PROGRAMMABLE SHADERS.
09/25/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Shadows Stage 2 outline.
Real-Time Dynamic Shadow Algorithms Evan Closson CSE 528.
1 CSCE 441: Computer Graphics Hidden Surface Removal Jinxiang Chai.
Shadows David Luebke University of Virginia. Shadows An important visual cue, traditionally hard to do in real-time rendering Outline: –Notation –Planar.
Global Illumination (3) Photon Mapping (1). Overview Light Transport Notation Path Tracing Photon Mapping –Photon Tracing –The Photon Map.
09/23/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Reflections Shadows Part 1 Stage 1 is in.
CS 376 Introduction to Computer Graphics 04 / 13 / 2007 Instructor: Michael Eckmann.
CS 376 Introduction to Computer Graphics 04 / 18 / 2007 Instructor: Michael Eckmann.
CS-378: Game Technology Lecture #7: More Mapping Prof. Okan Arikan
Game Programming (Mapping)
3D Graphics Rendering PPT By Ricardo Veguilla.
Bump Mapping -1 Three scales of detail on an object
© University of Wisconsin, CS559 Fall 2004
CSCE 441: Computer Graphics Hidden Surface Removal
(c) 2002 University of Wisconsin
(c) 2002 University of Wisconsin
CS-378: Game Technology Lecture #4: Texture and Other Maps
Last Time Presentation of your game and idea Environment mapping
Presentation transcript:

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Graphics Pipeline Texturing Overview Cubic Environment Mapping

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Today More environment mapping Light Maps

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Environment Mapping Environment mapping produces reflections on shiny objects Texture is transferred in the direction of the reflected ray from the environment map onto the object –Uses ray with same direction but starting at the object center Map contains a view of the world as seen from the center of the object Object Viewer Reflected ray Environment Map Lookup ray

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Lat/Long Mapping The original algorithm (1976) placed the map on a sphere centered on the object Mapping functions assume that s,t texture coordinates equate to latitude and longitude on the sphere: What is bad about this method? –Sampling –Map generation –Complex texture coordinate computations

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Sphere Mapping Again the map lives on a sphere, but now the coordinate mapping is simplified To generate the map: –Take a map point (s,t), cast a ray onto a sphere in the -Z direction, and record what is reflected –Equivalent to photographing a reflective sphere with an orthographic camera (long lens, big distance) Again, makes the method suitable for film special effects

09/11/03CS679 - Fall Copyright Univ. of Wisconsin A Sphere Map

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Indexing Sphere Maps Given the reflection vector: Implemented in hardware Problems: –Highly non-uniform sampling –Highly non-linear mapping

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Non-uniform Sampling

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Non-linear Mapping Linear interpolation of per-vertex texture coordinates picks up the wrong texture pixels –Use small polygons! CorrectLinear

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Example

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Parabolic Mapping Assume the map resides on a parabolic surface –Two surfaces, facing each other Improves on sphere maps: –Texture coordinate generation is a near linear process –Sampling is more uniform –Result is more view-independent However, requires multi-passes to implement, so not generally used

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Other Env. Map Tricks Partially reflective objects –First stage applied color texture –Second stage does environment mapping using alpha blend with existing color Just put the lights in the environment map –What does this simulate? Recursive reflections Bad cases for environment maps?

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Light Maps Speed up lighting calculations by pre-computing lighting and storing it in maps –Allows complex illumination models to be used in generating the map (eg shadows, radiosity) –Used in complex rendering algorithms (Radiance), not just games Issues: –How is the mapping determined? –How are the maps generated? –How are they applied at run-time?

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Example

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Choosing a Mapping Problem: In a preprocessing phase, points on polygons must be associated with points in maps One solution: –Find groups of polygons that are “near” co-planar and do not overlap when projected onto a plane Result is a mapping from polygons to planes –Combine sections of the chosen planes into larger maps –Store texture coordinates at polygon vertices Lighting tends to change quite slowly (except when?), so the map resolution can be poor

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Generating the Map Problem: What value should go in each pixel of the light map? Solution: –Map texture pixels back into world space (using the inverse of the texture mapping) –Take the illumination of the polygon and put it in the pixel Advantages of this approach: –Choosing “good” planes means that texture pixels map to roughly square pieces of polygon - good sampling –Not too many maps are required, and not much memory is wasted

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Example Nearest interpolationLinear interpolation What type of lighting (diffuse, specular, reflections) can the map store?

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Example No light mapsWith light maps

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Applying Light Maps Use multi-texturing hardware –First stage: Apply color texture map –Second stage: Modulate with light map Actually, make points darker with light map DirectX allows you to make points brighter with texture Pre-lighting textures: –Apply the light map to the texture maps as a pre-process –Why is this less appealing? Multi-stage rendering: –Same effect as multi-texturing, but modulating in the frame buffer

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Dynamic Light Maps Light maps are a preprocessing step, so they can only capture static lighting Texture transformations allow some effects What is required to recompute a light map at run-time? How might we make this tractable? –Spatial subdivision algorithms allow us to identify nearby objects, which helps with this process Compute a separate, dynamic light map at runtime using same mapping as static light map Add additional texture pass to apply the dynamic map

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Fog Maps Dynamic modification of light-maps Put fog objects into the scene Compute where they intersect with geometry and paint the fog density into a dynamic light map –Use same mapping as static light map uses Apply the fog map as with a light map –Extra texture stage

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Fog Map Example

09/11/03CS679 - Fall Copyright Univ. of Wisconsin Todo Confirm group names and meeting times – By Monday, Sept 15: Goals for stage 1 By Monday, Sept 22: Lock in Stage 1