Skip to content

Commit e0ea2b0

Browse files
committed
Export all picked up things to
1 parent ed011e5 commit e0ea2b0

File tree

2 files changed

+5
-7
lines changed

2 files changed

+5
-7
lines changed

examples/slice/main.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
//! Port from Original code: https://github.com/leandromoreira/ffmpeg-libav-tutorial/blob/master/0_hello_world.c
22
//! Since this is a ported code, many warnings will emits.
33
#![allow(non_snake_case, non_camel_case_types, non_upper_case_globals)]
4-
use rusty_ffmpeg::{
5-
avutil::error::{AVERROR, AVERROR_EOF},
6-
ffi,
7-
};
4+
use rusty_ffmpeg::ffi;
85

96
use std::{
107
ffi::{CStr, CString},
@@ -167,7 +164,7 @@ fn decode_packet(
167164

168165
while response >= 0 {
169166
let response = unsafe { ffi::avcodec_receive_frame(pCodecContext, pFrame) };
170-
if response == AVERROR(ffi::EAGAIN as i32) || response == AVERROR_EOF {
167+
if response == ffi::AVERROR(ffi::EAGAIN as i32) || response == ffi::AVERROR_EOF {
171168
break;
172169
} else if response < 0 {
173170
return Err(String::from(

src/lib.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
mod avutil;
2+
13
#[allow(
24
non_snake_case,
35
non_camel_case_types,
@@ -6,7 +8,6 @@
68
clippy::all
79
)]
810
pub mod ffi {
11+
pub use crate::avutil::{_avutil::*, common::*, error::*, pixfmt::*, rational::*};
912
include!(concat!(env!("OUT_DIR"), "/binding.rs"));
1013
}
11-
12-
pub mod avutil;

0 commit comments

Comments
 (0)