From 823665c23920ef0917b2036079b4be2951445e2c Mon Sep 17 00:00:00 2001 From: Pierre Ossman Date: Mon, 20 Jan 2014 16:55:19 +0100 Subject: [PATCH] Document the different pixel representations that we deal with --- common/rfb/PixelFormat.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/common/rfb/PixelFormat.h b/common/rfb/PixelFormat.h index 10d39026..e05e6f9f 100644 --- a/common/rfb/PixelFormat.h +++ b/common/rfb/PixelFormat.h @@ -19,7 +19,16 @@ */ // // PixelFormat - structure to represent a pixel format. Also has useful -// methods for reading & writing to streams, etc. +// methods for reading & writing to streams, etc. Conversion to and from +// other formats are also handled by this class. We have three different +// representations that we refer to: +// +// a) Pixels - Unsigned native integers in the format specified by this +// PixelFormat object. +// b) Buffer - Same thing as pixels, but in the appropriate byte stream +// format. This involves endian conversion and padding. +// c) RGB - A byte stream of 8 bit red, green and blue elements, in that +// order. // #ifndef __RFB_PIXELFORMAT_H__ -- 2.39.5