Starting integration of AU visualization in CLI code.

This commit is contained in:
Tadas Baltrusaitis 2018-03-24 10:30:30 +00:00
parent 659f066fa4
commit 5ed6c4a6f3
5 changed files with 9 additions and 7 deletions

View file

@ -108,7 +108,7 @@ int main (int argc, char **argv)
Utilities::SequenceCapture sequence_reader; Utilities::SequenceCapture sequence_reader;
// A utility for visualizing the results (show just the tracks) // A utility for visualizing the results (show just the tracks)
Utilities::Visualizer visualizer(true, false, false); Utilities::Visualizer visualizer(true, false, false, false);
// Tracking FPS for visualization // Tracking FPS for visualization
Utilities::FpsTracker fps_tracker; Utilities::FpsTracker fps_tracker;

View file

@ -185,7 +185,7 @@ namespace OpenFaceOffline
face_model_params.optimiseForVideo(); face_model_params.optimiseForVideo();
// Setup the visualization // Setup the visualization
Visualizer visualizer_of = new Visualizer(ShowTrackedVideo || RecordTracked, ShowAppearance, ShowAppearance); Visualizer visualizer_of = new Visualizer(ShowTrackedVideo || RecordTracked, ShowAppearance, ShowAppearance, false);
// Initialize the face analyser // Initialize the face analyser
face_analyser = new FaceAnalyserManaged(AppDomain.CurrentDomain.BaseDirectory, DynamicAUModels, image_output_size, MaskAligned); face_analyser = new FaceAnalyserManaged(AppDomain.CurrentDomain.BaseDirectory, DynamicAUModels, image_output_size, MaskAligned);
@ -273,7 +273,7 @@ namespace OpenFaceOffline
face_model_params.optimiseForImages(); face_model_params.optimiseForImages();
// Setup the visualization // Setup the visualization
Visualizer visualizer_of = new Visualizer(ShowTrackedVideo || RecordTracked, ShowAppearance, ShowAppearance); Visualizer visualizer_of = new Visualizer(ShowTrackedVideo || RecordTracked, ShowAppearance, ShowAppearance, false);
// Initialize the face detector if it has not been initialized yet // Initialize the face detector if it has not been initialized yet
if (face_detector == null) if (face_detector == null)

View file

@ -54,9 +54,9 @@ namespace UtilitiesOF {
public: public:
Visualizer(bool vis_track, bool vis_hog, bool vis_aligned) Visualizer(bool vis_track, bool vis_hog, bool vis_aligned, bool vis_aus)
{ {
m_visualizer = new Utilities::Visualizer(vis_track, vis_hog, vis_aligned); m_visualizer = new Utilities::Visualizer(vis_track, vis_hog, vis_aligned, vis_aus);
} }
void SetObservationGaze(System::Tuple<double, double, double>^ gaze_direction0, System::Tuple<double, double, double>^ gaze_direction1, void SetObservationGaze(System::Tuple<double, double, double>^ gaze_direction0, System::Tuple<double, double, double>^ gaze_direction1,

View file

@ -54,7 +54,7 @@ namespace Utilities
// The constructor for the visualizer that specifies what to visualize // The constructor for the visualizer that specifies what to visualize
Visualizer(std::vector<std::string> arguments); Visualizer(std::vector<std::string> arguments);
Visualizer(bool vis_track, bool vis_hog, bool vis_align); Visualizer(bool vis_track, bool vis_hog, bool vis_align, bool vis_aus);
// Adding observations to the visualizer // Adding observations to the visualizer

View file

@ -86,6 +86,7 @@ Visualizer::Visualizer(std::vector<std::string> arguments)
vis_track = true; vis_track = true;
vis_align = true; vis_align = true;
vis_hog = true; vis_hog = true;
vis_aus = true;
} }
else if (arguments[i].compare("-vis-align") == 0) else if (arguments[i].compare("-vis-align") == 0)
{ {
@ -107,11 +108,12 @@ Visualizer::Visualizer(std::vector<std::string> arguments)
} }
Visualizer::Visualizer(bool vis_track, bool vis_hog, bool vis_align) Visualizer::Visualizer(bool vis_track, bool vis_hog, bool vis_align, bool vis_aus)
{ {
this->vis_track = vis_track; this->vis_track = vis_track;
this->vis_hog = vis_hog; this->vis_hog = vis_hog;
this->vis_align = vis_align; this->vis_align = vis_align;
this->vis_aus = vis_aus;
} }