Skip to content

Commit

Permalink
Обновление ffmpeg git-n6.2-dev-1752-gd7d2213a6b.
Browse files Browse the repository at this point in the history
  • Loading branch information
v0lt committed Mar 20, 2024
1 parent ef76822 commit 434b1ce
Show file tree
Hide file tree
Showing 42 changed files with 557 additions and 296 deletions.
2 changes: 1 addition & 1 deletion docs/Changelog.Rus.txt
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ MPC Video Renderer 0.7.3 включен в инсталлятор.
Обновлены библиотеки:
dav1d git-1.4.0-83-g872e470;
fdk-aac git-v2.0.3;
ffmpeg git-n6.2-dev-1636-g53a51e70f2;
ffmpeg git-n6.2-dev-1752-gd7d2213a6b;
Little-CMS git-lcms2.16-41-gfcf6792;
MediaInfo git-v24.01-19-gb7bb56e8d;
nanosvg git-93ce879;
Expand Down
2 changes: 1 addition & 1 deletion docs/Changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Updated German translation (by Klaus1189).
Updated libraries:
dav1d git-1.4.0-83-g872e470;
fdk-aac git-v2.0.3;
ffmpeg git-n6.2-dev-1636-g53a51e70f2;
ffmpeg git-n6.2-dev-1752-gd7d2213a6b;
Little-CMS git-lcms2.16-41-gfcf6792;
MediaInfo git-v24.01-19-gb7bb56e8d;
nanosvg git-93ce879;
Expand Down
10 changes: 5 additions & 5 deletions src/ExtLib/ffmpeg/libavcodec/aacpsdsp_template.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,14 +26,14 @@
#include "libavutil/attributes.h"
#include "aacpsdsp.h"

