EyeQ Docs

Structs

Parameter structures for configuring Perfectly Clear corrections.

This page documents the parameter structures used to configure Perfectly Clear corrections.

Core runtime structures

These foundational data structures are used throughout the SDK for image buffers, engine instances, and analysis profiles.

PFCIMAGE

Defines an image buffer including dimensions, pixel format, and data pointer for SDK processing.

typedef struct {
    int width;
    int height;
    int stride;
    PFCPIXELFORMAT format;
    unsigned char *data;
} PFCIMAGE;
FieldTypeDescription
widthintPixel width of image
heightintPixel height of image
strideintByte width of each scanline or row
formatPFCPIXELFORMATPixel format defining byte order
dataunsigned char*Pointer to first byte of image data buffer

Notes:

The stride may be larger than width times bytes per pixel if rows are padded for alignment. The SDK modifies image data in place during processing.

PFCENGINE

Contains the internal engine pointer and initialization status for a processing engine instance.

typedef struct {
    PFCINTERNAL pEngine;
    PFCENGINESTATUS status;
} PFCENGINE;
FieldTypeDescription
pEnginePFCINTERNALInternal pointer to engine implementation
statusPFCENGINESTATUSEngine initialization status

PFCIMAGEPROFILE

Contains pre-calculated analysis data and feature status codes returned by PFC_Calc.

typedef struct {
    PFCINTERNAL pPfcParam;
    PFCINTERNAL pNoiseParam;
    PFCINTERNAL pRedEyeParam;
    PFCINTERNAL pSFBParam;
    PFCINTERNAL pInternal;
    
    PFCCORE_STATUS CORE_Status;
    PFCNR_STATUS NR_Status;
    PFCFB_STATUS FB_Status;
    PFCRE_STATUS RE_Status;
    
    int Status;
} PFCIMAGEPROFILE;
FieldTypeDescription
CORE_StatusPFCCORE STATUSCore pre-calc status
NR_StatusPFCNR STATUSNoise Removal pre-calc status
FB_StatusPFCFB STATUSFace Beautification pre-calc status
RE_StatusPFCRE STATUSRed Eye pre-calc status
StatusintSummary status bits

Note: The PFCPROFILE type is a pointer to PFCIMAGEPROFILE:

#define PFCPROFILE PFCIMAGEPROFILE*

For background synchronization workflows, PFCBGPROFILE is defined as an internal profile handle:

#define PFCBGPROFILE PFCINTERNAL

Geometry structures

PFCPOINT

Represents a two-dimensional point with integer x and y coordinates.

typedef struct {
    int x;
    int y;
} PFCPOINT;

PFCRECT

Represents a rectangular region with position and dimensions.

typedef struct {
    int left;
    int top;
    int width;
    int height;
} PFCRECT;

Face detection structures

PFCFBFACEINFO

Contains simplified face geometry including eye positions and face bounds from Face Beautification detection.

typedef struct {
    PFCPOINT leftEye;
    PFCPOINT rightEye;
    PFCRECT face;
} PFCFBFACEINFO;
FieldTypeDescription
leftEyePFCPOINTLeft eye position
rightEyePFCPOINTRight eye position
facePFCRECTFace bounding rectangle

PFCFACERECT

Contains comprehensive face detection data including landmarks, angles, and confidence scores from Face Aware Exposure analysis.

typedef struct PFCFaceRect {
    PFCRECT rect;
    PFCRECT rcEyeL;
    PFCRECT rcEyeR;
    PFCRECT rcMouth;
    PFCPOINT ptEyeL;
    PFCPOINT ptEyeR;
    int angle;
    int blinkLevel;
    int blinkLevelL;
    int blinkLevelR;
    int confidence;
    int smileLevel;
    int yawAngle;
    int FAE[3];
    int widthImage;
    int heightImage;
    struct PFCFaceRect *pNext;
} PFCFACERECT;
FieldTypeDescription
rectPFCRECTFace bounding rectangle
rcEyeLPFCRECTLeft eye rectangle
rcEyeRPFCRECTRight eye rectangle
rcMouthPFCRECTMouth rectangle
ptEyeLPFCPOINTLeft eye coordinates with 10-bit fixed-point
ptEyeRPFCPOINTRight eye coordinates with 10-bit fixed-point
angleintRoll angle from -179 to 180 degrees
confidenceintDetection confidence
smileLevelintSmile detection level
yawAngleintYaw angle from -90 to 90 degrees
widthImageintSource image width
heightImageintSource image height
pNextPFCFACERECT*Next face in linked list

