Comments (9)
不好意思,这个问题我没遇到过。不过一般来说,对于UILabel这种常用的系统控件,苹果会帮我们处理好性能问题,因此一般情况可以不需要刻意去改变设置,这样子虽然有可能会对性能有略微损耗,但是避免了我们自己过于Hacking的优化方法造成图像绘制有偏差的情况。
from zen.
我测试与了解到的情况是,如果不做处理,列表会变得很卡。我有测过微信,微信一样对UILabel作了性能的处理,所以划起来的帧数才能达到55帧左右,如果不处理,大概只能到48帧左右。我测试到,UILabel在iOS8下所关联的图层不再是CALayer,而是UILabelLayer,所以绘制才发生了变化。
from zen.
感谢提供资讯。在网上没有查找到UILabelLayer的相关信息。有无开启UILabel的opaque。
If set to YES, the drawing system treats the view as fully opaque, which allows the drawing system to optimize some drawing operations and improve performance.
from zen.
有开启,我也试过不开启,但结果是一样的。UILabelLayer是私有的,应该查不到。
from zen.
这样子。按照官方文档标注,开启后应该就不会造成Blending。如果是iOS8才开始有的话,可能还需要进一步查正一下原因。我在网上帮你查了一下,好像没有关于iOS8下UILabel出现问题的报告。
from zen.
是这样的,我下了最新的微信,他们一样没作iOS8本文的处理,至于为什么,不清楚。我现在的做法只是,遇到会出现横线的,我就不加背景色,但出现横线的机率并不高
from zen.
嗯。也可能是苹果官方的bug。可以尝试去StackOverFlow提个问题。希望找到结果之后给大家分享一下。感谢。抱歉没能帮你解决这个问题。
from zen.
我一会把问题提上去,之前我也写了一些关于图形性能这方面的东西,打算发的,哈哈,你已经发布了,看到就想跟你交流一下。
from zen.
哈哈。我也是入门选手。以后多多交流。
from zen.
Related Issues (17)
- iOS夯实:ARC时代的内存管理中的[self someMethod]; HOT 1
- iOS夯实:ARC时代的内存管理 HOT 1
- 这是一个关于DispatchWallTime的使用问题?如果你能帮助我,真的很感谢 HOT 5
- 错字 找成内存泄漏 HOT 1
- SwiftTimer.deinit EXC_BAD_INSTRUCTION (code=EXC_I386_INVOP, subcode=0x0) HOT 2
- 对于 throttle 的使用场景存在疑问
- Swift学习: 从Objective-C到Swift中有误 HOT 2
- 网络相关 HOT 1
- 关于 swift 中的 atomic,苹果官方,给出了一个替代/模拟 atomic 的方案 HOT 1
- 看了RunLoop的文章,请教一个问题 HOT 1
- apple说的是不能在initialize方法里使用存取器吧,不是init方法吧 HOT 1
- 不懂就问,为何我这里增加target报错呢? HOT 1
- readonly,readwrie 直接通过声明变量var,声明常量let的方式来指明 HOT 1
- 图形性能离屏渲染 HOT 1
- 非常感谢! HOT 1
- 一处手误 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zen.