Files
ffmpeg-the-third/src/codec/mod.rs
2015-05-12 03:33:13 +02:00

23 lines
380 B
Rust

use std::ffi::CStr;
use std::str::from_utf8_unchecked;
use ffi::*;
pub fn version() -> u32 {
unsafe {
avcodec_version()
}
}
pub fn configuration() -> &'static str {
unsafe {
from_utf8_unchecked(CStr::from_ptr(avcodec_configuration()).to_bytes())
}
}
pub fn license() -> &'static str {
unsafe {
from_utf8_unchecked(CStr::from_ptr(avcodec_license()).to_bytes())
}
}