Results 1 to 9 of 9

Thread: How to plot the real time data in qwtplot while erasing fixed-width old data?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    May 2020
    Location
    HongKong
    Posts
    4
    Qt products
    Qt4 Qt5 Qt/Embedded

    Default Re: How to plot the real time data in qwtplot while erasing fixed-width old data?

    Quote Originally Posted by Uwe View Post
    Then your code does not make any sense.

    Uwe
    I have renewed.Thanks for the quick reply!

    What I don’t understand is why these my two methods are so different, why the CPU consumption is so different? Looks like they are doing the same partial refresh.

    Maybe as you said:QWidget does not offer to "erase" something - all you can do is to redraw from scratch.

  2. #2
    Join Date
    Feb 2006
    Location
    Munich, Germany
    Posts
    3,318
    Thanked 879 Times in 827 Posts
    Qt products
    Qt3 Qt4 Qt/Embedded
    Platforms
    MacOS X Unix/X11 Windows

    Default Re: How to plot the real time data in qwtplot while erasing fixed-width old data?

    Quote Originally Posted by lockdown View Post
    What I don’t understand is why these my two methods are so different, why the CPU consumption is so different?
    Hard to say what your code is doing as the code snippet does not show the real code.

    But the plot canvas is actually using a backing store ( a QPixmap ), that gets updated on certain operations like when the size of the canvas is changing or replot has been called.
    Beside that the content of the widget is always restored from this backing store only.

    So when calling QWidget::update( region ) only all what happens is, that the rectangles from region will be copied from the backing store of the canvas to another backing store - the default one every widgets has.

    Uwe

  3. #3
    Join Date
    Jun 2020
    Posts
    2
    Qt products
    Qt5 Qt/Embedded
    Platforms
    Unix/X11

    Default Re: How to plot the real time data in qwtplot while erasing fixed-width old data?

    @lockdown Have you found a way to achieve this? because I am running in circles about the same issue and that would be really great help.

Similar Threads

  1. Replies: 2
    Last Post: 31st December 2019, 18:24
  2. Plot the graph for real time data
    By swinetha in forum Qwt
    Replies: 13
    Last Post: 1st August 2013, 04:56
  3. Replies: 2
    Last Post: 5th April 2013, 04:58
  4. real time data display
    By hammer256 in forum Qt Programming
    Replies: 13
    Last Post: 25th March 2013, 16:47
  5. Replies: 1
    Last Post: 27th April 2011, 10:35

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.