Notify the encoder to return any pending packets
(&mut self)
| 283 | |
| 284 | /// Notify the encoder to return any pending packets |
| 285 | pub fn flush(&mut self) -> Result<EncodeFrames> { |
| 286 | call_vpx!(vpx_codec_encode( |
| 287 | &mut self.ctx, |
| 288 | ptr::null(), |
| 289 | -1, // PTS |
| 290 | 1, // Duration |
| 291 | 0, // Flags |
| 292 | VPX_DL_REALTIME as _, |
| 293 | )); |
| 294 | |
| 295 | Ok(EncodeFrames { |
| 296 | ctx: &mut self.ctx, |
| 297 | iter: ptr::null(), |
| 298 | }) |
| 299 | } |
| 300 | |
| 301 | #[inline] |
| 302 | pub fn create_video_frame( |