1 | #[macro_use ] |
2 | pub mod dictionary; |
3 | pub mod channel_layout; |
4 | pub mod chroma; |
5 | pub mod color; |
6 | pub mod error; |
7 | pub mod format; |
8 | pub mod frame; |
9 | pub mod interrupt; |
10 | pub mod log; |
11 | pub mod mathematics; |
12 | pub mod media; |
13 | pub mod option; |
14 | pub mod picture; |
15 | pub mod range; |
16 | pub mod rational; |
17 | pub mod time; |
18 | |
19 | use std::ffi::CStr; |
20 | use std::str::from_utf8_unchecked; |
21 | |
22 | use ffi::*; |
23 | |
24 | #[inline (always)] |
25 | pub fn version() -> u32 { |
26 | unsafe { avutil_version() } |
27 | } |
28 | |
29 | #[inline (always)] |
30 | pub fn configuration() -> &'static str { |
31 | unsafe { from_utf8_unchecked(CStr::from_ptr(avutil_configuration()).to_bytes()) } |
32 | } |
33 | |
34 | #[inline (always)] |
35 | pub fn license() -> &'static str { |
36 | unsafe { from_utf8_unchecked(CStr::from_ptr(avutil_license()).to_bytes()) } |
37 | } |
38 | |