egl

Getting Exception: FATAL EXCEPTION: GLThread No configs match configSpec

怎甘沉沦 提交于 2019-12-23 05:27:49
问题 I am using the below code for the MultiSampling to make the smooth edge. Below code is working on some mobile and other mobile I am getting exception ' No configs match configSpec . Please help me to solve this issue. Thanks in advance. package com.amplimesh.renderer; import javax.microedition.khronos.egl.EGL10; import javax.microedition.khronos.egl.EGLConfig; import javax.microedition.khronos.egl.EGLDisplay; import android.opengl.GLSurfaceView; import android.util.Log; // This class shows

“EGL Error : could not create the EGL surface: error 0x300b” on i.MX6 when running Qt5 application with -platform eglfs

雨燕双飞 提交于 2019-12-20 04:53:05
问题 I am trying to run the hellogl_es2 Qt example without X Server by specifying the eglfs platform: ./hellogl_es2 -platform eglfs EGL Error : Could not create the egl surface: error = 0x300b Aborted (core dumped) CPU is Freescale i.MX6. Linux kernel is 3.10.17. Distribution is Ubuntu 14.04.4 LTS (trusty). Qt version is 5.2.1, installed from http://packages.ubuntu.com, armhf architecture, packages qtbase5-dev, qtbase5-examples, qtbase5-examples-dbg. The core dump is: GNU gdb (Ubuntu 7.7.1

EGL 介绍和使用

为君一笑 提交于 2019-12-13 16:34:48
1、形象介绍 原文地址: https://www.jianshu.com/p/95dfe935b169 部分内容摘自其他博客,请见最下[参考资料] 首先来看看Android官方对EGL的解释: OpenGL ES 定义了一个渲染图形的 API,但没有定义窗口系统。为了让 GLES 能够适合各种平台,GLES 将与知道如何通过操作系统创建和访问窗口的库结合使用。用于 Android 的库称为 EGL。如果要绘制纹理多边形,应使用 GLES 调用;如果要在屏幕上进行渲染,应使用 EGL 调用。 OpenGL ES 是Android绘图API,但OpenGL ES是平台通用的,在特定设备上使用需要一个中间层做适配,这个中间层就是EGL。 EGL架构 Display(EGLDisplay) 是对实际显示设备的抽象。 Surface(EGLSurface)是对用来存储图像的内存区域 FrameBuffer 的抽象,包括 Color Buffer, Stencil Buffer ,Depth Buffer。 Context (EGLContext) 存储 OpenGL ES绘图的一些状态信息。 Android中的OpenGL 与EGL Android 2.0版本之后图形系统的底层渲染均由OpenGL负责,OpenGL除了负责处理3D API调用,还需负责管理显示内存及处理Android

Using GraphicBuffers to fast read from a texture

北城余情 提交于 2019-12-12 09:47:29
问题 I am working on some code that runs some GPGPU code on Android using shaders. Usually a Framebuffer is used so the result of the computation is stored in a texture. Also the input data is usually a texture. To improve performance it would be great to get rid of glTexImage2D and glReadPixels to upload and download images to and from the GPU memory space. All the code related to OpenGL is native. On Android GraphicBuffer can be used on Android for this propose because in mobile devices gpu

Bitmap texture does not show up in framebuffer surface on Android

让人想犯罪 __ 提交于 2019-12-11 09:42:52
问题 I'm trying to use the new EffectFactory/Effect to add effects to images off screen (i.e. framebuffer). I've looked at the HelloEffects.java example provided in the SDK and I've tried it out and it works. Except it obviously uses a GLSurfaceView and that isn't what I want. So I've taken tests/effect/src/android/effect/cts/GLEnv.java to setup the EGL stuff and I've also grabbed TextureRenderer.java and GLToolbox from the HelloEffects example. Mashed them all up and I've got the code below. (On

What is the right way to choose an EGL config in Android?

家住魔仙堡 提交于 2019-12-10 19:40:08
问题 I'm using my own GLSurfaceView and have been struggling with crashes related to the EGL config chooser for a while. It seems as though requesting RGB_565 by calling setEGLConfigChooser(5, 6, 5, 0, 16, 0) should be the most supported. However, running this code on the emulator using host GPU I still get a crash, seemingly because my graphics card does not natively support RGB_565. Setting to RGBA_8888 by calling setEGLConfigChooser(8, 8, 8, 8, 16, 0) seems to run fine on my emulator and HTC

Difference from eglCreatePbufferSurface and eglCreatePixmapSurface with OpenGL ES(EGL)

末鹿安然 提交于 2019-12-10 18:34:00
问题 I am having a problem where I need to some off-screen work with opengl es2 by software rendering(Only has CPU, no GPU). The question is can I use pbuffer without GPU? Also, how to directly save to a png file after drawing something. Please help and give me a demo. 回答1: First, use EGL to create an off-screen buffer: eglCreatePbufferSurface(display, config, PBufAttribs); Then read the buffer: GLint size; size = esContext->width * esContext->height * 4; GLubyte *data = (GLubyte*)malloc(size);

EGLDisplay on GBM

五迷三道 提交于 2019-12-10 13:12:50
问题 I want to create an OpenGL context through EGL. As I won't actually draw, I want to use Pbuffers in conjunction with the GBM platform. This is the code (C99): #include <stdlib.h> #include <assert.h> #include <fcntl.h> #include <unistd.h> #include <EGL/egl.h> #include <EGL/eglext.h> #include <gbm.h> int main( void ) { assert( eglBindAPI( EGL_OPENGL_API ) == EGL_TRUE ); int fd = open("/dev/dri/card0", O_RDWR); struct gbm_device * gbm = gbm_create_device( fd ); EGLDisplay dpy = eglGetDisplay(

Issue in passing Egl configured surface to native and push the data

余生颓废 提交于 2019-12-09 23:53:53
问题 First, thanks to fadden for your wonderful examples. I tried following this ContinuousCapture.java example, and produced the below program. 1) I am trying to display the image into TextureView in the native layer by getting its ANativeWwindow reference, and using ANative lock and unlockpost methods to acquire the BufferQueue and to fill the data. Ie: ANativeWindow_lock(*window, &buffer, NULL) ANativeWindow_unlockAndPost(*window); 2) At the same time i want to retrieve the data from this

Is there a standard way to query EGL error string?

给你一囗甜甜゛ 提交于 2019-12-07 06:11:14
问题 Currently my function to convert result of eglGetError() looks like this: std::string eglErrorString(EGLint error) { switch(error) { case EGL_SUCCESS: return "No error"; case EGL_NOT_INITIALIZED: return "EGL not initialized or failed to initialize"; case EGL_BAD_ACCESS: return "Resource inaccessible"; case EGL_BAD_ALLOC: return "Cannot allocate resources"; case EGL_BAD_ATTRIBUTE: return "Unrecognized attribute or attribute value"; case EGL_BAD_CONTEXT: return "Invalid EGL context"; case EGL