Bitwise operations in C Bitwise operations in C In the C programming language, operations can be performed on a bit level using bitwise operators. Bitwise operations are contrasted by byte-level operations which characterize the bitwise operators' logical counterparts, the AND, OR and NOT operators. Instead of performing on individual bits, byte-level operators perform on strings of eight bits (known as bytes) at a time. The reason for this is that a byte is normally the smallest unit of addressable memory (i.e. data with a unique memory address.) This applies to bitwise operators as well, which means that even though they operate on only one
Packed pixel Packed pixel In packed pixel or chunky framebuffer organization, the bits defining each pixel are grouped together. For example, if there are 16 bits per pixel, each pixel is represented in two consecutive (contiguous) 8-bit bytes in the framebuffer (a.k.a. screen buffer). If there are 4 bits per pixel (16 colors), each frame buffer byte defines two pixels, one in each nibble. The latter example is as opposed to storing perhaps half of the bits—2 bits—for each of four pixels in one byte and the other two bits for each of those four pixels in another byte or bytes. It