Some Things Jeremy Sugerman 22 February 2005. Jeremy Sugerman, FLASHG 22 February 2005 Topics Quick GPU Topics Conditional Execution GPU Ray Tracing.

Slides:



Advertisements
Similar presentations
Exploration of advanced lighting and shading techniques
Advertisements

Sven Woop Computer Graphics Lab Saarland University
Debugging Tools Tim Purcell NVIDIA. Programming Soap Box Successful programming systems require at least three ‘tools’ Successful programming systems.
Photon Mapping on Programmable Graphics Hardware Timothy J. Purcell Mike Cammarano Pat Hanrahan Stanford University Craig Donner Henrik Wann Jensen University.
Ray tracing. New Concepts The recursive ray tracing algorithm Generating eye rays Non Real-time rendering.
Understanding the graphics pipeline Lecture 2 Original Slides by: Suresh Venkatasubramanian Updates by Joseph Kider.
Graphics Pipeline.
Status – Week 257 Victor Moya. Summary GPU interface. GPU interface. GPU state. GPU state. API/Driver State. API/Driver State. Driver/CPU Proxy. Driver/CPU.
Graphics Hardware CMSC 435/634. Transform Shade Clip Project Rasterize Texture Z-buffer Interpolate Vertex Fragment Triangle A Graphics Pipeline.
Interactive Ray Tracing: From bad joke to old news David Luebke University of Virginia.
I3D Fast Non-Linear Projections using Graphics Hardware Jean-Dominique Gascuel, Nicolas Holzschuch, Gabriel Fournier, Bernard Péroche I3D 2008.
Rasterization and Ray Tracing in Real-Time Applications (Games) Andrew Graff.
Extending GRAMPS Shaders Jeremy Sugerman June 2, 2009 FLASHG.
Control Flow Virtualization for General-Purpose Computation on Graphics Hardware Ghulam Lashari Ondrej Lhotak University of Waterloo.
Brook for GPUs Ian Buck, Tim Foley, Daniel Horn, Jeremy Sugerman, Kayvon Fatahalian, Mike Houston, Pat Hanrahan Stanford University DARPA Site Visit, UNC.
GH05 KD-Tree Acceleration Structures for a GPU Raytracer Tim Foley, Jeremy Sugerman Stanford University.
A Crash Course on Programmable Graphics Hardware Li-Yi Wei 2005 at Tsinghua University, Beijing.
3D Graphics Processor Architecture Victor Moya. PhD Project Research on architecture improvements for future Graphic Processor Units (GPUs). Research.
Many-Core Programming with GRAMPS Jeremy Sugerman Kayvon Fatahalian Solomon Boulos Kurt Akeley Pat Hanrahan.
Z-Buffer Optimizations Patrick Cozzi Analytical Graphics, Inc.
GPU Simulator Victor Moya. Summary Rendering pipeline for 3D graphics. Rendering pipeline for 3D graphics. Graphic Processors. Graphic Processors. GPU.
Z-Buffer Optimizations Patrick Cozzi Analytical Graphics, Inc.
Data Parallel Computing on Graphics Hardware Ian Buck Stanford University.
Status – Week 283 Victor Moya. 3D Graphics Pipeline Akeley & Hanrahan course. Akeley & Hanrahan course. Fixed vs Programmable. Fixed vs Programmable.
The programmable pipeline Lecture 10 Slide Courtesy to Dr. Suresh Venkatasubramanian.
Vertex & Pixel Shaders CPS124 – Computer Graphics Ferdinand Schober.
Mapping Computational Concepts to GPU’s Jesper Mosegaard Based primarily on SIGGRAPH 2004 GPGPU COURSE and Visualization 2004 Course.
Interactive k-D Tree GPU Raytracing Daniel Reiter Horn, Jeremy Sugerman, Mike Houston and Pat Hanrahan.
Status – Week 260 Victor Moya. Summary shSim. shSim. GPU design. GPU design. Future Work. Future Work. Rumors and News. Rumors and News. Imagine. Imagine.
3D Rendering & Algorithms__ Sean Reichel & Chester Gregg a.k.a. “The boring stuff happening behind the video games you really want to play right now.”
GPU Graphics Processing Unit. Graphics Pipeline Scene Transformations Lighting & Shading ViewingTransformations Rasterization GPUs evolved as hardware.
Ray Tracing and Photon Mapping on GPUs Tim PurcellStanford / NVIDIA.
Mapping Computational Concepts to GPUs Mark Harris NVIDIA Developer Technology.
NVIDIA PROPRIETARY AND CONFIDENTIAL Occlusion (HP and NV Extensions) Ashu Rege.
Visibility Queries Using Graphics Hardware Presented by Jinzhu Gao.
Mapping Computational Concepts to GPUs Mark Harris NVIDIA.
GPU Computation Strategies & Tricks Ian Buck Stanford University.
Interactive Rendering of Meso-structure Surface Details using Semi-transparent 3D Textures Vision, Modeling, Visualization Erlangen, Germany November 16-18,
Chris Kerkhoff Matthew Sullivan 10/16/2009.  Shaders are simple programs that describe the traits of either a vertex or a pixel.  Shaders replace a.
Interactive Time-Dependent Tone Mapping Using Programmable Graphics Hardware Nolan GoodnightGreg HumphreysCliff WoolleyRui Wang University of Virginia.
Cg Programming Mapping Computational Concepts to GPUs.
Week 2 - Friday.  What did we talk about last time?  Graphics rendering pipeline  Geometry Stage.
The Graphics Rendering Pipeline 3D SCENE Collection of 3D primitives IMAGE Array of pixels Primitives: Basic geometric structures (points, lines, triangles,
Raytracing and Global Illumination Intro. to Computer Graphics, CS180, Fall 2008 UC Santa Barbara.
The programmable pipeline Lecture 3.
Stream Processing Main References: “Comparing Reyes and OpenGL on a Stream Architecture”, 2002 “Polygon Rendering on a Stream Architecture”, 2000 Department.
Shadow Mapping Chun-Fa Chang National Taiwan Normal University.
Tone Mapping on GPUs Cliff Woolley University of Virginia Slides courtesy Nolan Goodnight.
Saarland University, Germany B-KD Trees for Hardware Accelerated Ray Tracing of Dynamic Scenes Sven Woop Gerd Marmitt Philipp Slusallek.
GPU Computation Strategies & Tricks Ian Buck NVIDIA.
1 Ray Tracing with Existing Graphics Systems Jeremy Sugerman, FLASHG 31 January 2006.
M. Jędrzejewski, K.Marasek, Warsaw ICCVG, Multimedia Chair Computation of room acoustics using programable video hardware Marcin Jędrzejewski.
Motivation Properties of real data sets Surface like structures
Fateme Hajikarami Spring  What is GPGPU ? ◦ General-Purpose computing on a Graphics Processing Unit ◦ Using graphic hardware for non-graphic computations.
From Turing Machine to Global Illumination Chun-Fa Chang National Taiwan Normal University.
Ray Tracing using Programmable Graphics Hardware
Shadows David Luebke University of Virginia. Shadows An important visual cue, traditionally hard to do in real-time rendering Outline: –Notation –Planar.
Ray Tracing by GPU Ming Ouhyoung. Outline Introduction Graphics Hardware Streaming Ray Tracing Discussion.
COMPUTER GRAPHICS CHAPTER 38 CS 482 – Fall 2017 GRAPHICS HARDWARE
Graphics Processing Unit
Chapter 6 GPU, Shaders, and Shading Languages
From Turing Machine to Global Illumination
Christian Lauterbach GPGPU presentation 3/5/2007
Graphics Processing Unit
UMBC Graphics for Games
Debugging Tools Tim Purcell NVIDIA.
Ray Tracing on Programmable Graphics Hardware
RADEON™ 9700 Architecture and 3D Performance
CIS 441/541: Introduction to Computer Graphics Lecture 15: shaders
Frame Buffer Applications
Presentation transcript:

Some Things Jeremy Sugerman 22 February 2005

Jeremy Sugerman, FLASHG 22 February 2005 Topics Quick GPU Topics Conditional Execution GPU Ray Tracing

Jeremy Sugerman, FLASHG 22 February 2005 PCI-Express PCI-Express solves data transfer problems… DownUp NV AGP NV PCI ATI AGP ATI PCI DL AGP

Jeremy Sugerman, FLASHG 22 February DLabs Realizm 100 AGP Mediocre Fill Rate (About half a 9800XT) Reasonable Texture Bandwidth Variable Cost Instructions 6 GFLOPS ADD – 0.5 GFLOPS LG2 Remarkable Readback But, No GL_TEXTURE_RECTANGLE_EXT

Jeremy Sugerman, FLASHG 22 February 2005 Conditional Execution Depth and Stencil are classic tools Only effective early All shaders support predication and KIL No savings in execution time KIL does gruesome things to the pipeline Pixel Shader 3.0 has true branching If-Then-Else, Data dependent loops NV4x currently, no ATI until R500

Jeremy Sugerman, FLASHG 22 February 2005 Compute Mask – Z Buffer Clear Z to 1.0 Draw Depth-Only at Z = 0.3 KIL where computation will happen Draw Color at Z = 0.7 Very Effective When it Works Fragile, Easily Disabled Stays Disabled Until glClear!

Jeremy Sugerman, FLASHG 22 February 2005 Compute Mask - EarlyZ NV41X800 Random 2x2 Blocks 3x3 Blocks 4x4 Blocks Wavefront

Jeremy Sugerman, FLASHG 22 February 2005 Compute Mask – PS3.0 Rasterize Normally a shader like: If (pixel is live) { … MOV result.color, } else { MOV result.color, // Or KIL } Easy to Write Must shade all fragments Must write a value or KIL for all fragments

Jeremy Sugerman, FLASHG 22 February 2005 Compute Mask – PS 3.0 Random 64x64 Blocks 32x32 Blocks 16x16 Blocks Wavefront

Jeremy Sugerman, FLASHG 22 February 2005 Pixel Shader 3.0 Not (yet?) a replacement for Early-Z What about loops? What about state machines? If (fragment is in state a) { // Computation 1 } else { // Computation 2 } Will execution time be MAX(a, b) or a + b?

Jeremy Sugerman, FLASHG 22 February 2005 GPU Ray Tracing Tim Purcell left us a Brook raycaster Tim (Foley) et al. beat on it for DARPA Line- of-Sight Early-Z, 2D Addressing Tim and I have forked it again Explore new hardware features Explore new algorithm options Mature, maintainable source base

Jeremy Sugerman, FLASHG 22 February 2005 Demo Break for demo…

Jeremy Sugerman, FLASHG 22 February 2005 GPU Ray Tracing – Brute Force Initialize Scene Parameters, Geometry (CPU) Generate Eye Rays Foreach( triangle in the scene ) Intersect with all rays Record if it hits closer than any prior triangle Shade Hits Ray-Triangle kernel is 39 instructions Over 100 million intersections per second

Jeremy Sugerman, FLASHG 22 February 2005 GPU Ray Tracing – Uniform Grid Initialize Scene Parameters, Geometry (CPU) Generate Eye Rays While (Any Rays Are Live) Traverse the traversing rays Intersect the intersecting rays Shade Hits Equivalent to ~14 million ray-triangles per second on our scenes.

Jeremy Sugerman, FLASHG 22 February 2005 “Any Live Rays?” Fundamentally a reduction Sum across all rays Readback to CPU Many passes to do a GPU reduction Could try occlusion query Kernel that just KIL’s on dead rays Still an extra pass GPU global counter registers would be cool Equivalent to 24 million ray-triangles per second when skipped.

Jeremy Sugerman, FLASHG 22 February 2005 Ping Ponging Buffers No read-modify-write causes copies: intersectTriangle(in ray, in oldHit, in tri, out hit) { if (ray hits tri closer than oldHit) { hit = ; } else { hit = oldHit;No RMW } Memory and Bandwidth Hungry Add conditionals / predication to kernels Complicates Early-Z compute masking

Jeremy Sugerman, FLASHG 22 February 2005 Render to Texture DirectX has it, OpenGL does not DirectX raytracer bluescreens NV4x drivers Every shader draws its results to a pbuffer Copied back to a texture each time Superbuffers offered a fix ATI supported them (broken now) ARB killed them Framebuffer Objects made it through the ARB Only drivers are preliminary NV4x drivers

Jeremy Sugerman, FLASHG 22 February 2005 GPU Ray Tracer Enhancements 2D Addressing (duh) kD-Tree Accelerator Early-Z and/or PS3.0 for the Accelerators Tuning Traverse vs. Intersect vs. Shade Occlusion Queries / Fast Reductions Shadows Tuning Bandwidth Shading…