140 likes | 279 Views
SIGGRAPH ASIA 2011 Preview seminar Shading and Shadows. Shading and Shadows. Image-space Bidirectional Scene Reprojection A Shading Reuse Method for Efficient Micropolygon Ray Tracing Genetic Programming for Shader Simplification
E N D
Shading and Shadows • Image-space Bidirectional Scene Reprojection • A Shading Reuse Method for Efficient Micropolygon Ray Tracing • Genetic Programming for ShaderSimplification • An Efficient Alias-free Shadow Algorithm for Opaque and Transparent Objects using per-triangle Shadow Volumes
Image-space Bidirectional Scene Reprojection L. Yang, Y-C. Tse, P. Sander, J. Lawrence, D. Nehab, H. Hoppe, C. Wilkins Real-time temporal upsampling through image-based reprojection of adjacent frames Rendered frame t Interpolated frame t+α Rendered frame t+1 Flow field Flow field
Image-space Bidirectional Scene Reprojection Scene-assisted interpolation Image-based interpolation Displacement No geometry infomation t+α Rendered t Rendered t+1 Rendered t Rasterized t+α Rendered t+1 1 Scene flow estimation at each pixel Reverse reprojection at each pixel Interpolated t+α Interpolated t+α
Image-space Bidirectional Scene Reprojection • Scene flow estimation • Partial computation of I-frames Time lag... Event!
Image-space Bidirectional Scene Reprojection • Additional search initialization • Increasing accuracy • Dual initialization, Latest-frame initialization • User study : simple game • To analyze effect on user and experience of the tradeoff between the higher framerates and increased latency • Question • Enjoyed the game? • Game was responsive? • Animation was smooth? Simple game
Genetic Programming for Shader Simplification P. Sitthi-amorn, N. Modly, W. Weimer, J. Lawrence • GP for optimizing shadercode • Mutation operation • Error metrics • Performance measure • Advantage • Possibly better than manual optimization Original shader Simplified shader
Genetic Programming for Shader Simplification AST AST + + • Population initialization • Mutating original shader • Fitness evaluation • Timing and quality • Ranking and Diversity • Retain low-ranked variants • Mating selection • Tournament selection • Crossover and Mutation • Selection for next iteration • same as Ranking and Diversity mutation a sin sin a * * b c b c crossover Selection (random) 1st 2nd 3rd 2nd 4th 4th 5th 6th Add Swap Replace by average Remove Crossover
Genetic Programming for Shader Simplification • Error model • L2-RGB error / structural similarity index over frames • Sampling small patches on G-buffer (modify pix-shader) • Cross-correlation 0.84 (actual error - predicted error) • Performance model • Sampling small patches on render target • minutes → 1-2 secs,cross-correlation 0.95 (error)
An Efficient Alias-free Shadow Algorithm for Opaque and Transparent Objects Using Per-triangle Shadow Volumes E. Sintorn, O. Olsson, U. Assarsson • A shadow volume algorithm • Cast shadow • Point (& directional?)light • Advantage • Screen-space anti-aliasing • Transparent shadow-caster & receiver • Small memory footprint • No load-balancing issue • Deferred shading pipeline
An Efficient Alias-free Shadow Algorithm for Opaque and Transparent Objects Using Per-triangle Shadow Volumes Common shadow volume Proposed algorithm Caster: each triangle No adjacency info. No preprocessing Depth + shadow buffer CUDA implementation Compatible with screen-space anti-aliasing, textured-shadow caster, stochastic transparency Caster = all faces • Caster : silhouette edge • Preprocessing • Depth + stencil buffer • Hardware support • Opaque model Caster Light Model Shadow mapping • Resolution of shadow map • Aliasing
An Efficient Alias-free Shadow Algorithm for Opaque and Transparent Objects Using Per-triangle Shadow Volumes min&max depth ←AABB point light caster (triangle) 1. Clip space 2. Depth buffer camera Shadow rasterization test against each plane of shadow frustum shadow frustum receiver 0 0 1 0 0 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 4. Rendered image 3. Shadow Buffer
An Efficient Alias-free Shadow Algorithm for Opaque and Transparent Objects Using Per-triangle Shadow Volumes • Hierarchical depth buffer and shadow buffer • Colored, transparent shadow-caster • Floating point value shadow buffer • Stochastically setting shadow bit • Screen-space anti-aliasing (MSAA, CSAA, SSAA) • # of shadow bits & depth derivative 1 1 0 1 1 0 0 0 1 1 0 0 1 1 1 1 0 1 1 0 0 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0
Shading and Shadows • Image-space Bidirectional Scene Reprojection • A Shading Reuse Method for Efficient Micropolygon Ray Tracing • Genetic Programming for Shader Simplification • An Efficient Alias-free Shadow Algorithm for Opaque and Transparent Objects using per-triangle Shadow Volumes