Results 1 to 5 of 5

Thread: real time plotting

  1. #1
    Join Date
    Sep 2007
    Posts
    99
    Thanks
    8
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Question real time plotting

    Is there a way how to do this using Qwt:
    I want to measure some data for a several hours lets say...And I need to display them in a plot...The problem is that I couldnt find anywhere how can I set a range of x-axis ...
    I want it to be changed dynamically after a certain time interval...like to enlarge by 10 after each 5 seconds...
    Does anyone have a clu how to do that ?
    Thanks

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

    Default Re: real time plotting

    Start with looking at the cpuplot example.

    Uwe

  3. #3
    Join Date
    Sep 2007
    Posts
    99
    Thanks
    8
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default

    Quote Originally Posted by Uwe View Post
    Start with looking at the cpuplot example.

    Uwe
    Aha...I wouldnt know that something like that I can find in that example...I was looking at realtime plots and other examples like that...thanks Ill have a look...

    What if I was just changing the axis scale upon some timer event using this method of QWTPlot ?
    Qt Code:
    1. setAxisScale()
    To copy to clipboard, switch view to plain text mode 
    Last edited by wysota; 11th December 2007 at 15:52. Reason: Posts merged

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

    Default Re: real time plotting

    Quote Originally Posted by gyre View Post
    What if I was just changing the axis scale upon some timer event ...
    I don't know enough about your application, but in general it should be enough to assign your new points to the curve and do a replot. The autoscaler will do the rest.

    If you store your data in your own type of container I recommend to write your own QwtData bridge. This way you don't need to copy anything and a single replot every couple of seconds will do what you want.

    Uwe

  5. #5
    Join Date
    Sep 2007
    Posts
    99
    Thanks
    8
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: real time plotting

    Quote Originally Posted by Uwe View Post
    If you store your data in your own type of container I recommend to write your own QwtData bridge. This way you don't need to copy anything and a single replot every couple of seconds will do what you want.
    Thanks...Ive searched the docs and what you are saying seems reasonable...

Similar Threads

  1. Rendering real time video using SDL and QT
    By venk2ksubbu in forum Newbie
    Replies: 4
    Last Post: 13th September 2007, 15:20
  2. Display the camera frame in real time
    By alex_lue in forum Qt Programming
    Replies: 8
    Last Post: 27th July 2007, 10:31
  3. Displaying real time images
    By Sheetal in forum Qt Programming
    Replies: 9
    Last Post: 22nd February 2007, 11:29
  4. QDateTime GMT add sec. or - sec. from locale time....
    By patrik08 in forum Qt Programming
    Replies: 2
    Last Post: 20th February 2007, 16:39
  5. Problem with pointers while using localtime() and time()
    By jamadagni in forum General Programming
    Replies: 7
    Last Post: 11th January 2006, 15:48

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.