Browse Source

Verify video profile fallback without excluding a supported codec

master
evgeny 5 days ago
parent
commit
a5f8b8431d
  1. 6
      tools/chatgui-android/app/src/test/java/com/utun/chat/data/StreamVideoCodecTest.kt

6
tools/chatgui-android/app/src/test/java/com/utun/chat/data/StreamVideoCodecTest.kt

@ -36,4 +36,10 @@ class StreamVideoCodecTest {
val config = StreamCaptureConfig(base, StreamOrientation.LEFT, 4000000).withMode(hevc)
assertEquals(3000000, config.bitrate); assertEquals(StreamOrientation.LEFT, config.orientation)
}
@Test fun availableProfileIsUsedWhenPreferredProfileIsMissing() {
val preferred = StreamVideoCodec.H264.profile!!
assertEquals(preferred, StreamVideoCodec.H264.encoderProfile(intArrayOf(999, preferred)))
assertEquals(999, StreamVideoCodec.H264.encoderProfile(intArrayOf(999)))
assertNull(StreamVideoCodec.H266.encoderProfile(intArrayOf()))
}
}

Loading…
Cancel
Save