错误OpenGLRenderer:GL错误:内存不足

时间:2019-04-23 09:41:16

标签: android opengl-es

我创建了相机应用程序以使用表面检测用户面部,应用程序在30分钟后崩溃,并在日志猫错误显示中显示为GL_OUT_OF_MEMORY。

使用了Samsung S4选项卡。

能否让我知道为什么我遇到这个问题?

Logcat错误消息

W/Adreno-GSL: <sharedmem_gpuobj_alloc:2337>: sharedmem_gpumem_alloc: mmap failed errno 12 Out of memory
E/Adreno-GSL: <gsl_memory_alloc_pure:2203>: GSL MEM ERROR: kgsl_sharedmem_alloc ioctl failed.
 W/Adreno-GSL: <sharedmem_gpuobj_alloc:2337>: sharedmem_gpumem_alloc: mmap failed errno 12 Out of memory
 E/Adreno-GSL: <gsl_memory_alloc_pure:2203>: GSL MEM ERROR: kgsl_sharedmem_alloc ioctl failed.
 W/Adreno-GSL: <sharedmem_gpuobj_alloc:2337>: sharedmem_gpumem_alloc: mmap failed errno 12 Out of memory
 E/Adreno-GSL: <gsl_memory_alloc_pure:2203>: GSL MEM ERROR: kgsl_sharedmem_alloc ioctl failed.
W/Adreno-GSL: <sharedmem_gpuobj_alloc:2337>: sharedmem_gpumem_alloc: mmap failed errno 12 Out of memory
 E/Adreno-GSL: <gsl_memory_alloc_pure:2203>: GSL MEM ERROR: kgsl_sharedmem_alloc ioctl failed.
 W/Adreno-GSL: <sharedmem_gpuobj_alloc:2337>: sharedmem_gpumem_alloc: mmap failed errno 12 Out of memory
E/Adreno-GSL: <gsl_memory_alloc_pure:2203>: GSL MEM ERROR: kgsl_sharedmem_alloc ioctl failed.

 E/OpenGLRenderer: GL error:  Out of memory!
A/OpenGLRenderer: glTexImage2D error! GL_OUT_OF_MEMORY (0x505)

1 个答案:

答案 0 :(得分:1)

由于凌空库,我收到了内存不足错误,我创建了凌空的多个请求队列对象。

  

您只需要为您的应用程序创建一个截击请求即可。

    public RequestQueue getmRequestQueue(){
    if (mRequestQueue == null) {
        mRequestQueue = Volley.newRequestQueue(getApplicationContext());
    }

    return mRequestQueue;
    }

我已经在应用程序类中创建了只获取一个截击请求的方法。

相关问题