nvjpeg
copied
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Readme
Files and versions
26 lines
483 B
26 lines
483 B
#pragma once
|
|
|
|
#include <pybind11/pybind11.h>
|
|
#include <pybind11/stl.h>
|
|
#include "nvjpeg_decoder.h"
|
|
|
|
namespace py = pybind11;
|
|
|
|
namespace NVJpegDecoder {
|
|
|
|
class PythonDecoder {
|
|
public:
|
|
PythonDecoder() = default;
|
|
|
|
PythonDecoder(PythonDecoder&) = delete;
|
|
PythonDecoder& operator=(PythonDecoder&) = delete;
|
|
|
|
bool BindDevice(int device_id=0);
|
|
py::object Read(std::string&);
|
|
py::object Decode(std::string&);
|
|
|
|
private:
|
|
Decoder mDecoder;
|
|
};
|
|
|
|
} // namespace NVJpegDecoder
|