PDF image utility classes

These C++ helper classes support iterating and replacing PFC-compatible images embedded in PDF files.

PFCPDFImage

Represents a single image extracted from a PDF document and exposes both expanded and compressed image representations.

MemberTypeDescription
imageFilePFCImageFile*Expanded image for processing; owned by PFCPDFImage
pdfObjectNumberuint32_tObject number in the PDF document
compressedBuffervoid*Raw compressed bytes
compressedBufferSizeintCompressed byte size

PFCPDFImageIterator

Iterates over PFC-supported images in a PDF and automatically embeds modified images back into the document.

MethodDescription
load(const char* path)Opens a PDF from disk and reports LoadStatus
nextImage()Returns next PFCPDFImage*, or nullptr when exhausted
save(const char* path)Writes updated PDF and reports SaveStatus
setExpandImageData(bool expand)Controls whether image bytes are expanded into PFCImageFile
document() / takeDocument()Accesses or transfers ownership of underlying PdfMemDocument

Master parameter structure

This section covers the top-level structure that contains all correction parameters.

PFCPARAM

The master structure that aggregates all correction parameter groups into a single configuration object.

typedef struct {
    PFCCOREPARAM core;
    PFCFBPARAM fb;
    PFCNRPARAM nr;
    PFCREPARAM re;
    PFCV3PARAM v3;
    PFCV3PARAM layer[3];
    PFCCOREMask mask[3];
    DP2PARAM dp2;
} PFCPARAM;
FieldTypeDescription
corePFCCOREPARAMCore correction parameters
fbPFCFBPARAMFace Beautification parameters
nrPFCNRPARAMNoise Reduction parameters
rePFCREPARAMRed Eye Removal parameters
v3PFCV3PARAMV3 corrections including LUTs and finishing
layerPFCV3PARAM arrayLayer parameters
maskPFCCOREMask arrayMasks for gradient filters
dp2DP2PARAMAI White Balance parameters

Core parameters

These parameters control the fundamental image corrections including exposure, contrast, color, and sharpening.

PFCCOREPARAM

Contains all settings for core image corrections such as exposure adjustment, contrast enhancement, color restoration, and sharpening.

FieldTypeRangeDescription
bEnabledBOOLEnable Core correction
bAbnormalTintRemovalBOOLEnable Tint Removal
eTintModeTINTCORRECTIONTint detection mode
fTintScalefloat0.0 to 1.0Tint correction amount
iBlackEnhancementint0 to 25Noise Management threshold
bVibrancyBOOLEnable Color Restore
iVibrancyint0 to 200Color Restore strength
iStrengthint0 to 150Exposure strength
bContrastBOOLEnable Depth
eContrastModeCONTRASTMODEDepth mode
iContrastint0 to 100Depth strength
eBiasModeBIASMODESkin and Depth Bias
fBiasScalefloat0.0 to 1.0Bias scale
bHighlightPreservationBOOLEnable Highlight Preservation
iHighlightPreservationint0 to 100Highlight Preservation amount
bSharpenBOOLEnable Sharpening
fSharpenScalefloat0.0 to 2.0Sharpening strength
bUseAutomaticStrengthSelectionBOOLAuto Strength Selection
bUseFAEBOOLFace Aware Exposure
eAggressivenessAGGRESSIVENESSExposure aggressiveness
iMaxStrengthint0 to 150Maximum exposure
iMinStrengthint0 to 150Minimum exposure
bInfraredBOOLEnable Infrared Removal
fInfraredfloat0.0 to 1.0Infrared Removal strength
bLightDiffusionBOOLEnable Light Diffusion
fLightDiffusionfloat0.0 to 1.0Light Diffusion strength
bDynamicRangeBOOLEnable dynamic range
bDCFBOOLEnable Fidelity
eDCFModeDCFMODEFidelity mode
fDCFfloat0.0 to 1.0Fidelity strength
bLocalContrastBOOLEnable Super Contrast
iLocalContrastint0 to 100Super Contrast strength
bSkintoneAutoBOOLAuto skin tone detection
iSkintoneAutoStrengthint0 to 100AI Skin Tone strength
bSelectiveColorBOOLEnable Selective Color
selectiveColorSELECTIVECOLOR arraySelective Color definitions

