Skip to main content
On Linux, the Facebetter SDK is accessed through the same C++ interface as Windows. This guide follows the C++ Desktop Demo as a reference.

Include Headers

Integration Overview


1. Configure Logging (optional)

Call this before creating the engine.
Log levels (ascending): Trace / Debug / Info / Warn / Error / Critical.

2. Create the Engine

At runtime, make sure libfacebetter.so is findable: place it next to the executable or point LD_LIBRARY_PATH to its directory.

3. Enable Beauty Types

All beauty types are disabled by default and must be explicitly enabled:

4. Set Beauty Parameters

All parameter values are in [0.0, 1.0]. A value of 0 disables the effect.

Basic Beauty

Skin-Only Beauty

Use SetSkinOnlyBeauty to set whether beauty effects are applied only to skin regions. When enabled, beauty effects (smoothing, whitening, etc.) will only be applied to detected skin areas, leaving non-skin areas unchanged.
After enabling skin-only beauty, even with high beauty parameter values, non-skin areas (such as background, clothing, etc.) will not be affected.

Face Reshape

Makeup

Stickers

Filters (LUT)


5. Process Frames

Load from file (single-image mode):
Convert output format if needed:

6. OpenGL Integration (render preview)


7. Full Example (real-time processing loop)


Quick Reference

The parameter enums and ImageFrame factory methods are identical to the Windows platform. See Windows – Implement Beauty for the full table.