Commit Graph

190 Commits

Author SHA1 Message Date
c6dd54003e Support ffmpeg 6.0
Closes #6
2023-03-07 13:21:43 -05:00
ed9703b739 Fix an issue where compilation may fail on some non-x64 platforms 2023-02-02 13:29:08 -05:00
fe89e158c0 Add serialize support for enums 2023-01-24 02:38:11 -05:00
cff28ba207 Fix things from renaming and clippy 2023-01-23 10:22:10 -05:00
92a8c6a9d8 add feature non-exhaustive-enums 2023-01-23 09:53:56 -05:00
28c356dd98 add wildcard branches for matches on enums 2023-01-23 09:53:52 -05:00
b6b2311fcf Bump to 5.1.1 2022-08-08 18:37:14 +02:00
22ad8b9598 Bump version to use ffmpeg 5 2022-02-11 17:58:42 +01:00
f559e13afc Fix linting errors 2021-10-02 22:51:32 +02:00
19ab5f67ad Fix linting errors 2021-07-07 16:52:30 +02:00
9c7ecb9b53 Initial ffmpeg 4.4 support 2021-05-06 17:08:45 -04:00
6f0a14ee8b codec: fix codec description potential null ptr issue
Codecs may not have .long_name initialized.

Issue raised by Pilyushkin in #34.
2020-10-04 11:37:59 +08:00
5affb85148 codec: fix signature of Packet::write_interleaved
av_interleaved_write_frame never returns 1, so bool makes no sense:
https://github.com/FFmpeg/FFmpeg/blob/n4.3.1/libavformat/avformat.h#L2592-L2635

Fixes #25.
2020-08-08 22:48:01 +08:00
6f44fb79fd codec: deprecate encoder's encode/flush and decoder's decode 2020-08-08 01:16:44 +08:00
07fe207ac2 codec: implement DerefMut for encoder::Audio and encoder::Subtitle 2020-08-08 00:38:09 +08:00
363001febe codec: expose modern send/receive packet/frame APIs
avcodec_encode_video2()/avcodec_decode_video2/avcodec_encode_audio2()/avcodec_decode_audio4()
have been deprecated since FFmpeg 3.1, with modern
avcodec_send_packet()/avcodec_receive_frame()/avcodec_send_frame()/avcodec_receive_packet()
as replacements.

This commit adds send_packet(), send_eof() and receive_frame() to
decoder::Opened; send_frame(), send_eof() and receive_packet() to
encoder::Encoder to expose these modern APIs.
2020-08-08 00:37:54 +08:00
516f8069f6 Packet setters 2020-08-07 22:43:53 +08:00
b28e852eb0 Implement automatic FFmpeg version detection
Based on ffmpeg-sys-next 4.3.2.
2020-08-02 11:44:13 +08:00
73b66ea438 Fix clippy::redundant_field_names 2020-07-26 01:01:13 +08:00
15c87a7837 Add FFmpeg 4.3 specific code 2020-06-17 01:51:38 +08:00
036c0e5b42 Fix duplicate enum variant issues for FFmpeg 3.4 2020-06-11 23:18:47 +08:00
307f52c002 Reformat code with latest cargo fmt 2020-06-02 17:54:31 +08:00
fcca68ae5e Add FFmpeg 4.2 specific code 2020-06-01 14:42:39 +08:00
a69a457e3a Add FFmpeg 4.1 specific code 2020-06-01 14:15:33 +08:00
6644a91da4 Update bitflags to 1.2 and fix namespacing 2020-06-01 13:06:34 +08:00
13a2354a2c Fix bare_trait_objects deprecation 2020-05-31 14:16:23 +08:00
587ec66592 Fix libc::int64_t deprecation 2020-05-31 13:34:24 +08:00
3056975836 Fix libc::uint32_t deprecation 2020-05-31 13:28:14 +08:00
a7eee9142f Revert 8199541 and guard with not(ffmpeg4) 2018-09-19 17:08:42 -04:00
0e05c0bb29 Mark new macros introduced in 2c5abbf as ffmpeg4 2018-09-19 16:54:16 -04:00
2c5abbfe33 Add missing macros (FFmpeg 4.0.2) 2018-09-10 16:22:16 -04:00
8199541f09 Drop obselete macros (obselete wrt FFmpeg 4.0) 2018-09-10 14:39:28 -04:00
0bcd4550b8 *: format code with rustfmt and fix clippy suggestions
* Add avformat_close_input call to clean up AVFormantContext
* Format code with rustfmt
* Fix clippy lint double_parens
* Fix clippy lint deref_addrof
* Fix clippy lint identity_conversion
* Fix clippy lint match_ref_pats
* Fix clippy lint cast_lossless
* Fix clippy lint cmp_null
* Fix clippy lint clone_on_ref_ptr
* Fix clippy lint map_clone
* Fix clippy lint needless_borrow
* Fix clippy lint needless_pass_by_value
* Fix clippy lints for examples
* Fix clippy lint unused_io_amount
* Fix clippy lint new_without_default
* Ignore inline_always clippy lint
* Add vim temp files to .gitignore
2018-04-10 16:06:42 +02:00
94ebdf143c *: add the newest enum values from ffmpeg-sys 2017-11-29 20:49:54 +01:00
7d980a693e *: fix warnings
- Don't use deprecated function for packet dropping
- Fix compiler warning about values, which do not need to be mutable
2017-09-19 14:36:35 +02:00
5afe774f40 crate: update bitflags 2017-07-10 11:35:49 +02:00
5ac0527bdc *: use latest ffmpeg-sys using bindgen
* Update bindings to newest ffmpeg version for new ffmpeg-sys, which is mostly generated by bindgen
* Bring back removed feature flags
* Fix whitespace formating
* Remove prepended enum names to enum variants
* Remove unneeded allows
2017-07-08 17:00:27 +02:00
9e933fa4fb codec/encoder/video: add colorspace and color_range accessors 2017-06-14 13:01:59 +02:00
meh
b48521108e *: update dependencies 2017-02-19 01:45:05 +01:00
edb6d91f59 codec/context: more Into 2016-12-03 01:44:56 +01:00
8609619a5d codec: impl AsMut for all Context wrappers 2016-12-03 01:43:30 +01:00
4df56b516f codec/parameters: impl AsRef for all codec::Context wrappers 2016-12-03 01:43:23 +01:00
36ac2513c1 codec/parameters: make api more flexible and consistent 2016-12-03 01:43:21 +01:00
f1ce26a137 codec/parameters: add medium and id methods 2016-12-03 01:42:40 +01:00
606847cc50 codec: introduce Parameters
As of ffmpeg 3.1, a new `AVCodecParameters` type and related API introduced.
This commit contains minimal changes to support new API.
2016-12-03 01:41:29 +01:00
e1c132bd08 codec/packet: add set_pts/dts methods 2016-11-29 01:07:26 +01:00
2ed824aaac *: upgrade to 3.2
Fix errors when built with https://github.com/meh/rust-ffmpeg-sys/pull/35.
2016-11-27 23:16:47 +01:00
859c01f268 codec/encoder/video: add missing feature flag (quant_bias) 2016-05-20 14:08:32 +02:00
e4fcdad658 codec/encoder/video: add missing feature flag (motion_est) 2016-05-20 14:08:32 +02:00
f5941792f9 codec/id: fix voxware feature name 2016-03-30 22:51:44 +02:00