android中实现ios8的实时毛玻璃效果

上传者: l448288137 | 上传时间: 2019-12-21 20:05:00 | 文件大小: 7.78MB | 文件类型: zip
在android下实现ios的实时毛玻璃效果的demo。使用非常简单,可以根据自己的需求对代码进行修改。 一般情况下只需要把需要模糊的view继承BlurringView,然后设置背景的blurredView。然后在画面刷新的时候使用invalidate()就好。 如果BlurringView需要继承ViewGroup的话记得加上setWillNotDraw(false); 如果mBlurredView.draw(mBlurringCanvas)无效,可以尝试用mBlurredView.getDrawingCache()后bitmap,在转换成mBlurringCanvas; 注意:需要support.v8.renderscript包。(对低版本的api) 效果图:http://www.jcodecraeer.com/uploads/150319/1-150319202G6305.gif 如何有问题可以留言讨论

文件下载

资源详情

[{"title":"( 43 个子文件 7.78MB ) android中实现ios8的实时毛玻璃效果","children":[{"title":"500px-android-blur-master","children":[{"title":"gradlew <span style='color:#111;'> 4.96KB </span>","children":null,"spread":false},{"title":"settings.gradle <span style='color:#111;'> 32B </span>","children":null,"spread":false},{"title":"LICENSE.txt <span style='color:#111;'> 1.03KB </span>","children":null,"spread":false},{"title":"blurdemo.gif <span style='color:#111;'> 6.32MB </span>","children":null,"spread":false},{"title":"blurringview","children":[{"title":"src","children":[{"title":"androidTest","children":[{"title":"java","children":[{"title":"com","children":[{"title":"fivehundredpx","children":[{"title":"blur","children":[{"title":"ApplicationTest.java <span style='color:#111;'> 353B </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true},{"title":"main","children":[{"title":"AndroidManifest.xml <span style='color:#111;'> 228B </span>","children":null,"spread":false},{"title":"res","children":[{"title":"values","children":[{"title":"defaults.xml <span style='color:#111;'> 232B </span>","children":null,"spread":false},{"title":"attrs.xml <span style='color:#111;'> 296B </span>","children":null,"spread":false},{"title":"strings.xml <span style='color:#111;'> 94B </span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"java","children":[{"title":"com","children":[{"title":"fivehundredpx","children":[{"title":"android","children":[{"title":"blur","children":[{"title":"BlurringView.java <span style='color:#111;'> 6.36KB </span>","children":null,"spread":false}],"spread":false}],"spread":false}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true},{"title":".gitignore <span style='color:#111;'> 7B </span>","children":null,"spread":false},{"title":"build.gradle <span style='color:#111;'> 561B </span>","children":null,"spread":false},{"title":"proguard-rules.pro <span style='color:#111;'> 660B </span>","children":null,"spread":false}],"spread":true},{"title":"gradle","children":[{"title":"wrapper","children":[{"title":"gradle-wrapper.properties <span style='color:#111;'> 232B </span>","children":null,"spread":false},{"title":"gradle-wrapper.jar <span style='color:#111;'> 48.73KB </span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"README.md <span style='color:#111;'> 578B </span>","children":null,"spread":false},{"title":"gradlew.bat <span style='color:#111;'> 2.35KB </span>","children":null,"spread":false},{"title":"gradle.properties <span style='color:#111;'> 855B </span>","children":null,"spread":false},{"title":".gitignore <span style='color:#111;'> 108B </span>","children":null,"spread":false},{"title":"app","children":[{"title":"src","children":[{"title":"androidTest","children":[{"title":"java","children":[{"title":"com","children":[{"title":"fivehundredpx","children":[{"title":"blurdemo","children":[{"title":"ApplicationTest.java <span style='color:#111;'> 357B </span>","children":null,"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":true},{"title":"main","children":[{"title":"AndroidManifest.xml <span style='color:#111;'> 718B </span>","children":null,"spread":false},{"title":"res","children":[{"title":"mipmap-hdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 3.34KB </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-xhdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 4.73KB </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-mdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 2.15KB </span>","children":null,"spread":false}],"spread":false},{"title":"layout","children":[{"title":"activity_main.xml <span style='color:#111;'> 4.86KB </span>","children":null,"spread":false}],"spread":false},{"title":"drawable-xxhdpi","children":[{"title":"p8.jpg <span style='color:#111;'> 124.05KB </span>","children":null,"spread":false},{"title":"p6.jpg <span style='color:#111;'> 206.31KB </span>","children":null,"spread":false},{"title":"p4.jpg <span style='color:#111;'> 218.97KB </span>","children":null,"spread":false},{"title":"p9.jpg <span style='color:#111;'> 72.75KB </span>","children":null,"spread":false},{"title":"p2.jpg <span style='color:#111;'> 115.97KB </span>","children":null,"spread":false},{"title":"p1.jpg <span style='color:#111;'> 196.08KB </span>","children":null,"spread":false},{"title":"p5.jpg <span style='color:#111;'> 234.94KB </span>","children":null,"spread":false},{"title":"p0.jpg <span style='color:#111;'> 152.65KB </span>","children":null,"spread":false},{"title":"p3.jpg <span style='color:#111;'> 106.42KB </span>","children":null,"spread":false},{"title":"p7.jpg <span style='color:#111;'> 171.39KB </span>","children":null,"spread":false}],"spread":false},{"title":"values","children":[{"title":"strings.xml <span style='color:#111;'> 140B </span>","children":null,"spread":false},{"title":"styles.xml <span style='color:#111;'> 194B </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-xxhdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 7.54KB </span>","children":null,"spread":false}],"spread":false}],"spread":false},{"title":"java","children":[{"title":"com","children":[{"title":"fivehundredpx","children":[{"title":"blurdemo","children":[{"title":"MainActivity.java <span style='color:#111;'> 5.11KB </span>","children":null,"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":true},{"title":".gitignore <span style='color:#111;'> 7B </span>","children":null,"spread":false},{"title":"build.gradle <span style='color:#111;'> 768B </span>","children":null,"spread":false},{"title":"proguard-rules.pro <span style='color:#111;'> 660B </span>","children":null,"spread":false}],"spread":true},{"title":"build.gradle <span style='color:#111;'> 436B </span>","children":null,"spread":false}],"spread":false}],"spread":true}]

评论信息

  • 代码彩戏师 :
    效果还算可以 有思路了
    2018-03-27
  • liyuyitong :
    虽然可以,但不是想要效果
    2016-05-23
  • xumu :
    得用Android studio打开,我还不太会用Android studio
    2016-02-27

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明