mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-01 19:42:07 +08:00
4b15f8a12d
* Refactor image texture stuff into class * cleanup * Update selfdrive/common/visionimg.cc Co-authored-by: Willem Melching <willem.melching@gmail.com> old-commit-hash: b3107e153cca4aa98b623b80fdd13b8446f76d1c
28 lines
432 B
C++
28 lines
432 B
C++
#pragma once
|
|
|
|
#include "visionbuf.h"
|
|
|
|
#ifdef __APPLE__
|
|
#include <OpenGL/gl3.h>
|
|
#else
|
|
#include <GLES3/gl3.h>
|
|
#endif
|
|
|
|
#ifdef QCOM
|
|
#include <EGL/egl.h>
|
|
#define EGL_EGLEXT_PROTOTYPES
|
|
#include <EGL/eglext.h>
|
|
#undef Status
|
|
#endif
|
|
|
|
class EGLImageTexture {
|
|
public:
|
|
EGLImageTexture(const VisionBuf *buf);
|
|
~EGLImageTexture();
|
|
GLuint frame_tex = 0;
|
|
#ifdef QCOM
|
|
void *private_handle = nullptr;
|
|
EGLImageKHR img_khr = 0;
|
|
#endif
|
|
};
|