Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/cyan-cups-wave.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"client-sdk-android": patch
---

Add AudioPresets and increase default audio max bitrate to 48kbps
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
/.idea/deploymentTargetDropDown.xml
/.idea/misc.xml
/.idea/gradle.xml
/.idea/runConfigurations.xml
/.idea/deploymentTargetSelector.xml
.DS_Store
/build
/captures
Expand All @@ -21,4 +23,4 @@
node_modules/
npm-debug.log
yarn-debug.log
yarn-error.log
yarn-error.log
Original file line number Diff line number Diff line change
Expand Up @@ -1107,11 +1107,22 @@ abstract class BaseAudioTrackPublishOptions {
abstract val red: Boolean
}

enum class AudioPresets(
val maxBitrate: Int,
) {
TELEPHONE(12_000),
SPEECH(24_000),
MUSIC(48_000),
MUSIC_STEREO(64_000),
MUSIC_HIGH_QUALITY(96_000),
MUSIC_HIGH_QUALITY_STEREO(128_000)
}

/**
* Default options for publishing an audio track.
*/
data class AudioTrackPublishDefaults(
override val audioBitrate: Int? = 20_000,
override val audioBitrate: Int? = AudioPresets.MUSIC.maxBitrate,
override val dtx: Boolean = true,
override val red: Boolean = true,
) : BaseAudioTrackPublishOptions()
Expand Down
Loading