mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-06-03 05:49:37 +00:00
video: Return NotNegotiated if setting the output state fails
This commit is contained in:
parent
7dfe7c09bd
commit
0868bce87d
|
@ -241,7 +241,7 @@ impl<O: IsA<VideoDecoder>> VideoDecoderExtManual for O {
|
|||
};
|
||||
|
||||
if state.is_null() {
|
||||
Err(gst::FlowError::Error)
|
||||
Err(gst::FlowError::NotNegotiated)
|
||||
} else {
|
||||
unsafe { Ok(VideoCodecState::<InNegotiation>::new(state, self.as_ref())) }
|
||||
}
|
||||
|
@ -272,7 +272,7 @@ impl<O: IsA<VideoDecoder>> VideoDecoderExtManual for O {
|
|||
};
|
||||
|
||||
if state.is_null() {
|
||||
Err(gst::FlowError::Error)
|
||||
Err(gst::FlowError::NotNegotiated)
|
||||
} else {
|
||||
unsafe { Ok(VideoCodecState::<InNegotiation>::new(state, self.as_ref())) }
|
||||
}
|
||||
|
|
|
@ -190,7 +190,7 @@ impl<O: IsA<VideoEncoder>> VideoEncoderExtManual for O {
|
|||
};
|
||||
|
||||
if state.is_null() {
|
||||
Err(gst::FlowError::Error)
|
||||
Err(gst::FlowError::NotNegotiated)
|
||||
} else {
|
||||
unsafe { Ok(VideoCodecState::<InNegotiation>::new(state, self.as_ref())) }
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue