mirror of
https://github.com/encounter/rust-ffmpeg-zmwangx.git
synced 2026-07-10 21:18:40 -07:00
Fix building previous versions
This commit is contained in:
@@ -102,7 +102,9 @@ impl Context {
|
||||
(*self.as_mut_ptr()).thread_type = config.kind.into();
|
||||
(*self.as_mut_ptr()).thread_count = config.count as c_int;
|
||||
#[cfg(not(feature = "ffmpeg_6_0"))]
|
||||
{ (*self.as_mut_ptr()).thread_safe_callbacks = if config.safe { 1 } else { 0 }; }
|
||||
{
|
||||
(*self.as_mut_ptr()).thread_safe_callbacks = if config.safe { 1 } else { 0 };
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+12
-2
@@ -47,7 +47,12 @@ impl Filter {
|
||||
if ptr.is_null() {
|
||||
None
|
||||
} else {
|
||||
Some(PadIter::new((*self.as_ptr()).inputs, (*self.as_ptr()).nb_inputs as isize))
|
||||
#[cfg(not(feature = "ffmpeg_6_0"))]
|
||||
let nb_inputs = avfilter_pad_count((*self.as_ptr()).inputs) as isize;
|
||||
#[cfg(feature = "ffmpeg_6_0")]
|
||||
let nb_inputs = (*self.as_ptr()).nb_inputs as isize;
|
||||
|
||||
Some(PadIter::new((*self.as_ptr()).inputs, nb_inputs))
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -59,7 +64,12 @@ impl Filter {
|
||||
if ptr.is_null() {
|
||||
None
|
||||
} else {
|
||||
Some(PadIter::new((*self.as_ptr()).outputs, (*self.as_ptr()).nb_outputs as isize))
|
||||
#[cfg(not(feature = "ffmpeg_6_0"))]
|
||||
let nb_outputs = avfilter_pad_count((*self.as_ptr()).outputs) as isize;
|
||||
#[cfg(feature = "ffmpeg_6_0")]
|
||||
let nb_outputs = (*self.as_ptr()).nb_outputs as isize;
|
||||
|
||||
Some(PadIter::new((*self.as_ptr()).outputs, nb_outputs))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user