Title: Single Pass Point Rendering and Transparent Shading
1Single Pass Point Rendering and Transparent
Shading
- Paper by Yanci Zhang and Renato Pajarola
- Presentation by
- Harmen de Weerd and Hedde Bosman
2The standard 21 algorithm
- Visibility Pass
- Smooth point interpolation and shading Pass
- Normalization/shading Pass
- Well known from the lab sessions
3The standard 21 algorithm cons
- 2 passes over the dataset with computational
intensive shaders - Transparency hard to achieve
- Back to front alpha blending, z-buffer is turned
off - Interpolation between overlapping splats in one
layer uses the z-buffer to cull fragments that do
not belong in this one layer (i.e. are not
visible). - Possible with depth-peeling seen in previous
presentation, but uses multiple geometry passes - One other algorithm proposed for alpha blending
which cannot use the GPU
4A new algorithm
- Idea
- Create multiple groups of the point set that do
not need a separate visibility pass - Render an image for each group
- postpone e-z-buffer test and smooth point
interpolation to an image composition pass
511 algorithm
6Deferred Blending
Divide point set S in K Groups
711 Algorithm Grouping
811 Algorithm Grouping
9(No Transcript)
10Largest First grouping algorithm
1
3
2
5
4
3
2
1
7
6
11Largest First grouping algorithm
1
3
2
5
4
3
2
1
7
6
12Largest First grouping algorithm
1
3
2
5
4
3
2
1
7
6
13Largest First grouping algorithm
1
3
2
5
4
3
2
1
7
6
14Largest First grouping algorithm
1
3
2
5
4
3
2
1
7
6
15(No Transcript)
1611 Algorithm Images...
- Create K images from K groups
- Add depth info to images.
- Since splats do not overlap in object space
(because of grouping) we do not need to worry
about visibility culling - Do use z-buffers since splats might overlap in
image space
1711 Algorithm Image composition
- For each resulting fragment
- Determine the minimum depth of the fragment
- Determine the sum of the color components if the
depth is within e of the minimum depth - Determine the sum of all alpha components if the
depth is within e of the minimum depth - Normalize the colors using the alpha RGBRGB/A
1811 Algorithm Transparency
- Previous algorithm does not account for
transparency, so... - Adapt grouping algorithm to make sure no holes
exists in surfaces of one group. - Render each group image using alpha blending
19Optimal grouping
20Transparency Problems
- cannot account weight and alpha simultaneously
- Need full surface coverage to look 'through' a
material layer - Should not have overlap between splats
21Transparency Problems 2,3
22Transparency Solutions
- cannot account weight and alpha simultaneously
- Solution
- Do not account the weight.
- Artifacts are reduced dramatically by multiple
transparent surface layers - Small errors aren't even visible because color is
only 8bit.
23Grouping algorithm extensions
- Relaxation of some edge definitions
- Virtually co-planer overlapping splats can go in
the same group - If normals of splats are in opposite directions
(n1 . N2 lt 0) the splats can be in the same
group. - Relax overlap condition with user defined
parameter - Add points to multiple groups
24Grouping algorithm extensions
Grouping results. a) Splats have smaller overlaps
but less surface coverage for K 8. b) Splats
have bigger overlaps but better surface cover for
K 4.
25Fragment culling
- Optimally in each transparent surface layer there
is exactly one fragment contributing to
alpha-blending per pixel - Two methods to create this situation
- Reduce z-buffer precision
- increase surface coverage in a group image
- Increased splat radius
- Add splats to multiple groups
- Decrease number of groups
26Basic 11 Algorithm (1)?
- For each group
- Render splat with color, depth and kernel weight
- Voronoi enhanced depth buffer (lower kernel
weight is culled)? - For each pixel
- Determine the minimum depth
- For each group image
- Sum the color and weight attributes if the
fragment is in the nearest layer. - Average the sum of color by the sum of weights.
27Voronoi enhance
28Basic transparency algorithm (2)?
- Use BSP-tree for efficient back-to-front ordering
- Transparency blending pass (using a-blending)
- Render all splats pi of each group Sk using
modified radii r into separate target images Ik - Perform back-to-front a-blending using material
transparency afrag - cnew afragcold (1 - afrag) cfrag
- Compositing pass (PBR blending)
- Average color of all images Ik into final
framebuffer
29Reduction in z-buffer accuracy
- Overlapping splats cause too much attenuation
- Solution cull fragments that are too close to
rendered fragments - Report the depth of each fragment in steps of
size e
30High quality transparency algorithm (3)?
- Geometry pass for nearest layer
- Use basic algorithm 1 to get depth and kernel
information about the nearest layer - Geometry pass for other layers
- Use transparency algorithm 2, but cull all
fragments from nearest layer using depth mask the
first pass - Composition pass
- Perform smooth point interpolation for nearest
layer - Average the color over all images for other
layers - Combine the nearest layer with the other layers
31Reflections and refractions
- Refraction effects and specular reflection
improve rendering realism - Both are derived from incident viewing vector,
surface normal, and environment mapping - Can be added to the nearest layer pass of
algorithm 3 - Downside only reflections and refractions for
nearest visible layer
32Multi-layer reflection/refraction
- Accumulate opacity over all layers for each group
Sk separately - Assuming constant material opacity a, approximate
number of layers l atotal / a - Ratio of light absorption (1 a)l
- Transmitted total refraction sin qT hl sin qI
33Single vs Multi-layer refraction
34Per fragment shading
- As with our lab sessions, all needed attributes
per fragment are interpolated - Deferred shading approach can be used for any
attribute other than color - Phong lighting
- Environment map reflection
- Multi-layer refraction
- Attenuation
35Visual results
Combining opaque and transparent objects
Single-pass (a) versus two-pass (b) algorithm
36Visual results
Depth Peeling vs Algorithm 3 vs Algorithm 2
37Speed Comparison
Standard 21 PBR algorithm vs the novel 11 pass
PBR algorithm
38Visual Comparison
39Ball Joint
40David Head
41Female model
42Q / A