Skip to content

Commit

Permalink
Remove ffmpeg7
Browse files Browse the repository at this point in the history
  • Loading branch information
ldm0 committed Apr 5, 2024
1 parent 2fb10b2 commit 7b233c4
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
1 change: 0 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,3 @@ camino = "1.1.6"
# linking system ffmpeg as fallback.
link_system_ffmpeg = ["rusty_ffmpeg/link_system_ffmpeg"]
ffmpeg6 = ["rusty_ffmpeg/ffmpeg6"]
ffmpeg7 = ["rusty_ffmpeg/ffmpeg7"]
7 changes: 0 additions & 7 deletions src/avformat/avio.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,18 +102,11 @@ impl AVIOContextCustom {
let opaque = unsafe { (opaque as *mut Opaque).as_mut() }.unwrap();
opaque.read_packet.as_mut().unwrap()(&mut opaque.data, buf)
}
#[cfg(not(feature = "ffmpeg7"))]
unsafe extern "C" fn write_c(opaque: *mut c_void, data: *mut u8, len: i32) -> i32 {
let buf = unsafe { slice::from_raw_parts(data, len as usize) };
let opaque = unsafe { (opaque as *mut Opaque).as_mut() }.unwrap();
opaque.write_packet.as_mut().unwrap()(&mut opaque.data, buf)
}
#[cfg(feature = "ffmpeg7")]
unsafe extern "C" fn write_c(opaque: *mut c_void, data: *const u8, len: i32) -> i32 {
let buf = unsafe { slice::from_raw_parts(data, len as usize) };
let opaque = unsafe { (opaque as *mut Opaque).as_mut() }.unwrap();
opaque.write_packet.as_mut().unwrap()(&mut opaque.data, buf)
}
unsafe extern "C" fn seek_c(opaque: *mut c_void, offset: i64, whence: i32) -> i64 {
let opaque = unsafe { (opaque as *mut Opaque).as_mut() }.unwrap();
opaque.seek.as_mut().unwrap()(&mut opaque.data, offset, whence)
Expand Down

0 comments on commit 7b233c4

Please sign in to comment.