Zhiming Wang
1d0d42d81a
filter: test_paditer: register_all before testing the overlay filter
...
avfilter_register_all required on FFmpeg <4 before avfilter_get_by_name can
find the builtin filters.
2020-07-26 12:42:57 +08:00
Zhiming Wang
e947bc5606
Fix clippy::transmute_ptr_to_ptr
2020-07-26 12:26:20 +08:00
Zhiming Wang
c9c6031a53
Fix clippy::ptr_offset_with_cast
2020-07-26 01:01:21 +08:00
Zhiming Wang
73b66ea438
Fix clippy::redundant_field_names
2020-07-26 01:01:13 +08:00
Zhiming Wang
ceb1a7ea7c
Allow clippy::{missing_safety_doc, module_inception, too_many_arguments}
2020-07-26 01:00:54 +08:00
Zhiming Wang
6639f02b80
Fix filter::filter::PadIter to actually iterate
...
Bug caught by clippy:
error: offset calculation on zero-sized value
--> src/filter/filter.rs:98:33
|
98 | let pad = Pad::wrap(self.ptr.offset(self.cur));
| ^^^^^^^^^^^^^^^^^^^^^^^^^
|
= note: `#[deny(clippy::zst_offset)]` on by default
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zst_offset
The problem is that `AVFilterPad` is zero-sized:
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct AVFilterPad {
_unused: [u8; 0],
}
which is in turn due to `AVFilterPad` being an opaque type in
`libavfilter/avfilter.h`:
typedef struct AVFilterContext AVFilterContext;
typedef struct AVFilterLink AVFilterLink;
typedef struct AVFilterPad AVFilterPad;
typedef struct AVFilterFormats AVFilterFormats;
Doing pointer arithmetic on an opaque (incomplete) type doesn't work. We have
to use the proper FFI calls to obtain info on individual pads. The API has to
be tweaked a bit; hopefully it doesn't break user programs (if it does it
should only break bugged ones...).
Fixes #20 .
2020-07-25 23:34:27 +08:00
Zhiming Wang
ec7fed0333
Bump to v4.3.2
2020-07-24 22:23:22 +08:00
Tim Hellhake
65be233a12
Add Raspberry Pi compatibility
...
Signed-off-by: Zhiming Wang <i@zhimingwang.org>
2020-07-24 22:18:58 +08:00
Zhiming Wang
d4c64458db
Fix ARM compatibility
...
Tested to successfully compile in an arm64v8/debian:buster container (running
on an x64 box through qemu-aarch64). Should work on armhf too, though haven't
tested yet.
2020-07-24 20:27:58 +08:00
Zhiming Wang
c7145dd9cb
Bump to v4.3.1
2020-07-23 10:11:42 +08:00
Zhiming Wang
48bca3e610
examples/avi-to-ppm: fix frame indexing
2020-07-23 10:07:07 +08:00
Zhiming Wang
ba2caf9d13
software::scaling::context::run: fix srcSliceH argument
...
Output height was erroneously used as the srcSliceH argument to
sws_scale, causing the output frame to be partially blank when scaling
down or outright erroring when scaling up. See documentation of sws_scale:
https://www.ffmpeg.org/doxygen/4.0/group__libsws.html#gae531c9754c9205d90ad6800015046d74
Fixes #18 .
2020-07-23 10:01:19 +08:00
Zhiming Wang
3e9c83ec4e
examples/avi-to-ppm: allow more than one stream in the input file
...
Only decode packets in the best video stream.
See #17 .
2020-07-22 20:45:50 +08:00
Zhiming Wang
5d74df996d
README: add link to wiki and set expectations
2020-07-21 23:35:19 +08:00
Zhiming Wang
3325f7ee31
Cargo.toml: drop dependencies.ffmpeg-sys-next.path
...
This is really inconvenient for people who don't need to modify
rust-ffmpeg-sys.
To develop the two repos together just put
paths = ['../rust-ffmpeg-sys']
in .cargo/config.toml.
2020-07-21 18:09:19 +08:00
Zhiming Wang
48271cc587
Bump to v4.3.0
2020-06-17 01:56:47 +08:00
Zhiming Wang
f050471dfe
README: update compat table
2020-06-17 01:56:30 +08:00
Zhiming Wang
15c87a7837
Add FFmpeg 4.3 specific code
2020-06-17 01:51:38 +08:00
Zhiming Wang
65d91df487
Bump to v4.2.2
2020-06-11 23:21:25 +08:00
Zhiming Wang
e6c028ac42
README: clarify support situation for FFmpeg <4
...
Pretty sure only 3.4.x works, and I have no intention of fixing things further
back.
2020-06-11 23:20:21 +08:00
Zhiming Wang
036c0e5b42
Fix duplicate enum variant issues for FFmpeg 3.4
2020-06-11 23:18:47 +08:00
abhijeetbhagat
3df1a1c209
Add example to convert AVI frame to RGB24 frame
2020-06-10 00:01:33 +05:30
Zhiming Wang
5a63bbff5b
Bump to v4.2.1
2020-06-02 19:04:02 +08:00
Zhiming Wang
97a43cf34a
Drop resampling from default features
...
lavr has been deprecated since FFmpeg 4.0.
Closes #3 .
2020-06-02 19:03:13 +08:00
Zhiming Wang
83150c968c
Bump to v4.2.0
2020-06-02 18:50:01 +08:00
Zhiming Wang
e7f778b471
Update README with more info on versioning
2020-06-02 18:49:37 +08:00
Zhiming Wang
307f52c002
Reformat code with latest cargo fmt
2020-06-02 17:54:31 +08:00
Zhiming Wang
fdea9d77e7
Fix examples
2020-06-02 17:54:01 +08:00
Zhiming Wang
fcca68ae5e
Add FFmpeg 4.2 specific code
2020-06-01 14:42:39 +08:00
Zhiming Wang
a69a457e3a
Add FFmpeg 4.1 specific code
2020-06-01 14:15:33 +08:00
Zhiming Wang
6220b88ef2
util/format/pixel: drop deprecated error::Error::description
2020-06-01 13:39:59 +08:00
Zhiming Wang
506f66ac51
Fix issues related to duplicate enum variants
...
C enums allow duplicate variants, but Rust enums don't. At some point bindgen
switched to generating duplicate variants as associated constants instead of
module-level constants, so use SomeEnum::* broke. Here we switch to associated
constants in the native API as well.
2020-06-01 13:36:50 +08:00
Zhiming Wang
1cd6d0499b
Switch to my fork of ffmpeg-sys
2020-06-01 13:17:08 +08:00
Zhiming Wang
6644a91da4
Update bitflags to 1.2 and fix namespacing
2020-06-01 13:06:34 +08:00
Zhiming Wang
3a8f366f60
software/scaling/context: fix mutability
2020-06-01 13:02:53 +08:00
Zhiming Wang
6c2d33fc07
Drop outdated lints
2020-05-31 14:16:23 +08:00
Zhiming Wang
13a2354a2c
Fix bare_trait_objects deprecation
2020-05-31 14:16:23 +08:00
Zhiming Wang
d3c10e4068
Fix libc::uint8_t deprecation
2020-05-31 14:16:23 +08:00
Zhiming Wang
cd6c9d972b
Fix std::error::Error::description deprecation
2020-05-31 14:16:23 +08:00
Zhiming Wang
587ec66592
Fix libc::int64_t deprecation
2020-05-31 13:34:24 +08:00
Zhiming Wang
3056975836
Fix libc::uint32_t deprecation
2020-05-31 13:28:14 +08:00
Erin Moon
a7ea073619
scaling and resampling contexts: fix null checks
...
dc6ace91ec
Fixes #1 .
2019-02-16 21:20:56 +08:00
Zhiming Wang
e13b01f30b
README: add crates.io badge
2018-09-19 21:35:58 -04:00
Zhiming Wang
7bcb223734
Cargo.toml: fix spacing
2018-09-19 19:57:23 -04:00
Zhiming Wang
e49d240068
Add README.md
2018-09-19 19:56:46 -04:00
Zhiming Wang
292a58ad0d
Cargo.toml: update to ffmpeg-next for crates.io packaging
2018-09-19 19:46:32 -04:00
Zhiming Wang
e6c7dc4bf5
Cargo.toml: add feature ffmpeg4 and mark as default
2018-09-19 17:09:59 -04:00
Zhiming Wang
a7eee9142f
Revert 8199541 and guard with not(ffmpeg4)
2018-09-19 17:08:42 -04:00
Zhiming Wang
0e05c0bb29
Mark new macros introduced in 2c5abbf as ffmpeg4
2018-09-19 16:54:16 -04:00
Zhiming Wang
4109fa5686
format::context::Context: add .bit_rate() method
2018-09-17 01:18:48 -04:00