static void ps_add_squares_c(INTFLOAT *av_restrict dst,
static void ps_add_squares_c(INTFLOAT *restrict dst,
const INTFLOAT (*src)[2], int n)
{
for (int i = 0; i < n; i++)
dst[i] += (UINTFLOAT)AAC_MADD28(src[i][0], src[i][0], src[i][1], src[i][1]);
}

static void ps_mul_pair_single_c(INTFLOAT (*av_restrict dst)[2],
static void ps_mul_pair_single_c(INTFLOAT (*restrict dst)[2],
INTFLOAT (*src0)[2], INTFLOAT *src1,
int n)
{
Expand All @@ -43,7 +43,7 @@ static void ps_mul_pair_single_c(INTFLOAT (*av_restrict dst)[2],
}
}

static void ps_hybrid_analysis_c(INTFLOAT (*av_restrict out)[2],
static void ps_hybrid_analysis_c(INTFLOAT (*restrict out)[2],
INTFLOAT (*in)[2],
const INTFLOAT (*filter)[8][2],
ptrdiff_t stride, int n)
Expand Down Expand Up @@ -77,7 +77,7 @@ static void ps_hybrid_analysis_c(INTFLOAT (*av_restrict out)[2],
}
}

static void ps_hybrid_analysis_ileave_c(INTFLOAT (*av_restrict out)[32][2],
static void ps_hybrid_analysis_ileave_c(INTFLOAT (*restrict out)[32][2],
INTFLOAT L[2][38][64],
int i, int len)
{
Expand All @@ -90,7 +90,7 @@ static void ps_hybrid_analysis_ileave_c(INTFLOAT (*av_restrict out)[32][2],
}

static void ps_hybrid_synthesis_deint_c(INTFLOAT out[2][38][64],
INTFLOAT (*av_restrict in)[32][2],
INTFLOAT (*restrict in)[32][2],
int i, int len)
{
for (; i < 64; i++) {
Expand Down
16 changes: 0 additions & 16 deletions src/ExtLib/ffmpeg/libavcodec/ac3tab.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,22 +45,6 @@ extern const uint8_t ff_ac3_band_start_tab[AC3_CRITICAL_BANDS+1];
extern const uint8_t ff_ac3_bin_to_band_tab[253];
extern const uint64_t ff_eac3_custom_channel_map_locations[16][2];


/** Custom channel map locations bitmask
* Other channels described in documentation:
* Lc/Rc pair, Lrs/Rrs pair, Ts, Lsd/Rsd pair,
* Lw/Rw pair, Lvh/Rvh pair, Cvh, Reserved, LFE2
*/
enum CustomChannelMapLocation{
AC3_CHMAP_L= 1<<(15-0),
AC3_CHMAP_C= 1<<(15-1),
AC3_CHMAP_R= 1<<(15-2),
AC3_CHMAP_L_SUR= 1<<(15-3),
AC3_CHMAP_R_SUR = 1<<(15-4),
AC3_CHMAP_C_SUR= 1<<(15-7),
AC3_CHMAP_LFE = 1<<(15-15)
};

#define COMMON_CHANNEL_MAP \
{ { 0, 1, }, { 0, 1, 2, } },\
{ { 0, }, { 0, 1, } },\
Expand Down
12 changes: 7 additions & 5 deletions src/ExtLib/ffmpeg/libavcodec/av1dec.c
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
#include "decode.h"
#include "hwaccel_internal.h"
#include "internal.h"
#include "itut35.h"
#include "hwconfig.h"
#include "profiles.h"
#include "refstruct.h"
Expand Down Expand Up @@ -951,7 +952,7 @@ static int export_itut_t35(AVCodecContext *avctx, AVFrame *frame,

provider_code = bytestream2_get_be16(&gb);
switch (provider_code) {
case 0x31: { // atsc_provider_code
case ITU_T_T35_PROVIDER_CODE_ATSC: {
uint32_t user_identifier = bytestream2_get_be32(&gb);
switch (user_identifier) {
case MKBETAG('G', 'A', '9', '4'): { // closed captions
Expand All @@ -975,12 +976,12 @@ static int export_itut_t35(AVCodecContext *avctx, AVFrame *frame,
}
break;
}
case 0x3C: { // smpte_provider_code
case ITU_T_T35_PROVIDER_CODE_SMTPE: {
AVDynamicHDRPlus *hdrplus;
int provider_oriented_code = bytestream2_get_be16(&gb);
int application_identifier = bytestream2_get_byte(&gb);

if (itut_t35->itu_t_t35_country_code != 0xB5 ||
if (itut_t35->itu_t_t35_country_code != ITU_T_T35_COUNTRY_CODE_US ||
provider_oriented_code != 1 || application_identifier != 4)
break;

Expand All @@ -994,9 +995,10 @@ static int export_itut_t35(AVCodecContext *avctx, AVFrame *frame,
return ret;
break;
}
case 0x3B: { // dolby_provider_code
case ITU_T_T35_PROVIDER_CODE_DOLBY: {
int provider_oriented_code = bytestream2_get_be32(&gb);
if (itut_t35->itu_t_t35_country_code != 0xB5 || provider_oriented_code != 0x800)
if (itut_t35->itu_t_t35_country_code != ITU_T_T35_COUNTRY_CODE_US ||
provider_oriented_code != 0x800)
break;

ret = ff_dovi_rpu_parse(&s->dovi, gb.buffer, gb.buffer_end - gb.buffer);
Expand Down
13 changes: 13 additions & 0 deletions src/ExtLib/ffmpeg/libavcodec/avcodec.h
Original file line number Diff line number Diff line change
Expand Up @@ -2062,6 +2062,19 @@ typedef struct AVCodecContext {
* Number of entries in side_data_prefer_packet.
*/
unsigned nb_side_data_prefer_packet;

/**
* Array containing static side data, such as HDR10 CLL / MDCV structures.
* Side data entries should be allocated by usage of helpers defined in
* libavutil/frame.h.
*
* - encoding: may be set by user before calling avcodec_open2() for
* encoder configuration. Afterwards owned and freed by the
* encoder.
* - decoding: unused
*/
AVFrameSideData **decoded_side_data;
int nb_decoded_side_data;
} AVCodecContext;

/**
Expand Down
3 changes: 1 addition & 2 deletions src/ExtLib/ffmpeg/libavcodec/binkdsp.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
* Bink DSP routines
*/

#include "config.h"
#include "libavutil/attributes.h"
#include "binkdsp.h"

Expand Down Expand Up @@ -131,7 +130,7 @@ static void scale_block_c(const uint8_t src[64]/*align 8*/, uint8_t *dst/*align
}
}

static void add_pixels8_c(uint8_t *av_restrict pixels, int16_t *block,
static void add_pixels8_c(uint8_t *restrict pixels, int16_t *block,
int line_size)
{
int i;
Expand Down
4 changes: 1 addition & 3 deletions src/ExtLib/ffmpeg/libavcodec/binkdsp.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,11 @@

#include <stdint.h>

#include "config.h"

typedef struct BinkDSPContext {
void (*idct_put)(uint8_t *dest/*align 8*/, int line_size, int32_t *block/*align 16*/);
void (*idct_add)(uint8_t *dest/*align 8*/, int line_size, int32_t *block/*align 16*/);
void (*scale_block)(const uint8_t src[64]/*align 8*/, uint8_t *dst/*align 8*/, int linesize);
void (*add_pixels8)(uint8_t *av_restrict pixels, int16_t *block, int line_size);
void (*add_pixels8)(uint8_t *restrict pixels, int16_t *block, int line_size);
} BinkDSPContext;

void ff_binkdsp_init(BinkDSPContext *c);
Expand Down
4 changes: 4 additions & 0 deletions src/ExtLib/ffmpeg/libavcodec/dirac_arith.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,11 @@
#ifndef AVCODEC_DIRAC_ARITH_H
#define AVCODEC_DIRAC_ARITH_H

#include "config.h"

#if ARCH_X86
#include "libavutil/x86/asm.h"
#endif
#include "bytestream.h"
#include "get_bits.h"

Expand Down
2 changes: 1 addition & 1 deletion src/ExtLib/ffmpeg/libavcodec/dvdec.c
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ static inline void bit_copy(PutBitContext *pb, GetBitContext *gb)
put_bits(pb, bits_left, get_bits(gb, bits_left));
}

static av_always_inline void put_block_8x4(int16_t *block, uint8_t *av_restrict p, int stride)
static av_always_inline void put_block_8x4(int16_t *block, uint8_t *restrict p, int stride)
{
int i, j;

Expand Down
10 changes: 6 additions & 4 deletions src/ExtLib/ffmpeg/libavcodec/h2645_sei.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
#include "get_bits.h"
#include "golomb.h"
#include "h2645_sei.h"
#include "itut35.h"

#define IS_H264(codec_id) (CONFIG_H264_SEI && CONFIG_HEVC_SEI ? codec_id == AV_CODEC_ID_H264 : CONFIG_H264_SEI)
#define IS_HEVC(codec_id) (CONFIG_H264_SEI && CONFIG_HEVC_SEI ? codec_id == AV_CODEC_ID_HEVC : CONFIG_HEVC_SEI)
Expand Down Expand Up @@ -140,7 +141,8 @@ static int decode_registered_user_data(H2645SEI *h, GetByteContext *gb,
bytestream2_skipu(gb, 1); // itu_t_t35_country_code_extension_byte
}

if (country_code != 0xB5 && country_code != 0x26) { // usa_country_code and cn_country_code
if (country_code != ITU_T_T35_COUNTRY_CODE_US &&
country_code != ITU_T_T35_COUNTRY_CODE_CN) {
av_log(logctx, AV_LOG_VERBOSE,
"Unsupported User Data Registered ITU-T T35 SEI message (country_code = %d)\n",
country_code);
Expand All @@ -151,7 +153,7 @@ static int decode_registered_user_data(H2645SEI *h, GetByteContext *gb,
provider_code = bytestream2_get_be16u(gb);

switch (provider_code) {
case 0x31: { // atsc_provider_code
case ITU_T_T35_PROVIDER_CODE_ATSC: {
uint32_t user_identifier;

if (bytestream2_get_bytes_left(gb) < 4)
Expand All @@ -172,7 +174,7 @@ static int decode_registered_user_data(H2645SEI *h, GetByteContext *gb,
break;
}
#if CONFIG_HEVC_SEI
case 0x04: { // cuva_provider_code
case ITU_T_T35_PROVIDER_CODE_CUVA: {
const uint16_t cuva_provider_oriented_code = 0x0005;
uint16_t provider_oriented_code;

Expand All @@ -188,7 +190,7 @@ static int decode_registered_user_data(H2645SEI *h, GetByteContext *gb,
}
break;
}
case 0x3C: { // smpte_provider_code
case ITU_T_T35_PROVIDER_CODE_SMTPE: {
// A/341 Amendment - 2094-40
const uint16_t smpte2094_40_provider_oriented_code = 0x0001;
const uint8_t smpte2094_40_application_identifier = 0x04;
Expand Down
Loading

0 comments on commit 434b1ce

Please sign in to comment.