Bitmap too large to be uploaded into a texture 解决方法
来源:互联网 发布:网络终端机 改造 编辑:程序博客网 时间:2024/05/16 09:24
1.现象
从手机相册里面显示图片,但是发现有的图片能显示有的图片不能显示,路径都是对的,程序也没提示任何错误。
打印的日志如下:
Bitmap too large to be uploaded into a texture,该日志信息不一定是以错误日志呈现的,但一定会有记录。
2.解决方案
经过查找资料是因为当开启硬件加速的时候,GPU对于openglRender 有一个限制,这个不同的手机会有不同的限制。
简单说就是硬件加速的时候,对图片的大小有限制。不同设备可能有不同的最大值。这个问题悲催的地方是,程序貌似没有捕获到这个exception, 结果是程序也不报错,图片也显示不出来。
一个解决的方法是禁止硬件加速
<application android:hardwareAccelerated="false" ...>
针对某些适配的机型,可能在application中设置禁止硬件加速,会造成其他问题,因此,可以在具体的activity标签中添加android:hardwareAccelerated="false"即可。
本文参考了http://chy2z.blog.163.com/blog/static/3166884620147209110507/
0 0
- Bitmap too large to be uploaded into a texture 解决方法
- Bitmap too large to be uploaded into a texture 解决方法
- Bitmap too large to be uploaded into a texture
- Bitmap too large to be uploaded into a texture exception
- Bitmap too large to be uploaded into a texture
- Bitmap too large to be uploaded into a texture
- Bitmap too large to be uploaded into a texture
- Bitmap too large to be uploaded into a texture
- Bitmap too large to be uploaded into a texture 解决方案
- Bitmap too large to be uploaded into a texture
- Bitmap too large to be uploaded into a texture问题的解决方法
- 解决:Bitmap too large to be uploaded into a texture exception
- 解决:Bitmap too large to be uploaded into a texture exception
- 关于使用ImageLoader出现的Bitmap too large to be uploaded into a texture
- 解决:Bitmap too large to be uploaded into a texture exception
- 解决:Bitmap too large to be uploaded into a texture exception
- Bitmap too large to be uploaded into a texture,Hardware accelerated
- 解决:Bitmap too large to be uploaded into a texture exception
- 认识UML类关系——依赖、关联、聚合、组合、泛化
- 6.14、处理时间:PeriodsToDate、LastPeriods、ParallelPeriod
- pat甲 1103. Integer Factorization ( dfs)
- java 格式化时间
- mysql在windows下不区分大小写,在linux下区分大小写
- Bitmap too large to be uploaded into a texture 解决方法
- ajax总结
- Unity说明文档翻译-Importing from the Asset Store
- Java基础-接口,内部类及对象克隆的学习
- 一个MFC制作的跑酷游戏的小Demo
- spark的checkpoint
- Linux基础——chown&chgrp 更改用户及属组
- 1093.Count PAT's (25)...to be continued...
- 如何生成JKS文件