.TH "QwtSamplingThread" 3 "Fri Apr 15 2011" "Version 6.0.0" "Qwt User's Guide" \" -*- nroff -*- .ad l .nh .SH NAME QwtSamplingThread \- .PP A thread collecting samples at regular intervals. .SH SYNOPSIS .br .PP .PP \fC#include \fP .SS "Public Slots" .in +1c .ti -1c .RI "void \fBsetInterval\fP (double interval)" .br .ti -1c .RI "void \fBstop\fP ()" .br .in -1c .SS "Public Member Functions" .in +1c .ti -1c .RI "virtual \fB~QwtSamplingThread\fP ()" .br .ti -1c .RI "double \fBinterval\fP () const " .br .ti -1c .RI "double \fBelapsed\fP () const " .br .in -1c .SS "Protected Member Functions" .in +1c .ti -1c .RI "\fBQwtSamplingThread\fP (QObject *parent=NULL)" .br .ti -1c .RI "virtual void \fBrun\fP ()" .br .ti -1c .RI "virtual void \fBsample\fP (double elapsed)=0" .br .in -1c .SH "Detailed Description" .PP A thread collecting samples at regular intervals. Contiounous signals are converted into a discrete signal by collecting samples at regular intervals. A discrete signal can be displayed by a \fBQwtPlotSeriesItem\fP on a \fBQwtPlot\fP widget. .PP \fBQwtSamplingThread\fP starts a thread calling perodically \fBsample()\fP, to collect and store ( or emit ) a single sample. .PP \fBSee also:\fP .RS 4 \fBQwtPlotCurve\fP, \fBQwtPlotSeriesItem\fP .RE .PP .SH "Constructor & Destructor Documentation" .PP .SS "QwtSamplingThread::~QwtSamplingThread ()\fC [virtual]\fP" .PP Destructor. .SS "QwtSamplingThread::QwtSamplingThread (QObject *parent = \fCNULL\fP)\fC [explicit, protected]\fP" .PP Constructor. .SH "Member Function Documentation" .PP .SS "double QwtSamplingThread::elapsed () const"\fBReturns:\fP .RS 4 Time (in ms) since the thread was started .RE .PP \fBSee also:\fP .RS 4 QThread::start(), \fBrun()\fP .RE .PP .SS "double QwtSamplingThread::interval () const"\fBReturns:\fP .RS 4 Interval (in ms), between 2 calls of \fBsample()\fP .RE .PP \fBSee also:\fP .RS 4 \fBsetInterval()\fP .RE .PP .SS "void QwtSamplingThread::run ()\fC [protected, virtual]\fP"Loop collecting samples started from QThread::start() .PP \fBSee also:\fP .RS 4 \fBstop()\fP .RE .PP .SS "virtual void QwtSamplingThread::sample (doubleelapsed)\fC [protected, pure virtual]\fP"Collect a sample .PP \fBParameters:\fP .RS 4 \fIelapsed\fP Time since the thread was started in miliseconds .RE .PP .SS "void QwtSamplingThread::setInterval (doubleinterval)\fC [slot]\fP"Change the interval (in ms), when \fBsample()\fP is called. The default interval is 1000.0 ( = 1s ) .PP \fBParameters:\fP .RS 4 \fIinterval\fP Interval .RE .PP \fBSee also:\fP .RS 4 \fBinterval()\fP .RE .PP .SS "void QwtSamplingThread::stop ()\fC [slot]\fP"Terminate the collecting thread .PP \fBSee also:\fP .RS 4 QThread::start(), \fBrun()\fP .RE .PP .SH "Author" .PP Generated automatically by Doxygen for Qwt User's Guide from the source code.