
272.9 e Swap-Chain and Compositing Process
e most trivial method for guaranteeing frame completion is to call glFinish
when the canvas presents its buer to the compositor. However, this does not provide
great performance, as it forces the CPU to wait until the GPU is completely done with
the command stream. Instead, we merely need to establish a dependency relation on the
GPU side alone, where we don’t let the GPU read from the frontbuer until it is done
rendering it.
Such GPU-side synchronization is extremely platform dependent, especially when the
two sides may be in dierent processes. Many platforms have some variety of synchro-
nizat ...