Audacity 3.2.0
Public Member Functions | List of all members
NiceAudioSegment Class Referencefinal

#include <MockAudioSegmentFactory.h>

Inheritance diagram for NiceAudioSegment:
[legend]
Collaboration diagram for NiceAudioSegment:
[legend]

Public Member Functions

size_t GetFloats (float *const *, size_t numSamples) override
 Fills buffers with as many as numSamples or the number of remaining samples, whichever is smaller. More...
 
size_t NChannels () const override
 The number of channels in the segment. More...
 
bool Empty () const override
 Whether the segment has no more samples to provide. More...
 
- Public Member Functions inherited from AudioSegment
virtual ~AudioSegment ()
 
virtual size_t GetFloats (float *const *buffers, size_t numSamples)=0
 Fills buffers with as many as numSamples or the number of remaining samples, whichever is smaller. More...
 
virtual size_t NChannels () const =0
 The number of channels in the segment. More...
 
virtual bool Empty () const =0
 Whether the segment has no more samples to provide. More...
 

Detailed Description


Audacity: A Digital Audio Editor

MockAudioSegmentFactory.h

Matthieu Hodgkinson

Definition at line 16 of file MockAudioSegmentFactory.h.

Member Function Documentation

◆ Empty()

bool NiceAudioSegment::Empty ( ) const
inlineoverridevirtual

Whether the segment has no more samples to provide.

Implements AudioSegment.

Definition at line 29 of file MockAudioSegmentFactory.h.

30 {
31 return false;
32 }

◆ GetFloats()

size_t NiceAudioSegment::GetFloats ( float *const *  buffers,
size_t  numSamples 
)
inlineoverridevirtual

Fills buffers with as many as numSamples or the number of remaining samples, whichever is smaller.

Parameters
buffersPointers to buffers, one for each channel.
numSamplesThe max. number of samples to write to each buffer.
Returns
The number of samples actually provided in each buffer.

Implements AudioSegment.

Definition at line 19 of file MockAudioSegmentFactory.h.

20 {
21 return numSamples;
22 }

◆ NChannels()

size_t NiceAudioSegment::NChannels ( ) const
inlineoverridevirtual

The number of channels in the segment.

Implements AudioSegment.

Definition at line 24 of file MockAudioSegmentFactory.h.

25 {
26 return 1u;
27 }

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