10 Commits

Author SHA1 Message Date
FreezyLemon
9ecb233d50 Implement most of the chroma location API 2024-10-27 19:53:51 -04:00
FreezyLemon
814f8b9464
FFmpeg 7.1 support (#74)
* Add new build-lib features

* Update CI to use 7.1

jrottenberg/ffmpeg does not have 7.1 yet

* Add libavcodec version for 7.1

* Add FF_API flags for 7.1

* Update crate versions, bump MSRV to 1.65

* Add new audio channel masks

* Add new AVColorSpace variants

* Add new AVFrameSideDataType variants

* Add new AVCodecID variants

* Add new AVPacketSideDataType variants
2024-10-18 00:06:01 -04:00
FreezyLemon
176f12c04d Use libc::c_char over i8
C `char` is unsigned on some platforms
2024-06-02 14:23:50 -04:00
FreezyLemon
40b7016177 sys: Fix clippy lints, run cargo fmt 2024-05-02 02:02:00 -04:00
FreezyLemon
fd2d71c92b
Support FFmpeg 7.0 (#48)
* sys: Run cargo fmt

* sys: Add new channel layout consts

* sys: Update build script for 7.0

- Add new FF_API flags
- Update version_check_info range
- Add ffmpeg_7_0 feature entry

* sys: Update non-exhaustive match statement

* Update enums

* Mark old APIs as removed with 7.0

* Make Audio frame work with 7.0

The .unwrap() in clone() is a bit wonky

* Add API for swr_alloc_set_opts2

* Use AVFrame::duration field in 7.0+

* Include 7.0 in CI runs

* Add fn ChanneLayoutIter::best

* Update examples for new API

* Add/update Context setter for ch layout
2024-04-29 21:38:37 -04:00
FreezyLemon
e7901750b4
ffmpeg-sys: Add basic impls for AVChannelLayout (#37) 2024-04-14 13:51:12 -04:00
FreezyLemon
684f758978
Replace avutil macros with const fns & clean up some code (#33)
* Replace tag/error macros with const fns

* Remove c_int -> c_int cast

These should always use the same type alias

* Remove duplicate av_strerror definition

* Document breaking change
2024-04-10 09:27:50 -04:00
FreezyLemon
6231b4bc3a
Move channel_layout_fixed.h to rust (#28)
* Move channel layout definitions to Rust

* Add channel layouts new in 6.1

* Add new AVChannelLayout consts

* Add new channel layout values to ChannelLayout

* Realign ChannelLayout consts
2024-04-10 09:24:10 -04:00
FreezyLemon
7a8643f2cc
Migrate crates to Rust edition 2021 (#24)
* Migrate ffmpeg-sys to Edition 2021

* Migrate ffmpeg to Edition 2021

* Remove now-redundant imports

* Reorder imports after edition migration
2024-04-06 21:31:36 -04:00
Josh Holmer
cbe6033984 Add sys crate and rename things 2023-01-23 09:59:27 -05:00