MythTV  master
Macros | Functions | Variables
audiooutputopensles.cpp File Reference
#include <iostream>
#include <dlfcn.h>
#include <QtGlobal>
#include <QJniEnvironment>
#include <QJniObject>
#include "libmythbase/mythlogging.h"
#include "audiooutputopensles.h"
Include dependency graph for audiooutputopensles.cpp:

Go to the source code of this file.

Macros

#define QAndroidJniEnvironment   QJniEnvironment
 
#define QAndroidJniObject   QJniObject
 
#define LOC   QString("AOSLES: ")
 
#define OPENSLES_BUFFERS   10 /* maximum number of buffers */
 
#define POSITIONUPDATEPERIOD   40
 
#define CHECK_OPENSL_ERROR(msg)
 
#define CHECK_OPENSL_START_ERROR(msg)
 
#define Destroy(a)   (*(a))->Destroy(a);
 
#define SetPlayState(a, b)   (*(a))->SetPlayState(a, b)
 
#define RegisterCallback(a, b, c)   (*(a))->RegisterCallback(a, b, c)
 
#define GetInterface(a, b, c)   (*(a))->GetInterface(a, b, c)
 
#define Realize(a, b)   (*(a))->Realize(a, b)
 
#define CreateOutputMix(a, b, c, d, e)   (*(a))->CreateOutputMix(a, b, c, d, e)
 
#define CreateAudioPlayer(a, b, c, d, e, f, g)   (*(a))->CreateAudioPlayer(a, b, c, d, e, f, g)
 
#define Enqueue(a, b, c)   (*(a))->Enqueue(a, b, c)
 
#define Clear(a)   (*(a))->Clear(a)
 
#define GetState(a, b)   (*(a))->GetState(a, b)
 
#define SetPositionUpdatePeriod(a, b)   (*(a))->SetPositionUpdatePeriod(a, b)
 
#define SetVolumeLevel(a, b)   (*(a))->SetVolumeLevel(a, b)
 
#define GetVolumeLevel(a, b)   (*(a))->GetVolumeLevel(a, b)
 
#define SetMute(a, b)   (*(a))->SetMute(a, b)
 
#define OPENSL_DLSYM(dest, name)
 

Functions

int GetNativeOutputSampleRate (void)
 

Variables

static constexpr std::chrono::milliseconds OPENSLES_BUFLEN { 10ms }
 

Macro Definition Documentation

◆ QAndroidJniEnvironment

#define QAndroidJniEnvironment   QJniEnvironment

Definition at line 11 of file audiooutputopensles.cpp.

◆ QAndroidJniObject

#define QAndroidJniObject   QJniObject

Definition at line 12 of file audiooutputopensles.cpp.

◆ LOC

#define LOC   QString("AOSLES: ")

Definition at line 19 of file audiooutputopensles.cpp.

◆ OPENSLES_BUFFERS

#define OPENSLES_BUFFERS   10 /* maximum number of buffers */

Definition at line 21 of file audiooutputopensles.cpp.

◆ POSITIONUPDATEPERIOD

#define POSITIONUPDATEPERIOD   40

Definition at line 25 of file audiooutputopensles.cpp.

◆ CHECK_OPENSL_ERROR

#define CHECK_OPENSL_ERROR (   msg)
Value:
if (result != SL_RESULT_SUCCESS) \
{ \
LOG(VB_GENERAL, LOG_ERR, LOC + QString("Open Error: (%1)").arg(result)); \
Close(); \
return false; \
}

Definition at line 28 of file audiooutputopensles.cpp.

◆ CHECK_OPENSL_START_ERROR

#define CHECK_OPENSL_START_ERROR (   msg)
Value:
if (result != SL_RESULT_SUCCESS) \
{ \
LOG(VB_GENERAL, LOG_ERR, LOC + QString("Start Error: (%1)").arg(result)); \
Stop(); \
return false; \
}

Definition at line 36 of file audiooutputopensles.cpp.

◆ Destroy

#define Destroy (   a)    (*(a))->Destroy(a);

Definition at line 45 of file audiooutputopensles.cpp.

◆ SetPlayState

#define SetPlayState (   a,
 
)    (*(a))->SetPlayState(a, b)

Definition at line 46 of file audiooutputopensles.cpp.

◆ RegisterCallback

#define RegisterCallback (   a,
  b,
 
)    (*(a))->RegisterCallback(a, b, c)

Definition at line 47 of file audiooutputopensles.cpp.

◆ GetInterface

#define GetInterface (   a,
  b,
 
)    (*(a))->GetInterface(a, b, c)

Definition at line 48 of file audiooutputopensles.cpp.

◆ Realize

#define Realize (   a,
 
)    (*(a))->Realize(a, b)

Definition at line 49 of file audiooutputopensles.cpp.

◆ CreateOutputMix

#define CreateOutputMix (   a,
  b,
  c,
  d,
 
)    (*(a))->CreateOutputMix(a, b, c, d, e)

Definition at line 50 of file audiooutputopensles.cpp.

◆ CreateAudioPlayer

#define CreateAudioPlayer (   a,
  b,
  c,
  d,
  e,
  f,
 
)    (*(a))->CreateAudioPlayer(a, b, c, d, e, f, g)

Definition at line 51 of file audiooutputopensles.cpp.

◆ Enqueue

#define Enqueue (   a,
  b,
 
)    (*(a))->Enqueue(a, b, c)

Definition at line 53 of file audiooutputopensles.cpp.

◆ Clear

#define Clear (   a)    (*(a))->Clear(a)

Definition at line 54 of file audiooutputopensles.cpp.

◆ GetState

#define GetState (   a,
 
)    (*(a))->GetState(a, b)

Definition at line 55 of file audiooutputopensles.cpp.

◆ SetPositionUpdatePeriod

#define SetPositionUpdatePeriod (   a,
 
)    (*(a))->SetPositionUpdatePeriod(a, b)

Definition at line 56 of file audiooutputopensles.cpp.

◆ SetVolumeLevel

#define SetVolumeLevel (   a,
 
)    (*(a))->SetVolumeLevel(a, b)

Definition at line 57 of file audiooutputopensles.cpp.

◆ GetVolumeLevel

#define GetVolumeLevel (   a,
 
)    (*(a))->GetVolumeLevel(a, b)

Definition at line 58 of file audiooutputopensles.cpp.

◆ SetMute

#define SetMute (   a,
 
)    (*(a))->SetMute(a, b)

Definition at line 59 of file audiooutputopensles.cpp.

◆ OPENSL_DLSYM

#define OPENSL_DLSYM (   dest,
  name 
)
Value:
do { \
const SLInterfaceID *sym = (const SLInterfaceID *)dlsym(m_so_handle, "SL_IID_" name); \
if (sym == nullptr) \
{ \
LOG(VB_GENERAL, LOG_ERR, "AOOSLES Error: Failed to load symbol SL_IID_" name); \
Close(); \
return false; \
} \
(dest) = *sym; \
} while(0)

Function Documentation

◆ GetNativeOutputSampleRate()

int GetNativeOutputSampleRate ( void  )

Variable Documentation

◆ OPENSLES_BUFLEN

constexpr std::chrono::milliseconds OPENSLES_BUFLEN { 10ms }
staticconstexpr
build_compdb.dest
dest
Definition: build_compdb.py:9
dlsym
#define dlsym(x, y)
Definition: compat.h:156
LOC
#define LOC
Definition: audiooutputopensles.cpp:19