1pub mod level;
2pub use self::level::Level;
3
4pub mod flag;
5pub use self::flag::Flags;
6
7use ffi::*;
8use std::convert::TryInto;
9
10pub fn set_level(value: Level) {
11 unsafe { av_log_set_level(value.into()) }
12}
13
14pub fn get_level() -> Result<Level, &'static str> {
15 unsafe { av_log_get_level().try_into() }
16}
17
18pub fn set_flags(value: Flags) {
19 unsafe { av_log_set_flags(value.bits()) }
20}
21
22pub fn get_flags() -> Flags {
23 unsafe { Flags::from_bits_truncate(bits:av_log_get_flags()) }
24}
25