Which is faster: 4 lines or a rectangle SWT Java

隐身守侯 提交于 2019-12-10 20:23:51

问题


Is there any performance differences between 4 lines or a rectangle when it comes to drawing in SWT. Even if its a small difference I am interested. The system I am creating can makes a ton of these calls per frame.


回答1:


On a system I work on, after profiling it, we switched from drawing one rectangle + two lines for a polyline and we got a great boost on drawing. (to draw candles like those:

)

It was, at least, twice as fast.



来源:https://stackoverflow.com/questions/12375175/which-is-faster-4-lines-or-a-rectangle-swt-java

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!