Perfectly Clear SDK Documentation  9.0.0.295
PerfectlyClearPro.h
Go to the documentation of this file.
1 
3 #ifndef __PERFECTLYCLEARPRO_H__
4 #define __PERFECTLYCLEARPRO_H__
5 #ifdef __cplusplus
6 extern "C" {
7 #endif
8 
9 #ifdef _LINUX
10 #define BOOL int
11 #define ULONG unsigned long
12 #define UINT unsigned int
13 #define TRUE 1
14 #define FALSE 0
15 //#define NULL 0
16 #endif
17 
19 #define NRRETCODE(x) (x & 0x000000FF)
20 #define CORERETCODE(x) ((x >> 8) & 0x000000FF)
22 #define FBRETCODE(x) ((x >> 16) & 0x000000FF)
24 #define RERETCODE(x) ((x >> 24) & 0x000000FF)
26 #define PFCINTERNAL void*
28 
32 typedef BOOL (*PFC_PROGRESS)(int iPercent);
33 
35 typedef enum {
149 
151 typedef enum {
156 
158 typedef enum {
159  CALC_CORE = 1,
160  CALC_NR = 2,
161  CALC_FB = 4,
162  CALC_RE = 8,
163  CALC_ALL = 15,
165  CALC_NOFAE = 32,
167  CALC_CARTOON_DETECTOR = 128,
168  CALC_SHARP = 256
169 } PFCFEATURE;
170 
172 typedef enum {
180 } PFCPRESETID;
181 
183 typedef struct {
184  int x;
185  int y;
186 }
187 PFCPOINT;
188 
190 typedef struct {
191  int left;
192  int top;
193  int width;
194  int height;
195 }
196 PFCRECT;
197 
199 typedef struct {
203 }
205 
215 typedef struct PFCFaceRect{
222  int angle;
229  int yawAngle;
230  int FAE[3];
233  struct PFCFaceRect *pNext;
234 } PFCFACERECT;
235 typedef PFCFACERECT* LPPFCFACERECT;
236 
238 typedef struct {
241 } PFCENGINE;
242 
244 typedef struct {
245  int width;
246  int height;
247  int stride;
249  unsigned char *data;
250 } PFCIMAGE;
251 
253 typedef enum {
258 }
260 
262 typedef enum {
265 }
267 
269 typedef enum {
272 }
273 DCFMODE;
274 
276 typedef enum {
280 }
282 
284 typedef enum {
291 }
292 BIASMODE;
293 
295 typedef enum {
298 }
299 SKINMODE;
300 
302 typedef enum {
306 }
308 
310 typedef enum {
316 }
318 
320 typedef enum {
324 }
326 
328 typedef enum {
337 } PFCNR_STATUS;
338 
340 typedef enum {
350 
352 typedef enum {
364 } PFCFB_STATUS;
365 
367 typedef enum {
377 } PFCRE_STATUS;
378 
380 typedef enum {
394 
397 typedef enum {
402 
404 typedef struct {
405  BOOL bEnabled;
408  float fTintScale;
410  BOOL bVibrancy;
411  int iVibrancy;
412  int iStrength;
413  BOOL bContrast;
415  int iContrast;
417  float fBiasScale;
420  BOOL bSharpen;
423  BOOL bUseFAE;
426  BOOL bInfrared;
427  float fInfrared;
431  BOOL bDCF;
433  float fDCF;
436 } PFCCOREPARAM;
437 
439 typedef struct {
440  BOOL bEnabled;
441  BOOL bSmooth;
445  BOOL bEnlarge;
447  BOOL bEnhance;
449  BOOL bEyeCirc;
450  int iEyeCirc;
451  BOOL bTeeth;
453  BOOL bBlemish;
454  int iBlemish;
455  BOOL bSlim;
456  int iSlim;
457  BOOL bDeFlash;
458  int iDeFlash;
459  BOOL bCatchLight;
462  BOOL bSkinToning;
472  BOOL bLipSharpen;
475  BOOL bBlush;
476  int iBlush;
477 } PFCFBPARAM;
478 
480 typedef struct {
481  BOOL bEnabled;
482  int iPreset;
483  int iStrengthOffset;
492 } PFCNRPARAM;
493 
495 typedef struct {
496  BOOL bEnabled;
497 } PFCREPARAM;
498 
499 #define PFC3DLutGuidLength 32
500 typedef struct {
502  char guid[PFC3DLutGuidLength + 1];
503  unsigned char strength;
504 } PFC3DLutInfo;
505 
514 };
515 
517 typedef struct PFCCOREMask
518 {
519  PFCCORE_MASK_TYPE type;
520  float centerX;
521  float centerY;
522  float width;
523  float height;
524  float radius;
525  float feather;
526  float angle;
527  float transparency;
528  bool invert;
529  // if two layers (top and bottom) - swap params between layers instead.
530 } PFCCOREMask;
531 
533 typedef struct {
534  // Image Ambulance
537 
538  // built-in 3D luts
545  // custom output 3D Lut
547 
548  // Finishing
560 
561  int iDeltaR;
562  int iDeltaG;
563  int iDeltaB;
564 } PFCV3PARAM;
565 
567 typedef struct {
573 #ifndef PFCCOREONLY
574  PFCV3PARAM layer[3];
575  PFCCOREMask mask[3];
576 #endif
577 } PFCPARAM;
578 
580 typedef struct {
586 
591 
592  int Status;
601 #define PFCPROFILE PFCIMAGEPROFILE*
602 
604 #define PFCBGPROFILE PFCINTERNAL
605 
607 typedef struct {
608  int iRawMaskMode; // 7
609  int iBG; // 0..100
610  int iFG; // 0 .. 100
611  int iTolerance; // allow target I variation (similar to +- 8 logic)
612  int iSobel; // Sobel binarization threshold, 32
613  int iBlur;
614  bool bImfill; // remove black holes
615  bool bAreaopen; // do areaopen in black subject (remove white)
616  int iAreaopen; // size param in 1/10000 of w*h
617  bool bAreaopenBG; // do areaopen in white BG (rem small blacks)
618  int iAreaopenBG;
619  int iConnectivity; // 8 or 4
620  bool bGrad; // add grad filter
621  bool bGradAuto; // fixed based on detected face bottom,
622  int iGradBottom; // rel bottom
623  int iGradHeight; // rel spread
624  float avR; // calculated average BG RGB
625  float avG;
626  float avB;
627 }
629 
630 
634 
667 int PFC_SetProtectionPath(const char*utf8FolderPath, const char* liceseCode = NULL);
668 
677 
696 int PFC_ReadPresets(PFCPARAM &param, char *filename);
697 
724 int PFC_AutoCorrect(PFCIMAGE *pImage, PFCIMAGE *pImageds, PFCPARAM &param, int iISO=-1, char *pCameraModel=NULL, BOOL bFastFAE=FALSE, PFC_PROGRESS progfn=NULL);
725 
729 
730 
732 
736 
744 
771 PFCPROFILE PFC_Calc(PFCIMAGE *pImage, PFCIMAGE *pImageds, PFCENGINE* pEngine, unsigned int feature=CALC_ALL, int iISO=-1, char *pCameraModel=NULL, PFCPROFILE pImageProfile=NULL, PFC_PROGRESS progfn=NULL, int iRejectOption=PFC_REJECT_CLIPART);
772 
773 
802 PFCAPPLYSTATUS PFC_Apply(PFCIMAGE *pImage, PFCENGINE *pEngine, PFCPROFILE pImageProfile, PFCPARAM &param, PFC_PROGRESS progfn=NULL, int iOpacity=100, void* pBGProfile=NULL);
803 
810 void PFC_ReleaseProfile(PFCPROFILE pProfile);
811 
820 
824 
830 void PFC_SetAddonPath(const char *utf8AddonPath);
831 
834 void PFC_ReleaseAddonPath();
835 
842 bool PFC_HasFaceBeautification(PFCENGINE *pEngine);
843 
851 int PFC_FBFaceCount(PFCPROFILE pImageProfile);
852 
860 int PFC_FAEFaceCount(PFCIMAGEPROFILE *pImageProfile);
884 bool PFC_GetFaceInfo(PFCIMAGEPROFILE *pImageProfile, PFCFBFACEINFO *pFace, int index);
885 
904 
913 bool PFC_IsNoiseDetected(PFCIMAGEPROFILE *pImageProfile, int iNoisePreset);
914 
925 bool PFC_AbnormalTintDetected(PFCIMAGEPROFILE *pImageProfile, TINTCORRECTION eTintMethod);
926 
949 PFCAPPLYSTATUS PFC_ApplyLocal(PFCIMAGE *pImage, int xOffset, int yOffset, int widthOrig, int heightOrig, PFCENGINE *pEngine, PFCPROFILE pImageProfile, PFCPARAM &param, int iOpacity=100);
950 
965 int PFC_AutoCorrectPreset(PFCIMAGE *pImage, PFCIMAGE *pImageds, PFCPRESETID id=PRESET_IAUTO_2019, int iISO=-1, char *pCameraModel=NULL, BOOL bFastFAE=FALSE, PFC_PROGRESS progfn=NULL);
966 
967 
987 int PFC_ReadPresetsFromStream(PFCPARAM &param, const char *s);
988 
996 void PFC_SetSingleThreadedEngine(PFCENGINE* p, bool bSingleThreaded);
997 
1003 void PFC_GetVersion(char* buf, int *len, bool bFormatted = false);
1004 
1010 PFCAPPLYSTATUS PFC_Resize(PFCIMAGE *pImageSrc, PFCIMAGE *pImageDst);
1011 
1017 PFCAPPLYSTATUS PFC_TransposeExif(PFCIMAGE *pImageSrc, int iEXIFOrientation);
1018 
1025 void PFC_ApplyStrengthToParam(PFCPARAM &param, int strength);
1026 
1035 int PFC_WasmSetCertificate(PFCENGINE* pEngine, const char *clientAPIKey, const char *certificate);
1036 
1040 void PFC_TrackSave(const char *clientAPIKey);
1041 
1048 
1049 
1051 
1052 #ifdef EYEQINTERNAL
1053 #include "../Header-internal/PerfectlyClearPro-internal.h"
1054 #endif
1055 
1056 #ifdef __cplusplus
1057 }
1058 #endif
1059 #endif //__PERFECTLYCLEARPRO_H__
int iDeltaG
Delta G correction amount.
BIASMODE eBiasMode
Skin and depth bias control. Recommended value is BIAS_AVERAGE_PREFERENCE, unless you are printing to...
BOOL bContrast
Set to TRUE to also apply Athentech's patented Medical Imaging contrast technology.
int iTeethLevel
Teeth whitening level. Range 0 to 100.
float centerY
Y of center.
BOOL bEnabled
Set to true to enable the entire Core correction.
PFCPIXELFORMAT
defines the format of the image data
1.0 everywhere (background)
SKINTONINGTYPE eSkinToningType
See enum definition of SKINTONINGTYPE.
DCFMODE
Enumeration defining DCF analysis mode.
PFCFB_STATUS
Enumeration defining status of Face Beautification pre-calculation.
SKINMODE eSmoothMode
Use SKINMODE_FACE to apply correction ONLY on skin regions included in faces. Use SKINMODE_BODY to ap...
Adjust skin to user defined foundation color.
BOOL bUseAutomaticStrengthSelection
Set to TRUE (recommended default) to enable Automatic Strength Selection. Perfectly Clear will determ...
int PFC_FAEFaceCount(PFCIMAGEPROFILE *pImageProfile)
Return number of faces detected during Face Aware Exposure analysis.
void PFC_TrackSave(const char *clientAPIKey)
Report image save event from WASM SDK.
int iEnlargeLevel
Eye enlargement level. Range 0 to 100.
int iColorVibrancy
Color Vibrancy amount.
For normal photo.
Reject images classified as clipart, used by default.
int childLevel
We don't implement this.
bool bPreprocessEV
Enable EV correction (Image Ambulance)
Error reading image data.
Skip pre-calculations on Abnormal Tint Correction during Core pre-calculations.
int iEnhanceLevel
Eye enhancement level. Range 0 to 100.
Process aborted because of insufficient memory.
void PFC_ReleaseProtectionPath()
Releases resources from PFC_SetProtectionPath function call.
Invalid License or validation failed.
PFCCORE_STATUS
Enumeration defining status of Core pre-calculation.
int iFinishTemp
Temp correction amount.
LIPSHARPENTYPE eLipSharpenType
See definition of LIPSHARPENTYPE.
AGGRESSIVENESS
Enumeration defining Auto Exposure calculation modes.
PFCINTERNAL pPfcParam
Internal use only.
Full res image (pImage) is missing.
PFC3DLutInfo lutInputSky
LUT data to apply.
PFCFBPARAM fb
Face Beautification corrections.
Engine created successfully.
PFCCORE_MASK_TYPE
Enumeration describing mapping of PFCMask and PFC_MASK_TYPE with 'PFC' -> 'PFCCORE'.
BOOL bEyeCirc
Set to TRUE to enable eye circle removal.
float transparency
overall transparency applied to the whole mask (strength 100 means transparency 0.0, 0 -> 1.0)
Process cancelled.
This type of correction provides a more uniform appearance to the complexion. It combines the natural...
TINTCORRECTION
Enumeration defining different abnormal tint analysis mode.
PFCNRPARAM nr
Noise reduction corrections.
int iContrast
Intensity of contrast or depth. Range 0 to 100.
No correction occur during process.
float fBiasScale
Scalar value of how much BIAS correction should be applied. Range 0.0 to 1.0.
BOOL bEnabled
Set to TRUE to enable noise removal.
int iNeutralDensity
Neutral density filter amout.
Feature not enabled.
int widthImage
image width
PFCPOINT ptEyeR
Specifies the x,y coordinates of the right eye, in fixed-point arithmetics (10 bit precision)...
Structure encapsulating the CORE processing parameters.
void PFC_ReleaseProfile(PFCPROFILE pProfile)
Release PFCPROFILE instance.
PFCREPARAM re
Red Eye Removal.
BOOL bAbnormalTintRemoval
Set to true to enable Abnormal Tint Removal. Recommended default is FALSE.
int stride
Byte width of each scanline.
int PFC_ReadPresetsFromStream(PFCPARAM &param, const char *s)
Load image processing settings from a char buffer.
Pixel format not supported.
Feature not enabled.
PFC3DLutInfo lutOutput
LUT data to apply.
float width
radial/rounded: w of bounding rect, linear: ignored
PFCPOINT ptEyeL
Specifies the x,y coordinates of the left eye, in fixed-point arithmetics (10 bit precision)...
int left
x in point coordinate of this rect.
void PFC_GetRecommendedParam(PFCIMAGEPROFILE *profile, PFCCOREPARAM *dst, PFCCOREPARAM *src)
Get recommended values of auto params using result of precalc.
SKINMODE
Enumeration defining modes in Perfect Smooth analysis.
bool PFC_AbnormalTintDetected(PFCIMAGEPROFILE *pImageProfile, TINTCORRECTION eTintMethod)
Query if abnormal tint is detected.
rounded rect
Struct defining a rectangle.
Noise not found.
BOOL bLipSharpen
Set to TRUE to enable lip sharpening.
int iEyeCirc
Eye circle removal level. Range 0 to 100.
Warning. e.g. face not detected.
float height
radial/rounded: h of bounding rect, linear: dist from centerY where grad becomes 1.0
For average usage, corresponds to "Normal" in PfC Products.
BOOL bVibrancy
Set to true (recommended default) to enable Color Vibrancy in the library.
#define PFCPROFILE
Define.
This is a more aggressive and effective correction where the appearance of the entire skin (including...
int height
Pixel height of image.
PFCRECT rcMouth
Specifies the bounding rectangle of the mouth.
BOOL bDCF
Set to TRUE to enable Digital Color Fidelity. Recommended value is FALSE.
If set, the library is unable to locate SFB functions from the loaded library.
PFCRECT face
Bounding rectangle of detected face.
Same as iAuto 2019 but also with Red Eye Correction enabled.
int iSmoothLevel
Face smoothing level. Range 0 to 100.
PFCV3PARAM v3
V3 Corrections.
int iHighlightPreservation
Amount of Highlight Preservation to apply. Range 0 to 100.
Highest sensitivity level of tint detection.
Apply correction ONLY on skin regions included in faces.
PFCINTERNAL pEngine
Pointer to binary definition of the processing engine.
Beautify Plus provides stronger beautification corrections. This is in the 'Perfectly Clear Essential...
PFCPROFILE PFC_Calc(PFCIMAGE *pImage, PFCIMAGE *pImageds, PFCENGINE *pEngine, unsigned int feature=CALC_ALL, int iISO=-1, char *pCameraModel=NULL, PFCPROFILE pImageProfile=NULL, PFC_PROGRESS progfn=NULL, int iRejectOption=PFC_REJECT_CLIPART)
Perform initial analysis on images.
Struct defining an PFC engine instance.
int iDetailOffset
Offset to recommended level of preservation of details. Range -30 to 30.
Moderate level of tint detection.
bool PFC_IsNoiseDetected(PFCIMAGEPROFILE *pImageProfile, int iNoisePreset)
Query if noise is detected.
PFCPOINT leftEye
Point of left eye in detected face.
Full res image (pImage) is missing.
BOOL bEnabled
Set to TRUE to enable red eye removal.
Moderate level of exposure correction.
Feature not enabled.
int iFinishWhites
Whites correction amount.
PFC3DLutInfo lutInputCorrective
LUT data to apply.
Struct PFCPARAM the master structure of all processing parameters.
DCFMODE eDCFMode
Select different class of DCF.
Whitens (bleaches) face. Recommended mainly for darker skin.
int blinkLevelR
Right eye Blink level.
PFC3DLutInfo lutInputFoliageGreen
LUT data to apply.
int angle
Roll angle of the face, from -179 to 180 degrees. 0 degrees means the face it oriented "normally"...
General error.
Clipart type image.
Fine tuned for Asian skin tone.
int blinkLevel
Indicates the presence of a blink.
Operation cancelled by user.
int iFinishShadows
Shadows correction amount.
Unable to locate function in the SFBEngine library.
float fInfrared
Scale value to control intensity of infrared correction. Range 0.0 to 1.0.
BOOL bBlemish
Set to TRUE to enable blemish removal.
BOOL bHighlightPreservation
Set to true to enable Highlight Preservation.
Use Fast mode of Face Aware Exposure pre-calculations.
Calculates for all of the above.
float centerX
X of center.
PFCENGINESTATUS
ENUM for engine initialization status.
Process cancelled.
Structure encapsulating Face Beautification parameters.
Struct describing V3 parameters.
For more color vibrancy.
int width
Pixel width of image.
Apply correction on most skin regions regardless they are linked with a face or not.
int PFC_AutoCorrectPreset(PFCIMAGE *pImage, PFCIMAGE *pImageds, PFCPRESETID id=PRESET_IAUTO_2019, int iISO=-1, char *pCameraModel=NULL, BOOL bFastFAE=FALSE, PFC_PROGRESS progfn=NULL)
Single function to perform Perfectly Clear corrections.
int iFinishContrast
Contrast correction amount.
PFCCORE_STATUS CORE_Status
Status code for CORE pre-calc analysis.
void PFC_DestroyEngine(PFCENGINE *p)
Destroy PFCENGINE instance and release associated resources.
Struct defining an image to be used in PFC library.
Average usage with brighter tone, corresponds to "Bright" in PfC Products.
Optimized to bring out more details in the shadows, more details in the highlights, and more pleasing skin tones.
int PFC_FBFaceCount(PFCPROFILE pImageProfile)
Return number of faces detected.
int iFinishVibrancy
Vibrancy correction amount.
AGGRESSIVENESS eAggressiveness
The desired level of lighting for Automatic Strength Selection to target at the Exposure Correction...
Pointer pEngine is NULL.
The face analysis did not complete successfully.
SKINSMOOTHTYPE eSmoothType
See enum definition of SKINSMOOTHTYPE.
More aggressive in exposure correction.
CONTRASTMODE eContrastMode
Select contrast mode.
PFCINTERNAL pSFBParam
Internal use only.
PFCAPPLYSTATUS PFC_TransposeExif(PFCIMAGE *pImageSrc, int iEXIFOrientation)
Transpose image upright from/to EXIF Orientation.
PFCAPPLYSTATUS PFC_Apply(PFCIMAGE *pImage, PFCENGINE *pEngine, PFCPROFILE pImageProfile, PFCPARAM &param, PFC_PROGRESS progfn=NULL, int iOpacity=100, void *pBGProfile=NULL)
Correct image with parameters.
void PFC_GetVersion(char *buf, int *len, bool bFormatted=false)
Get info string with version and features.
BOOL bUseFAE
Set to TRUE (recommended) to enable Face Aware Exposure selection. Recommended exposure will be calcu...
int top
y in point corrdinate of this rect.
PFC3DLutInfo lutInputFoliageBrown
LUT data to apply.
Wrong domain for WASM certificate.
int blinkLevelL
Left eye Blink level.
PFCCOREPARAM core
Core corrections to apply.
int PFC_WasmSetCertificate(PFCENGINE *pEngine, const char *clientAPIKey, const char *certificate)
Pass certificate to authorize WASM SDK usage Certificate (2048 string) should match clientAPIKey and ...
int x
x coordinate of this point.
Image side dimension smaller than 32 pixels.
PFCAPPLYSTATUS PFC_Resize(PFCIMAGE *pImageSrc, PFCIMAGE *pImageDst)
Resizes the input image to the dimensions specificed in by the output image. The output image must be...
BOOL(* PFC_PROGRESS)(int iPercent)
PFCNR_STATUS
Enumeration defining status of Noise Removal pre-calculation.
Structure defining face attributes detected by the Face Detection library.
PFCENGINE * PFC_CreateEngine()
Create PFCENGINE instance.
Stronger sharpening. Details are more pronounced.
int iDeFlash
Deflash level. Range 0 to 100.
Priority on minimum false positive detection.
float fTintScale
Scalar value of how much tint correction should be applied. Range 0.0 to 1.0.
Struct defining an image profile as calculated from PFC_Calc() function.
PFCRECT rcEyeR
Specifies the bounding rectangle of the right eye.
PFCRECT rect
Specifies the bounding rectangle of a face.
Monolith source image.
Struct defining a point.
PFCFEATURE
ENUM controlling types of calculations at the pre-calculation stage.
Feature not enabled.
Wrong APIKEY for WASM certificate.
int height
height of this rect.
Structure encapsulating Red Eye Correction parameters.
int iBlackEnhancement
Set luminance threshold for Noise Management. Range 0 to 25.
BOOL bDynamicRange
Set to TRUE to enable dynamic range correction.
Intelligent Auto - this has been superceded by iAuto 2019 and is here for backwards compatability...
int width
width of this rect.
BOOL bBlush
Set to TRUE to add blush.
PFCAPPLYSTATUS PFC_ApplyLocal(PFCIMAGE *pImage, int xOffset, int yOffset, int widthOrig, int heightOrig, PFCENGINE *pEngine, PFCPROFILE pImageProfile, PFCPARAM &param, int iOpacity=100)
Apply correction locally.
int yawAngle
The Yaw or profile angle, from -90 (left profile) to 90 (right profile)
Vivid - good for landscapes and other general photography. This is in the 'Perfectly Clear Essentials...
Pointer pImage is NULL.
int FAE[3]
Internal data for Face Aware Exposure.
float radius
only for MASK_ROUNDRECT - corner radius, relative to image w.
Darkens skin, makes it look naturally tanned.
iAuto Details - legacy preset for backwards compability. This is in the 'Athentech Legacy' group in E...
0.0 everywhere, don't apply
PFCPOINT rightEye
Point of right eye in detected face.
int iStrength
Set the strength of exposure correction. If Automatic Strength Selection is enabled, the recommended value is put in this variable upon function return. Range 0 to 150.
Warms skin tone.
Error in settings.
int confidence
A numerical parameter describing the confidence attributed by the detection algorithm to each face...
BOOL bInfrared
Set to TRUE (recommended default) to enable infrared correction. It's a good idea to turn Infrared Co...
Less aggressive in exposure correction.
Disable image rejection.
void PFC_SetSingleThreadedEngine(PFCENGINE *p, bool bSingleThreaded)
Force processing to be single threaded.
linear from 1.0 on top
Struct defining parameters for building BG mask.
unsigned char * data
Pointer pointing to the first byte of image data buffer.
int iCatchLight
Catchlight level. Range 0 to 100.
wrong format version of WASM certificate
Process cancelled.
Makes skin look lighter and more pale.
BOOL bEnabled
Set to TRUE to enable entire face beautification.
PFCINTERNAL pInternal
Internal use only.
BOOL bEnlarge
Set to TRUE to enable eye enlargement.
Process cancelled.
Pointer pProfile is NULL.
SKINMODE eSkinToningMode
Use SKINMODE_FACE to apply correction ONLY on skin regions included in faces. Use SKINMODE_BODY to ap...
Structure encapsulating Noise Removal parameters.
PFCFB_STATUS FB_Status
Status code for Face Beautification pre-calc analysis.
bool PFC_GetFaceInfo(PFCIMAGEPROFILE *pImageProfile, PFCFBFACEINFO *pFace, int index)
Utility function to query geometry of detected faces.
void PFC_ApplyStrengthToParam(PFCPARAM &param, int strength)
Apply overall strength to parameters, same as Strength in Perfecly Clear products Reads the correctio...
PFCRE_STATUS
Enumeration defining status of Red Eye pre-calculation.
int iPreprocessEV
EV correction amount (Image Ambulace)
Unable to create SFB Engine object for processing.
Calculates for Perfectly Clear Core correction.
int smileLevel
Indicates the presence of a smile.
Red eye not found.
PFCINTERNAL pNoiseParam
Internal use only.
PFCREJECTOPTION
Enumeration defining rejection flags.
struct PFCCOREMask PFCCOREMask
Struct describing mask for grad filter, all coordinates are relative (Y/height, X/width) in final cro...
BOOL bSharpen
Set to TRUE to enable sharpening.
WASM certificate invalid or not matching APIKEY and domain.
BOOL bLightDiffusion
Set to TRUE to enable light diffusion during DCF correction.
int iDeltaR
Delta R correction amount.
PFCPIXELFORMAT format
Defines byte order of input buffer.
int PFC_ReadPresets(PFCPARAM &param, char *filename)
Load image processing settings from a .preset file. Use this function to load image processing settin...
int heightImage
image height
void PFC_SetAddonPath(const char *utf8AddonPath)
Set path to directory containing runtime add-ons such as .looks file(s) This enables searching for ad...
float feather
relative length of gradient, from where it starts (1.0) to where it is 0.0,
Calculates for Perfectly Clear Noise Removal.
PFCRECT rcEyeL
Specifies the bounding rectangle of the left eye.
#define PFCINTERNAL
Internal used pointer type.
Apply auto calculated bias mode and strength.
bool PFC_HasFaceBeautification(PFCENGINE *pEngine)
Check if Face Beautification is available.
BOOL bCatchLight
Set to TRUE to enable catchlight removal.
Beautify - provides a good default set of corrections for portratis and other photos of people...
Struct describing mask for grad filter, all coordinates are relative (Y/height, X/width) in final cro...
Reserved, never use.
BOOL bLocalContrast
Set to true to enable Local Contrast.
PFCAPPLYSTATUS
Enumeration defining return code from the Apply() function.
struct PFCFaceRect PFCFACERECT
Structure defining face attributes detected by the Face Detection library.
bool invert
invert mask (x = 1.0 - x). NOTE: UI meaning of invert is: if one mask layer set invert = true ...
PFCPRESETID
ENUM for presets support by this SDK.
Structure defining face area detected from the SFB library.
PFCNR_STATUS NR_Status
Status code for Noise Removal pre-calc analysis.
BIASMODE
Enumeration defining BIAS analysis mode.
Skip Face Aware Exposure pre-calculations during Core pre-calculations.
The subtle correction removes the wrinkles and spots alone while it keeps the texture of the face unc...
WASM certificate has expired.
BOOL bTeeth
Set to TRUE to enable teeth whitening.
int iFinishHighlights
Highlights correction amount.
int iFinishExposure
Exposure correction amount.
Face beautification feature not available.
int iSkinToning
Skin Toning level. Range 0 to 100.
void PFC_ReleaseAddonPath()
Releases resources from PFC_SetAddonPath function call.
Full res image (pImage) is missing.
float fDCF
Scale value to control intensity of Digital Color Fidelity correction. Range 0.0 to 1...
SKINSMOOTHTYPE
Enumeration defining types of Skin Smoothing correction.
BOOL bEnhance
Set to TRUE to enable eye enhancement.
int iLocalContrast
Amount of Local Contrast to apply. Range 0 to 100.
Full res source image (pImage) is missing.
Calculates for Red Eye Removal.
int iFinishPositiveContrast
Positive Contrast correction amount.
int iMaxStrength
Use this value to limit the maximum Exposure to be applied on the Automatic Exposure Strength Selecti...
Fine touch of sharpening.
void PFC_SetParam(PFCPARAM &param, PFCPRESETID id=PRESET_IAUTO_2019)
Initialize a PFCPARAM structure.
CONTRASTMODE
Enumeration defining contrast mode.
Reject simple images that don't benefit from correction, like solid colors. This was the default befo...
Insufficient memory.
Turn off bias correction.
int iDeltaB
Delta B correction amount.
int iFinishSaturation
Saturation correction amount.
int PFC_SetProtectionPath(const char *utf8FolderPath, const char *liceseCode=NULL)
Set path to location of SDK License files This enables license protection and allows activation using...
Lip details are coarsely pronounced.
int iLipSharpen
Lip sharpening level. Range 0 to 100.
int iBlemish
Blemish removal level. Range 0 to 100.
int iBlush
Blush level. Range 0 to 100.
LIPSHARPENTYPE
Enumeration defining Lip Sharpening mode.
float fLightDiffusion
Scale value to control intensity of light diffusion correction.
int y
y coordinate of this point.
int iVibrancy
Degree of color vibrancy. This value will only be use when bVibrancy is TRUE. Very large values can p...
Optimized to bring higher contrast to the image.
int iFinishTint
Tint correction amount.
New iAuto for even better image corrections - this is the default Preset and a great starting point f...
BOOL bSlim
Set to TRUE to enable face slimming.
SKINTONINGTYPE
Enumeration defining type of Skin Toning correction.
PFCRE_STATUS RE_Status
Status code for Red Eye pre-calc analysis.
PFCENGINESTATUS status
Status of engine defined in PFCENGINESTATUS. For NO-SFB version the status will always be ENGINESTATU...
float fSharpenScale
Sharpening intensity. This value controls how much sharpening to be applied. Range 0...
TINTCORRECTION eTintMode
ENUM value defined in TINTCORRECTION. It sets the aggressiveness of Tint Removal. ...
BOOL bSmooth
Set to TRUE to enable face smoothing.
PFCINTERNAL pRedEyeParam
Internal use only.
int PFC_AutoCorrect(PFCIMAGE *pImage, PFCIMAGE *pImageds, PFCPARAM &param, int iISO=-1, char *pCameraModel=NULL, BOOL bFastFAE=FALSE, PFC_PROGRESS progfn=NULL)
Single function to perform Perfectly Clear correction.
linear from 1.0 on bottom
Aggressive detection of tint.
int iFinishBlacks
Blacks correction amount.
If set, the library is unable to load the SFB library.
BOOL bDeFlash
Set to TRUE to enable deflash.
Calculates for Face Beautification.
LPPFCFACERECT PFC_EnumFAEFaceRect(PFCIMAGEPROFILE *pImageProfile, LPPFCFACERECT p)
Utility function to enumerate faces detected during Face Aware Exposure analysis. ...
int iSlim
Face slimming level. Range 0 to 100.