Build of MathGL with best performance

57 views
Skip to first unread message

Sean Saud

unread,
Oct 26, 2020, 12:32:04 PM10/26/20
to MathGL

Professor Alexey,

What components of MathGL should I use to have the best performance? I will be processing huge amounts of data and plotting the data in real time. By the way, I am now using Centos 7 x86_64.

Sincerely,
Sean

mathgl....@gmail.com

unread,
Oct 26, 2020, 1:21:28 PM10/26/20
to mat...@googlegroups.com
Dear Sean,

If you have a huge amount of data then you probably need to use direct export to a bitmap file (like PNG, JPEG and so on), because GUI redrawing may be slow. But you need to test this on your computer, since MathGL draws plots rather quickly.

Also don't forget to call SetQuality(6) first to reduce memory usage, but this will disable vector output (like EPS, SVG and so on). Alternatively, you can use the combination of functions Rasterize() and Clf() to draw part of the plot as a bitmap one, and part of the plot (like axis, text, annotations, etc) as a vector one. Or you can first call SetQuality(6) for bitmap output, and switch to SetQuality(2) for vector one later.

пн, 26 окт. 2020 г. в 19:32, Sean Saud <sean...@gmail.com>:
--
You received this message because you are subscribed to the Google Groups "MathGL" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mathgl+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/mathgl/2e0b81aa-2f96-4bcd-9e1b-2b730ce84983n%40googlegroups.com.


--
Kind regards,
Alexey Balakin

Sean Saud

unread,
Oct 26, 2020, 2:10:39 PM10/26/20
to MathGL
Thank you so much for the fast answer! But my end goal is to be able to plot live data (data is being collected), so I wanted it to display it on a GUI. What widget would you recommend using? FLTK, glut, or qt5?

Sincerely,
Sean

mathgl....@gmail.com

unread,
Oct 26, 2020, 2:17:10 PM10/26/20
to mat...@googlegroups.com
In my opinion, FLTK is faster overall. However, the difference between Qt5 and FLTK widgets is not significant since both use MathGL core for drawing plots.

пн, 26 окт. 2020 г. в 21:10, Sean Saud <sean...@gmail.com>:

Sean Saud

unread,
Oct 26, 2020, 2:34:58 PM10/26/20
to MathGL
Thank you very much! I really appreciate it.
Reply all
Reply to author
Forward
0 new messages