Skip to content

Commit

Permalink
Minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
natario1 committed Aug 11, 2024
1 parent 533fdae commit 4520ae6
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 26 deletions.
2 changes: 2 additions & 0 deletions .idea/.gitignore

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 0 additions & 10 deletions .idea/deploymentTargetDropDown.xml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -69,21 +69,21 @@ class IssuesTests {
transcode {
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(input("0.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 2000_000L, 3000_000L))
addDataSource(input("1.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 4000_000L, 5000_000L))
addDataSource(input("2.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 6000_000L, 7000_000L))
addDataSource(input("3.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 8000_000L, 9000_000L))
addDataSource(input("4.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 10000_000L, 11000_000L))
addDataSource(input("5.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 12000_000L, 13000_000L))
addDataSource(input("6.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 14000_000L, 15000_000L))
addDataSource(input("7.amr"))
addDataSource(ClipDataSource(input("main.mp3"), 0L, 1000_000L))
addDataSource(ClipDataSource(input("main.mp3"), 16000_000L, 17000_000L))
addDataSource(input("8.amr"))
}
Unit
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ internal interface AudioRemixer {
companion object {
internal operator fun get(inputChannels: Int, outputChannels: Int): AudioRemixer = when {
inputChannels !in setOf(1, 2) -> error("Input channel count not supported: $inputChannels")
outputChannels !in setOf(1, 2) -> error("Input channel count not supported: $inputChannels")
outputChannels !in setOf(1, 2) -> error("Output channel count not supported: $inputChannels")
inputChannels < outputChannels -> UpMixAudioRemixer()
inputChannels > outputChannels -> DownMixAudioRemixer()
else -> PassThroughAudioRemixer()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ internal class DefaultTranscodeEngine(
}

private fun createPipeline(
type: TrackType,
index: Int,
status: TrackStatus,
outputFormat: MediaFormat
type: TrackType,
index: Int,
status: TrackStatus,
outputFormat: MediaFormat
): Pipeline {
log.w("createPipeline($type, $index, $status), format=$outputFormat")
val interpolator = timer.interpolator(type, index)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,7 @@ public void setOrientation(int rotation) {

@Override
public void setLocation(double latitude, double longitude) {
if (Build.VERSION.SDK_INT >= 19) {
mMuxer.setLocation((float) latitude, (float) longitude);
}
mMuxer.setLocation((float) latitude, (float) longitude);
}

@Override
Expand Down

0 comments on commit 4520ae6

Please sign in to comment.