rdpCodecs struct (include/freerdp/codecs.h), which holds one context per codec type and is accessible via context->codecs.
rdpCodecs — The Codec Container
FreeRDP_CodecFlags:
Codec Flags
RDP GFX Pipeline (MS-RDPEGFX)
The Graphics Pipeline Extension (Windows 8+) is delivered over therdpgfx dynamic virtual channel (Microsoft::Windows::RDS::Graphics). It replaces the legacy slow-path graphics orders with an explicit surface model:
- The server creates surfaces (
RDPGFX_CMDID_CREATESURFACE) and maps them to output regions (RDPGFX_CMDID_MAPSURFACETOOUTPUT). - Frame boundaries are delimited with
RDPGFX_CMDID_STARTFRAME/RDPGFX_CMDID_ENDFRAME. - The client acknowledges frames with
RDPGFX_CMDID_FRAMEACKNOWLEDGEto implement backpressure. - Pixels are delivered via
RDPGFX_CMDID_WIRETOSURFACE_1(uncompressed or codec-compressed) orRDPGFX_CMDID_WIRETOSURFACE_2(cache-based). - A surface-to-surface blit (
RDPGFX_CMDID_SURFACETOSURFACE) and an import cache (RDPGFX_CMDID_CACHEIMPORTOFFER/RDPGFX_CMDID_CACHEIMPORTREPLY) further reduce bandwidth.
H.264 / AVC (H264_CONTEXT)
Declared in include/freerdp/codec/h264.h. Supports two chroma sub-sampling modes:
Rate Control
Usage Types
Backend Selection
FreeRDP selects an H.264 subsystem at build time (or runtime where multiple are compiled in):RemoteFX (RFX_CONTEXT)
Declared in include/freerdp/codec/rfx.h. RemoteFX is a wavelet-based lossless codec optimized for screen content with sharp edges and text.
RLGR1 and RLGR3 modes.
RemoteFX (
FreeRDP_RemoteFxCodec) uses the classic slow-path surface commands. For the GFX pipeline variant use the Progressive codec (FreeRDP_GfxProgressive).Progressive Codec (PROGRESSIVE_CONTEXT)
Declared in include/freerdp/codec/progressive.h. The Progressive codec (MS-RDPEGFX section 2.2.4) is an evolution of RemoteFX that supports progressive quality refinement: an initial low-quality frame is sent first, then delta frames progressively improve fidelity — useful on bandwidth-constrained links.
NSCodec (NSC_CONTEXT)
Declared in include/freerdp/codec/nsc.h. NSCodec (also known as MS-RDPNSC) is a simple color-space conversion codec that converts RGB bitmaps to YCoCg color space before RLE compression. It targets UI elements with few distinct colors.
Enable with FreeRDP_NSCodec = TRUE.
RDP 6.x Bitmap Compression
Legacy bitmap compression used in RDP 6.0 and earlier. FreeRDP provides two contexts:
These are used for classic slow-path
TS_BITMAP_DATA PDUs and are always available regardless of GFX pipeline support.
