Skip to content

How to get temperature value #96

Description

@HedgeHao

I have a FLIR purethermal 3 module. I can get the video frame using OpenCV VideoCap in c++. How can I convert this OpenCV Mat data to actual temperature value?

#include <iostream>
#include <opencv2/core/core.hpp>
#include <opencv2/videoio/videoio.hpp>
#include <opencv2/highgui/highgui.hpp>

using namespace std;
using namespace cv;

int main()
{
    VideoCapture cap(0);
    if (!cap.isOpened())
    {
        cout << "Cannot open camera\n";
        return 1;
    }

    Mat frame;
    while (true)
    {
        bool ret = cap.read(frame);
        if (!ret)
        {
            cout << "Can't receive frame (stream end?). Exiting ...\n";
            break;
        }

        imshow("live", frame);
        if (waitKey(1) == 'q')
        {
            break;
        }
    }
    return 0;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions