X-Git-Url: https://git.ucc.asn.au/?p=ipdf%2Fdocuments.git;a=blobdiff_plain;f=LitNotes%2FPorterDuffCompositing;fp=LitNotes%2FPorterDuffCompositing;h=94253b3639ecb0c18088be57cf61e11076a5a313;hp=0000000000000000000000000000000000000000;hb=cfb938735e59c97943e4e73d11f1c5602b61d96f;hpb=219690fbbd295afe83783788ae7bbd4eaba887dd diff --git a/LitNotes/PorterDuffCompositing b/LitNotes/PorterDuffCompositing new file mode 100644 index 0000000..94253b3 --- /dev/null +++ b/LitNotes/PorterDuffCompositing @@ -0,0 +1,42 @@ +Porter, Thomas and Duff, Tom, "Compositing Digital Images", Computer Graphics Vol 18, Num 3, July 1984 + +Compositing Digital Images +Thomas Porter +Tom Duff +Computer Graphics Project +Lucasfilm Ltd. + + +Perter and Duff's classic paper "Compositing Digital Images" lays the +foundation for digital compositing today. By providing an "alpha channel," +images of aribitary shapes — and images with soft edges or sub-pixel coverage +imformation — can be overlayed digitally, allowing separate objects to be +rasterized separately without a loss in quality. + +Pixels in digital images are usually represented as 3-tuples containing +(red component, green component, blue component). Nominally these values are in +the [0-1] range. In the Porter-Duff paper, pixels are stored as (R,G,B,\alpha) +4-tuples, where alpha is the fractional coverage of each pixel. If the image +only covers half of a given pixel, for example, its alpha value would be 0.5. + +To improve compositing performance, albeit at a possible loss of precision in +some implementations, the red, green and blue channels are premultiplied by the +alpha channel. This also simplifies the resulting arithmetic by having the +colour channels and alpha channels use the same compositing equations. + +Several binary compositing operations are defined: +- over +- in +- out +- atop +- xor +- plus + +The paper further provides some additional operations for implementing fades and +dissolves, as well as for changing the opacity of individual elements in a +scene. + +The method outlined in this paper is still the standard system for compositing +and is implemented almost exactly by modern graphics APIs such as OpenGL. It is +all but garunteed that this is the method we will be using for compositing +document elements in our project.