TSignalBrowseBuffer Class

Header: Dew.Signal/SignalAnalysis.h · Cross-compiler
tObjectTMtxComponentTAnalysisTSignalTSignalBrowseBuffer

class TSignalBrowseBuffer : public TSignal;

Stores and buffers an overview of the incoming signal.

The size of the preview is maintained small enough to allow quick redraw on a chart. At start the component holds the actual signal up to the size of the SpanLimit. Once SpanLimit is exceeded an overview of the signal is computed and the original is discarded. From that point on, only the overview of the signal is kept. Once the overview exceeds the SpanLimit a new signal overview is computed from the existing overview and this procedure repeats in to infinity allowing virtually unlimited length of the overview. The component allow's limited zoom-in in to the overview, because intermediate results are discarded, but the data discarded will not exceed a factor of sqr(Increment). The default value for increment is 20 and 20^2 = 400. For a 2GB long recording this will result in 5MB of the in-memory buffer. On the resulting overview PixelDownSample method should be applied again. For true navigation use TSignalBrowse component.

The purpose of this component is to allow an overview of already recorded data to be displayed to the user. The IsOverview function returns true, if the component stores an overview, otherwise it is still buffering the original signal. This is important to know because the drawing method may differ substantially for signal and overview. The overview stores Max and Min values interleaved. The Max values form the upper and the Min values from the lower envelope.

Calling Update or Pull method will return pipeOK, if the Data property has been updated. It will return pipeStream, if there is not enough data buffered yet to update.

Constructors

NameDescription
TSignalBrowseBuffer (2)

Destructors

NameDescription
~TSignalBrowseBuffer

Properties

NameTypeDescription
ActiveboolSet active to false to suppress the propagation of the Pull request and the subsequent call to the Update method.
BandWidthdoubleReturn the bandwidth of the signal.
BandwidthHdoubleReturns the upper bandwidth edge of the signal.
BandwidthLdoubleReturns the lower bandwidth edge of the signal.
BlockAssignboolBlock streaming of specific properties when storing only a "template".
ChannelCountintGet or set the number of channels multiplexed in the data property.
ComplexboolSet this property to true, to request computation using complex numbers.
ContinuousboolIf True, the component will pass on the udpate request to the connected component.
DataTVec*Stores the result of the processing.
DtdoubleTime between two consecutive samples.
EditorActiveboolReturns True, if the component editor is displayed.
FloatPrecisionTMtxFloatPrecisionSet this property to request computation in 32bit/64bit precision with real/complex numbers.
FloatPrecisionLockboolSet this property to true to lock changes to FloatPrecision property.
HzResdoubleFrequency resolution obtained, if an FFT algorithm would be run on the data.
IncrementintDefines the increment at which the overview is sampled.
InputTSignal*
InputsTSignalCollection*
IsDoubleboolSet this property to false, to request computation in 32bit floating point precision, 64bit, if true.
ItemNumberintNumber to label the object when it is an item in the List.
LengthintGet or set the length of the signal in samples.
MarksTMarkList*Stores the time stamps and amplitude of selected samples.
MaxAmpltdoubleStores the maximum amplitude of the signal found by the MinMax method.
MaxXdoubleUse the MaxX property to store the time stamp (in seconds) of the right most sample.
MinAmpltdoubleStores the minimum amplitude of the signal found by the MinMax method.
MinXdoubleUse the MinX property to store the time stamp of the left-most sample.
MultiChannelboolSet MultiChannel to True, if Inputs property will be published, and Input property will remain hidden.
NameDewString
OnAfterUpdatetNotifyEventThe event is triggered after the call to the Update method.
OnBeforeUpdatetNotifyEventThe event is triggered just before the call to the Update method.
OnDisplayUpdatetNotifyEventThe event is triggered after the OnAfterUpdate event. Use this event to update any associated charts or graphs or result tables.
OnGetInputtNotifyEventIf the Input property is not assigned, the component will call OnGetInput.
OnNotifyUpdatetNotifyEventThe event is called after a call to InternalUpdate, OnAfterUpdate and OnDisplayUpdate from within the Update method.
OnParameterUpdatetNotifyEventThe event is triggered when ParamUpdate method is called. The ParamUpdate method is usually called by component editors when a value was changed by the user and the editor was "Live".
PipeDirtybool
PipeStateTPipeStateReturns the state of the pipe after the last update.
ReferenceTReferenceList*Stores a list of components that have to be notified, when this component is destroyed.
SamplingFrequencydoubleDefines the sampling frequency of the signal.
SamplingTimedoubleThe length of the signal in seconds.
SpanLimitintDefines the samples count at which an overview is computed.
SuspendNotifyUpdateboolSet this property to True, to prevent calling OnNotifyUpdate from the Update Method.
UsesInputsboolSet it to True to indicate, that valid signals will be connected to the Input or Inputs properties.

Methods

NameDescription
AllowStreaming
AppendAppends Sample to the end of the signal.
Assign
AssignTemplateAssign values of "template-like" published properties from Source.
CopyCopies signal Data and sampling frequency information.
CrestCompute the CREST parameter.
DetectChannelCount
EditorClassTo be overriden in descendanr classses.
get_CValues
get_Values
GetInput
GetInputs
InputsDirtyIf all Inputs[i] are dirty the function returns true.
InternalPullWhen called, the method will pass Update requests recursively to all connected objects.
InvalidateNotifies all connected components that this component has fresh data.
IsOverviewDefines, if the component already stores an overview.
LoadFromStreamLoad the component from Src stream.
LoadTemplateFromFileLoad a template from file.
LoadTemplateFromStreamLoad a template from stream.
MarksToStringsConvert marks to strings.
MinMaxFind minimum and maximum amplitude and store the result in the MinAmplt and MaxAmplt properties.
ParamUpdateThe method can be assigned to some other component even handler, as a notification that a parameter has changed and that Self should consider a recalculation.
PeakFind the maximum deviation of the signal from its mean value.
PipeResetRecursively processes all connected components backward and calls Reset method.
PullRequest recalculation of the entire chain of all connected components.
PullUntilEndCalls Pull until pipeEnd is returned.
ReferenceRemoved
ResetReset the buffering and overview.
SaveTemplateToFileSave template to file.
SaveTemplateToStreamSave template to stream.
SaveToStreamSave the component to Dst stream.
set_CValues
set_Values
SetComplex
SetFloatPrecision
SetInputs
SetIsDouble
SizeAssign the size of the signal from Src.
UpdateRequest recalculation of the data and place the result in Self.
UpdateNotifyCall this method only, if SuspendNotifyUpdate is True.
Values
ValuesToStringsConvert values to strings.

Operators

NameDescription
operator[]

Fields

NameTypeDescription
Tagintptr_t