Graph generation on iPhone

Graph generation on iPhone

明月松间行 发布于 2021-11-27 字数 408 浏览 871 回复 6 原文

Anyone have experience with drawing graphs on the iPhone? Looks like GraphKit isn't an option, so it's up to the programmer to either write his own library (using OpenGL, I guess), or an existing library. I can't seem to find any libraries that are confirmed to work on the iPhone.

If you've written your own how did you go about it (opengl, quartz, etc), or if you used a library which one?

如果你对这篇文章有疑问,欢迎到本站 社区 发帖提问或使用手Q扫描下方二维码加群参与讨论,获取更多帮助。



需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。


太阳哥哥 2022-06-07 6 楼

You can check out the PowerPlot library which is an iOS native library. It is the only choice (to my knowledge) that not only has the "usual" assortment of charts, but also graphs (with nodes and connections) among the views. It is not based on OpenGL, but on Quartz. It also does not target the desktop version of MacOS, focusing specifically on iOS.

Licensing policy is dual license - developers can choose GPLv3 or a commercial one.

夜巴黎 2022-06-07 5 楼

I have tried to plot a graph using Quartz 2D . It looks more like a drawing. But I am fixing the axes and plotting the coordinates according to the axes. But the problem is I want to make the graph user interactive. Each coordinate on the graph will further have to drill down showing the details of the coordinate. So how can I make the coordinates interactive .

痞味浪人 2022-06-07 4 楼

I've done graphs in an application before using Quartz2D. Since the graph was particularly wide, I had to use a CATiledLayer for the view, which I think was what caused more issues than it fixed. The graph looked nice, but in the end, it was just too difficult to deal with. Too many bugs when trying to draw too much of the graph at once, or trying to draw the graph several times in a row quickly as the user changes between different views.

At this point, my suggestion would be to try something in OpenGL, though I don't know how you'd go about achieving it, since line drawing is pretty basic on the iPhone in OpenGL.

悟红尘 2022-06-07 3 楼

Have tried and used CorePlot, on my way to a app-store app. Was a pain setting it up and then digging in deep, certainly the best graphing option currently.

︶ ̄淡然 2022-06-07 2 楼

Ive used an appstore app with it...not thrilled about its use. Its very customizable, maybe TOO customizable. It gave me quite a bit of trouble setting it up and i still have problems with is. Id like to know how does their porting from excel, it looks pretty good. MSOffice4mac should just come out with a direct port to iphone

猥琐帝 2022-06-07 1 楼

I have been keeping my eye on this one:


but I haven't yet tried it. Though it seams like it has potential.