Results 1 to 6 of 6

Thread: Overloading QwtPlot replot() to replot every 100 msec

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Jan 2016
    Posts
    4
    Qt products
    Qt4
    Platforms
    Windows

    Default Overloading QwtPlot replot() to replot every 100 msec

    Hi,

    I am using QwtPlot to display large amounts of data, that comes in fas (every 1 msec). I decided i will not be refreshing the plot every time data new data comes and will rather do it every 100 msec. So I'm using a QTimer that times out every 100msec. When that happens QwtPlot::replot() is called.

    Qt Code:
    1. void EWOSubPlot2D::replotTimerTimeout() {
    2. lock_guard<mutex> replotLock(replotMutex);
    3. if (replotFlag) {
    4. QwtPlot::replot();
    5. replotFlag = false;
    6. }
    7. }
    8.  
    9. void EWOSubPlot2D::replot() {
    10. lock_guard<mutex> replotLock(replotMutex);
    11. replotFlag = true;
    12. }
    To copy to clipboard, switch view to plain text mode 

    I am using a zoomer, magnifier and a panner.
    When I overload replot() method like shown above, zommer does not draw rectangles as i draw them and
    when i press keyboard combination for zoom out, axis labels are not displayed yet. It seems to me that QwtPlot::replot() does other things than just replotting, so it cant be "put in queue" and executed later?

    I'm using Qwt 6.1.2

    BR, f0orz4h
    Last edited by f0orz4h; 22nd January 2016 at 10:53.

Similar Threads

  1. Replies: 1
    Last Post: 14th May 2014, 07:57
  2. the replot of a qwtPlot is too slow
    By gaia86 in forum Qwt
    Replies: 3
    Last Post: 4th April 2012, 08:33
  3. the replot of a qwtPlot is too slow
    By gaia86 in forum Qwt
    Replies: 1
    Last Post: 3rd April 2012, 16:54
  4. the replot of a qwtPlot is too slow
    By gaia86 in forum Qwt
    Replies: 0
    Last Post: 3rd April 2012, 15:19
  5. Replies: 1
    Last Post: 4th November 2009, 22:14

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.