How to create xy chart images?

Discussion about using Moai SDK - post questions, bugs and issues here.

Moderators: seebs, franciscotufro

How to create xy chart images?

Postby hes » Tue May 15, 2012 8:14 am

I just started looking at Moai and have things running and have checked out most of the samples. I have no experience with mobile development.

I would be using Moai for a simple app, but not a game. As part of my app I would want to create a bunch of xy chart image files from datasets of roughly 50 or so points. The resulting images would then be displayed as list on screen with text and also used to export to html.

I''m trying to find how I would create the xy chart image files in Moai. What is the simplest way to do this?

Thanks,

Herb Sitz
hes
 
Posts: 1
Joined: Tue May 15, 2012 8:07 am

Re: How to create xy chart images?

Postby ibisum » Tue May 15, 2012 10:42 am

We have added a linegraph control to the moaigui - if you can wait, it will be pushed to derickdongs archive some time at the end of next week, and should provide you what you need:

Image

If you can't wait, its very, very easy to program one yourself .. you could use the moaigui framework as a starting place or just develop your own method for drawing it. Essentially you use a props' draw callback to attach MOAIDraw linedrawing commands.
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: How to create xy chart images?

Postby ibisum » Fri Jun 22, 2012 3:27 am

I just wanted to let you know that I have added our xy chart (line graph) widget to the moaigui framework, and hope that derickdong will merge the pull request shortly. The code in "linegraph.lua" demonstrates how you can do line drawing and may help you with your needs, so check it out:

My fork is here: https://github.com/seclorum/moaigui
(This will hopefully be merged in with derickd's moaigui framework shortly .. but its up to him, and I'll leave my fork up until he does that, if he does..)

Run the multilayoutdemo.lua demonstration file to see the linegraph in use (as well as learn how to do multiple layouts with moaigui)
;
--
ibisum@gmail.com
Got a MOAI snippet? Please consider adding it to http://moaisnippets.info
User avatar
ibisum
 
Posts: 1005
Joined: Mon Oct 17, 2011 1:11 am
Location: Vienna, Austria

Re: How to create xy chart images?

Postby todd » Sat Jun 23, 2012 6:33 pm

Thanks Ibisum.
User avatar
todd
 
Posts: 262
Joined: Fri Mar 25, 2011 1:11 pm


Return to Moai SDK

Who is online

Users browsing this forum: No registered users and 1 guest

x