fix:跳转帧间延迟间隔、缓冲区大小

This commit is contained in:
liyi 2025-07-09 11:33:03 +08:00
parent bedb692484
commit a451a2288e

View File

@ -49,7 +49,7 @@ class VideoDecoder(
companion object {
private const val TAG = "VideoDecoder"
private const val TIMEOUT_US = 10000L
private const val BUFFER_QUEUE_CAPACITY = 100 // 增大输入缓冲区容量
private const val BUFFER_QUEUE_CAPACITY = 50 // 增大输入缓冲区容量
}
// region 成员变量定义
@ -99,7 +99,7 @@ class VideoDecoder(
// 1. 新增成员变量
@Volatile
private var latestRenderedTimestampMs: Long? = null
private val MAX_ALLOWED_DELAY_MS = 750 // 最大允许延迟,单位毫秒
private val MAX_ALLOWED_DELAY_MS = 1000 // 最大允许延迟,单位毫秒
@Volatile
private var timestampBaseMs: Long? = null
@Volatile