fix: return stream on decoder flush
This commit is contained in:
parent
e8ae73f3a8
commit
8b6166f1db
@ -18,6 +18,7 @@ use log::debug;
|
|||||||
pub struct DecoderCodecContext {
|
pub struct DecoderCodecContext {
|
||||||
pub context: *mut AVCodecContext,
|
pub context: *mut AVCodecContext,
|
||||||
pub codec: *const AVCodec,
|
pub codec: *const AVCodec,
|
||||||
|
pub stream: *mut AVStream,
|
||||||
pub hw_config: *const AVCodecHWConfig,
|
pub hw_config: *const AVCodecHWConfig,
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -200,6 +201,7 @@ impl Decoder {
|
|||||||
Ok(e.insert(DecoderCodecContext {
|
Ok(e.insert(DecoderCodecContext {
|
||||||
context,
|
context,
|
||||||
codec,
|
codec,
|
||||||
|
stream,
|
||||||
hw_config,
|
hw_config,
|
||||||
}))
|
}))
|
||||||
} else {
|
} else {
|
||||||
@ -214,7 +216,7 @@ impl Decoder {
|
|||||||
pkgs.extend(Self::decode_pkt_internal(
|
pkgs.extend(Self::decode_pkt_internal(
|
||||||
ctx.context,
|
ctx.context,
|
||||||
ptr::null_mut(),
|
ptr::null_mut(),
|
||||||
ptr::null_mut(),
|
ctx.stream,
|
||||||
)?);
|
)?);
|
||||||
}
|
}
|
||||||
Ok(pkgs)
|
Ok(pkgs)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user