Interactive Cloth Simulation. Matthias Wloka NVIDIA Corporation

Similar documents
Graphics Hardware. Instructor Stephen J. Guy

Cloth Simulation on the GPU. Cyril Zeller NVIDIA Corporation

In-Game Special Effects and Lighting

Computer Graphics (CS 543) Lecture 10: Normal Maps, Parametrization, Tone Mapping

Computer Graphics. Si Lu. Fall uter_graphics.htm 11/22/2017

CS451Real-time Rendering Pipeline

Surface Rendering. Surface Rendering

CSE528 Computer Graphics: Theory, Algorithms, and Applications

CS 498 VR. Lecture 19-4/9/18. go.illinois.edu/vrlect19

Computer Graphics (CS 543) Lecture 10: Soft Shadows (Maps and Volumes), Normal and Bump Mapping

Real-Time Universal Capture Facial Animation with GPU Skin Rendering

GUERRILLA DEVELOP CONFERENCE JULY 07 BRIGHTON

CHAPTER 1 Graphics Systems and Models 3

Higher Order Surfaces in OpenGL with NV_evaluators. Sébastien Dominé

Intro to Ray-Tracing & Ray-Surface Acceleration

Lighting and Shading

Recursion and Data Structures in Computer Graphics. Ray Tracing

Direct Rendering of Trimmed NURBS Surfaces

C P S C 314 S H A D E R S, O P E N G L, & J S RENDERING PIPELINE. Mikhail Bessmeltsev

Photorealism: Ray Tracing

Life on the Bleeding Edge: More Secrets of the NVIDIA Demo Team Eugene d Eon NVIDIA Corporation.

Programming Graphics Hardware

Bringing AAA graphics to mobile platforms. Niklas Smedberg Senior Engine Programmer, Epic Games

Mattan Erez. The University of Texas at Austin

DirectX10 Effects. Sarah Tariq

Topic 12: Texture Mapping. Motivation Sources of texture Texture coordinates Bump mapping, mip-mapping & env mapping

DirectX10 Effects and Performance. Bryan Dudash

Computer Graphics. Shadows

Topic 11: Texture Mapping 11/13/2017. Texture sources: Solid textures. Texture sources: Synthesized

Computergrafik. Matthias Zwicker. Herbst 2010

of the NVIDIA Demo Team Eugene d Eon 2008 NVIDIA Corporation.

2.11 Particle Systems

Topic 11: Texture Mapping 10/21/2015. Photographs. Solid textures. Procedural

Scalable multi-gpu cloud raytracing with OpenGL

CS 450: COMPUTER GRAPHICS TEXTURE MAPPING SPRING 2015 DR. MICHAEL J. REALE

Zeyang Li Carnegie Mellon University

Wednesday, July 24, 13

CS451 Texturing 4. Bump mapping continued. Jyh-Ming Lien Department of Computer SCience George Mason University. From Martin Mittring,

Evolution of GPUs Chris Seitz

Introduction Ray tracing basics Advanced topics (shading) Advanced topics (geometry) Graphics 2010/2011, 4th quarter. Lecture 11: Ray tracing

Mali Demos: Behind the Pixels. Stacy Smith

Computer Graphics. Lecture 14 Bump-mapping, Global Illumination (1)

CS 354R: Computer Game Technology

Homework #2. Shading, Ray Tracing, and Texture Mapping

AGDC Per-Pixel Shading. Sim Dietrich

Hardware-Assisted Relief Texture Mapping

Input Nodes. Surface Input. Surface Input Nodal Motion Nodal Displacement Instance Generator Light Flocking

Advanced Shading and Texturing

Rendering. Converting a 3D scene to a 2D image. Camera. Light. Rendering. View Plane

Computer Graphics I Lecture 11

Graphics Hardware, Graphics APIs, and Computation on GPUs. Mark Segal

Technical Report. Anisotropic Lighting using HLSL

Enhancing Traditional Rasterization Graphics with Ray Tracing. March 2015

Rendering Algorithms: Real-time indirect illumination. Spring 2010 Matthias Zwicker

CMSC427 Advanced shading getting global illumination by local methods. Credit: slides Prof. Zwicker

Ray Casting of Trimmed NURBS Surfaces on the GPU

Computer Graphics 1. Chapter 7 (June 17th, 2010, 2-4pm): Shading and rendering. LMU München Medieninformatik Andreas Butz Computergraphik 1 SS2010

CPSC / Texture Mapping

Texture Mapping. Brian Curless CSE 457 Spring 2016

Deferred Rendering Due: Wednesday November 15 at 10pm

Graphics Processing Unit Architecture (GPU Arch)

Spring 2009 Prof. Hyesoon Kim

COMP 4801 Final Year Project. Ray Tracing for Computer Graphics. Final Project Report FYP Runjing Liu. Advised by. Dr. L.Y.

Parallax Bumpmapping. Whitepaper

Canonical Shaders for Optimal Performance. Sébastien Dominé Manager of Developer Technology Tools

Advanced Maya Texturing and Lighting

Texture Mapping. Brian Curless CSE 457 Spring 2015

Enabling immersive gaming experiences Intro to Ray Tracing

CS GAME PROGRAMMING Question bank

Motivation MGB Agenda. Compression. Scalability. Scalability. Motivation. Tessellation Basics. DX11 Tessellation Pipeline

Texture Mapping II. Light maps Environment Maps Projective Textures Bump Maps Displacement Maps Solid Textures Mipmaps Shadows 1. 7.

Rendering: Reality. Eye acts as pinhole camera. Photons from light hit objects

How to Work on Next Gen Effects Now: Bridging DX10 and DX9. Guennadi Riguer ATI Technologies

Pipeline Operations. CS 4620 Lecture 14

Topics and things to know about them:

Texture Mapping. Reading. Implementing texture mapping. Texture mapping. Daniel Leventhal Adapted from Brian Curless CSE 457 Autumn 2011.

Chapter 7 - Light, Materials, Appearance

Review. Stephen J. Guy

Advanced Maya e Texturing. and Lighting. Second Edition WILEY PUBLISHING, INC.

Wednesday, 26 January 2005, 14:OO - 17:OO h.

V-Ray RT: A New Paradigm in Photorealistic Raytraced Rendering on NVIDIA GPUs. Vladimir Koylazov Chaos Software.

Optimal Shaders Using High-Level Languages

Pipeline Operations. CS 4620 Lecture Steve Marschner. Cornell CS4620 Spring 2018 Lecture 11

Dominic Filion, Senior Engineer Blizzard Entertainment. Rob McNaughton, Lead Technical Artist Blizzard Entertainment

Shadow Techniques. Sim Dietrich NVIDIA Corporation

INF3320 Computer Graphics and Discrete Geometry

Ray tracing. Computer Graphics COMP 770 (236) Spring Instructor: Brandon Lloyd 3/19/07 1

Applications of Explicit Early-Z Z Culling. Jason Mitchell ATI Research

6.837 Introduction to Computer Graphics Final Exam Tuesday, December 20, :05-12pm Two hand-written sheet of notes (4 pages) allowed 1 SSD [ /17]

Reading. Texture Mapping. Non-parametric texture mapping. Texture mapping. Required. Angel, 8.6, 8.7, 8.9, 8.10,

Shaders. Slide credit to Prof. Zwicker

Spring 2011 Prof. Hyesoon Kim

lecture 18 - ray tracing - environment mapping - refraction

LEVEL 1 ANIMATION ACADEMY2010

Other Rendering Techniques CSE 872 Fall Intro You have seen Scanline converter (+z-buffer) Painter s algorithm Radiosity CSE 872 Fall

Texturing Theory. Overview. All it takes is for the rendered image to look right. -Jim Blinn 11/10/2018

Consider a partially transparent object that is illuminated with two lights, one visible from each side of the object. Start with a ray from the eye

Interactive Methods in Scientific Visualization

Mia Round Corners Node

Those Delicious Texels or Dynamic Image-Space Per-Pixel

Transcription:

Interactive Cloth Simulation Matthias Wloka NVIDIA Corporation MWloka@nvidia.com

Overview Higher-order surfaces Vertex-shader deformations Lighting modes Per-vertex diffuse Per-pixel diffuse with bump-map Minnaert lighting (velvet) Blinn-bump reflection Reflection and refraction

CPU Work CPU computes cloth-equations on a control-net Collision detection and resolution with sphere Vertex shader cannot access control-net points Control-net defines Bspline- (or Bezier-) patches GPU generates vertices from the control-net Advantages: CPU processes only control-net points Bandwidth savings (cache/main-memory, AGP) Dynamic LODing is simplified Optimal way to draw triangles

Control-Net vs. Rendered Vertices Control-net: 13 x 10 = 130 vertices Rendered vertices: (10*13) x (7*13) = 11,830 vertices

Collision Detection and Resolution Control-net collisions are low resolution Possible interpenetration in center of patch Vertex shaders resolve interpenetration Compute distance of vertex to sphere-center If greater than radius, do nothing If less than radius, displace vertex along distancevector by (radius distance)

Vertex Shader Collision Resolution Vertex a a c 2 > r 2 Sphere c r Vertex b Vertex b b c 2 < r 2 b = c + r b c

Vertex Shader Deformation

Per-Pixel Lighting Higher-order surfaces module generates per-vertex normal and tangent Vertex shader computes Per-vertex bi-normal = normal x tangent Model- to texture-space matrix Normal.x Tangent.x Bi-Normal.x Normal.y Tangent.y Bi-Normal.y Normal.z Tangent.z Bi-Normal.z Transforms light-vector to texture space Send transformed light-vector to pixel shader

Per-Pixel Lighting (cont.) Pixel shader fetches Per-pixel normal from bump-map Per-pixel color from texture Per-pixel light-vector from vertex shader Renormalize via normalization cube-map And computes Diffuse (N dot L) Modulate with light- and material-color

Per-Pixel Lighting Screenshot

Minnaert Lighting Custom per-pixel lighting model that simulates velvet F(N dot L, N dot E) * (N dot L) * material_color F(x, y) is custom (generated) texture: Vertex shader set-up: Compute model-space normal, light, and eye-vector Compute texture space light vector Copy material color and uv-coords (for bump-map)

Minnaert Lighting Screenshot

Blinn-Bump Reflection Vertex shader Compute and store normal, tangent, and bi-normal And store eye-vector in the w-components Pixel-shader Looks up normal And lets the hardware do Texture-space to model-space transform Reflection vector computation Environment cube-map look-up

Blinn Bump Reflection Screenshot

Sphere Reflection Environment-map does not contain sphere Sphere casts no reflection Render sphere into environment-map Environment-map works because environment is conceptually far away Origin of reflection vector is insignificant For close objects, location of reflection does matter (multiple reflections)

Sphere Reflection Problem A A B V B V C C Environment is rendered from some viewpoint V The further away objects are, the more V can jitter without noticeable difference Moving in-between A, B, C, V is very noticeable

Sphere Reflection Solution Ray-trace per vertex in vertex shader! Compute eye-reflection vector Test ray-sphere intersection Compute sphere-intersection point and normal Light intersection point Store sphere-color blend factor in alpha 0 if no intersection Attenuate by intersection distance Attenuate by proximity to rim

Ray Tracing in the Vertex Shader compute vector from eye to vertex n v n reflect that vector compute vector from intersection point to light; light via n dot l perform raysphere intersection; if hit, compute intersection point

Sphere Reflection Close-Up

Blinn-Bump Reflection, 2 nd Pass First pass Blend between per-pixel reflection and sphere ray-trace Second pass Compute specular Modulate texture color with texture alpha Alpha blend sum of above with 1 st pass result

Reflection and Refraction No per-pixel normal Vertex shader computes Reflection vector R = -(E 2*(E dot N) * N) Refraction vector Approximate via shortened normal N = s * N R = -(E s 2 * 2*(E dot N) * N) Specular N E R E N R

Reflection and Refraction (cont.) Pixel shader computes Environmental cube-map look-up for reflection and refraction vector Blend reflection-result and sphere ray-trace Blend result with refraction Add specular contribution

Reflection and Refraction Screenshot

Vertex/Pixel Shader Debugger It s a debugger Step Break Examine register values http://www.nvidia.com/developer

NVEffectsBrowser Vertex- and pixel-shader framework to: Quickly prototype Experiment Demo DirectX8 effects Nvidia s Vertex and Pixel Shader Contest Submit your shaders to NVidia Fabulous prizes See http://www.nvidia.com/developer for details

Vertex Shader Uses Custom texture coordinate generation goes a long way Various materials Reflection and refraction Fogging effects Discretization Because texture look-up encodes an arbitrary function t = f(u, v, w) Pixel shader set-up

Vertex Shader Uses (2) Deformations Lens-distortions Distort along normals (halo/silhouette rendering) Local/global deformations Waves/ripples Data generation Compute normals on the fly (deformed geometry) Compute position/color/etc. from time

Vertex Shader Uses (3) Multi-transforms Matrix-palette skinning Morphing Motion blur Silhouettes and tangent/bi-normal Art-based rendering (NPR rendering) Volumes (shadow volume)

Pixel Shader Uses Per-pixel custom lighting Per-pixel normals, potentially animated Area is wide open Access to pixel-neighbors via four texture units Limited image processing Blurred shadows Depth of Field Color-space conversions Edge-detection Procedural textures

Questions? Matthias Wloka MWloka@nvidia.com www.nvidia.com/developer