synthclone  0.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
synthclone::SampleCopier Class Reference

Utility class that copies Sample data from a SampleInputStream to a SampleOutputStream, emitting SampleCopier::copyProgress events as it goes along. More...

#include <synthclone/samplecopier.h>

Inheritance diagram for synthclone::SampleCopier:
Collaboration diagram for synthclone::SampleCopier:

Signals

void copyProgress (synthclone::SampleFrameCount framesCopied, synthclone::SampleFrameCount totalFrames)
 Emitted when frames are being copied. More...
 

Public Member Functions

 SampleCopier (QObject *parent=0)
 Constructs a new SampleCopier. More...
 
 ~SampleCopier ()
 Destroys the SampleCopier object. More...
 
SampleFrameCount copy (SampleInputStream &inputStream, SampleOutputStream &outputStream, SampleFrameCount frames)
 Copies data from a SampleInputStream to a SampleOutputStream. More...
 

Detailed Description

Utility class that copies Sample data from a SampleInputStream to a SampleOutputStream, emitting SampleCopier::copyProgress events as it goes along.

Constructor & Destructor Documentation

synthclone::SampleCopier::SampleCopier ( QObject *  parent = 0)
explicit

Constructs a new SampleCopier.

Parameters
parentThe parent object of the new SampleCopier object.
synthclone::SampleCopier::~SampleCopier ( )

Destroys the SampleCopier object.

Member Function Documentation

SampleFrameCount synthclone::SampleCopier::copy ( SampleInputStream inputStream,
SampleOutputStream outputStream,
SampleFrameCount  frames 
)

Copies data from a SampleInputStream to a SampleOutputStream.

Parameters
inputStreamThe SampleInputStream.
outputStreamThe SampleOutputStream.
framesThe maximum number of frames to copy. If the end of the SampleInputStream is reached before this amount of frames is copied, then the return value will be different than this parameter.
Returns
The total number of frames copied.
void synthclone::SampleCopier::copyProgress ( synthclone::SampleFrameCount  framesCopied,
synthclone::SampleFrameCount  totalFrames 
)
signal

Emitted when frames are being copied.

Parameters
framesCopiedThe number of frames copied thus far.
totalFramesThe maximum amount of frames that will be copied.

The documentation for this class was generated from the following file: