Create simple plots and histograms with OF


I’m starting to learn OF and I was thinking that a good way to do it would be to port my Processing/P5.js grafica library to OF. I did a fast google search and I didn’t find an extension doing similar things, but maybe I missed it.

Here are some examples of what grafica can do:

Would the community like to have the library or I would be duplicating someone else work?

Thank you for your help!

1 Like

New addons are always welcome!
I would be interested on helping out. There are some options out there tho.
The ones I remember right now are:

VTK, probably the ultimate answer but its a monster library.

ImGui, a gui library of course… probably not what you are looking for, but some plotting can be done. Interactive part is really good, very fast drawing rutines.

When i have been looking at infoviz libraries i also wanted to have the possibility to interact with the plots.
In my opinion it would be good to write on top of ImGui. Then you would have all the interaction and windowing for free, not sure if you like the idea…

Still, it would be also good to have an addon for this purpose. Something much smaller than the ones i mentioned. Just drawing with openGL very simple interaction.

Just my few cents.

1 Like

Hi Jordi,

Thanks a lot for the links.

My idea was more to create a library that does not depend on other libraries, only on the OF tools. That is the philosophy behind Grafica for Processing and P5.js. The lib uses the drawing tools provided by Processing to draw the lines, points, text, handle control events, etc. I was wondering if there was already a OF addon doing that.

Translating Grafica to the OF commands should not be a lot of work and in the way I will learn OF and C++, so it will be fun :slight_smile:

I will keep you updated on the progress if you want.


Hey @jagracar
It sounds like a great idea for an addon. I know that there are some for live plotting values, but not as much possibilities as what your processing lib shows. You should take a look at and see what’s there. (BTW, pull all the repos from github that look like an openFrameworks addon, so it would be a good idea that you publish your addon on github).

Just let me know if you need any help.

all the best

Hi! Great to see that there is some interest.

Yes, I will create a ofxGrafica github repository based on this template:

I had a quick look at the ofxaddons page and the only similar addons that I could find are:


Hi @roymacdonald and @Jordi!

I’m almost finished porting the library to OF. Only the mouse events are missing.

You can have a look at the addon and test some of the examples here:



Hey @jagracar your addon looks awesome!
Let me know if you need any help with the mouse interactions.
For zooming and panning I made an addon that might be useful, whose functionalities can be achieved by configuring correctly an instance of ofEasyCam when using OF0.10


Great that you like it @roymacdonald.

I just added the mouse events and they should be working with my latest commits.

There is only a bug in the life expectancy example that I will fix tomorrow

Hi again,

I think I’m 99% finished with the addon. All the examples are working.

Still missing:

  • documentation
  • touch events

Some questions concerning ofTrueTypeFont: is there a font that one can be 100% sure that is going to be available in all systems? How do I get bold fonts?