Beatmup
Beatmup::Audio::Android::SLESPlayback Class Reference

OpenSL ES Android playback. More...

#include <sles_playback.h>

Inheritance diagram for Beatmup::Audio::Android::SLESPlayback:
Beatmup::Audio::BasicRealtimePlayback Beatmup::Audio::AbstractPlayback Beatmup::AbstractTask Beatmup::Object

Public Member Functions

 SLESPlayback ()
 
 ~SLESPlayback ()
 
void initialize (Mode mode)
 Initializes the playback setting its main parameters. More...
 
void start ()
 Starts playback. More...
 
void stop ()
 Stops playback. More...
 
- Public Member Functions inherited from Beatmup::Audio::BasicRealtimePlayback
virtual ~BasicRealtimePlayback ()
 
bool process (TaskThread &thread)
 Executes the task on CPU within a given thread. More...
 
void bufferQueueCallbackFunc ()
 
void pullBuffer (sample8 *buffer, dtime numFrames)
 Called in pulling output mode to send data to output. More...
 
- Public Member Functions inherited from Beatmup::Audio::AbstractPlayback
ThreadIndex getMaxThreads () const
 Gives the upper limint on the number of threads the task may be performed by. More...
 
void beforeProcessing (ThreadIndex threadCount, ProcessingTarget target, GraphicPipeline *gpu)
 Instruction called before the task is executed. More...
 
void setSource (Source *source)
 Specifies a Source to sample. More...
 
SourcegetSource () const
 Returns the signal source to sample. More...
 
- Public Member Functions inherited from Beatmup::AbstractTask
virtual void afterProcessing (ThreadIndex threadCount, GraphicPipeline *gpu, bool aborted)
 Instruction called after the task is executed. More...
 
virtual bool processOnGPU (GraphicPipeline &gpu, TaskThread &thread)
 Executes the task on GPU. More...
 
virtual TaskDeviceRequirement getUsedDevices () const
 Communicates devices (CPU and/or GPU) the task is run on. More...
 
- Public Member Functions inherited from Beatmup::Object
virtual ~Object ()
 

Protected Member Functions

void pushBuffer (sample8 *buffer, int bufferIndex)
 Pushes some data to the output. More...
 
- Protected Member Functions inherited from Beatmup::Audio::BasicRealtimePlayback
 BasicRealtimePlayback (OutputMode)
 
virtual sample8createBuffer (const AbstractPlayback::Mode &mode) const
 Creates an atomic playing buffer. More...
 
virtual void freeBuffer (sample8 *buffer) const
 Frees an atomic playing buffer. More...
 
- Protected Member Functions inherited from Beatmup::Audio::AbstractPlayback
 AbstractPlayback ()
 
void advanceTime ()
 Moves time pointer one buffer forward. More...
 

Protected Attributes

SLESBackend * backend
 
- Protected Attributes inherited from Beatmup::Audio::BasicRealtimePlayback
msize bufferSize
 size of each buffer in bytes More...
 
- Protected Attributes inherited from Beatmup::Audio::AbstractPlayback
Mode mode
 
Sourcesource
 
dtime clock
 

Additional Inherited Members

- Public Types inherited from Beatmup::AbstractTask
enum class  TaskDeviceRequirement { CPU_ONLY , GPU_OR_CPU , GPU_ONLY }
 Specifies which device (CPU and/or GPU) is used to run the task. More...
 
- Static Public Member Functions inherited from Beatmup::AbstractTask
static ThreadIndex validThreadCount (int number)
 Valid thread count from a given integer value. More...
 
- Protected Types inherited from Beatmup::Audio::BasicRealtimePlayback
enum class  OutputMode { PULL , PUSH }
 Specifies how the output audio signal is handled by the audio backend. More...
 

Detailed Description

OpenSL ES Android playback.

Definition at line 29 of file sles_playback.h.

Constructor & Destructor Documentation

◆ SLESPlayback()

Beatmup::Audio::Android::SLESPlayback::SLESPlayback ( )

◆ ~SLESPlayback()

Beatmup::Audio::Android::SLESPlayback::~SLESPlayback ( )

Member Function Documentation

◆ pushBuffer()

void Beatmup::Audio::Android::SLESPlayback::pushBuffer ( sample8 buffer,
int  bufferIndex 
)
protectedvirtual

Pushes some data to the output.

Reimplemented from Beatmup::Audio::BasicRealtimePlayback.

◆ initialize()

void Beatmup::Audio::Android::SLESPlayback::initialize ( Mode  mode)
virtual

Initializes the playback setting its main parameters.

Reimplemented from Beatmup::Audio::BasicRealtimePlayback.

◆ start()

void Beatmup::Audio::Android::SLESPlayback::start ( )
virtual

Starts playback.

Reimplemented from Beatmup::Audio::BasicRealtimePlayback.

◆ stop()

void Beatmup::Audio::Android::SLESPlayback::stop ( )
virtual

Stops playback.

Implements Beatmup::Audio::BasicRealtimePlayback.

Member Data Documentation

◆ backend

SLESBackend* Beatmup::Audio::Android::SLESPlayback::backend
protected

Definition at line 33 of file sles_playback.h.


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