Face beautification parameters

These parameters control portrait enhancement features including skin smoothing, eye enhancement, and facial contouring.

PFCFBPARAM

Contains all settings for Face Beautification corrections including skin smoothing, eye enhancement, teeth whitening, and facial contouring.

FieldTypeRangeDescription
bEnabledBOOLEnable Face Beautification
bSmoothBOOLEnable Perfectly Smooth
iSmoothLevelint0 to 100Smooth strength
eSmoothModeSKINMODEFace or body
eSmoothTypeSKINSMOOTHTYPESmooth type
bEnlargeBOOLEnable Eye Enlarge
iEnlargeLevelint0 to 100Eye Enlarge strength
bEnhanceBOOLEnable Eye Enhance
iEnhanceLevelint0 to 100Eye Enhance strength
bEyeCircBOOLEnable Dark Circle Removal
iEyeCircint0 to 100Dark Circle strength
bTeethBOOLEnable Teeth Whitening
iTeethLevelint0 to 100Teeth Whitening strength
bBlemishBOOLEnable Blemish Removal
iBlemishint0 to 100Blemish Removal strength
bSlimBOOLEnable Face Contouring
iSlimint0 to 100Face Contouring strength
bDeFlashBOOLEnable Shine Removal
iDeFlashint0 to 100Shine Removal strength
bCatchLightBOOLEnable Catchlights
iCatchLightint0 to 100Catchlight level
iCatchLightModeint1 to 51 is Umbrella, 2 is Ringlight, 3 is Softbox, 4 is Beauty Dish, 5 is Outdoors
bSkinToningBOOLEnable Skin Toning
iSkinToningint0 to 100Skin Toning strength
eSkinToningModeSKINMODEFace or body
eSkinToningTypeSKINTONINGTYPEToning type
colorSkinToningunsigned intAARRGGBBSkin color, default 0xFFF5BCA9
bBlushBOOLEnable Blush
iBlushint0 to 100Blush level
colorBlushunsigned intAARRGGBBBlush color, default 0xFFFD7171

Noise removal parameters

These parameters control the noise reduction algorithm behavior and strength.

PFCNRPARAM

Contains settings for intelligent noise detection and removal with preset-based configurations.

FieldTypeRangeDescription
bEnabledBOOLEnable Noise Removal
iPresetint0 to 40 is Default, 1 is Portrait, 2 is Night, 3 is Camera phone, 4 is Force
iStrengthOffsetint-5 to 5Strength offset
iDetailOffsetint-30 to 30Detail preservation offset

Red eye parameters

These parameters control automatic red eye detection and correction.

PFCREPARAM

Contains settings for automatic red eye detection and removal in flash photography.

FieldTypeDescription
bEnabledBOOLEnable Red Eye Removal

V3 parameters

These parameters control advanced finishing effects including LUTs, color grading, and final adjustments.

PFCV3PARAM

Contains settings for V3 finishing corrections including LUT application, Image Ambulance, and final color adjustments.

