studio报错显示png图片异常
2016-07-28 18:40
447 查看
今天日了狗了。
在进行eclipse转到studio的过程中发现出现了一下错误
Information:Gradle tasks [clean, :app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies, :app:compileDebugSources, :app:compileDebugAndroidTestSources, :app:compileDebugUnitTestSources]
Observed package id 'add-ons;addon-google_apis-google-23' in inconsistent location 'D:\sdk\add-ons\addon-google_apis-google-23-1' (Expected 'D:\sdk\add-ons\addon-google_apis-google-23')
:clean
:app:clean
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2400Library
:app:prepareComAndroidSupportAppcompatV72400Library
:app:prepareComAndroidSupportSupportV42400Library
:app:prepareComAndroidSupportSupportVectorDrawable2400Library
:app:prepareDebugDependencies
:app:compileDebugAidl
:app:compileDebugRenderscript
:app:generateDebugBuildConfig
:app:mergeDebugShaders
:app:compileDebugShaders
:app:generateDebugAssets
:app:mergeDebugAssets
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources
:app:mergeDebugResources
AAPT err(Facade for 2014483692): libpng error: Not a PNG file
Error:Execution failed for task ':app:mergeDebugResources'.
> Some file crunching failed, see logs for details
Information:BUILD FAILED
Information:Total time: 6.565 secs
Information:1 error
Information:0 warnings
Information:See complete output in console
产生原因:
图片的格式不对,这个不对是自己的图片本来是jpg 的,但是我修改了后缀名为png ,。 在eclipse中没有报错,但是在studio中却显示为错误。
解决办法:
删掉
我的做法:
新建studio项目,将原来eclipse项目中的所有图片放置到新建本地电脑文件夹中,然后通过二分法,快速定位到出错的那个图片。
为什么确定:
发现导入的那张图片拿出来 在ps中以png打开显示解析异常,修改后缀名为jpg的然后就可以正常打开。从而确定就是这张图片错误的原因就是修改了不是png的类型。
妈的 搞了一整天。我是不是傻!!!
在进行eclipse转到studio的过程中发现出现了一下错误
Information:Gradle tasks [clean, :app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies, :app:compileDebugSources, :app:compileDebugAndroidTestSources, :app:compileDebugUnitTestSources]
Observed package id 'add-ons;addon-google_apis-google-23' in inconsistent location 'D:\sdk\add-ons\addon-google_apis-google-23-1' (Expected 'D:\sdk\add-ons\addon-google_apis-google-23')
:clean
:app:clean
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2400Library
:app:prepareComAndroidSupportAppcompatV72400Library
:app:prepareComAndroidSupportSupportV42400Library
:app:prepareComAndroidSupportSupportVectorDrawable2400Library
:app:prepareDebugDependencies
:app:compileDebugAidl
:app:compileDebugRenderscript
:app:generateDebugBuildConfig
:app:mergeDebugShaders
:app:compileDebugShaders
:app:generateDebugAssets
:app:mergeDebugAssets
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources
:app:mergeDebugResources
AAPT err(Facade for 2014483692): libpng error: Not a PNG file
Error:Execution failed for task ':app:mergeDebugResources'.
> Some file crunching failed, see logs for details
Information:BUILD FAILED
Information:Total time: 6.565 secs
Information:1 error
Information:0 warnings
Information:See complete output in console
产生原因:
图片的格式不对,这个不对是自己的图片本来是jpg 的,但是我修改了后缀名为png ,。 在eclipse中没有报错,但是在studio中却显示为错误。
解决办法:
删掉
我的做法:
新建studio项目,将原来eclipse项目中的所有图片放置到新建本地电脑文件夹中,然后通过二分法,快速定位到出错的那个图片。
为什么确定:
发现导入的那张图片拿出来 在ps中以png打开显示解析异常,修改后缀名为jpg的然后就可以正常打开。从而确定就是这张图片错误的原因就是修改了不是png的类型。
妈的 搞了一整天。我是不是傻!!!
相关文章推荐
- 一线公司面试题宝典
- 利用 LLMNR 名称解析缺陷劫持内网指定主机会话
- 将一个View和一个xib文件进行绑定
- hdu 5775 Bubble Sort 树状数组
- 2016 Multi-University Training Contest 4题解报告
- 1040. 有几个PAT(25)
- 基础学习-Linux文件系统
- 高通平台手机开发之LCD
- eclipse 启动 org.eclipse.jst.servlet.ui was unable to instantiate class
- BZOJ 1046: [HAOI2007]上升序列
- Redis 集群教程
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- 线程“死亡”后的反思
- 作为一个技术人员提高薪水除了不断跳槽之外,有什么好的建议?
- objective-C之宏定义实现单例设计模式