Arduino A2DP

Public Member Functions | List of all members
OneChannel8BitSoundData Class Reference

1 Channel data is provided as signed int8 values. More...

`#include <SoundData.h>`

Inheritance diagram for OneChannel8BitSoundData:

## Public Member Functions
| OneChannel8BitSoundData (bool loop=false, ChannelInfo channelInfo=Both)
| OneChannel8BitSoundData (int8_t *data, int32_t len, bool loop=false, ChannelInfo channelInfo=Both)
bool | doLoop ()
int32_t | get2ChannelData (int32_t pos, int32_t len, uint8_t *data)
int32_t | getData (int32_t pos, Frame &frame)
int32_t | getData (int32_t pos, int32_t len, int8_t *data)
void | setData (int8_t *data, int32_t len)
void | setDataRaw (uint8_t *data, int32_t len)
void | setLoop (bool loop)

## Detailed Description

1 Channel data is provided as signed int8 values.

Author
  Phil Schatzmann

Copyright
  Apache License Version 2

## Constructor & Destructor Documentation

## ◆ OneChannel8BitSoundData()

OneChannel8BitSoundData::OneChannel8BitSoundData | ( | int8_t * | data,
|  | int32_t | len,
|  | bool | loop = `false`,
|  | ChannelInfo | channelInfo = `Both`
| ) |  |

Constructor for data conisting only of one Channel

## Member Function Documentation

## ◆ doLoop()

bool SoundData::doLoop | ( |  | ) |
| inherited

Automatic restart playing on end

## ◆ get2ChannelData()

int32_t OneChannel8BitSoundData::get2ChannelData | ( | int32_t | pos,
|  | int32_t | len,
|  | uint8_t * | data
| ) |  |
| virtual

Data is stored in one channel with int16_t data. However we need to provide 2 channels. pos, len and result are in bytes.

Implements SoundData.

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

- src/SoundData.h
- src/SoundData.cpp