mirror of
https://github.com/Monibuca/engine.git
synced 2025-10-30 03:21:47 +08:00
1、当发布者离线时没有订阅者时,流的超时时间从1s改为10ms。
2、Track增加离线状态,当发布者离线时,Track状态改为离线状态,当发布者重新上线时,Track状态改为在线状态。 3、Track在恢复在线后,记录时间戳的差值,保持后续时间戳和之前的连续。 4、进一步优化订阅者读取音视频同步逻辑。
This commit is contained in:
@@ -282,9 +282,10 @@ func (p BytesPool) Get(size int) (item *ListItem[Buffer]) {
|
||||
type Pool[T any] List[T]
|
||||
|
||||
func (p *Pool[T]) Get() (item *ListItem[T]) {
|
||||
item = (*List[T])(p).PoolShift()
|
||||
if item == nil {
|
||||
item = &ListItem[T]{}
|
||||
if item = (*List[T])(p).PoolShift(); item == nil {
|
||||
item = &ListItem[T]{
|
||||
Pool: (*List[T])(p),
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user