eos 1.4.0
|
Defines which 2D landmarks comprise the right and left face contour. More...
#include <contour_correspondence.hpp>
Static Public Member Functions | |
static ContourLandmarks | load (std::string filename) |
Public Attributes | |
std::vector< std::string > | right_contour |
std::vector< std::string > | left_contour |
Defines which 2D landmarks comprise the right and left face contour.
This class holds 2D image contour landmark information. More specifically, it defines which 2D landmark IDs correspond to the right contour and which to the left. These definitions are loaded from a file, for example from the "contour_landmarks" part of share/ibug_to_sfm.txt.
Todo: We should improve error handling here. When there's no contour_landmarks in the file, it will crash, but it would be nice if it still worked, the returned vectors should just be empty.
Note: Better names could be ContourDefinition or ImageContourLandmarks, to disambiguate 3D and 2D landmarks? Todo: I think this should go into the LandmarkMapper. Isn't it part of ibug_to_sfm.txt already?
|
inlinestatic |
Helper method to load contour landmarks from a text file with landmark mappings, like ibug_to_sfm.txt.
[in] | filename | Filename to a landmark-mapping file. |
std::runtime_error | runtime_error or toml::exception if there is an error loading the landmarks from the file. |