FaceGen SDK Manual - Source Code
Porting
- Language
- Standard C++17
- All FaceGen libraries compile cleanly with -Wall / W4.
- Exceptions
- The source code uses exceptions. Exceptions must be enabled.
- RTTI
- The source code uses RTTI. RTTI must be enabled.
- Endianness
- This SDK is only tested on little-endian architectures. Contact us if you require a big-endian compilation target.
- Defines
- No special defines are required. Only default defines from each supported compiler are used.
- Linking
- The visual studio solutions specify static CRT linkage. The *nix makefiles use dynamic.
Open Source Used
MIT License. Used for a wide variety of generic and 3D tasks
Parts of the Eigen 3.3.9 linear algebra library are included in unmodified form.
Only files covered by the MPL2 license are used, and this is enforced using #define EIGEN_MPL2_ONLY
License: ~sdk/source/LibTpEigen/COPYING.MPL2
MIT License. Used for reading and writing images to PNG, JPG, BMP and TGA file formats.
No copyright. Used for cross-platform deterministic hashing.
Boost Sofware License 1.0
Version History
Reverse chronological order, most recent patch number only:
- 3.V.1 Released 2023.06
- Unreal Metahuman DNA export supported
- Daz Genesis 9 export supported
- 'fg3 cssm / cscm' now 'fg3 apply ssm / scm'
- 3.V.0 Released 2023.04
- automatic landmark detection for frontal photos
- added 'dlib' FOSS libary
- 3.U.0 Released 2023.03
- switch to C++17
- Remove BOOST libraries
- 3.T.4 Released 2022.09
- add Sam3NLControls::randomHispanic()
- update Android build
- update iOS build
- update to boost 1.69
- remove IJG libjpeg library and use STB library instead
- 3.S.3 Released 2022.02
- 'fgbl render' add roll/tilt/pan command-line options
- 'fgbl mesh inject' add deltas (-d) option
- 'fgbl render run' fix -matrix output to include roll/tilt/pan values
- 'fg3 cscm' faster, all steps are multithreaded with option flag
- 'fg3 controls demographic edit' supports just shape or just color values
- 'fgbl mesh convert' modified to handle multi-mesh formats
- 'fgbl render' command split into setup/run/batch (latter with multithreading)
- 'fgbl render' bug fixed that sometimes caused hair render glitches
- 'fg3t scm' bug fixed that sometimes caused random colors
- Minor improvements and fixes
- Add 'fg3t ssmEyeC / ssmEyeI' commands for spherical eye SSM creation
- Split 'fg3 construct' into 'fg3 apply ssm' and 'fg3 cscm'
- Improve documentation
- Minor improvements and fixes
- 3.R.0 Released 2021.03
- Spherical eye option in 'fg3t nrr / ssm'
- Add 'fg3t scan'
- Collada DAE export support
- GPU speedup of detail texture modulation
- Switch to C++14
- Add Daz Genesis 8.1 support
- Minor improvements and fixes
- 3.Q.1 Released 2020.01
- Put codebase into 'Fg' namespace, rename most global types and functions
- Speed up loading from EGM files
- Switch GUI renderer to Direct3D 11.1 (Windows only) for improved hair, specular highlights.
- Explicit Visual Studio 19 support
- Many breaking changes due to renames
- 3.P.0 Released 2019.03
- Support iOS
- Replace Imagemagick with stb
- Replace JAMA with Eigen
- Refactorings including breaking changes
- 3.N.1 Released 2018.11
- Fix and improve 'Quick Start' section of manual
- Add 'fg3 morph anim' for simpler morph application
- 'fg3 render' add save/load camera and pose state
- 'fg3t nrr' add fixed seam option
- Migrate boost:: thread/function/bind/etc. to std::
- Various fixes and refactorings
- Support CMake, Android
- Refactor 'fg3 controls' command, add slider value exports
- Add file cache option to 'fg3t ssm' for faster integration of model set parts added later.
- 3.M.1 Released 2018.04
- Supports Artist 2.1 functions; Genesis 8, custom base maps
- Update to boost 1.66 for Visual Studio 2017 support
- Remove support for Visual Studio 2012 to better support C++11
- Various fixes and refactorings
- 3.L.7 Released 2017.08
- Add support for C++11, Visual Studio 2015/2017
- Add support for clang and intel compilers on Linux
- Remove support for Visual Studio 2008, 2010
- Update to boost 1.63
- Various fixes and refactorings
- 3.K.1 Released 2016.12
- Improved FBX export
- Full set of FACS morphs added to 'Animate' mesh
- 'fg3t scm' now supports custom base texture integration
- Daz export includes Genesis 3 and body textures
- Default gamma value changed to 2.2
- Minor fixes, refactorings, renamings.
- 3.J.1 Released 2016.05
- Added 'fgppValidatePoints' for user point layout validation.
- Unicode support for command-line example programs.
- Improvements to integration tools
- Minor fixes and refactorings.
- 3.I.1 Released 2015.12
- Export support for FBX, 3DS, PLY, LWO, MA, XSI
- Updated model sets and parts
- Export support for Daz Studio Genesis 1 and 2 meshes
- Improve Daz export eye shape
- Various refactorings and fixes including photofit and mesh construction
- Improvements to sample programs GUI (Windows only)
- 3.H.2 Released 2015.10
- 'fg3t nrr' added for non-rigid registration of custom meshes to FaceGen internal mesh.
- 'fg3t scm' saves results to PNG to avoid BMP issues.
- 'fg3 coord' added XML export/import.
- Generic functionality consolidated into 'FgLibBase' and made open-source.
- Update to Boost 1.58
- Add support for Visual Studio 2013.
- Refactorings, small fixes and feature additions.
- 3.G.2 Released 2015.04
- 'fg3t scm' added to create SCMs from the command-line.
- 'fg3 render' now supports relative scale, translation, and field of view parameters.
- Photofit API simplified, and now returns projective transform from fit mesh to image
- Refactorings, small fixes and feature additions
- 3.F.1 Released 2015.01
- STL file format export
- Multi-mesh FBX export
- GUI example code for face controls (windows only)
- Add simpler age and gender controls
- Refactorings, small fixes and feature additions
- 3.E.3 Released 2014.05
- Add csamDefault33 model set with unified geometry and UVs, reduced eyelid lines and reduced shape change to back of head.
- Improve 'fg3t ssm' to ensure seam vertices remain precisely unchanged to float precision.
- 'fg3t morphx' will not create duplicate morphs.
- OS/X makefiles updated for xcode 5
- Fix 'fg3 mesh seams'.
- Add gamma correction option to 'fg3 construct'.
- 'fg3 mesh merge' now preserves morphs.
- 'fg3 morph copy' can move morphs between like meshes.
- 'fg3 construct' now preserves the image file format.
- Support for converting a mesh to FBX format.
- Improve handling of opacity in interactive renderer.
- Add 'fg3 image addalpha'.
- Photofit now supports a 'userPointsOnly' option for profile image fitting.
- 'fg3 mesh xform' improved, can now generate transforms from meshes.
- Add 'fg3 view fg' command.
- Fix 'fg3 mesh merge' command.
- 'fg3 triexport' simplified and now defaults to .PNG format.
- 'fg3 render' now defaults to .PNG format.
- Other minor improvements and refactorings.
- 3.D.0 Released 2013.11
- Add new 'random' command to batch-generate random face images.
- Add new 'coord' command demonstrating access to face coordate values in .FG file.
- Add interactive surface point marking (Windows only) and surface point projection into rendered images.
- Refactor all example commands to take 'FgArgs' struct instead of legacy C 'int argc,char *argv[]'.
- Add vertex normals to '.OBJ' export.
- Bug fixes to test directories, soft render uv clamping, morphx command line parsing.
- 3.C.1 Released 2013.09
- Add 'fg3t' tools for SSM creation, morph transfer and rebasing.
- Example commands read Wavefront .OBJ files.
- Improved mesh viewing GUI example.
- Various fixes and refactorings.
- 3.B.3 Released 2013.06
- 'fg3 controls' now lists control names.
- Software rendering handles transparency.
- Update to Boost 1.52
- 'fg3 controls reflect' command added.
- 'fg3 detail' command added.
- Viewing of images in example GUI.
- Polygon depth sorting for better transparency rendering in example renderer.
- Various fixes, refactorings and speed improvements.
- 3.A.4 Released 2012.06
- Make SDK easier to use by changing API and 'fg3' utility program.
- Get rid of rare exception thrown in photofit.
- Improve profile detail masking to avoid detail texture artifacts.
- Fix endiantoggle for FG files without detail texture.
- 3.9.2 Released 2011.03
- Fix 'construct' to allow for shape-only or texture-only application.
- Change user bootstrap point files to XML format from binary .bpt.
- Add MTL support to 'triexport' of OBJ for easier texture loading.
- 3.8.2 Released 2010.11
- Photofit uses significantly less memory.
- Lighing issue with 'fg3win render' fixed.
- Add -1 option for fgppSetSpeedup() for very slow highest precision photofit.
- Memory access error fixed when face in photo is too close to edge.
- VRML export works properly with filenames containing spaces.
- Triexport command options now support full similarity transform.
- 3.7.2 Released 2010.08
- Render and Substitute commands added
- Photofit API now gives number of milestones.
- Rare photofit bug fixed.
- More regression tests added.
- Triexport command replaces meshimport/meshexport
- Rename Overlay command to Composite
- Rename Viewer command to View
- 3.6.0 Released 2009.08
- Parallelize, speedup and improve photofit
- Port photofit and some of the example applications to Linux
- Add command-line Customizer utility (CustomizerCL.exe)
- Rename 'coding' to 'construct'.
- Various small bug fixes.
- 3.5.0 Released 2009.04
- Improvements and minor fixes in testing framework.
- Add 'addAnimateMorph' utility.
- Fix off-by-1 bug in detail texture mirroring.
- Fix minor bugs in fg3 generate.
- Photofit added ignoring green pixels capability.
- Photofit now returns an error if it runs out of memory (with very large source photos).
- Photofit now runs a bit faster (exact amount is platform dependent).
- 3.4.1 Released 2008.10.03
- Photofit bug fix for source images smaller than 256 pixels.
- Interactive deformation math improved to properly account for different mesh scalings.
- Maximum detail texture source reduced to 2048 from 4096 to avoid allocation errors
- Fix occluding boundary artifacts if face is partly obscured by green mask or off-image.
- Add gender-specific all-races distributions to reduce female beard issue
- Add fixed FG file input option to 'generate' functionality.
- 3.3.0 Released 2008.04.15
- Various small bug fixes and portability fixes
- Improve projectImageToFg and projectGeomToFg
- Allow for detail textures up to 4K
- FgGenerate: Allow loading TGA images with alpha channels in addition to JPG and BMP for all textures and overlays
- Photofit: Improve dark skin results and force resulting colours closer to original photo