Texture Mapping Applications 2. Parallax Mapping with Slope  parallax mapping assumes that the surface is a single plane  a better approximation  surface.

Slides:



Advertisements
Similar presentations
Lecture 8 Transparency, Mirroring
Advertisements

Technische Universität München Computer Graphics SS 2014 Graphics Effects Rüdiger Westermann Lehrstuhl für Computer Graphik und Visualisierung.
Ray tracing. New Concepts The recursive ray tracing algorithm Generating eye rays Non Real-time rendering.
Exploration of bump, parallax, relief and displacement mapping
03/16/2009Dinesh Manocha, COMP770 Texturing Surface’s texture: its look & feel Graphics: a process that takes a surface and modifies its appearance using.
Computer Graphics Bing-Yu Chen National Taiwan University.
CLASS 9 ADVANCE RENDERING RAY TRACING RADIOSITY LIGHT FIELD CS770/870.
COMPUTER GRAPHICS CS 482 – FALL 2014 OCTOBER 6, 2014 TEXTURE MAPPING TEXTURES BUMP MAPPING ENVIRONMENT MAPPING PROCEDURAL TEXTURING.
Week 9 - Wednesday.  What did we talk about last time?  Fresnel reflection  Snell's Law  Microgeometry effects  Implementing BRDFs  Image based.
Reflections from Bumpy Surfaces GPU Graphics. What are we trying to achieve?  Most surfaces are not flat like glass  Some of these surfaces still give.
Informationsteknologi Thursday, November 22, 2007Computer Graphics - Class 111 Today’s class Clipping Parametric and point-normal form of lines Intersecting.
WILLIAM MOSS ADVANCED RENDERING COURSE PROJECT DECEMBER 4 TH, 2008 Real-time rendering of water and bubbles.
CS6500 Adv. Computer Graphics © Chun-Fa Chang, Spring 2003 Object-Order vs. Screen-Order Rendering April 24, 2003.
(conventional Cartesian reference system)
Ray Casting Ray-Surface Intersections Barycentric Coordinates Reflection and Transmission [Shirley, Ch.9] Ray Tracing Handouts Ray Casting Ray-Surface.
Texture Mapping from Watt, Ch. 8 Jonathan Han. Topics Discussed Texture Map to Models Bump Maps, Light Maps Environment (Reflection) Mapping 3D Textures.
Parallelizing Raytracing Gillian Smith CMPE 220 February 19 th, 2008.
CIS 310: Visual Programming, Spring 2006 Western State College 310: Visual Programming Ray Tracing.
Texture Mapping Texture Mapping Ltjg Omer Arisut Turkish Navy Turkish Navy Texture Mapping Texture Mapping Ltjg Omer Arisut Turkish Navy Turkish Navy.
Basic Ray Tracing CMSC 435/634. Visibility Problem Rendering: converting a model to an image Visibility: deciding which objects (or parts) will appear.
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.
Computer Graphics Inf4/MSc Computer Graphics Lecture 11 Texture Mapping.
Cornell CS465 Fall 2004 Lecture 3© 2004 Steve Marschner 1 Ray Tracing CS 465 Lecture 3.
1 Perception, Illusion and VR HNRS 299, Spring 2008 Lecture 19 Other Graphics Considerations Review.
1 Computer Graphics Week13 –Shading Models. Shading Models Flat Shading Model: In this technique, each surface is assumed to have one normal vector (usually.
Computer Graphics: Programming, Problem Solving, and Visual Communication Steve Cunningham California State University Stanislaus and Grinnell College.
Computer Graphics Inf4/MSc Computer Graphics Lecture 7 Texture Mapping, Bump-mapping, Transparency.
1 Perception and VR MONT 104S, Spring 2008 Lecture 22 Other Graphics Considerations Review.
COMP 175: Computer Graphics March 24, 2015
Environment Mapping. Examples Fall Motivation Silver candlestick No appropriate texture for it “ environment ” map Simulates the results of ray-tracing.
Reflections Specular reflection is the perfect reflection of light from a surface. The law a reflection states that the direction of the incoming ray and.
11/11/04© University of Wisconsin, CS559 Fall 2004 Last Time Shading Interpolation Texture mapping –Barycentric coordinates for triangles.
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.
09/11/03CS679 - Fall Copyright Univ. of Wisconsin Last Time Graphics Pipeline Texturing Overview Cubic Environment Mapping.
CS 638, Fall 2001 Today Project Stage 0.5 Environment mapping Light Mapping.
1 Rendering Geometry with Relief Textures L.Baboud X.Décoret ARTIS-GRAVIR/IMAG-INRIA.
September 5, 2013Computer Vision Lecture 2: Digital Images 1 Computer Vision A simple two-stage model of computer vision: Image processing Scene analysis.
Rendering Overview CSE 3541 Matt Boggus. Rendering Algorithmically generating a 2D image from 3D models Raster graphics.
Basic Ray Tracing CMSC 435/634. Visibility Problem Rendering: converting a model to an image Visibility: deciding which objects (or parts) will appear.
Advanced Computer Graphics Advanced Shaders CO2409 Computer Graphics Week 16.
Computing & Information Sciences Kansas State University Lecture 10 of 42CIS 636/736: (Introduction to) Computer Graphics CIS 636/736 Computer Graphics.
Computer Graphics 2 Lecture 7: Texture Mapping Benjamin Mora 1 University of Wales Swansea Pr. Min Chen Dr. Benjamin Mora.
CHAPTER 8 Color and Texture Mapping © 2008 Cengage Learning EMEA.
More on Environment Mapping Glenn G. Chappell U. of Alaska Fairbanks CS 381 Lecture Notes Wednesday, December 10, 2003.
CS 325 Introduction to Computer Graphics 03 / 29 / 2010 Instructor: Michael Eckmann.
Global Illumination. Local Illumination  the GPU pipeline is designed for local illumination  only the surface data at the visible point is needed to.
CS 376 Introduction to Computer Graphics 04 / 02 / 2007 Instructor: Michael Eckmann.
Ray Tracing Fall, Introduction Simple idea  Forward Mapping  Natural phenomenon infinite number of rays from light source to object to viewer.
Graphics Interface 2009 The-Kiet Lu Kok-Lim Low Jianmin Zheng 1.
Real-Time Relief Mapping on Arbitrary Polygonal Surfaces Fabio Policarpo Manuel M. Oliveira Joao L. D. Comba.
11/5/2002 (c) University of Wisconsin, CS 559 Last Time Local Shading –Diffuse term –Specular term –All together –OpenGL brief overview.
CSCE 441: Computer Graphics Ray Tracing
11/24/ :45 Graphics II Shadow Maps Reflections Session 5.
Module 06 –environment mapping Module 06 – environment mapping Module 06 Advanced mapping techniques: Environment mapping.
OpenGL Vertex Arrays OpenGL vertex arrays store vertex properties such as coordinates, normal vectors, color values and texture coordinates. These properties.
Image-Based Rendering Geometry and light interaction may be difficult and expensive to model –Think of how hard radiosity is –Imagine the complexity of.
RENDERING : Global Illumination
Global Illumination (3) Path Tracing. Overview Light Transport Notation Path Tracing Photon Mapping.
CS 325 Introduction to Computer Graphics 04 / 07 / 2010 Instructor: Michael Eckmann.
Real-Time Relief Mapping on Arbitrary Polygonal Surfaces Fabio Policarpo Manuel M. Oliveira Joao L. D. Comba.
Visible-Surface Detection Methods. To identify those parts of a scene that are visible from a chosen viewing position. Surfaces which are obscured by.
CS 376 Introduction to Computer Graphics 04 / 13 / 2007 Instructor: Michael Eckmann.
Texturing Tomas Akenine-Möller Department of Computer Engineering Chalmers University of Technology.

Ravish Mehra Subodh Kumar IIT Delhi IIT Delhi
Reflections from Bumpy Surfaces
Michael Tanaya , Hua ming Chen
Environment Mapping.
Texture Mapping Jung Lee.
Presentation transcript:

Texture Mapping Applications 2

Parallax Mapping with Slope  parallax mapping assumes that the surface is a single plane  a better approximation  surface is locally planar where the plane normal is given by the normal vector from the normal map

Parallax Mapping with Slope  point on approximating plane L Szirmay-Kalos and T Umenhoffer, “Displacement mapping on the GPU-State of the art”

Parallax Mapping with Slope  equation of “eye” ray L Szirmay-Kalos and T Umenhoffer, “Displacement mapping on the GPU-State of the art”

Parallax Mapping with Slope  intersection of ray and approximating plane L Szirmay-Kalos and T Umenhoffer, “Displacement mapping on the GPU-State of the art”

Parallax Mapping with Slope  solve for a then s’ and t’  tends to produce somewhat better results than ordinary parallax mapping

Parallax Mapping  the previous parallax mapping methods assume that the height field does not change rapidly  if the height field changes rapidly then the computed offset texture coordinate will likely be incorrect

Parallax Mapping  the problem that needs to be solved is “what is the height map intersection nearest to the viewer?”  this is a root finding problem

Iterative Methods  because height maps typically do not have simple functional forms, the intersection of the eye ray with the height field has to be solved numerically (with an iterative root finding method)  iterative methods can be categorized as being unsafe or safe  unsafe: an approximate intersection is found but not necessarily the one closest to the viewer  safe: an approximate intersection is found and it is the one closest to the viewer

Iterated Parallax Mapping  the simplest unsafe iterative method is to simply iterate the estimate of the eye ray intersection point  iteration is typically performed 3 or 4 times  start with a guess of the intersection point  substitute into eye ray equation

Iterated Parallax Mapping  solving for the updated approximation  iterate the above equation in a loop a few times to get the offset texture coordinates parallax mapping with slope iterated parallax mapping “Displacement mapping on the GPU-State of the art”

Binary Search Parallax Mapping  start with two guesses A and B for the intersection point  A has height below the height at the intersection point  B has height above the height at the intersection point  this can be done because the unbiased height map has height values in the range {0, 1}  look at the point M halfway between the two guesses  keep the interval [A,M] if M is above the height field, otherwise keep the interval [M,B]  repeat a fixed number of times

Binary Search Parallax Mapping “Displacement mapping on the GPU-State of the art”

Ray Marching  ray marching is a quasi-safe method  safe if step size is smaller than 1 texel  idea is very simple  starting from the maximum height on the ray to the viewer  take a fixed number of steps of constant size along the ray  check if the point is below the height map surface  if it is then there must be an intersection with the height map “Displacement mapping on the GPU-State of the art”

Ray Marching  ray marching speed can be increased if we could avoid visiting points far from the height map surface  this is possible, but requires additional data structures computed as a preprocessing step  dilation and erosion maps  pyramidal displacement mapping  sphere tracing  cone stepping  see “Displacement mapping on the GPU-State of the art” article for references

Ray Marching  used in a broad class of methods called relief mapping  also known as steep parallax mapping and parallax occlusion mapping  can be slow if texture is large and the step size is small  tends to produce staircase artifacts “Displacement mapping on the GPU-State of the art”

Vertex Shader Displacement Mapping  the vertex shader can be used to actually move the vertex positions using a height map  simply move the vertex in the normal vector direction by an amount given by the height map  this only works if the object being displacement mapped is sufficiently tesselated  a significant advantage is that objects with curved surfaces can be displacement mapped in the vertex shader

Cube Mapping  textbook p  a type of environment mapping  used to simulate the effect of an environment that surrounds an object or scene  used to create realtime reflections or refractions (typically for a single object)  basic idea  a cube surrounds the environment  the environment is projected onto the six inner surfaces of the cube  OpenGL and glsl provide support for cube mapping

Cube Mapping

 imagine a shiny (or transparent) object located at the center of the cube  for any point on the object we can easily find the reflection (or refraction) direction  use glsl reflect (or refract )  using the reflection (or refraction) direction we can find which side of the cube is seen by the reflected (or refracted) ray  intersecting the ray with cube side yields a color texture value that can be applied to the object point  yields realtime reflection (and refraction)

Cube Mapping  indexed using a three-dimensional texture coordinate (s, t, p)  this is just the reflection or refraction direction

Cube Mapping 1. find which of s, t, and p has the largest absolute value  determines which side of the cube is hit by the ray (in this case the face labelled –x)

Cube Mapping 2. divide the other two coordinates (call them a and b) by v to obtain the texture coordinates 3. use s’ and t’ as the texture coordinates

Cube Mapping reflect.glib refract.glib

Cube Mapping  cube maps can be updated in realtime to show changes in the environment  idea: from a fixed location, render the scene with a camera facing in the six different directions directly into the six textures of the cube map

Cube Mapping

 Wikipedia page on cube mapping describes some other uses of cube maps Wikipedia page on cube mapping

Procedural Texture Mapping  textbook p  a significant problem with image textures is that they have finite resolution  leads to magnification problems  image textures can consume a large amount of memory  procedural texture mapping computes a texture value given a texture coordinate  “infinite” resolution  small memory footprint

Procedural Texture Mapping  disadvantages  limited to textures that you can generate algorithmically  probably slower than image texture lookup  aliasing  not necessarily platform independent  nothing to prevent you from using both image and procedural textures on the same object

Textbook Examples  procedural stripes

Textbook Examples  procedural fractals

Textbook Examples  procedural bump map

Textbook Examples  procedural bumpmap

Procedural Textures  Ken Perlin Ken Perlin  Making Noise Making Noise