This directory contains the internal C++ implementation of the PDF specification. These modules are for internal use and may change without notice.
PDFium's core is divided into several subdirectories, each with a specific responsibility:
fxge for managing target bitmaps.Building a rendered page involves several layers working in concert:
fpdfapi/parser reads raw bytes and builds the PDF object graph (Dictionaries, Streams, etc.).fxcodec decodes compressed data streams.fpdfapi/page interprets the objects into higher-level constructs like paths, text objects, and images.fpdfapi/render traverses the page objects and issues drawing commands to fxge.fxge uses its rendering backend (e.g., AGG or Skia) to convert these primitives into final pixels in a device buffer.PDF documents use User Space, a coordinate system where the origin (0,0) is typically at the bottom-left of the page. Rendering devices (managed by fxge) usually use Device Space, where the origin is at the top-left.
core/ handles the complex affine transformations needed to map between these spaces, taking into account page rotation, scaling, and the specific transformation matrices (CTM) defined within content streams.