Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Qt plotting application

Currently I'm trying to develop some simple plot prototype and I'm struggling with some kind of white/empty sheet syndrome. I'm back to Qt after 2 years, so I feel quite retarded.

My application should:

  • plot and manage custom layers of data
  • plot on custom canvas background
  • manage markers on plot

My plan is to use following design:

  • QGraphicsScene /View/Item as a sprite like management widgets for background, markers, pointers and other "bitmap" objects etc.
  • QPainter/ Qpixmap or QPicture for actual data layers - and if possible set them as QGraphicItem to simplify management of dynamic graphics

I don't want to use Qwt or similar library, unless I can plot with it on custom background (I don't like the look of the qwt's graphic style).

Is my plan proper in scope of qt class usage and composition? I'd like to have at least clear overview of the classes which should be involved for this kind of prototype. Thanks in advance. P.

like image 334
bua Avatar asked Jan 31 '10 21:01

bua


1 Answers

I think you have the basic idea with QGraphicsView. Here are a few resources which might help:

Graphics View

Diagram Scene

If you want to use the new animation and state set classes:

Stickman

Also, take a look at gunnar's labs blog. He recently did a series on graphics performance.

All of these are strictly Qt (animation and state set are in 4.6). They are in C++ but hopefully you can translate what you need to python.

like image 122
Adam W Avatar answered Oct 06 '22 01:10

Adam W