Fix hevc decode error "Could not find ref with POC" (#9960)
1. Dropping frames can cause this error, reset encoder when this happens. 2. There are some logic error for clear video queue, because video queue message is not cleared. This need to be fixed. Signed-off-by: 21pages <sunboeasy@gmail.com>
This commit is contained in:
@@ -1146,9 +1146,13 @@ impl<T: InvokeUiSession> Remote<T> {
|
||||
.ok();
|
||||
} else {
|
||||
if let Some(video_queue) = video_queue_write.get_mut(&display) {
|
||||
video_queue.force_push(vf);
|
||||
if video_queue.force_push(vf).is_some() {
|
||||
while let Some(_) = video_queue.pop() {}
|
||||
self.handler.refresh_video(display as _);
|
||||
} else {
|
||||
self.video_sender.send(MediaData::VideoQueue(display)).ok();
|
||||
}
|
||||
}
|
||||
self.video_sender.send(MediaData::VideoQueue(display)).ok();
|
||||
}
|
||||
self.fps_control
|
||||
.last_active_time
|
||||
|
||||
Reference in New Issue
Block a user