1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-19 05:49:09 +02:00
FFmpeg/libavutil
Zhao Zhili ba9cd06c76 avutil/avutil: make AV_TIME_BASE_Q available in C++
ISO C++ forbids compound-literals. It's not available with MSVC.
This is a known issue from 10 years ago, and that's why there is a
av_get_time_base_q().

Since we have no plan to remove AV_TIME_BASE_Q, just make it
available in C++.

There are multiple choices:
1. Use C++11 syntax: AVRational{1, AV_TIME_BASE}

Users may still use C++98 to write new code. So no.

2. Use av_get_time_base_q().

It's for this purpose. But it's not compile time constants as
AV_TIME_BASE_Q in C.

So I choose av_make_q() as Anton's suggestion.

https://libav-devel.libav.narkive.com/ZQCWfTun/patch-0-2-fix-avutil-h-usage-from-c
Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
2023-09-19 00:52:21 +08:00
..
2023-07-15 22:56:30 +03:00
2023-03-26 01:46:39 +01:00
2023-09-07 00:42:10 +02:00
2021-04-27 10:43:13 -03:00
2023-07-12 15:35:37 +02:00
2022-09-13 16:50:43 -03:00
2023-09-07 00:42:10 +02:00
2022-11-06 08:26:50 +01:00
2023-09-02 02:49:06 +02:00
2023-09-02 02:49:06 +02:00
2023-09-07 00:42:10 +02:00
2023-08-08 09:46:11 +02:00
2023-09-07 00:42:10 +02:00
2021-07-22 14:34:31 +02:00
2023-09-07 00:42:10 +02:00
2021-07-22 14:34:31 +02:00
2022-10-17 09:56:47 +02:00
2021-07-22 14:34:31 +02:00
2022-02-24 12:56:49 +01:00
2021-07-21 16:35:27 +02:00
2023-09-02 02:49:06 +02:00
2023-09-07 00:42:10 +02:00
2021-07-22 14:34:31 +02:00
2023-02-09 15:35:14 +01:00
2023-09-07 00:42:10 +02:00
2023-09-07 00:42:10 +02:00
2021-07-22 14:34:31 +02:00
2022-03-15 09:42:29 -03:00
2020-05-23 15:51:44 +02:00
2021-07-22 14:34:31 +02:00
2021-07-22 14:34:31 +02:00
2021-07-22 14:34:31 +02:00
2023-07-22 21:35:15 +03:00
2023-09-07 00:42:10 +02:00
2021-07-22 14:34:31 +02:00
2022-10-17 09:51:47 +02:00
2023-09-07 00:42:10 +02:00
2023-09-01 23:59:10 +02:00
2023-08-08 09:46:11 +02:00
2023-08-08 09:46:11 +02:00