I'm trying to get a camera image from the tango api by calling "TangoService_connectTextureId".
The problem is, there is no "GL_TEXTURE_EXTERNAL_OES" defined, so I'm not able to create an external texture object. All the samples use ES 2 only but having this limitation is just stupid on such a device.
maybe it's my fault, so here is my setup:
- Visual Studio 2013 with Nsight Tegra extension.
Includes:
#include <GLES3/gl3.h> #include <GLES3/gl3ext.h> #include <GLES3/gl3platform.h> #include <EGL/egl.h> #include <EGL/eglext.h>
I'm linking against:
tango_client_api GLESv3 EGL
The texture to pass TangoService_connectTextureId to should be created like this (while using GL_TEXTURE_2D does not work because the image stays black):
glGenTextures(1, &texture_id_); glBindTexture(GL_TEXTURE_EXTERNAL_OES, texture_id_); glTexParameteri(GL_TEXTURE_EXTERNAL_OES, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_EXTERNAL_OES, GL_TEXTURE_MAG_FILTER, GL_NEAREST); glBindTexture(GL_TEXTURE_EXTERNAL_OES, 0);