FieldTypeDescription
bPreprocessEVboolEnable EV correction for Image Ambulance
iPreprocessEVintEV correction amount
iNeutralDensityintNeutral density filter
lutInputCorrectivePFC3DLutInfoCorrective Filter LUT
lutInputSkyPFC3DLutInfoSky Enhance LUT
lutInputFoliageGreenPFC3DLutInfoFoliage Green LUT
lutInputFoliageBrownPFC3DLutInfoFoliage Brown LUT
lutOutputPFC3DLutInfoCreative LOOKs Filter or LOOKs
iFinishTempintTemperature
iFinishTintintTint
iFinishExposureintExposure
iFinishBlacksintBlacks
iFinishShadowsintShadows
iFinishHighlightsintHighlights
iFinishWhitesintWhites
iFinishSaturationintSaturation
iFinishVibrancyintVibrancy
iFinishContrastintContrast
bDynamicBOOLEnable AI Color
iDynamicintAI Color strength from 0 to 100
iDynamicWBintDynamic WB strength from 0 to 100

Supporting structures

These structures provide additional data types used within the main parameter structures.

PFC3DLutInfo

References a 3D LUT file for color grading and creative effects.

FieldTypeDescription
guidchar array32-character GUID
strengthunsigned charStrength from 0 to 100

SELECTIVECOLOR

Defines a selective color correction that targets a specific hue range for adjustment.

FieldTypeRangeDescription
rintHue ramp start
aintFlat range start
mintFlat range end
pintHue ramp end
Hint-180 to 180Hue shift
Sint-100 to 100Saturation shift
Lint-100 to 100Luminance shift

PFCCOREMask

Defines a gradient mask for applying selective corrections to specific image regions.

FieldTypeDescription
typePFCCORE MASK TYPEMask type
centerXfloatCenter X as relative value
centerYfloatCenter Y as relative value
widthfloatWidth as relative value
heightfloatHeight as relative value
radiusfloatCorner radius for ROUNDRECT only
featherfloatGradient length
anglefloatRotation clockwise
transparencyfloatOverall transparency
invertboolInvert mask

Notes:

  • Coordinates are relative to the final crop-rotated image (Y/height, X/width).
  • height for linear masks defines distance from centerY where gradient reaches 1.0.
  • radius is used only for MASK_ROUNDRECT.

DP2PARAM

Contains settings for AI-powered white balance and color density corrections.

FieldTypeRangeDescription
iDensityint-100 to 100Density
iDeltaRint-100 to 100Red delta
iDeltaGint-100 to 100Green delta
iDeltaBint-100 to 100Blue delta
fGammafloat0.3 to 4.0Gamma
iContrastint-100 to 100Contrast
iSaturationint-100 to 100Saturation
bAutoBOOLUse AI-detected params
bEnableBOOLEnable correction

PFCSCENEDESCRIPTION

Contains metadata about a detected scene returned from PFC_GetSceneDescription.

FieldTypeDescription
namechar arrayUTF-8 scene name
profileUUIDintProfile UUID

BGMASKPARAM

Defines parameters for background mask generation used with background synchronization workflows.

FieldTypeDescription
iRawMaskModeintRaw mask mode selector
iBGintBackground level, 0 to 100
iFGintForeground level, 0 to 100
iToleranceintAllowed target intensity variation
iSobelintSobel binarization threshold
iBlurintBlur amount
bImfillboolFill black holes
bAreaopenboolRemove white noise in black subject
iAreaopenintArea-open parameter relative to image size
bAreaopenBGboolRemove small black regions in white background
iAreaopenBGintBackground area-open parameter
iConnectivityintConnectivity mode (4 or 8)
bGradboolEnable gradient filtering
bGradAutoboolAuto gradient placement based on detected face bottom
iGradBottomintRelative gradient bottom
iGradHeightintRelative gradient spread
avRfloatCalculated average background red
avGfloatCalculated average background green
avBfloatCalculated average background blue

PFC-SDK Version 10.7.3.1317 built from df9dbc8727c92fb9b1d2c68b21e60ea9c7229e1a on 03-23-2026.

Copyright © 2026 EyeQ Imaging Inc. All rights reserved.

On this page