diff --git a/lib/local/Utilities/include/ImageManipulationHelpers.h b/lib/local/Utilities/include/ImageManipulationHelpers.h index 6b2be4c..23a4cb0 100644 --- a/lib/local/Utilities/include/ImageManipulationHelpers.h +++ b/lib/local/Utilities/include/ImageManipulationHelpers.h @@ -43,39 +43,6 @@ namespace Utilities // Converting between color spaces and bit depths //=========================================================================== - // Perform the conversion inplace - static void ConvertToRGB_8bit(cv::Mat& in_out) - { - if (in_out.channels() == 3 && in_out.depth() == CV_16U) - { - in_out = in_out / 256; - } - else if (in_out.channels() == 4) - { - if (in_out.depth() == CV_16U) - { - in_out = in_out / 256; - cv::cvtColor(in_out, in_out, CV_BGRA2BGR); - } - else - { - cv::cvtColor(in_out, in_out, CV_BGRA2BGR); - } - } - else if (in_out.channels() == 1) - { - if (in_out.depth() == CV_16U) - { - in_out = in_out / 256; - cv::cvtColor(in_out, in_out, CV_GRAY2BGR); - } - else - { - cv::cvtColor(in_out, in_out, CV_GRAY2BGR); - } - } - } - static void ConvertToGrayscale_8bit(const cv::Mat& in, cv::Mat& out) { if (in.channels() == 3) diff --git a/lib/local/Utilities/src/ImageCapture.cpp b/lib/local/Utilities/src/ImageCapture.cpp index d9074c6..0ec7154 100644 --- a/lib/local/Utilities/src/ImageCapture.cpp +++ b/lib/local/Utilities/src/ImageCapture.cpp @@ -364,9 +364,6 @@ cv::Mat ImageCapture::GetNextImage() exit(1); } - // Convert the latest frame to 3 channel 8 bit format if it is not in it already - //ConvertToRGB_8bit(latest_frame); TODO check - image_height = latest_frame.size().height; image_width = latest_frame.size().width; diff --git a/lib/local/Utilities/src/RecorderOpenFace.cpp b/lib/local/Utilities/src/RecorderOpenFace.cpp index ee9c221..9356d83 100644 --- a/lib/local/Utilities/src/RecorderOpenFace.cpp +++ b/lib/local/Utilities/src/RecorderOpenFace.cpp @@ -187,7 +187,7 @@ RecorderOpenFace::RecorderOpenFace(const std::string in_filename, RecorderOpenFa } else { - this->media_filename = path(filename).concat(".bmp").string(); // TODO change back to jpg + this->media_filename = path(filename).concat(".jpg").string(); metadata_file << "Output image:" << this->media_filename << endl; this->media_filename = (path(record_root) / this->media_filename).string(); }