Author: eilemann@gmail.com
State: Design
Overview
Transparency needs special attention when using a sort-last (DB) compound. Typically, all transparent objects have to be rendered back-to-front on top of the assembled opaque objects. This document explores what can and should be implemented in Equalizer to facilitate sort-last compounds with transparency.
Design
Serial Transparency Rendering
The simplest approach is to have one rendering pass for all transparent objects on the destination channel, after the assembly has happened. The order of operations would be:
render opaque geometry in parallel assemble opaque geometry (in parallel) (gather assembled tiles) render transparent geometry on destination channelThis approach fits for most applications, which have to render small amounts of transparent geometry. The destination channel can be relieved of some rendering workload by using a smaller range, or load-balancing (once implemented). It does not work for applications where rendering the transparent object take a lot of time, for example volume rendering mixed with geometry.
Parallel Transparency Rendering
For applications rendering lots of transparent data, decomposing the transparent rendering is desirable. The order of operations could be:
render opaque geometry in parallel assemble opaque geometry (in parallel) render transparent geometry (in parallel, 2D 'compound' on tile) (gather assembled tiles)OR:
render opaque geometry in parallel assemble opaque geometry (in parallel) save framebuffer [assembled result] clear framebuffer render transparent geometry in parallel save framebuffer [transparent geometry] restore framebuffer [assembled result] assemble transparent data w/ saved framebuffer [transparent geometry] (gather assembled tiles)OR:
render opaque and transparent geometry in parallel on different channels assemble (in parallel): z-assemble all opaque frames sorted-blend assemble all transparent frames (gather assembled tiles)The last approach seems to be the best. The serial transparency rendering is a special case of this algorithm, where all transparent data is rendered on one channel only. This algorithm has the following preconditions:
- If the destination channel is also source, it has to render opaque geometry, or it has to readback its content for sorted assembly.
- Channels have to exclusively render opaque or transparent geometry. The application has to map the DB-range to that concrete boundary, or the server has to obey the boundary. Both approaches may need some changes in Equalizer to be implementable.
- A specialized
eq::Channel::frameAssemble
implementation using two steps to assemble, as outlined above. This could be implemented in Equalizer, and is useful for pure volume rendering as well.
Implementation
TBD
API
TBD
File Format
TBD
Open Issues