CSE 872 Dr. Charles B. Owen Advanced Computer Graphics1 Other Rendering Techniques Types of rendering – Wireframe techniques – Scan-line conversion – Reyes.

Slides:



Advertisements
Similar presentations
Visible-Surface Detection(identification)
Advertisements

CSC418 Computer Graphics n Polygon normals n Back Faces n Visibility Algorithms.
CS 352: Computer Graphics Chapter 7: The Rendering Pipeline.
Graphics Pipeline.
Week 10 - Monday.  What did we talk about last time?  Global illumination  Shadows  Projection shadows  Soft shadows.
3D Graphics Rendering and Terrain Modeling
03/12/02 (c) 2002 University of Wisconsin, CS559 Last Time Some Visibility (Hidden Surface Removal) algorithms –Painter’s Draw in some order Things drawn.
Graphics Graphics Korea University cgvr.korea.ac.kr 1 Hidden Surface Removal 고려대학교 컴퓨터 그래픽스 연구실.
Part I: Basics of Computer Graphics
Real-Time Rendering SPEACIAL EFFECTS Lecture 03 Marina Gavrilova.
Chapter 6: Vertices to Fragments Part 2 E. Angel and D. Shreiner: Interactive Computer Graphics 6E © Addison-Wesley Mohan Sridharan Based on Slides.
CS6500 Adv. Computer Graphics © Chun-Fa Chang, Spring 2003 Object-Order vs. Screen-Order Rendering April 24, 2003.
Computer Graphics (Fall 2005) COMS 4160, Lecture 21: Ray Tracing
Hidden Surface Elimination Wen-Chieh (Steve) Lin Institute of Multimedia Engineering I-Chen Lin’ CG Slides, Rich Riesenfeld’s CG Slides, Shirley, Fundamentals.
1 CSCE 441: Computer Graphics Hidden Surface Removal (Cont.) Jinxiang Chai.
Vertices and Fragments III Mohan Sridharan Based on slides created by Edward Angel 1 CS4395: Computer Graphics.
Spatial Data Structure: Quadtree, Octree,and BSP tree Mengxia Zhu Fall 2007.
Introduction to 3D Graphics John E. Laird. Basic Issues u Given a internal model of a 3D world, with textures and light sources how do you project it.
Hidden Surface Removal
Graphics Pipeline Hidden Surfaces CMSC 435/634. Visibility We can convert simple primitives to pixels Which primitives (or parts of primitives) should.
Graphics Pipeline Hidden Surface CMSC 435/634. Visibility We can convert simple primitives to pixels/fragments How do we know which primitives (or which.
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
10/29/02 (c) 2002 University of Wisconsin, CS559 Today Hidden Surface Removal Exact Visibility.
Computer Graphics Panos Trahanias ΗΥ358 Spring 2009.
Technology and Historical Overview. Introduction to 3d Computer Graphics  3D computer graphics is the science, study, and method of projecting a mathematical.
C O M P U T E R G R A P H I C S Guoying Zhao 1 / 14 C O M P U T E R G R A P H I C S Guoying Zhao 1 / 14 Going-through.
CSC418 Computer Graphics n BSP tree n Z-Buffer n A-buffer n Scanline.
Week 2 - Friday.  What did we talk about last time?  Graphics rendering pipeline  Geometry Stage.
Advanced Computer Graphics Depth & Stencil Buffers / Rendering to Textures CO2409 Computer Graphics Week 19.
10/26/04© University of Wisconsin, CS559 Fall 2004 Last Time Drawing lines Polygon fill rules Midterm Oct 28.
Visible-Surface Detection Jehee Lee Seoul National University.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
Rendering Overview CSE 3541 Matt Boggus. Rendering Algorithmically generating a 2D image from 3D models Raster graphics.
Shadows. Shadows is important in scenes, consolidating spatial relationships “Geometric shadows”: the shape of an area in shadow Early days, just pasted.
CS-378: Game Technology Lecture #2.2: Clipping and Hidden Surfaces Prof. Okan Arikan University of Texas, Austin Thanks to James O’Brien, Steve Chenney,
Solutions to homework #6 Wu Xiaomao May 27, 2004.
3/23/04© University of Wisconsin, CS559 Spring 2004 Last Time Antialiasing –Area-weighted sampling Visibility –Painters algorithm –Depth buffer (Z-buffer)
1Computer Graphics Implementation II Lecture 16 John Shearer Culture Lab – space 2
Implementation II Ed Angel Professor of Computer Science, Electrical and Computer Engineering, and Media Arts University of New Mexico.
CS 325 Introduction to Computer Graphics 03 / 22 / 2010 Instructor: Michael Eckmann.
Hidden Surface Removal
Implementation II.
Computer graphics & visualization Shadows / Transparency.
Global Illumination. Local Illumination  the GPU pipeline is designed for local illumination  only the surface data at the visible point is needed to.
Review on Graphics Basics. Outline Polygon rendering pipeline Affine transformations Projective transformations Lighting and shading From vertices to.
CS123 | INTRODUCTION TO COMPUTER GRAPHICS Andries van Dam © Visible Surface Determination (VSD) To render or not to render, that is the question… 1 of.
Ray Tracing Fall, Introduction Simple idea  Forward Mapping  Natural phenomenon infinite number of rays from light source to object to viewer.
Where We Stand At this point we know how to: –Convert points from local to window coordinates –Clip polygons and lines to the view volume –Determine which.
Computer Graphics I, Fall 2010 Implementation II.
Honours Graphics 2008 Session 5. Today’s focus Rasterization Visibility determination Coarse / fine visibility determination.
1 CSCE 441: Computer Graphics Hidden Surface Removal Jinxiang Chai.
CS559: Computer Graphics Lecture 12: Antialiasing & Visibility Li Zhang Spring 2008.
Shadows David Luebke University of Virginia. Shadows An important visual cue, traditionally hard to do in real-time rendering Outline: –Notation –Planar.
01/28/09Dinesh Manocha, COMP770 Visibility Computations Visible Surface Determination Visibility Culling.
Computer Graphics Inf4/MSc 1 Computer Graphics Lecture 5 Hidden Surface Removal and Rasterization Taku Komura.
CSE 681 Introduction to Ray Tracing. CSE 681 Ray Tracing Shoot a ray through each pixel; Find first object intersected by ray. Image plane Eye Compute.
09/23/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Reflections Shadows Part 1 Stage 1 is in.
Visible-Surface Detection Methods. To identify those parts of a scene that are visible from a chosen viewing position. Surfaces which are obscured by.
Hidden Surface Removal. 2 Goal: Determine which surfaces are visible and which are not. Z-Buffer is just one of many hidden surface removal algorithms.
Lecture 30: Visible Surface Detection
(c) 2002 University of Wisconsin, CS559
Solid Area Scan Conversion or Visible Surface Detection
CSC418 Computer Graphics Back Faces Visibility Algorithms.
3D Graphics Rendering PPT By Ricardo Veguilla.
© University of Wisconsin, CS559 Spring 2004
© University of Wisconsin, CS559 Fall 2004
CSCE 441: Computer Graphics Hidden Surface Removal
Hidden Surface Removal
Visible-Surface Determination
Presentation transcript:

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics1 Other Rendering Techniques Types of rendering – Wireframe techniques – Scan-line conversion – Reyes rendering – Ray tracing (done) Shadows Reflections Depth of field, focus, etc. Antialiasing

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics2 Line only techniques Hidden-line removal – Line graphics – Wireframe images – “Halo” line images

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics3 Floating Horizon Algorithms

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics4 Robert’s Algorithm First visible line algorithm O(N 2 ) complexity All objects must be convex volumes Excessively complex

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics5 Warnock Algorithm Spatial subdivision – Quad-trees

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics6 Appel’s Algorithm Quantitative invisibility – When a line goes behind something, increment by 1 – When it comes out, increment by -1

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics7 Haloed Lines

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics8 So much for wireframe…

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics9 What are the ways to convert primitives to image? Scan-line conversion Ray tracing Anything else?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics10 Scan-line conversion Each primitive is mapped to 2D and then converted to image – List priority algorithms – Z-buffer techniques – A-buffer techniques

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics11 Painters Algorithm Sort back to front Draw back to front – That’s all there is to it Does this always work?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics12 Z-buffer algorithms Associate a z value with each pixel – Contains z for nearest point drawn so far – OpenGL, Direct3D, etc. Where do we get the Z?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics13 A-Buffer Algorithms Create a list of polygons for each scan line Determine x extents for each line Sort in z order Draw pixel for nearest line

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics14 Spanning Scan Line Algorithms Create a list of polygons for each scan line Determine x extents for each line Determine spans – All end points and intersections partition spans Draw front line for each span

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics15 List priority algorithms Sort things in depth order – Painter’s algorithm paints back to front – We could just paint front if no overlaps Newell-Newell-Sancha Algorithm – Provides way to sort polygons Splits any polygons if there is a cyclical relationship

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics16 Doing things in a z-buffer world Z-buffer: the most common scan-line method – What’s good about it? – What’s bad about it?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics17 Shadows? Why does OpenGL not show shadows?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics18 Drawing Shadows Assume a light at (0,0,0). We want to know were the shadow projects on a plane defined by ax+by+cz+d=0 – An occluding point S=(s x,s y,s z,1) – Anything along line through S would be: (  s x,  s y,  s z,1) – Line intersection with plane is: –  as x +  bs y +  cs z +d=0 – a=-d/(as x +bs y +cs z ) – Intersection with plane is: -d(s x,s y,s z )/(as x +bs y +cs z )

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics19 Using this equation -d(s x,s y,s z )/(as x +bs y +cs z ) 1. Translate so light is at origin 2. Put this matrix on stack (using translated plane) 3. Draw object we are casting shadow of in shadow color ??? Similar approach exists For lights at infinity

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics20 How I got this working… I display the shadow into the stencil buffer I then draw the polygon with alpha value that decreases brightness See example program…

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics21 Shadow Direction Image from light 0 viewpoint Image from light 1 viewpoint What all can we do with this?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics22 Lit Polygon Determination Image from light 0 viewpoint Image from light 1 viewpoint Partition polygons into lit/not lit sets Subdivide any that are partially lit

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics23 Shadow Texture Image from light 0 viewpoint Image from light 1 viewpoint Create a texture map for each visible polygon

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics24 Shadow Map Image from light 0 viewpoint Depth map from light 0 viewpoint The map partitions the space into shadowed/not shadowed. For each point, determine which partition we are in

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics25 Deep Shadow Maps 3D texture where each point is how much illumination we receive

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics26 Shadow Volumes Polygons cast polyhedra of shadow volumes Intersect polyhedra and object space

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics27 Reflections/Transparency? How?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics28 Environment Maps Uses vertex normals to generate texture coordinates How can we use this to generate: – Reflections – Transparency with refraction?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics29 Depth of Field? What? Why? How?

CSE 872 Dr. Charles B. Owen Advanced Computer Graphics30 Motion Blur What? Why? How?