Files
Vincent Rabaud 1cdb76c8e3 Include opencv2/videoio.hpp
In my configuration with bazel, when building the Java bindings,
it is not like building C++ and including videio/videoio.hpp
triggers:
error this is a compatibility header which should not be used inside the OpenCV library
2025-07-03 13:14:48 +02:00

26 lines
599 B
C++

#ifndef VIDEOIO_CONVERTERS_HPP
#define VIDEOIO_CONVERTERS_HPP
#include <jni.h>
#include "opencv_java.hpp"
#include "opencv2/core.hpp"
#include "opencv2/videoio.hpp"
class JavaStreamReader : public cv::IStreamReader
{
public:
JavaStreamReader(JNIEnv* env, jobject obj);
~JavaStreamReader();
long long read(char* buffer, long long size) CV_OVERRIDE;
long long seek(long long offset, int way) CV_OVERRIDE;
private:
JavaVM* vm;
jobject obj;
jmethodID m_read, m_seek;
};
jobject vector_VideoCaptureAPIs_to_List(JNIEnv* env, std::vector<cv::VideoCaptureAPIs>& vs);
#endif