#include "attributes.h"
+#include "macros.h"
#include "version.h"
#include "libavutil/avconfig.h"
@@ -53,9 +54,12 @@
#define RSHIFT(a,b) ((a) > 0 ? ((a) + ((1<<(b))>>1))>>(b) : ((a) + ((1<<(b))>>1)-1)>>(b))
/* assume b>0 */
#define ROUNDED_DIV(a,b) (((a)>0 ? (a) + ((b)>>1) : (a) - ((b)>>1))/(b))
-/* assume a>0 and b>0 */
-#define FF_CEIL_RSHIFT(a,b) (!av_builtin_constant_p(b) ? -((-(a)) >> (b)) \
+/* Fast a/(1<=0 and b>=0 */
+#define AV_CEIL_RSHIFT(a,b) (!av_builtin_constant_p(b) ? -((-(a)) >> (b)) \
: ((a) + (1<<(b)) - 1) >> (b))
+/* Backwards compat. */
+#define FF_CEIL_RSHIFT AV_CEIL_RSHIFT
+
#define FFUDIV(a,b) (((a)>0 ?(a):(a)-(b)+1) / (b))
#define FFUMOD(a,b) ((a)-(b)*FFUDIV(a,b))
@@ -94,7 +98,6 @@
#define FFSWAP(type,a,b) do{type SWAP_tmp= b; b= a; a= SWAP_tmp;}while(0)
#define FF_ARRAY_ELEMS(a) (sizeof(a) / sizeof((a)[0]))
-#define FFALIGN(x, a) (((x)+(a)-1)&~((a)-1))
/* misc math functions */
@@ -155,7 +158,7 @@ static av_always_inline av_const int64_t av_clip64_c(int64_t a, int64_t amin, in
*/
static av_always_inline av_const uint8_t av_clip_uint8_c(int a)
{
- if (a&(~0xFF)) return (-a)>>31;
+ if (a&(~0xFF)) return (~a)>>31;
else return a;
}
@@ -177,7 +180,7 @@ static av_always_inline av_const int8_t av_clip_int8_c(int a)
*/
static av_always_inline av_const uint16_t av_clip_uint16_c(int a)
{
- if (a&(~0xFFFF)) return (-a)>>31;
+ if (a&(~0xFFFF)) return (~a)>>31;
else return a;
}
@@ -211,7 +214,7 @@ static av_always_inline av_const int32_t av_clipl_int32_c(int64_t a)
*/
static av_always_inline av_const int av_clip_intp2_c(int a, int p)
{
- if ((a + (1 << p)) & ~((2 << p) - 1))
+ if (((unsigned)a + (1 << p)) & ~((2 << p) - 1))
return (a >> 31) ^ ((1 << p) - 1);
else
return a;
@@ -225,7 +228,7 @@ static av_always_inline av_const int av_clip_intp2_c(int a, int p)
*/
static av_always_inline av_const unsigned av_clip_uintp2_c(int a, int p)
{
- if (a & ~((1<> 31 & ((1<
> 31 & ((1<
> 32));
}
+static av_always_inline av_const int av_parity_c(uint32_t v)
+{
+ return av_popcount(v) & 1;
+}
+
#define MKTAG(a,b,c,d) ((a) | ((b) << 8) | ((c) << 16) | ((unsigned)(d) << 24))
#define MKBETAG(a,b,c,d) ((d) | ((c) << 8) | ((b) << 16) | ((unsigned)(a) << 24))
@@ -351,13 +383,13 @@ static av_always_inline av_const int av_popcount64_c(uint64_t x)
* to prevent undefined results.
*/
#define GET_UTF8(val, GET_BYTE, ERROR)\
- val= GET_BYTE;\
+ val= (GET_BYTE);\
{\
uint32_t top = (val & 128) >> 1;\
if ((val & 0xc0) == 0x80 || val >= 0xFE)\
ERROR\
while (val & top) {\
- int tmp= GET_BYTE - 128;\
+ int tmp= (GET_BYTE) - 128;\
if(tmp>>6)\
ERROR\
val= (val<<6) + tmp;\
@@ -505,6 +537,12 @@ static av_always_inline av_const int av_popcount64_c(uint64_t x)
#ifndef av_sat_dadd32
# define av_sat_dadd32 av_sat_dadd32_c
#endif
+#ifndef av_sat_sub32
+# define av_sat_sub32 av_sat_sub32_c
+#endif
+#ifndef av_sat_dsub32
+# define av_sat_dsub32 av_sat_dsub32_c
+#endif
#ifndef av_clipf
# define av_clipf av_clipf_c
#endif
@@ -517,3 +555,6 @@ static av_always_inline av_const int av_popcount64_c(uint64_t x)
#ifndef av_popcount64
# define av_popcount64 av_popcount64_c
#endif
+#ifndef av_parity
+# define av_parity av_parity_c
+#endif
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/cpu.h b/neo/libs/ffmpeg-win64/include/libavutil/cpu.h
index bff8518c..8bb9eb60 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/cpu.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/cpu.h
@@ -21,6 +21,8 @@
#ifndef AVUTIL_CPU_H
#define AVUTIL_CPU_H
+#include
+
#include "attributes.h"
#define AV_CPU_FLAG_FORCE 0x80000000 /* force usage of selected flags (OR) */
@@ -39,6 +41,7 @@
#define AV_CPU_FLAG_SSE3SLOW 0x20000000 ///< SSE3 supported, but usually not faster
///< than regular MMX/SSE (e.g. Core1)
#define AV_CPU_FLAG_SSSE3 0x0080 ///< Conroe SSSE3 functions
+#define AV_CPU_FLAG_SSSE3SLOW 0x4000000 ///< SSSE3 supported, but usually not faster
#define AV_CPU_FLAG_ATOM 0x10000000 ///< Atom processor, some SSSE3 instructions are slower
#define AV_CPU_FLAG_SSE4 0x0100 ///< Penryn SSE4.1 functions
#define AV_CPU_FLAG_SSE42 0x0200 ///< Nehalem SSE4.2 functions
@@ -52,6 +55,7 @@
#define AV_CPU_FLAG_FMA3 0x10000 ///< Haswell FMA3 functions
#define AV_CPU_FLAG_BMI1 0x20000 ///< Bit Manipulation Instruction Set 1
#define AV_CPU_FLAG_BMI2 0x40000 ///< Bit Manipulation Instruction Set 2
+#define AV_CPU_FLAG_AVX512 0x100000 ///< AVX-512 functions: requires OS support even if YMM/ZMM registers aren't used
#define AV_CPU_FLAG_ALTIVEC 0x0001 ///< standard
#define AV_CPU_FLAG_VSX 0x0002 ///< ISA 2.06
@@ -64,12 +68,13 @@
#define AV_CPU_FLAG_VFPV3 (1 << 4)
#define AV_CPU_FLAG_NEON (1 << 5)
#define AV_CPU_FLAG_ARMV8 (1 << 6)
+#define AV_CPU_FLAG_VFP_VM (1 << 7) ///< VFPv2 vector mode, deprecated in ARMv7-A and unavailable in various CPUs implementations
#define AV_CPU_FLAG_SETEND (1 <<16)
/**
* Return the flags which specify extensions supported by the CPU.
* The returned value is affected by av_force_cpu_flags() if that was used
- * before. So av_get_cpu_flags() can easily be used in a application to
+ * before. So av_get_cpu_flags() can easily be used in an application to
* detect the enabled cpu flags.
*/
int av_get_cpu_flags(void);
@@ -84,8 +89,6 @@ void av_force_cpu_flags(int flags);
* Set a mask on flags returned by av_get_cpu_flags().
* This function is mainly useful for testing.
* Please use av_force_cpu_flags() and av_get_cpu_flags() instead which are more flexible
- *
- * @warning this function is not thread safe.
*/
attribute_deprecated void av_set_cpu_flags_mask(int mask);
@@ -113,4 +116,15 @@ int av_parse_cpu_caps(unsigned *flags, const char *s);
*/
int av_cpu_count(void);
+/**
+ * Get the maximum data alignment that may be required by FFmpeg.
+ *
+ * Note that this is affected by the build configuration and the CPU flags mask,
+ * so e.g. if the CPU supports AVX, but libavutil has been built with
+ * --disable-avx or the AV_CPU_FLAG_AVX flag has been disabled through
+ * av_set_cpu_flags_mask(), then this function will behave as if AVX is not
+ * present.
+ */
+size_t av_cpu_max_align(void);
+
#endif /* AVUTIL_CPU_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/crc.h b/neo/libs/ffmpeg-win64/include/libavutil/crc.h
index e86bf1de..47e22b4c 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/crc.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/crc.h
@@ -18,16 +18,29 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_crc32
+ * Public header for CRC hash function implementation.
+ */
+
#ifndef AVUTIL_CRC_H
#define AVUTIL_CRC_H
#include
#include
#include "attributes.h"
+#include "version.h"
/**
- * @defgroup lavu_crc32 CRC32
- * @ingroup lavu_crypto
+ * @defgroup lavu_crc32 CRC
+ * @ingroup lavu_hash
+ * CRC (Cyclic Redundancy Check) hash function implementation.
+ *
+ * This module supports numerous CRC polynomials, in addition to the most
+ * widely used CRC-32-IEEE. See @ref AVCRCId for a list of available
+ * polynomials.
+ *
* @{
*/
@@ -40,7 +53,8 @@ typedef enum {
AV_CRC_32_IEEE,
AV_CRC_32_IEEE_LE, /*< reversed bitorder version of AV_CRC_32_IEEE */
AV_CRC_16_ANSI_LE, /*< reversed bitorder version of AV_CRC_16_ANSI */
- AV_CRC_24_IEEE = 12,
+ AV_CRC_24_IEEE,
+ AV_CRC_8_EBU,
AV_CRC_MAX, /*< Not part of public API! Do not use outside libavutil. */
}AVCRCId;
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/dict.h b/neo/libs/ffmpeg-win64/include/libavutil/dict.h
index 5b8d0033..118f1f00 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/dict.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/dict.h
@@ -1,5 +1,4 @@
/*
- *
* This file is part of FFmpeg.
*
* FFmpeg is free software; you can redistribute it and/or
@@ -65,7 +64,6 @@
}
av_dict_free(&d);
@endcode
- *
*/
#define AV_DICT_MATCH_CASE 1 /**< Only get an entry with exact-case key match. Only relevant in av_dict_get(). */
@@ -78,6 +76,7 @@
#define AV_DICT_DONT_OVERWRITE 16 ///< Don't overwrite existing entries.
#define AV_DICT_APPEND 32 /**< If the entry already exists, append to it. Note that no
delimiter is added, the strings are simply concatenated. */
+#define AV_DICT_MULTIKEY 64 /**< Allow to store several equal keys in the dictionary */
typedef struct AVDictionaryEntry {
char *key;
@@ -118,10 +117,13 @@ int av_dict_count(const AVDictionary *m);
* Note: If AV_DICT_DONT_STRDUP_KEY or AV_DICT_DONT_STRDUP_VAL is set,
* these arguments will be freed on error.
*
+ * Warning: Adding a new entry to a dictionary invalidates all existing entries
+ * previously returned with av_dict_get.
+ *
* @param pm pointer to a pointer to a dictionary struct. If *pm is NULL
* a dictionary struct is allocated and put in *pm.
- * @param key entry key to add to *pm (will be av_strduped depending on flags)
- * @param value entry value to add to *pm (will be av_strduped depending on flags).
+ * @param key entry key to add to *pm (will either be av_strduped or added as a new key depending on flags)
+ * @param value entry value to add to *pm (will be av_strduped or added as a new key depending on flags).
* Passing a NULL value will cause an existing entry to be deleted.
* @return >= 0 on success otherwise an error code <0
*/
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/display.h b/neo/libs/ffmpeg-win64/include/libavutil/display.h
index c0cfee32..515adad7 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/display.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/display.h
@@ -18,21 +18,38 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * Display matrix
+ */
+
#ifndef AVUTIL_DISPLAY_H
#define AVUTIL_DISPLAY_H
#include
+#include "common.h"
/**
+ * @addtogroup lavu_video
+ * @{
+ *
+ * @defgroup lavu_video_display Display transformation matrix functions
+ * @{
+ */
+
+/**
+ * @addtogroup lavu_video_display
* The display transformation matrix specifies an affine transformation that
* should be applied to video frames for correct presentation. It is compatible
* with the matrices stored in the ISO/IEC 14496-12 container format.
*
* The data is a 3x3 matrix represented as a 9-element array:
*
+ * @code{.unparsed}
* | a b u |
* (a, b, u, c, d, v, x, y, w) -> | c d v |
* | x y w |
+ * @endcode
*
* All numbers are stored in native endianness, as 16.16 fixed-point values,
* except for u, v and w, which are stored as 2.30 fixed-point values.
@@ -40,15 +57,21 @@
* The transformation maps a point (p, q) in the source (pre-transformation)
* frame to the point (p', q') in the destination (post-transformation) frame as
* follows:
+ *
+ * @code{.unparsed}
* | a b u |
* (p, q, 1) . | c d v | = z * (p', q', 1)
* | x y w |
+ * @endcode
*
* The transformation can also be more explicitly written in components as
* follows:
+ *
+ * @code{.unparsed}
* p' = (a * p + c * q + x) / z;
* q' = (b * p + d * q + y) / z;
* z = u * p + v * q + w
+ * @endcode
*/
/**
@@ -83,4 +106,9 @@ void av_display_rotation_set(int32_t matrix[9], double angle);
*/
void av_display_matrix_flip(int32_t matrix[9], int hflip, int vflip);
+/**
+ * @}
+ * @}
+ */
+
#endif /* AVUTIL_DISPLAY_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/encryption_info.h b/neo/libs/ffmpeg-win64/include/libavutil/encryption_info.h
new file mode 100644
index 00000000..8fe7ebfe
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/encryption_info.h
@@ -0,0 +1,205 @@
+/**
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_ENCRYPTION_INFO_H
+#define AVUTIL_ENCRYPTION_INFO_H
+
+#include
+#include
+
+typedef struct AVSubsampleEncryptionInfo {
+ /** The number of bytes that are clear. */
+ unsigned int bytes_of_clear_data;
+
+ /**
+ * The number of bytes that are protected. If using pattern encryption,
+ * the pattern applies to only the protected bytes; if not using pattern
+ * encryption, all these bytes are encrypted.
+ */
+ unsigned int bytes_of_protected_data;
+} AVSubsampleEncryptionInfo;
+
+/**
+ * This describes encryption info for a packet. This contains frame-specific
+ * info for how to decrypt the packet before passing it to the decoder.
+ *
+ * The size of this struct is not part of the public ABI.
+ */
+typedef struct AVEncryptionInfo {
+ /** The fourcc encryption scheme, in big-endian byte order. */
+ uint32_t scheme;
+
+ /**
+ * Only used for pattern encryption. This is the number of 16-byte blocks
+ * that are encrypted.
+ */
+ uint32_t crypt_byte_block;
+
+ /**
+ * Only used for pattern encryption. This is the number of 16-byte blocks
+ * that are clear.
+ */
+ uint32_t skip_byte_block;
+
+ /**
+ * The ID of the key used to encrypt the packet. This should always be
+ * 16 bytes long, but may be changed in the future.
+ */
+ uint8_t *key_id;
+ uint32_t key_id_size;
+
+ /**
+ * The initialization vector. This may have been zero-filled to be the
+ * correct block size. This should always be 16 bytes long, but may be
+ * changed in the future.
+ */
+ uint8_t *iv;
+ uint32_t iv_size;
+
+ /**
+ * An array of subsample encryption info specifying how parts of the sample
+ * are encrypted. If there are no subsamples, then the whole sample is
+ * encrypted.
+ */
+ AVSubsampleEncryptionInfo *subsamples;
+ uint32_t subsample_count;
+} AVEncryptionInfo;
+
+/**
+ * This describes info used to initialize an encryption key system.
+ *
+ * The size of this struct is not part of the public ABI.
+ */
+typedef struct AVEncryptionInitInfo {
+ /**
+ * A unique identifier for the key system this is for, can be NULL if it
+ * is not known. This should always be 16 bytes, but may change in the
+ * future.
+ */
+ uint8_t* system_id;
+ uint32_t system_id_size;
+
+ /**
+ * An array of key IDs this initialization data is for. All IDs are the
+ * same length. Can be NULL if there are no known key IDs.
+ */
+ uint8_t** key_ids;
+ /** The number of key IDs. */
+ uint32_t num_key_ids;
+ /**
+ * The number of bytes in each key ID. This should always be 16, but may
+ * change in the future.
+ */
+ uint32_t key_id_size;
+
+ /**
+ * Key-system specific initialization data. This data is copied directly
+ * from the file and the format depends on the specific key system. This
+ * can be NULL if there is no initialization data; in that case, there
+ * will be at least one key ID.
+ */
+ uint8_t* data;
+ uint32_t data_size;
+
+ /**
+ * An optional pointer to the next initialization info in the list.
+ */
+ struct AVEncryptionInitInfo *next;
+} AVEncryptionInitInfo;
+
+/**
+ * Allocates an AVEncryptionInfo structure and sub-pointers to hold the given
+ * number of subsamples. This will allocate pointers for the key ID, IV,
+ * and subsample entries, set the size members, and zero-initialize the rest.
+ *
+ * @param subsample_count The number of subsamples.
+ * @param key_id_size The number of bytes in the key ID, should be 16.
+ * @param iv_size The number of bytes in the IV, should be 16.
+ *
+ * @return The new AVEncryptionInfo structure, or NULL on error.
+ */
+AVEncryptionInfo *av_encryption_info_alloc(uint32_t subsample_count, uint32_t key_id_size, uint32_t iv_size);
+
+/**
+ * Allocates an AVEncryptionInfo structure with a copy of the given data.
+ * @return The new AVEncryptionInfo structure, or NULL on error.
+ */
+AVEncryptionInfo *av_encryption_info_clone(const AVEncryptionInfo *info);
+
+/**
+ * Frees the given encryption info object. This MUST NOT be used to free the
+ * side-data data pointer, that should use normal side-data methods.
+ */
+void av_encryption_info_free(AVEncryptionInfo *info);
+
+/**
+ * Creates a copy of the AVEncryptionInfo that is contained in the given side
+ * data. The resulting object should be passed to av_encryption_info_free()
+ * when done.
+ *
+ * @return The new AVEncryptionInfo structure, or NULL on error.
+ */
+AVEncryptionInfo *av_encryption_info_get_side_data(const uint8_t *side_data, size_t side_data_size);
+
+/**
+ * Allocates and initializes side data that holds a copy of the given encryption
+ * info. The resulting pointer should be either freed using av_free or given
+ * to av_packet_add_side_data().
+ *
+ * @return The new side-data pointer, or NULL.
+ */
+uint8_t *av_encryption_info_add_side_data(
+ const AVEncryptionInfo *info, size_t *side_data_size);
+
+
+/**
+ * Allocates an AVEncryptionInitInfo structure and sub-pointers to hold the
+ * given sizes. This will allocate pointers and set all the fields.
+ *
+ * @return The new AVEncryptionInitInfo structure, or NULL on error.
+ */
+AVEncryptionInitInfo *av_encryption_init_info_alloc(
+ uint32_t system_id_size, uint32_t num_key_ids, uint32_t key_id_size, uint32_t data_size);
+
+/**
+ * Frees the given encryption init info object. This MUST NOT be used to free
+ * the side-data data pointer, that should use normal side-data methods.
+ */
+void av_encryption_init_info_free(AVEncryptionInitInfo* info);
+
+/**
+ * Creates a copy of the AVEncryptionInitInfo that is contained in the given
+ * side data. The resulting object should be passed to
+ * av_encryption_init_info_free() when done.
+ *
+ * @return The new AVEncryptionInitInfo structure, or NULL on error.
+ */
+AVEncryptionInitInfo *av_encryption_init_info_get_side_data(
+ const uint8_t* side_data, size_t side_data_size);
+
+/**
+ * Allocates and initializes side data that holds a copy of the given encryption
+ * init info. The resulting pointer should be either freed using av_free or
+ * given to av_packet_add_side_data().
+ *
+ * @return The new side-data pointer, or NULL.
+ */
+uint8_t *av_encryption_init_info_add_side_data(
+ const AVEncryptionInitInfo *info, size_t *side_data_size);
+
+#endif /* AVUTIL_ENCRYPTION_INFO_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/ffversion.h b/neo/libs/ffmpeg-win64/include/libavutil/ffversion.h
index e6c73222..e5c2702c 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/ffversion.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/ffversion.h
@@ -1,5 +1,5 @@
/* Automatically generated by version.sh, do not manually edit! */
#ifndef AVUTIL_FFVERSION_H
#define AVUTIL_FFVERSION_H
-#define FFMPEG_VERSION "N-76479-gc878082"
+#define FFMPEG_VERSION "4.2.2"
#endif /* AVUTIL_FFVERSION_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/file.h b/neo/libs/ffmpeg-win64/include/libavutil/file.h
index e931be71..3ef4a602 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/file.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/file.h
@@ -33,6 +33,8 @@
* allocated buffer or map it with mmap() when available.
* In case of success set *bufptr to the read or mmapped buffer, and
* *size to the size in bytes of the buffer in *bufptr.
+ * Unlike mmap this function succeeds with zero sized files, in this
+ * case *bufptr will be set to NULL and *size will be set to 0.
* The returned buffer must be released with av_file_unmap().
*
* @param log_offset loglevel offset used for logging
@@ -62,6 +64,7 @@ void av_file_unmap(uint8_t *bufptr, size_t size);
* @note On very old libcs it is necessary to set a secure umask before
* calling this, av_tempfile() can't call umask itself as it is used in
* libraries and could interfere with the calling application.
+ * @deprecated as fd numbers cannot be passed saftely between libs on some platforms
*/
int av_tempfile(const char *prefix, char **filename, int log_offset, void *log_ctx);
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/frame.h b/neo/libs/ffmpeg-win64/include/libavutil/frame.h
index 9c6061a1..5d3231e7 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/frame.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/frame.h
@@ -1,5 +1,4 @@
/*
- *
* This file is part of FFmpeg.
*
* FFmpeg is free software; you can redistribute it and/or
@@ -26,6 +25,7 @@
#ifndef AVUTIL_FRAME_H
#define AVUTIL_FRAME_H
+#include
#include
#include "avutil.h"
@@ -106,12 +106,79 @@ enum AVFrameSideDataType {
* @endcode
*/
AV_FRAME_DATA_SKIP_SAMPLES,
-
/**
* This side data must be associated with an audio frame and corresponds to
* enum AVAudioServiceType defined in avcodec.h.
*/
AV_FRAME_DATA_AUDIO_SERVICE_TYPE,
+ /**
+ * Mastering display metadata associated with a video frame. The payload is
+ * an AVMasteringDisplayMetadata type and contains information about the
+ * mastering display color volume.
+ */
+ AV_FRAME_DATA_MASTERING_DISPLAY_METADATA,
+ /**
+ * The GOP timecode in 25 bit timecode format. Data format is 64-bit integer.
+ * This is set on the first frame of a GOP that has a temporal reference of 0.
+ */
+ AV_FRAME_DATA_GOP_TIMECODE,
+
+ /**
+ * The data represents the AVSphericalMapping structure defined in
+ * libavutil/spherical.h.
+ */
+ AV_FRAME_DATA_SPHERICAL,
+
+ /**
+ * Content light level (based on CTA-861.3). This payload contains data in
+ * the form of the AVContentLightMetadata struct.
+ */
+ AV_FRAME_DATA_CONTENT_LIGHT_LEVEL,
+
+ /**
+ * The data contains an ICC profile as an opaque octet buffer following the
+ * format described by ISO 15076-1 with an optional name defined in the
+ * metadata key entry "name".
+ */
+ AV_FRAME_DATA_ICC_PROFILE,
+
+#if FF_API_FRAME_QP
+ /**
+ * Implementation-specific description of the format of AV_FRAME_QP_TABLE_DATA.
+ * The contents of this side data are undocumented and internal; use
+ * av_frame_set_qp_table() and av_frame_get_qp_table() to access this in a
+ * meaningful way instead.
+ */
+ AV_FRAME_DATA_QP_TABLE_PROPERTIES,
+
+ /**
+ * Raw QP table data. Its format is described by
+ * AV_FRAME_DATA_QP_TABLE_PROPERTIES. Use av_frame_set_qp_table() and
+ * av_frame_get_qp_table() to access this instead.
+ */
+ AV_FRAME_DATA_QP_TABLE_DATA,
+#endif
+
+ /**
+ * Timecode which conforms to SMPTE ST 12-1. The data is an array of 4 uint32_t
+ * where the first uint32_t describes how many (1-3) of the other timecodes are used.
+ * The timecode format is described in the av_timecode_get_smpte_from_framenum()
+ * function in libavutil/timecode.c.
+ */
+ AV_FRAME_DATA_S12M_TIMECODE,
+
+ /**
+ * HDR dynamic metadata associated with a video frame. The payload is
+ * an AVDynamicHDRPlus type and contains information for color
+ * volume transform - application 4 of SMPTE 2094-40:2016 standard.
+ */
+ AV_FRAME_DATA_DYNAMIC_HDR_PLUS,
+
+ /**
+ * Regions Of Interest, the data is an array of AVRegionOfInterest type, the number of
+ * array element is implied by AVFrameSideData.size / AVRegionOfInterest.self_size.
+ */
+ AV_FRAME_DATA_REGIONS_OF_INTEREST,
};
enum AVActiveFormatDescription {
@@ -139,6 +206,62 @@ typedef struct AVFrameSideData {
AVBufferRef *buf;
} AVFrameSideData;
+/**
+ * Structure describing a single Region Of Interest.
+ *
+ * When multiple regions are defined in a single side-data block, they
+ * should be ordered from most to least important - some encoders are only
+ * capable of supporting a limited number of distinct regions, so will have
+ * to truncate the list.
+ *
+ * When overlapping regions are defined, the first region containing a given
+ * area of the frame applies.
+ */
+typedef struct AVRegionOfInterest {
+ /**
+ * Must be set to the size of this data structure (that is,
+ * sizeof(AVRegionOfInterest)).
+ */
+ uint32_t self_size;
+ /**
+ * Distance in pixels from the top edge of the frame to the top and
+ * bottom edges and from the left edge of the frame to the left and
+ * right edges of the rectangle defining this region of interest.
+ *
+ * The constraints on a region are encoder dependent, so the region
+ * actually affected may be slightly larger for alignment or other
+ * reasons.
+ */
+ int top;
+ int bottom;
+ int left;
+ int right;
+ /**
+ * Quantisation offset.
+ *
+ * Must be in the range -1 to +1. A value of zero indicates no quality
+ * change. A negative value asks for better quality (less quantisation),
+ * while a positive value asks for worse quality (greater quantisation).
+ *
+ * The range is calibrated so that the extreme values indicate the
+ * largest possible offset - if the rest of the frame is encoded with the
+ * worst possible quality, an offset of -1 indicates that this region
+ * should be encoded with the best possible quality anyway. Intermediate
+ * values are then interpolated in some codec-dependent way.
+ *
+ * For example, in 10-bit H.264 the quantisation parameter varies between
+ * -12 and 51. A typical qoffset value of -1/10 therefore indicates that
+ * this region should be encoded with a QP around one-tenth of the full
+ * range better than the rest of the frame. So, if most of the frame
+ * were to be encoded with a QP of around 30, this region would get a QP
+ * of around 24 (an offset of approximately -1/10 * (51 - -12) = -6.3).
+ * An extreme value of -1 would indicate that this region should be
+ * encoded with the best possible quality regardless of the treatment of
+ * the rest of the frame - that is, should be encoded at a QP of -12.
+ */
+ AVRational qoffset;
+} AVRegionOfInterest;
+
/**
* This structure describes decoded (raw) audio or video data.
*
@@ -164,9 +287,10 @@ typedef struct AVFrameSideData {
*
* sizeof(AVFrame) is not a part of the public ABI, so new fields may be added
* to the end with a minor bump.
- * Similarly fields that are marked as to be only accessed by
- * av_opt_ptr() can be reordered. This allows 2 forks to add fields
- * without breaking compatibility with each other.
+ *
+ * Fields can be accessed through AVOptions, the name string used, matches the
+ * C structure field name for fields accessible through AVOptions. The AVClass
+ * for AVFrame can be obtained from avcodec_get_frame_class()
*/
typedef struct AVFrame {
#define AV_NUM_DATA_POINTERS 8
@@ -178,6 +302,9 @@ typedef struct AVFrame {
* see avcodec_align_dimensions2(). Some filters and swscale can read
* up to 16 bytes beyond the planes, if these filters are to be used,
* then 16 extra bytes must be allocated.
+ *
+ * NOTE: Except for hwaccel formats, pointers not needed by the format
+ * MUST be set to NULL.
*/
uint8_t *data[AV_NUM_DATA_POINTERS];
@@ -215,9 +342,18 @@ typedef struct AVFrame {
uint8_t **extended_data;
/**
- * width and height of the video frame
+ * @name Video dimensions
+ * Video frames only. The coded dimensions (in pixels) of the video frame,
+ * i.e. the size of the rectangle that contains some well-defined values.
+ *
+ * @note The part of the frame intended for display/presentation is further
+ * restricted by the @ref cropping "Cropping rectangle".
+ * @{
*/
int width, height;
+ /**
+ * @}
+ */
/**
* number of audio samples (per channel) described by this frame
@@ -251,10 +387,14 @@ typedef struct AVFrame {
*/
int64_t pts;
+#if FF_API_PKT_PTS
/**
* PTS copied from the AVPacket that was decoded to produce this frame.
+ * @deprecated use the pts field instead
*/
+ attribute_deprecated
int64_t pkt_pts;
+#endif
/**
* DTS copied from the AVPacket that triggered returning this frame. (if frame threading isn't used)
@@ -312,13 +452,12 @@ typedef struct AVFrame {
int palette_has_changed;
/**
- * reordered opaque 64bit (generally an integer or a double precision float
+ * reordered opaque 64 bits (generally an integer or a double precision float
* PTS but can be anything).
* The user sets AVCodecContext.reordered_opaque to represent the input at
* that time,
* the decoder reorders values as needed and sets AVFrame.reordered_opaque
* to exactly one of the values provided by the user through AVCodecContext.reordered_opaque
- * @deprecated in favor of pkt_pts
*/
int64_t reordered_opaque;
@@ -369,6 +508,7 @@ typedef struct AVFrame {
/**
* @defgroup lavu_frame_flags AV_FRAME_FLAGS
+ * @ingroup lavu_frame
* Flags describing additional frame properties.
*
* @{
@@ -378,6 +518,10 @@ typedef struct AVFrame {
* The frame data may be corrupted, e.g. due to decoding errors.
*/
#define AV_FRAME_FLAG_CORRUPT (1 << 0)
+/**
+ * A flag to mark the frames which need to be decoded, but shouldn't be output.
+ */
+#define AV_FRAME_FLAG_DISCARD (1 << 2)
/**
* @}
*/
@@ -389,8 +533,6 @@ typedef struct AVFrame {
/**
* MPEG vs JPEG YUV range.
- * It must be accessed using av_frame_get_color_range() and
- * av_frame_set_color_range().
* - encoding: Set by user
* - decoding: Set by libavcodec
*/
@@ -402,8 +544,6 @@ typedef struct AVFrame {
/**
* YUV colorspace type.
- * It must be accessed using av_frame_get_colorspace() and
- * av_frame_set_colorspace().
* - encoding: Set by user
* - decoding: Set by libavcodec
*/
@@ -413,8 +553,6 @@ typedef struct AVFrame {
/**
* frame timestamp estimated using various heuristics, in stream time base
- * Code outside libavutil should access this field using:
- * av_frame_get_best_effort_timestamp(frame)
* - encoding: unused
* - decoding: set by libavcodec, read by user.
*/
@@ -422,8 +560,6 @@ typedef struct AVFrame {
/**
* reordered pos from the last AVPacket that has been input into the decoder
- * Code outside libavutil should access this field using:
- * av_frame_get_pkt_pos(frame)
* - encoding: unused
* - decoding: Read by user.
*/
@@ -432,8 +568,6 @@ typedef struct AVFrame {
/**
* duration of the corresponding packet, expressed in
* AVStream->time_base units, 0 if unknown.
- * Code outside libavutil should access this field using:
- * av_frame_get_pkt_duration(frame)
* - encoding: unused
* - decoding: Read by user.
*/
@@ -441,8 +575,6 @@ typedef struct AVFrame {
/**
* metadata.
- * Code outside libavutil should access this field using:
- * av_frame_get_metadata(frame)
* - encoding: Set by user.
* - decoding: Set by libavcodec.
*/
@@ -452,19 +584,17 @@ typedef struct AVFrame {
* decode error flags of the frame, set to a combination of
* FF_DECODE_ERROR_xxx flags if the decoder produced a frame, but there
* were errors during the decoding.
- * Code outside libavutil should access this field using:
- * av_frame_get_decode_error_flags(frame)
* - encoding: unused
* - decoding: set by libavcodec, read by user.
*/
int decode_error_flags;
#define FF_DECODE_ERROR_INVALID_BITSTREAM 1
#define FF_DECODE_ERROR_MISSING_REFERENCE 2
+#define FF_DECODE_ERROR_CONCEALMENT_ACTIVE 4
+#define FF_DECODE_ERROR_DECODE_SLICES 8
/**
* number of audio channels, only used for audio.
- * Code outside libavutil should access this field using:
- * av_frame_get_channels(frame)
* - encoding: unused
* - decoding: Read by user.
*/
@@ -472,8 +602,7 @@ typedef struct AVFrame {
/**
* size of the corresponding packet containing the compressed
- * frame. It must be accessed using av_frame_get_pkt_size() and
- * av_frame_set_pkt_size().
+ * frame.
* It is set to a negative value if unknown.
* - encoding: unused
* - decoding: set by libavcodec, read by user.
@@ -483,13 +612,11 @@ typedef struct AVFrame {
#if FF_API_FRAME_QP
/**
* QP table
- * Not to be accessed directly from outside libavutil
*/
attribute_deprecated
int8_t *qscale_table;
/**
* QP store stride
- * Not to be accessed directly from outside libavutil
*/
attribute_deprecated
int qstride;
@@ -497,45 +624,112 @@ typedef struct AVFrame {
attribute_deprecated
int qscale_type;
- /**
- * Not to be accessed directly from outside libavutil
- */
+ attribute_deprecated
AVBufferRef *qp_table_buf;
#endif
+ /**
+ * For hwaccel-format frames, this should be a reference to the
+ * AVHWFramesContext describing the frame.
+ */
+ AVBufferRef *hw_frames_ctx;
+
+ /**
+ * AVBufferRef for free use by the API user. FFmpeg will never check the
+ * contents of the buffer ref. FFmpeg calls av_buffer_unref() on it when
+ * the frame is unreferenced. av_frame_copy_props() calls create a new
+ * reference with av_buffer_ref() for the target frame's opaque_ref field.
+ *
+ * This is unrelated to the opaque field, although it serves a similar
+ * purpose.
+ */
+ AVBufferRef *opaque_ref;
+
+ /**
+ * @anchor cropping
+ * @name Cropping
+ * Video frames only. The number of pixels to discard from the the
+ * top/bottom/left/right border of the frame to obtain the sub-rectangle of
+ * the frame intended for presentation.
+ * @{
+ */
+ size_t crop_top;
+ size_t crop_bottom;
+ size_t crop_left;
+ size_t crop_right;
+ /**
+ * @}
+ */
+
+ /**
+ * AVBufferRef for internal use by a single libav* library.
+ * Must not be used to transfer data between libraries.
+ * Has to be NULL when ownership of the frame leaves the respective library.
+ *
+ * Code outside the FFmpeg libs should never check or change the contents of the buffer ref.
+ *
+ * FFmpeg calls av_buffer_unref() on it when the frame is unreferenced.
+ * av_frame_copy_props() calls create a new reference with av_buffer_ref()
+ * for the target frame's private_ref field.
+ */
+ AVBufferRef *private_ref;
} AVFrame;
+#if FF_API_FRAME_GET_SET
/**
- * Accessors for some AVFrame fields.
- * The position of these field in the structure is not part of the ABI,
- * they should not be accessed directly outside libavutil.
+ * Accessors for some AVFrame fields. These used to be provided for ABI
+ * compatibility, and do not need to be used anymore.
*/
+attribute_deprecated
int64_t av_frame_get_best_effort_timestamp(const AVFrame *frame);
+attribute_deprecated
void av_frame_set_best_effort_timestamp(AVFrame *frame, int64_t val);
+attribute_deprecated
int64_t av_frame_get_pkt_duration (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_pkt_duration (AVFrame *frame, int64_t val);
+attribute_deprecated
int64_t av_frame_get_pkt_pos (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_pkt_pos (AVFrame *frame, int64_t val);
+attribute_deprecated
int64_t av_frame_get_channel_layout (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_channel_layout (AVFrame *frame, int64_t val);
+attribute_deprecated
int av_frame_get_channels (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_channels (AVFrame *frame, int val);
+attribute_deprecated
int av_frame_get_sample_rate (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_sample_rate (AVFrame *frame, int val);
+attribute_deprecated
AVDictionary *av_frame_get_metadata (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_metadata (AVFrame *frame, AVDictionary *val);
+attribute_deprecated
int av_frame_get_decode_error_flags (const AVFrame *frame);
+attribute_deprecated
void av_frame_set_decode_error_flags (AVFrame *frame, int val);
+attribute_deprecated
int av_frame_get_pkt_size(const AVFrame *frame);
+attribute_deprecated
void av_frame_set_pkt_size(AVFrame *frame, int val);
-AVDictionary **avpriv_frame_get_metadatap(AVFrame *frame);
#if FF_API_FRAME_QP
+attribute_deprecated
int8_t *av_frame_get_qp_table(AVFrame *f, int *stride, int *type);
+attribute_deprecated
int av_frame_set_qp_table(AVFrame *f, AVBufferRef *buf, int stride, int type);
#endif
+attribute_deprecated
enum AVColorSpace av_frame_get_colorspace(const AVFrame *frame);
+attribute_deprecated
void av_frame_set_colorspace(AVFrame *frame, enum AVColorSpace val);
+attribute_deprecated
enum AVColorRange av_frame_get_color_range(const AVFrame *frame);
+attribute_deprecated
void av_frame_set_color_range(AVFrame *frame, enum AVColorRange val);
+#endif
/**
* Get the name of a colorspace.
@@ -573,6 +767,10 @@ void av_frame_free(AVFrame **frame);
* If src is not reference counted, new buffers are allocated and the data is
* copied.
*
+ * @warning: dst MUST have been either unreferenced with av_frame_unref(dst),
+ * or newly allocated with av_frame_alloc() before calling this
+ * function, or undefined behavior will occur.
+ *
* @return 0 on success, a negative AVERROR on error
*/
int av_frame_ref(AVFrame *dst, const AVFrame *src);
@@ -593,6 +791,10 @@ void av_frame_unref(AVFrame *frame);
/**
* Move everything contained in src to dst and reset src.
+ *
+ * @warning: dst is not unreferenced, but directly overwritten without reading
+ * or deallocating its contents. Call av_frame_unref(dst) manually
+ * before calling this function to ensure that no memory is leaked.
*/
void av_frame_move_ref(AVFrame *dst, AVFrame *src);
@@ -608,8 +810,14 @@ void av_frame_move_ref(AVFrame *dst, AVFrame *src);
* necessary, allocate and fill AVFrame.extended_data and AVFrame.extended_buf.
* For planar formats, one buffer will be allocated for each plane.
*
+ * @warning: if frame already has been allocated, calling this function will
+ * leak memory. In addition, undefined behavior can occur in certain
+ * cases.
+ *
* @param frame frame in which to store the new buffers.
- * @param align required buffer size alignment
+ * @param align Required buffer size alignment. If equal to 0, alignment will be
+ * chosen automatically for the current CPU. It is highly
+ * recommended to pass 0 here unless you know what you are doing.
*
* @return 0 on success, a negative AVERROR on error.
*/
@@ -688,6 +896,22 @@ AVFrameSideData *av_frame_new_side_data(AVFrame *frame,
enum AVFrameSideDataType type,
int size);
+/**
+ * Add a new side data to a frame from an existing AVBufferRef
+ *
+ * @param frame a frame to which the side data should be added
+ * @param type the type of the added side data
+ * @param buf an AVBufferRef to add as side data. The ownership of
+ * the reference is transferred to the frame.
+ *
+ * @return newly added side data on success, NULL on error. On failure
+ * the frame is unchanged and the AVBufferRef remains owned by
+ * the caller.
+ */
+AVFrameSideData *av_frame_new_side_data_from_buf(AVFrame *frame,
+ enum AVFrameSideDataType type,
+ AVBufferRef *buf);
+
/**
* @return a pointer to the side data of a given type on success, NULL if there
* is no side data with such type in this frame.
@@ -701,6 +925,40 @@ AVFrameSideData *av_frame_get_side_data(const AVFrame *frame,
*/
void av_frame_remove_side_data(AVFrame *frame, enum AVFrameSideDataType type);
+
+/**
+ * Flags for frame cropping.
+ */
+enum {
+ /**
+ * Apply the maximum possible cropping, even if it requires setting the
+ * AVFrame.data[] entries to unaligned pointers. Passing unaligned data
+ * to FFmpeg API is generally not allowed, and causes undefined behavior
+ * (such as crashes). You can pass unaligned data only to FFmpeg APIs that
+ * are explicitly documented to accept it. Use this flag only if you
+ * absolutely know what you are doing.
+ */
+ AV_FRAME_CROP_UNALIGNED = 1 << 0,
+};
+
+/**
+ * Crop the given video AVFrame according to its crop_left/crop_top/crop_right/
+ * crop_bottom fields. If cropping is successful, the function will adjust the
+ * data pointers and the width/height fields, and set the crop fields to 0.
+ *
+ * In all cases, the cropping boundaries will be rounded to the inherent
+ * alignment of the pixel format. In some cases, such as for opaque hwaccel
+ * formats, the left/top cropping is ignored. The crop fields are set to 0 even
+ * if the cropping was rounded or ignored.
+ *
+ * @param frame the frame which should be cropped
+ * @param flags Some combination of AV_FRAME_CROP_* flags, or 0.
+ *
+ * @return >= 0 on success, a negative AVERROR on error. If the cropping fields
+ * were invalid, AVERROR(ERANGE) is returned, and nothing is changed.
+ */
+int av_frame_apply_cropping(AVFrame *frame, int flags);
+
/**
* @return a string identifying the side data type
*/
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hash.h b/neo/libs/ffmpeg-win64/include/libavutil/hash.h
index d4bcbf8c..7693e6bf 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/hash.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hash.h
@@ -18,18 +18,110 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_hash_generic
+ * Generic hashing API
+ */
+
#ifndef AVUTIL_HASH_H
#define AVUTIL_HASH_H
#include
+#include "version.h"
+
+/**
+ * @defgroup lavu_hash Hash Functions
+ * @ingroup lavu_crypto
+ * Hash functions useful in multimedia.
+ *
+ * Hash functions are widely used in multimedia, from error checking and
+ * concealment to internal regression testing. libavutil has efficient
+ * implementations of a variety of hash functions that may be useful for
+ * FFmpeg and other multimedia applications.
+ *
+ * @{
+ *
+ * @defgroup lavu_hash_generic Generic Hashing API
+ * An abstraction layer for all hash functions supported by libavutil.
+ *
+ * If your application needs to support a wide range of different hash
+ * functions, then the Generic Hashing API is for you. It provides a generic,
+ * reusable API for @ref lavu_hash "all hash functions" implemented in libavutil.
+ * If you just need to use one particular hash function, use the @ref lavu_hash
+ * "individual hash" directly.
+ *
+ * @section Sample Code
+ *
+ * A basic template for using the Generic Hashing API follows:
+ *
+ * @code
+ * struct AVHashContext *ctx = NULL;
+ * const char *hash_name = NULL;
+ * uint8_t *output_buf = NULL;
+ *
+ * // Select from a string returned by av_hash_names()
+ * hash_name = ...;
+ *
+ * // Allocate a hash context
+ * ret = av_hash_alloc(&ctx, hash_name);
+ * if (ret < 0)
+ * return ret;
+ *
+ * // Initialize the hash context
+ * av_hash_init(ctx);
+ *
+ * // Update the hash context with data
+ * while (data_left) {
+ * av_hash_update(ctx, data, size);
+ * }
+ *
+ * // Now we have no more data, so it is time to finalize the hash and get the
+ * // output. But we need to first allocate an output buffer. Note that you can
+ * // use any memory allocation function, including malloc(), not just
+ * // av_malloc().
+ * output_buf = av_malloc(av_hash_get_size(ctx));
+ * if (!output_buf)
+ * return AVERROR(ENOMEM);
+ *
+ * // Finalize the hash context.
+ * // You can use any of the av_hash_final*() functions provided, for other
+ * // output formats. If you do so, be sure to adjust the memory allocation
+ * // above. See the function documentation below for the exact amount of extra
+ * // memory needed.
+ * av_hash_final(ctx, output_buffer);
+ *
+ * // Free the context
+ * av_hash_freep(&ctx);
+ * @endcode
+ *
+ * @section Hash Function-Specific Information
+ * If the CRC32 hash is selected, the #AV_CRC_32_IEEE polynomial will be
+ * used.
+ *
+ * If the Murmur3 hash is selected, the default seed will be used. See @ref
+ * lavu_murmur3_seedinfo "Murmur3" for more information.
+ *
+ * @{
+ */
+
+/**
+ * @example ffhash.c
+ * This example is a simple command line application that takes one or more
+ * arguments. It demonstrates a typical use of the hashing API with allocation,
+ * initialization, updating, and finalizing.
+ */
+
struct AVHashContext;
/**
* Allocate a hash context for the algorithm specified by name.
*
* @return >= 0 for success, a negative error code for failure
- * @note The context is not initialized, you must call av_hash_init().
+ *
+ * @note The context is not initialized after a call to this function; you must
+ * call av_hash_init() to do so.
*/
int av_hash_alloc(struct AVHashContext **ctx, const char *name);
@@ -38,8 +130,8 @@ int av_hash_alloc(struct AVHashContext **ctx, const char *name);
*
* This function can be used to enumerate the algorithms.
*
- * @param i index of the hash algorithm, starting from 0
- * @return a pointer to a static string or NULL if i is out of range
+ * @param[in] i Index of the hash algorithm, starting from 0
+ * @return Pointer to a static string or `NULL` if `i` is out of range
*/
const char *av_hash_names(int i);
@@ -49,64 +141,129 @@ const char *av_hash_names(int i);
const char *av_hash_get_name(const struct AVHashContext *ctx);
/**
- * Maximum value that av_hash_get_size will currently return.
+ * Maximum value that av_hash_get_size() will currently return.
*
- * You can use this if you absolutely want or need to use static allocation
- * and are fine with not supporting hashes newly added to libavutil without
- * recompilation.
- * Note that you still need to check against av_hash_get_size, adding new hashes
- * with larger sizes will not be considered an ABI change and should not cause
- * your code to overflow a buffer.
+ * You can use this if you absolutely want or need to use static allocation for
+ * the output buffer and are fine with not supporting hashes newly added to
+ * libavutil without recompilation.
+ *
+ * @warning
+ * Adding new hashes with larger sizes, and increasing the macro while doing
+ * so, will not be considered an ABI change. To prevent your code from
+ * overflowing a buffer, either dynamically allocate the output buffer with
+ * av_hash_get_size(), or limit your use of the Hashing API to hashes that are
+ * already in FFmpeg during the time of compilation.
*/
#define AV_HASH_MAX_SIZE 64
/**
* Get the size of the resulting hash value in bytes.
*
- * The pointer passed to av_hash_final have space for at least this many bytes.
+ * The maximum value this function will currently return is available as macro
+ * #AV_HASH_MAX_SIZE.
+ *
+ * @param[in] ctx Hash context
+ * @return Size of the hash value in bytes
*/
int av_hash_get_size(const struct AVHashContext *ctx);
/**
* Initialize or reset a hash context.
+ *
+ * @param[in,out] ctx Hash context
*/
void av_hash_init(struct AVHashContext *ctx);
/**
* Update a hash context with additional data.
+ *
+ * @param[in,out] ctx Hash context
+ * @param[in] src Data to be added to the hash context
+ * @param[in] len Size of the additional data
*/
+#if FF_API_CRYPTO_SIZE_T
void av_hash_update(struct AVHashContext *ctx, const uint8_t *src, int len);
+#else
+void av_hash_update(struct AVHashContext *ctx, const uint8_t *src, size_t len);
+#endif
/**
* Finalize a hash context and compute the actual hash value.
+ *
+ * The minimum size of `dst` buffer is given by av_hash_get_size() or
+ * #AV_HASH_MAX_SIZE. The use of the latter macro is discouraged.
+ *
+ * It is not safe to update or finalize a hash context again, if it has already
+ * been finalized.
+ *
+ * @param[in,out] ctx Hash context
+ * @param[out] dst Where the final hash value will be stored
+ *
+ * @see av_hash_final_bin() provides an alternative API
*/
void av_hash_final(struct AVHashContext *ctx, uint8_t *dst);
/**
- * Finalize a hash context and compute the actual hash value.
- * If size is smaller than the hash size, the hash is truncated;
- * if size is larger, the buffer is padded with 0.
+ * Finalize a hash context and store the actual hash value in a buffer.
+ *
+ * It is not safe to update or finalize a hash context again, if it has already
+ * been finalized.
+ *
+ * If `size` is smaller than the hash size (given by av_hash_get_size()), the
+ * hash is truncated; if size is larger, the buffer is padded with 0.
+ *
+ * @param[in,out] ctx Hash context
+ * @param[out] dst Where the final hash value will be stored
+ * @param[in] size Number of bytes to write to `dst`
*/
void av_hash_final_bin(struct AVHashContext *ctx, uint8_t *dst, int size);
/**
- * Finalize a hash context and compute the actual hash value as a hex string.
+ * Finalize a hash context and store the hexadecimal representation of the
+ * actual hash value as a string.
+ *
+ * It is not safe to update or finalize a hash context again, if it has already
+ * been finalized.
+ *
* The string is always 0-terminated.
- * If size is smaller than 2 * hash_size + 1, the hex string is truncated.
+ *
+ * If `size` is smaller than `2 * hash_size + 1`, where `hash_size` is the
+ * value returned by av_hash_get_size(), the string will be truncated.
+ *
+ * @param[in,out] ctx Hash context
+ * @param[out] dst Where the string will be stored
+ * @param[in] size Maximum number of bytes to write to `dst`
*/
void av_hash_final_hex(struct AVHashContext *ctx, uint8_t *dst, int size);
/**
- * Finalize a hash context and compute the actual hash value as a base64 string.
+ * Finalize a hash context and store the Base64 representation of the
+ * actual hash value as a string.
+ *
+ * It is not safe to update or finalize a hash context again, if it has already
+ * been finalized.
+ *
* The string is always 0-terminated.
- * If size is smaller than AV_BASE64_SIZE(hash_size), the base64 string is
- * truncated.
+ *
+ * If `size` is smaller than AV_BASE64_SIZE(hash_size), where `hash_size` is
+ * the value returned by av_hash_get_size(), the string will be truncated.
+ *
+ * @param[in,out] ctx Hash context
+ * @param[out] dst Where the final hash value will be stored
+ * @param[in] size Maximum number of bytes to write to `dst`
*/
void av_hash_final_b64(struct AVHashContext *ctx, uint8_t *dst, int size);
/**
- * Free hash context.
+ * Free hash context and set hash context pointer to `NULL`.
+ *
+ * @param[in,out] ctx Pointer to hash context
*/
void av_hash_freep(struct AVHashContext **ctx);
+/**
+ * @}
+ * @}
+ */
+
#endif /* AVUTIL_HASH_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hdr_dynamic_metadata.h b/neo/libs/ffmpeg-win64/include/libavutil/hdr_dynamic_metadata.h
new file mode 100644
index 00000000..2d72de56
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hdr_dynamic_metadata.h
@@ -0,0 +1,343 @@
+/*
+ * Copyright (c) 2018 Mohammad Izadi
+ *
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HDR_DYNAMIC_METADATA_H
+#define AVUTIL_HDR_DYNAMIC_METADATA_H
+
+#include "frame.h"
+#include "rational.h"
+
+/**
+ * Option for overlapping elliptical pixel selectors in an image.
+ */
+enum AVHDRPlusOverlapProcessOption {
+ AV_HDR_PLUS_OVERLAP_PROCESS_WEIGHTED_AVERAGING = 0,
+ AV_HDR_PLUS_OVERLAP_PROCESS_LAYERING = 1,
+};
+
+/**
+ * Represents the percentile at a specific percentage in
+ * a distribution.
+ */
+typedef struct AVHDRPlusPercentile {
+ /**
+ * The percentage value corresponding to a specific percentile linearized
+ * RGB value in the processing window in the scene. The value shall be in
+ * the range of 0 to100, inclusive.
+ */
+ uint8_t percentage;
+
+ /**
+ * The linearized maxRGB value at a specific percentile in the processing
+ * window in the scene. The value shall be in the range of 0 to 1, inclusive
+ * and in multiples of 0.00001.
+ */
+ AVRational percentile;
+} AVHDRPlusPercentile;
+
+/**
+ * Color transform parameters at a processing window in a dynamic metadata for
+ * SMPTE 2094-40.
+ */
+typedef struct AVHDRPlusColorTransformParams {
+ /**
+ * The relative x coordinate of the top left pixel of the processing
+ * window. The value shall be in the range of 0 and 1, inclusive and
+ * in multiples of 1/(width of Picture - 1). The value 1 corresponds
+ * to the absolute coordinate of width of Picture - 1. The value for
+ * first processing window shall be 0.
+ */
+ AVRational window_upper_left_corner_x;
+
+ /**
+ * The relative y coordinate of the top left pixel of the processing
+ * window. The value shall be in the range of 0 and 1, inclusive and
+ * in multiples of 1/(height of Picture - 1). The value 1 corresponds
+ * to the absolute coordinate of height of Picture - 1. The value for
+ * first processing window shall be 0.
+ */
+ AVRational window_upper_left_corner_y;
+
+ /**
+ * The relative x coordinate of the bottom right pixel of the processing
+ * window. The value shall be in the range of 0 and 1, inclusive and
+ * in multiples of 1/(width of Picture - 1). The value 1 corresponds
+ * to the absolute coordinate of width of Picture - 1. The value for
+ * first processing window shall be 1.
+ */
+ AVRational window_lower_right_corner_x;
+
+ /**
+ * The relative y coordinate of the bottom right pixel of the processing
+ * window. The value shall be in the range of 0 and 1, inclusive and
+ * in multiples of 1/(height of Picture - 1). The value 1 corresponds
+ * to the absolute coordinate of height of Picture - 1. The value for
+ * first processing window shall be 1.
+ */
+ AVRational window_lower_right_corner_y;
+
+ /**
+ * The x coordinate of the center position of the concentric internal and
+ * external ellipses of the elliptical pixel selector in the processing
+ * window. The value shall be in the range of 0 to (width of Picture - 1),
+ * inclusive and in multiples of 1 pixel.
+ */
+ uint16_t center_of_ellipse_x;
+
+ /**
+ * The y coordinate of the center position of the concentric internal and
+ * external ellipses of the elliptical pixel selector in the processing
+ * window. The value shall be in the range of 0 to (height of Picture - 1),
+ * inclusive and in multiples of 1 pixel.
+ */
+ uint16_t center_of_ellipse_y;
+
+ /**
+ * The clockwise rotation angle in degree of arc with respect to the
+ * positive direction of the x-axis of the concentric internal and external
+ * ellipses of the elliptical pixel selector in the processing window. The
+ * value shall be in the range of 0 to 180, inclusive and in multiples of 1.
+ */
+ uint8_t rotation_angle;
+
+ /**
+ * The semi-major axis value of the internal ellipse of the elliptical pixel
+ * selector in amount of pixels in the processing window. The value shall be
+ * in the range of 1 to 65535, inclusive and in multiples of 1 pixel.
+ */
+ uint16_t semimajor_axis_internal_ellipse;
+
+ /**
+ * The semi-major axis value of the external ellipse of the elliptical pixel
+ * selector in amount of pixels in the processing window. The value
+ * shall not be less than semimajor_axis_internal_ellipse of the current
+ * processing window. The value shall be in the range of 1 to 65535,
+ * inclusive and in multiples of 1 pixel.
+ */
+ uint16_t semimajor_axis_external_ellipse;
+
+ /**
+ * The semi-minor axis value of the external ellipse of the elliptical pixel
+ * selector in amount of pixels in the processing window. The value shall be
+ * in the range of 1 to 65535, inclusive and in multiples of 1 pixel.
+ */
+ uint16_t semiminor_axis_external_ellipse;
+
+ /**
+ * Overlap process option indicates one of the two methods of combining
+ * rendered pixels in the processing window in an image with at least one
+ * elliptical pixel selector. For overlapping elliptical pixel selectors
+ * in an image, overlap_process_option shall have the same value.
+ */
+ enum AVHDRPlusOverlapProcessOption overlap_process_option;
+
+ /**
+ * The maximum of the color components of linearized RGB values in the
+ * processing window in the scene. The values should be in the range of 0 to
+ * 1, inclusive and in multiples of 0.00001. maxscl[ 0 ], maxscl[ 1 ], and
+ * maxscl[ 2 ] are corresponding to R, G, B color components respectively.
+ */
+ AVRational maxscl[3];
+
+ /**
+ * The average of linearized maxRGB values in the processing window in the
+ * scene. The value should be in the range of 0 to 1, inclusive and in
+ * multiples of 0.00001.
+ */
+ AVRational average_maxrgb;
+
+ /**
+ * The number of linearized maxRGB values at given percentiles in the
+ * processing window in the scene. The maximum value shall be 15.
+ */
+ uint8_t num_distribution_maxrgb_percentiles;
+
+ /**
+ * The linearized maxRGB values at given percentiles in the
+ * processing window in the scene.
+ */
+ AVHDRPlusPercentile distribution_maxrgb[15];
+
+ /**
+ * The fraction of selected pixels in the image that contains the brightest
+ * pixel in the scene. The value shall be in the range of 0 to 1, inclusive
+ * and in multiples of 0.001.
+ */
+ AVRational fraction_bright_pixels;
+
+ /**
+ * This flag indicates that the metadata for the tone mapping function in
+ * the processing window is present (for value of 1).
+ */
+ uint8_t tone_mapping_flag;
+
+ /**
+ * The x coordinate of the separation point between the linear part and the
+ * curved part of the tone mapping function. The value shall be in the range
+ * of 0 to 1, excluding 0 and in multiples of 1/4095.
+ */
+ AVRational knee_point_x;
+
+ /**
+ * The y coordinate of the separation point between the linear part and the
+ * curved part of the tone mapping function. The value shall be in the range
+ * of 0 to 1, excluding 0 and in multiples of 1/4095.
+ */
+ AVRational knee_point_y;
+
+ /**
+ * The number of the intermediate anchor parameters of the tone mapping
+ * function in the processing window. The maximum value shall be 15.
+ */
+ uint8_t num_bezier_curve_anchors;
+
+ /**
+ * The intermediate anchor parameters of the tone mapping function in the
+ * processing window in the scene. The values should be in the range of 0
+ * to 1, inclusive and in multiples of 1/1023.
+ */
+ AVRational bezier_curve_anchors[15];
+
+ /**
+ * This flag shall be equal to 0 in bitstreams conforming to this version of
+ * this Specification. Other values are reserved for future use.
+ */
+ uint8_t color_saturation_mapping_flag;
+
+ /**
+ * The color saturation gain in the processing window in the scene. The
+ * value shall be in the range of 0 to 63/8, inclusive and in multiples of
+ * 1/8. The default value shall be 1.
+ */
+ AVRational color_saturation_weight;
+} AVHDRPlusColorTransformParams;
+
+/**
+ * This struct represents dynamic metadata for color volume transform -
+ * application 4 of SMPTE 2094-40:2016 standard.
+ *
+ * To be used as payload of a AVFrameSideData or AVPacketSideData with the
+ * appropriate type.
+ *
+ * @note The struct should be allocated with
+ * av_dynamic_hdr_plus_alloc() and its size is not a part of
+ * the public ABI.
+ */
+typedef struct AVDynamicHDRPlus {
+ /**
+ * Country code by Rec. ITU-T T.35 Annex A. The value shall be 0xB5.
+ */
+ uint8_t itu_t_t35_country_code;
+
+ /**
+ * Application version in the application defining document in ST-2094
+ * suite. The value shall be set to 0.
+ */
+ uint8_t application_version;
+
+ /**
+ * The number of processing windows. The value shall be in the range
+ * of 1 to 3, inclusive.
+ */
+ uint8_t num_windows;
+
+ /**
+ * The color transform parameters for every processing window.
+ */
+ AVHDRPlusColorTransformParams params[3];
+
+ /**
+ * The nominal maximum display luminance of the targeted system display,
+ * in units of 0.0001 candelas per square metre. The value shall be in
+ * the range of 0 to 10000, inclusive.
+ */
+ AVRational targeted_system_display_maximum_luminance;
+
+ /**
+ * This flag shall be equal to 0 in bit streams conforming to this version
+ * of this Specification. The value 1 is reserved for future use.
+ */
+ uint8_t targeted_system_display_actual_peak_luminance_flag;
+
+ /**
+ * The number of rows in the targeted system_display_actual_peak_luminance
+ * array. The value shall be in the range of 2 to 25, inclusive.
+ */
+ uint8_t num_rows_targeted_system_display_actual_peak_luminance;
+
+ /**
+ * The number of columns in the
+ * targeted_system_display_actual_peak_luminance array. The value shall be
+ * in the range of 2 to 25, inclusive.
+ */
+ uint8_t num_cols_targeted_system_display_actual_peak_luminance;
+
+ /**
+ * The normalized actual peak luminance of the targeted system display. The
+ * values should be in the range of 0 to 1, inclusive and in multiples of
+ * 1/15.
+ */
+ AVRational targeted_system_display_actual_peak_luminance[25][25];
+
+ /**
+ * This flag shall be equal to 0 in bitstreams conforming to this version of
+ * this Specification. The value 1 is reserved for future use.
+ */
+ uint8_t mastering_display_actual_peak_luminance_flag;
+
+ /**
+ * The number of rows in the mastering_display_actual_peak_luminance array.
+ * The value shall be in the range of 2 to 25, inclusive.
+ */
+ uint8_t num_rows_mastering_display_actual_peak_luminance;
+
+ /**
+ * The number of columns in the mastering_display_actual_peak_luminance
+ * array. The value shall be in the range of 2 to 25, inclusive.
+ */
+ uint8_t num_cols_mastering_display_actual_peak_luminance;
+
+ /**
+ * The normalized actual peak luminance of the mastering display used for
+ * mastering the image essence. The values should be in the range of 0 to 1,
+ * inclusive and in multiples of 1/15.
+ */
+ AVRational mastering_display_actual_peak_luminance[25][25];
+} AVDynamicHDRPlus;
+
+/**
+ * Allocate an AVDynamicHDRPlus structure and set its fields to
+ * default values. The resulting struct can be freed using av_freep().
+ *
+ * @return An AVDynamicHDRPlus filled with default values or NULL
+ * on failure.
+ */
+AVDynamicHDRPlus *av_dynamic_hdr_plus_alloc(size_t *size);
+
+/**
+ * Allocate a complete AVDynamicHDRPlus and add it to the frame.
+ * @param frame The frame which side data is added to.
+ *
+ * @return The AVDynamicHDRPlus structure to be filled by caller or NULL
+ * on failure.
+ */
+AVDynamicHDRPlus *av_dynamic_hdr_plus_create_side_data(AVFrame *frame);
+
+#endif /* AVUTIL_HDR_DYNAMIC_METADATA_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hmac.h b/neo/libs/ffmpeg-win64/include/libavutil/hmac.h
index 576a0a4f..412e9507 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/hmac.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hmac.h
@@ -35,7 +35,7 @@ enum AVHMACType {
AV_HMAC_SHA1,
AV_HMAC_SHA224,
AV_HMAC_SHA256,
- AV_HMAC_SHA384 = 12,
+ AV_HMAC_SHA384,
AV_HMAC_SHA512,
};
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext.h
new file mode 100644
index 00000000..f5a4b623
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext.h
@@ -0,0 +1,584 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_H
+#define AVUTIL_HWCONTEXT_H
+
+#include "buffer.h"
+#include "frame.h"
+#include "log.h"
+#include "pixfmt.h"
+
+enum AVHWDeviceType {
+ AV_HWDEVICE_TYPE_NONE,
+ AV_HWDEVICE_TYPE_VDPAU,
+ AV_HWDEVICE_TYPE_CUDA,
+ AV_HWDEVICE_TYPE_VAAPI,
+ AV_HWDEVICE_TYPE_DXVA2,
+ AV_HWDEVICE_TYPE_QSV,
+ AV_HWDEVICE_TYPE_VIDEOTOOLBOX,
+ AV_HWDEVICE_TYPE_D3D11VA,
+ AV_HWDEVICE_TYPE_DRM,
+ AV_HWDEVICE_TYPE_OPENCL,
+ AV_HWDEVICE_TYPE_MEDIACODEC,
+};
+
+typedef struct AVHWDeviceInternal AVHWDeviceInternal;
+
+/**
+ * This struct aggregates all the (hardware/vendor-specific) "high-level" state,
+ * i.e. state that is not tied to a concrete processing configuration.
+ * E.g., in an API that supports hardware-accelerated encoding and decoding,
+ * this struct will (if possible) wrap the state that is common to both encoding
+ * and decoding and from which specific instances of encoders or decoders can be
+ * derived.
+ *
+ * This struct is reference-counted with the AVBuffer mechanism. The
+ * av_hwdevice_ctx_alloc() constructor yields a reference, whose data field
+ * points to the actual AVHWDeviceContext. Further objects derived from
+ * AVHWDeviceContext (such as AVHWFramesContext, describing a frame pool with
+ * specific properties) will hold an internal reference to it. After all the
+ * references are released, the AVHWDeviceContext itself will be freed,
+ * optionally invoking a user-specified callback for uninitializing the hardware
+ * state.
+ */
+typedef struct AVHWDeviceContext {
+ /**
+ * A class for logging. Set by av_hwdevice_ctx_alloc().
+ */
+ const AVClass *av_class;
+
+ /**
+ * Private data used internally by libavutil. Must not be accessed in any
+ * way by the caller.
+ */
+ AVHWDeviceInternal *internal;
+
+ /**
+ * This field identifies the underlying API used for hardware access.
+ *
+ * This field is set when this struct is allocated and never changed
+ * afterwards.
+ */
+ enum AVHWDeviceType type;
+
+ /**
+ * The format-specific data, allocated and freed by libavutil along with
+ * this context.
+ *
+ * Should be cast by the user to the format-specific context defined in the
+ * corresponding header (hwcontext_*.h) and filled as described in the
+ * documentation before calling av_hwdevice_ctx_init().
+ *
+ * After calling av_hwdevice_ctx_init() this struct should not be modified
+ * by the caller.
+ */
+ void *hwctx;
+
+ /**
+ * This field may be set by the caller before calling av_hwdevice_ctx_init().
+ *
+ * If non-NULL, this callback will be called when the last reference to
+ * this context is unreferenced, immediately before it is freed.
+ *
+ * @note when other objects (e.g an AVHWFramesContext) are derived from this
+ * struct, this callback will be invoked after all such child objects
+ * are fully uninitialized and their respective destructors invoked.
+ */
+ void (*free)(struct AVHWDeviceContext *ctx);
+
+ /**
+ * Arbitrary user data, to be used e.g. by the free() callback.
+ */
+ void *user_opaque;
+} AVHWDeviceContext;
+
+typedef struct AVHWFramesInternal AVHWFramesInternal;
+
+/**
+ * This struct describes a set or pool of "hardware" frames (i.e. those with
+ * data not located in normal system memory). All the frames in the pool are
+ * assumed to be allocated in the same way and interchangeable.
+ *
+ * This struct is reference-counted with the AVBuffer mechanism and tied to a
+ * given AVHWDeviceContext instance. The av_hwframe_ctx_alloc() constructor
+ * yields a reference, whose data field points to the actual AVHWFramesContext
+ * struct.
+ */
+typedef struct AVHWFramesContext {
+ /**
+ * A class for logging.
+ */
+ const AVClass *av_class;
+
+ /**
+ * Private data used internally by libavutil. Must not be accessed in any
+ * way by the caller.
+ */
+ AVHWFramesInternal *internal;
+
+ /**
+ * A reference to the parent AVHWDeviceContext. This reference is owned and
+ * managed by the enclosing AVHWFramesContext, but the caller may derive
+ * additional references from it.
+ */
+ AVBufferRef *device_ref;
+
+ /**
+ * The parent AVHWDeviceContext. This is simply a pointer to
+ * device_ref->data provided for convenience.
+ *
+ * Set by libavutil in av_hwframe_ctx_init().
+ */
+ AVHWDeviceContext *device_ctx;
+
+ /**
+ * The format-specific data, allocated and freed automatically along with
+ * this context.
+ *
+ * Should be cast by the user to the format-specific context defined in the
+ * corresponding header (hwframe_*.h) and filled as described in the
+ * documentation before calling av_hwframe_ctx_init().
+ *
+ * After any frames using this context are created, the contents of this
+ * struct should not be modified by the caller.
+ */
+ void *hwctx;
+
+ /**
+ * This field may be set by the caller before calling av_hwframe_ctx_init().
+ *
+ * If non-NULL, this callback will be called when the last reference to
+ * this context is unreferenced, immediately before it is freed.
+ */
+ void (*free)(struct AVHWFramesContext *ctx);
+
+ /**
+ * Arbitrary user data, to be used e.g. by the free() callback.
+ */
+ void *user_opaque;
+
+ /**
+ * A pool from which the frames are allocated by av_hwframe_get_buffer().
+ * This field may be set by the caller before calling av_hwframe_ctx_init().
+ * The buffers returned by calling av_buffer_pool_get() on this pool must
+ * have the properties described in the documentation in the corresponding hw
+ * type's header (hwcontext_*.h). The pool will be freed strictly before
+ * this struct's free() callback is invoked.
+ *
+ * This field may be NULL, then libavutil will attempt to allocate a pool
+ * internally. Note that certain device types enforce pools allocated at
+ * fixed size (frame count), which cannot be extended dynamically. In such a
+ * case, initial_pool_size must be set appropriately.
+ */
+ AVBufferPool *pool;
+
+ /**
+ * Initial size of the frame pool. If a device type does not support
+ * dynamically resizing the pool, then this is also the maximum pool size.
+ *
+ * May be set by the caller before calling av_hwframe_ctx_init(). Must be
+ * set if pool is NULL and the device type does not support dynamic pools.
+ */
+ int initial_pool_size;
+
+ /**
+ * The pixel format identifying the underlying HW surface type.
+ *
+ * Must be a hwaccel format, i.e. the corresponding descriptor must have the
+ * AV_PIX_FMT_FLAG_HWACCEL flag set.
+ *
+ * Must be set by the user before calling av_hwframe_ctx_init().
+ */
+ enum AVPixelFormat format;
+
+ /**
+ * The pixel format identifying the actual data layout of the hardware
+ * frames.
+ *
+ * Must be set by the caller before calling av_hwframe_ctx_init().
+ *
+ * @note when the underlying API does not provide the exact data layout, but
+ * only the colorspace/bit depth, this field should be set to the fully
+ * planar version of that format (e.g. for 8-bit 420 YUV it should be
+ * AV_PIX_FMT_YUV420P, not AV_PIX_FMT_NV12 or anything else).
+ */
+ enum AVPixelFormat sw_format;
+
+ /**
+ * The allocated dimensions of the frames in this pool.
+ *
+ * Must be set by the user before calling av_hwframe_ctx_init().
+ */
+ int width, height;
+} AVHWFramesContext;
+
+/**
+ * Look up an AVHWDeviceType by name.
+ *
+ * @param name String name of the device type (case-insensitive).
+ * @return The type from enum AVHWDeviceType, or AV_HWDEVICE_TYPE_NONE if
+ * not found.
+ */
+enum AVHWDeviceType av_hwdevice_find_type_by_name(const char *name);
+
+/** Get the string name of an AVHWDeviceType.
+ *
+ * @param type Type from enum AVHWDeviceType.
+ * @return Pointer to a static string containing the name, or NULL if the type
+ * is not valid.
+ */
+const char *av_hwdevice_get_type_name(enum AVHWDeviceType type);
+
+/**
+ * Iterate over supported device types.
+ *
+ * @param type AV_HWDEVICE_TYPE_NONE initially, then the previous type
+ * returned by this function in subsequent iterations.
+ * @return The next usable device type from enum AVHWDeviceType, or
+ * AV_HWDEVICE_TYPE_NONE if there are no more.
+ */
+enum AVHWDeviceType av_hwdevice_iterate_types(enum AVHWDeviceType prev);
+
+/**
+ * Allocate an AVHWDeviceContext for a given hardware type.
+ *
+ * @param type the type of the hardware device to allocate.
+ * @return a reference to the newly created AVHWDeviceContext on success or NULL
+ * on failure.
+ */
+AVBufferRef *av_hwdevice_ctx_alloc(enum AVHWDeviceType type);
+
+/**
+ * Finalize the device context before use. This function must be called after
+ * the context is filled with all the required information and before it is
+ * used in any way.
+ *
+ * @param ref a reference to the AVHWDeviceContext
+ * @return 0 on success, a negative AVERROR code on failure
+ */
+int av_hwdevice_ctx_init(AVBufferRef *ref);
+
+/**
+ * Open a device of the specified type and create an AVHWDeviceContext for it.
+ *
+ * This is a convenience function intended to cover the simple cases. Callers
+ * who need to fine-tune device creation/management should open the device
+ * manually and then wrap it in an AVHWDeviceContext using
+ * av_hwdevice_ctx_alloc()/av_hwdevice_ctx_init().
+ *
+ * The returned context is already initialized and ready for use, the caller
+ * should not call av_hwdevice_ctx_init() on it. The user_opaque/free fields of
+ * the created AVHWDeviceContext are set by this function and should not be
+ * touched by the caller.
+ *
+ * @param device_ctx On success, a reference to the newly-created device context
+ * will be written here. The reference is owned by the caller
+ * and must be released with av_buffer_unref() when no longer
+ * needed. On failure, NULL will be written to this pointer.
+ * @param type The type of the device to create.
+ * @param device A type-specific string identifying the device to open.
+ * @param opts A dictionary of additional (type-specific) options to use in
+ * opening the device. The dictionary remains owned by the caller.
+ * @param flags currently unused
+ *
+ * @return 0 on success, a negative AVERROR code on failure.
+ */
+int av_hwdevice_ctx_create(AVBufferRef **device_ctx, enum AVHWDeviceType type,
+ const char *device, AVDictionary *opts, int flags);
+
+/**
+ * Create a new device of the specified type from an existing device.
+ *
+ * If the source device is a device of the target type or was originally
+ * derived from such a device (possibly through one or more intermediate
+ * devices of other types), then this will return a reference to the
+ * existing device of the same type as is requested.
+ *
+ * Otherwise, it will attempt to derive a new device from the given source
+ * device. If direct derivation to the new type is not implemented, it will
+ * attempt the same derivation from each ancestor of the source device in
+ * turn looking for an implemented derivation method.
+ *
+ * @param dst_ctx On success, a reference to the newly-created
+ * AVHWDeviceContext.
+ * @param type The type of the new device to create.
+ * @param src_ctx A reference to an existing AVHWDeviceContext which will be
+ * used to create the new device.
+ * @param flags Currently unused; should be set to zero.
+ * @return Zero on success, a negative AVERROR code on failure.
+ */
+int av_hwdevice_ctx_create_derived(AVBufferRef **dst_ctx,
+ enum AVHWDeviceType type,
+ AVBufferRef *src_ctx, int flags);
+
+
+/**
+ * Allocate an AVHWFramesContext tied to a given device context.
+ *
+ * @param device_ctx a reference to a AVHWDeviceContext. This function will make
+ * a new reference for internal use, the one passed to the
+ * function remains owned by the caller.
+ * @return a reference to the newly created AVHWFramesContext on success or NULL
+ * on failure.
+ */
+AVBufferRef *av_hwframe_ctx_alloc(AVBufferRef *device_ctx);
+
+/**
+ * Finalize the context before use. This function must be called after the
+ * context is filled with all the required information and before it is attached
+ * to any frames.
+ *
+ * @param ref a reference to the AVHWFramesContext
+ * @return 0 on success, a negative AVERROR code on failure
+ */
+int av_hwframe_ctx_init(AVBufferRef *ref);
+
+/**
+ * Allocate a new frame attached to the given AVHWFramesContext.
+ *
+ * @param hwframe_ctx a reference to an AVHWFramesContext
+ * @param frame an empty (freshly allocated or unreffed) frame to be filled with
+ * newly allocated buffers.
+ * @param flags currently unused, should be set to zero
+ * @return 0 on success, a negative AVERROR code on failure
+ */
+int av_hwframe_get_buffer(AVBufferRef *hwframe_ctx, AVFrame *frame, int flags);
+
+/**
+ * Copy data to or from a hw surface. At least one of dst/src must have an
+ * AVHWFramesContext attached.
+ *
+ * If src has an AVHWFramesContext attached, then the format of dst (if set)
+ * must use one of the formats returned by av_hwframe_transfer_get_formats(src,
+ * AV_HWFRAME_TRANSFER_DIRECTION_FROM).
+ * If dst has an AVHWFramesContext attached, then the format of src must use one
+ * of the formats returned by av_hwframe_transfer_get_formats(dst,
+ * AV_HWFRAME_TRANSFER_DIRECTION_TO)
+ *
+ * dst may be "clean" (i.e. with data/buf pointers unset), in which case the
+ * data buffers will be allocated by this function using av_frame_get_buffer().
+ * If dst->format is set, then this format will be used, otherwise (when
+ * dst->format is AV_PIX_FMT_NONE) the first acceptable format will be chosen.
+ *
+ * The two frames must have matching allocated dimensions (i.e. equal to
+ * AVHWFramesContext.width/height), since not all device types support
+ * transferring a sub-rectangle of the whole surface. The display dimensions
+ * (i.e. AVFrame.width/height) may be smaller than the allocated dimensions, but
+ * also have to be equal for both frames. When the display dimensions are
+ * smaller than the allocated dimensions, the content of the padding in the
+ * destination frame is unspecified.
+ *
+ * @param dst the destination frame. dst is not touched on failure.
+ * @param src the source frame.
+ * @param flags currently unused, should be set to zero
+ * @return 0 on success, a negative AVERROR error code on failure.
+ */
+int av_hwframe_transfer_data(AVFrame *dst, const AVFrame *src, int flags);
+
+enum AVHWFrameTransferDirection {
+ /**
+ * Transfer the data from the queried hw frame.
+ */
+ AV_HWFRAME_TRANSFER_DIRECTION_FROM,
+
+ /**
+ * Transfer the data to the queried hw frame.
+ */
+ AV_HWFRAME_TRANSFER_DIRECTION_TO,
+};
+
+/**
+ * Get a list of possible source or target formats usable in
+ * av_hwframe_transfer_data().
+ *
+ * @param hwframe_ctx the frame context to obtain the information for
+ * @param dir the direction of the transfer
+ * @param formats the pointer to the output format list will be written here.
+ * The list is terminated with AV_PIX_FMT_NONE and must be freed
+ * by the caller when no longer needed using av_free().
+ * If this function returns successfully, the format list will
+ * have at least one item (not counting the terminator).
+ * On failure, the contents of this pointer are unspecified.
+ * @param flags currently unused, should be set to zero
+ * @return 0 on success, a negative AVERROR code on failure.
+ */
+int av_hwframe_transfer_get_formats(AVBufferRef *hwframe_ctx,
+ enum AVHWFrameTransferDirection dir,
+ enum AVPixelFormat **formats, int flags);
+
+
+/**
+ * This struct describes the constraints on hardware frames attached to
+ * a given device with a hardware-specific configuration. This is returned
+ * by av_hwdevice_get_hwframe_constraints() and must be freed by
+ * av_hwframe_constraints_free() after use.
+ */
+typedef struct AVHWFramesConstraints {
+ /**
+ * A list of possible values for format in the hw_frames_ctx,
+ * terminated by AV_PIX_FMT_NONE. This member will always be filled.
+ */
+ enum AVPixelFormat *valid_hw_formats;
+
+ /**
+ * A list of possible values for sw_format in the hw_frames_ctx,
+ * terminated by AV_PIX_FMT_NONE. Can be NULL if this information is
+ * not known.
+ */
+ enum AVPixelFormat *valid_sw_formats;
+
+ /**
+ * The minimum size of frames in this hw_frames_ctx.
+ * (Zero if not known.)
+ */
+ int min_width;
+ int min_height;
+
+ /**
+ * The maximum size of frames in this hw_frames_ctx.
+ * (INT_MAX if not known / no limit.)
+ */
+ int max_width;
+ int max_height;
+} AVHWFramesConstraints;
+
+/**
+ * Allocate a HW-specific configuration structure for a given HW device.
+ * After use, the user must free all members as required by the specific
+ * hardware structure being used, then free the structure itself with
+ * av_free().
+ *
+ * @param device_ctx a reference to the associated AVHWDeviceContext.
+ * @return The newly created HW-specific configuration structure on
+ * success or NULL on failure.
+ */
+void *av_hwdevice_hwconfig_alloc(AVBufferRef *device_ctx);
+
+/**
+ * Get the constraints on HW frames given a device and the HW-specific
+ * configuration to be used with that device. If no HW-specific
+ * configuration is provided, returns the maximum possible capabilities
+ * of the device.
+ *
+ * @param ref a reference to the associated AVHWDeviceContext.
+ * @param hwconfig a filled HW-specific configuration structure, or NULL
+ * to return the maximum possible capabilities of the device.
+ * @return AVHWFramesConstraints structure describing the constraints
+ * on the device, or NULL if not available.
+ */
+AVHWFramesConstraints *av_hwdevice_get_hwframe_constraints(AVBufferRef *ref,
+ const void *hwconfig);
+
+/**
+ * Free an AVHWFrameConstraints structure.
+ *
+ * @param constraints The (filled or unfilled) AVHWFrameConstraints structure.
+ */
+void av_hwframe_constraints_free(AVHWFramesConstraints **constraints);
+
+
+/**
+ * Flags to apply to frame mappings.
+ */
+enum {
+ /**
+ * The mapping must be readable.
+ */
+ AV_HWFRAME_MAP_READ = 1 << 0,
+ /**
+ * The mapping must be writeable.
+ */
+ AV_HWFRAME_MAP_WRITE = 1 << 1,
+ /**
+ * The mapped frame will be overwritten completely in subsequent
+ * operations, so the current frame data need not be loaded. Any values
+ * which are not overwritten are unspecified.
+ */
+ AV_HWFRAME_MAP_OVERWRITE = 1 << 2,
+ /**
+ * The mapping must be direct. That is, there must not be any copying in
+ * the map or unmap steps. Note that performance of direct mappings may
+ * be much lower than normal memory.
+ */
+ AV_HWFRAME_MAP_DIRECT = 1 << 3,
+};
+
+/**
+ * Map a hardware frame.
+ *
+ * This has a number of different possible effects, depending on the format
+ * and origin of the src and dst frames. On input, src should be a usable
+ * frame with valid buffers and dst should be blank (typically as just created
+ * by av_frame_alloc()). src should have an associated hwframe context, and
+ * dst may optionally have a format and associated hwframe context.
+ *
+ * If src was created by mapping a frame from the hwframe context of dst,
+ * then this function undoes the mapping - dst is replaced by a reference to
+ * the frame that src was originally mapped from.
+ *
+ * If both src and dst have an associated hwframe context, then this function
+ * attempts to map the src frame from its hardware context to that of dst and
+ * then fill dst with appropriate data to be usable there. This will only be
+ * possible if the hwframe contexts and associated devices are compatible -
+ * given compatible devices, av_hwframe_ctx_create_derived() can be used to
+ * create a hwframe context for dst in which mapping should be possible.
+ *
+ * If src has a hwframe context but dst does not, then the src frame is
+ * mapped to normal memory and should thereafter be usable as a normal frame.
+ * If the format is set on dst, then the mapping will attempt to create dst
+ * with that format and fail if it is not possible. If format is unset (is
+ * AV_PIX_FMT_NONE) then dst will be mapped with whatever the most appropriate
+ * format to use is (probably the sw_format of the src hwframe context).
+ *
+ * A return value of AVERROR(ENOSYS) indicates that the mapping is not
+ * possible with the given arguments and hwframe setup, while other return
+ * values indicate that it failed somehow.
+ *
+ * @param dst Destination frame, to contain the mapping.
+ * @param src Source frame, to be mapped.
+ * @param flags Some combination of AV_HWFRAME_MAP_* flags.
+ * @return Zero on success, negative AVERROR code on failure.
+ */
+int av_hwframe_map(AVFrame *dst, const AVFrame *src, int flags);
+
+
+/**
+ * Create and initialise an AVHWFramesContext as a mapping of another existing
+ * AVHWFramesContext on a different device.
+ *
+ * av_hwframe_ctx_init() should not be called after this.
+ *
+ * @param derived_frame_ctx On success, a reference to the newly created
+ * AVHWFramesContext.
+ * @param derived_device_ctx A reference to the device to create the new
+ * AVHWFramesContext on.
+ * @param source_frame_ctx A reference to an existing AVHWFramesContext
+ * which will be mapped to the derived context.
+ * @param flags Some combination of AV_HWFRAME_MAP_* flags, defining the
+ * mapping parameters to apply to frames which are allocated
+ * in the derived device.
+ * @return Zero on success, negative AVERROR code on failure.
+ */
+int av_hwframe_ctx_create_derived(AVBufferRef **derived_frame_ctx,
+ enum AVPixelFormat format,
+ AVBufferRef *derived_device_ctx,
+ AVBufferRef *source_frame_ctx,
+ int flags);
+
+#endif /* AVUTIL_HWCONTEXT_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_cuda.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_cuda.h
new file mode 100644
index 00000000..81a0552c
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_cuda.h
@@ -0,0 +1,52 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+
+#ifndef AVUTIL_HWCONTEXT_CUDA_H
+#define AVUTIL_HWCONTEXT_CUDA_H
+
+#ifndef CUDA_VERSION
+#include
+#endif
+
+#include "pixfmt.h"
+
+/**
+ * @file
+ * An API-specific header for AV_HWDEVICE_TYPE_CUDA.
+ *
+ * This API supports dynamic frame pools. AVHWFramesContext.pool must return
+ * AVBufferRefs whose data pointer is a CUdeviceptr.
+ */
+
+typedef struct AVCUDADeviceContextInternal AVCUDADeviceContextInternal;
+
+/**
+ * This struct is allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVCUDADeviceContext {
+ CUcontext cuda_ctx;
+ CUstream stream;
+ AVCUDADeviceContextInternal *internal;
+} AVCUDADeviceContext;
+
+/**
+ * AVHWFramesContext.hwctx is currently not used
+ */
+
+#endif /* AVUTIL_HWCONTEXT_CUDA_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_d3d11va.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_d3d11va.h
new file mode 100644
index 00000000..9f91e9b1
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_d3d11va.h
@@ -0,0 +1,169 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_D3D11VA_H
+#define AVUTIL_HWCONTEXT_D3D11VA_H
+
+/**
+ * @file
+ * An API-specific header for AV_HWDEVICE_TYPE_D3D11VA.
+ *
+ * The default pool implementation will be fixed-size if initial_pool_size is
+ * set (and allocate elements from an array texture). Otherwise it will allocate
+ * individual textures. Be aware that decoding requires a single array texture.
+ *
+ * Using sw_format==AV_PIX_FMT_YUV420P has special semantics, and maps to
+ * DXGI_FORMAT_420_OPAQUE. av_hwframe_transfer_data() is not supported for
+ * this format. Refer to MSDN for details.
+ *
+ * av_hwdevice_ctx_create() for this device type supports a key named "debug"
+ * for the AVDictionary entry. If this is set to any value, the device creation
+ * code will try to load various supported D3D debugging layers.
+ */
+
+#include
+#include
+
+/**
+ * This struct is allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVD3D11VADeviceContext {
+ /**
+ * Device used for texture creation and access. This can also be used to
+ * set the libavcodec decoding device.
+ *
+ * Must be set by the user. This is the only mandatory field - the other
+ * device context fields are set from this and are available for convenience.
+ *
+ * Deallocating the AVHWDeviceContext will always release this interface,
+ * and it does not matter whether it was user-allocated.
+ */
+ ID3D11Device *device;
+
+ /**
+ * If unset, this will be set from the device field on init.
+ *
+ * Deallocating the AVHWDeviceContext will always release this interface,
+ * and it does not matter whether it was user-allocated.
+ */
+ ID3D11DeviceContext *device_context;
+
+ /**
+ * If unset, this will be set from the device field on init.
+ *
+ * Deallocating the AVHWDeviceContext will always release this interface,
+ * and it does not matter whether it was user-allocated.
+ */
+ ID3D11VideoDevice *video_device;
+
+ /**
+ * If unset, this will be set from the device_context field on init.
+ *
+ * Deallocating the AVHWDeviceContext will always release this interface,
+ * and it does not matter whether it was user-allocated.
+ */
+ ID3D11VideoContext *video_context;
+
+ /**
+ * Callbacks for locking. They protect accesses to device_context and
+ * video_context calls. They also protect access to the internal staging
+ * texture (for av_hwframe_transfer_data() calls). They do NOT protect
+ * access to hwcontext or decoder state in general.
+ *
+ * If unset on init, the hwcontext implementation will set them to use an
+ * internal mutex.
+ *
+ * The underlying lock must be recursive. lock_ctx is for free use by the
+ * locking implementation.
+ */
+ void (*lock)(void *lock_ctx);
+ void (*unlock)(void *lock_ctx);
+ void *lock_ctx;
+} AVD3D11VADeviceContext;
+
+/**
+ * D3D11 frame descriptor for pool allocation.
+ *
+ * In user-allocated pools, AVHWFramesContext.pool must return AVBufferRefs
+ * with the data pointer pointing at an object of this type describing the
+ * planes of the frame.
+ *
+ * This has no use outside of custom allocation, and AVFrame AVBufferRef do not
+ * necessarily point to an instance of this struct.
+ */
+typedef struct AVD3D11FrameDescriptor {
+ /**
+ * The texture in which the frame is located. The reference count is
+ * managed by the AVBufferRef, and destroying the reference will release
+ * the interface.
+ *
+ * Normally stored in AVFrame.data[0].
+ */
+ ID3D11Texture2D *texture;
+
+ /**
+ * The index into the array texture element representing the frame, or 0
+ * if the texture is not an array texture.
+ *
+ * Normally stored in AVFrame.data[1] (cast from intptr_t).
+ */
+ intptr_t index;
+} AVD3D11FrameDescriptor;
+
+/**
+ * This struct is allocated as AVHWFramesContext.hwctx
+ */
+typedef struct AVD3D11VAFramesContext {
+ /**
+ * The canonical texture used for pool allocation. If this is set to NULL
+ * on init, the hwframes implementation will allocate and set an array
+ * texture if initial_pool_size > 0.
+ *
+ * The only situation when the API user should set this is:
+ * - the user wants to do manual pool allocation (setting
+ * AVHWFramesContext.pool), instead of letting AVHWFramesContext
+ * allocate the pool
+ * - of an array texture
+ * - and wants it to use it for decoding
+ * - this has to be done before calling av_hwframe_ctx_init()
+ *
+ * Deallocating the AVHWFramesContext will always release this interface,
+ * and it does not matter whether it was user-allocated.
+ *
+ * This is in particular used by the libavcodec D3D11VA hwaccel, which
+ * requires a single array texture. It will create ID3D11VideoDecoderOutputView
+ * objects for each array texture element on decoder initialization.
+ */
+ ID3D11Texture2D *texture;
+
+ /**
+ * D3D11_TEXTURE2D_DESC.BindFlags used for texture creation. The user must
+ * at least set D3D11_BIND_DECODER if the frames context is to be used for
+ * video decoding.
+ * This field is ignored/invalid if a user-allocated texture is provided.
+ */
+ UINT BindFlags;
+
+ /**
+ * D3D11_TEXTURE2D_DESC.MiscFlags used for texture creation.
+ * This field is ignored/invalid if a user-allocated texture is provided.
+ */
+ UINT MiscFlags;
+} AVD3D11VAFramesContext;
+
+#endif /* AVUTIL_HWCONTEXT_D3D11VA_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_drm.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_drm.h
new file mode 100644
index 00000000..42709f21
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_drm.h
@@ -0,0 +1,169 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_DRM_H
+#define AVUTIL_HWCONTEXT_DRM_H
+
+#include
+#include
+
+/**
+ * @file
+ * API-specific header for AV_HWDEVICE_TYPE_DRM.
+ *
+ * Internal frame allocation is not currently supported - all frames
+ * must be allocated by the user. Thus AVHWFramesContext is always
+ * NULL, though this may change if support for frame allocation is
+ * added in future.
+ */
+
+enum {
+ /**
+ * The maximum number of layers/planes in a DRM frame.
+ */
+ AV_DRM_MAX_PLANES = 4
+};
+
+/**
+ * DRM object descriptor.
+ *
+ * Describes a single DRM object, addressing it as a PRIME file
+ * descriptor.
+ */
+typedef struct AVDRMObjectDescriptor {
+ /**
+ * DRM PRIME fd for the object.
+ */
+ int fd;
+ /**
+ * Total size of the object.
+ *
+ * (This includes any parts not which do not contain image data.)
+ */
+ size_t size;
+ /**
+ * Format modifier applied to the object (DRM_FORMAT_MOD_*).
+ *
+ * If the format modifier is unknown then this should be set to
+ * DRM_FORMAT_MOD_INVALID.
+ */
+ uint64_t format_modifier;
+} AVDRMObjectDescriptor;
+
+/**
+ * DRM plane descriptor.
+ *
+ * Describes a single plane of a layer, which is contained within
+ * a single object.
+ */
+typedef struct AVDRMPlaneDescriptor {
+ /**
+ * Index of the object containing this plane in the objects
+ * array of the enclosing frame descriptor.
+ */
+ int object_index;
+ /**
+ * Offset within that object of this plane.
+ */
+ ptrdiff_t offset;
+ /**
+ * Pitch (linesize) of this plane.
+ */
+ ptrdiff_t pitch;
+} AVDRMPlaneDescriptor;
+
+/**
+ * DRM layer descriptor.
+ *
+ * Describes a single layer within a frame. This has the structure
+ * defined by its format, and will contain one or more planes.
+ */
+typedef struct AVDRMLayerDescriptor {
+ /**
+ * Format of the layer (DRM_FORMAT_*).
+ */
+ uint32_t format;
+ /**
+ * Number of planes in the layer.
+ *
+ * This must match the number of planes required by format.
+ */
+ int nb_planes;
+ /**
+ * Array of planes in this layer.
+ */
+ AVDRMPlaneDescriptor planes[AV_DRM_MAX_PLANES];
+} AVDRMLayerDescriptor;
+
+/**
+ * DRM frame descriptor.
+ *
+ * This is used as the data pointer for AV_PIX_FMT_DRM_PRIME frames.
+ * It is also used by user-allocated frame pools - allocating in
+ * AVHWFramesContext.pool must return AVBufferRefs which contain
+ * an object of this type.
+ *
+ * The fields of this structure should be set such it can be
+ * imported directly by EGL using the EGL_EXT_image_dma_buf_import
+ * and EGL_EXT_image_dma_buf_import_modifiers extensions.
+ * (Note that the exact layout of a particular format may vary between
+ * platforms - we only specify that the same platform should be able
+ * to import it.)
+ *
+ * The total number of planes must not exceed AV_DRM_MAX_PLANES, and
+ * the order of the planes by increasing layer index followed by
+ * increasing plane index must be the same as the order which would
+ * be used for the data pointers in the equivalent software format.
+ */
+typedef struct AVDRMFrameDescriptor {
+ /**
+ * Number of DRM objects making up this frame.
+ */
+ int nb_objects;
+ /**
+ * Array of objects making up the frame.
+ */
+ AVDRMObjectDescriptor objects[AV_DRM_MAX_PLANES];
+ /**
+ * Number of layers in the frame.
+ */
+ int nb_layers;
+ /**
+ * Array of layers in the frame.
+ */
+ AVDRMLayerDescriptor layers[AV_DRM_MAX_PLANES];
+} AVDRMFrameDescriptor;
+
+/**
+ * DRM device.
+ *
+ * Allocated as AVHWDeviceContext.hwctx.
+ */
+typedef struct AVDRMDeviceContext {
+ /**
+ * File descriptor of DRM device.
+ *
+ * This is used as the device to create frames on, and may also be
+ * used in some derivation and mapping operations.
+ *
+ * If no device is required, set to -1.
+ */
+ int fd;
+} AVDRMDeviceContext;
+
+#endif /* AVUTIL_HWCONTEXT_DRM_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_dxva2.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_dxva2.h
new file mode 100644
index 00000000..e1b79bc0
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_dxva2.h
@@ -0,0 +1,75 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+
+#ifndef AVUTIL_HWCONTEXT_DXVA2_H
+#define AVUTIL_HWCONTEXT_DXVA2_H
+
+/**
+ * @file
+ * An API-specific header for AV_HWDEVICE_TYPE_DXVA2.
+ *
+ * Only fixed-size pools are supported.
+ *
+ * For user-allocated pools, AVHWFramesContext.pool must return AVBufferRefs
+ * with the data pointer set to a pointer to IDirect3DSurface9.
+ */
+
+#include
+#include
+
+/**
+ * This struct is allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVDXVA2DeviceContext {
+ IDirect3DDeviceManager9 *devmgr;
+} AVDXVA2DeviceContext;
+
+/**
+ * This struct is allocated as AVHWFramesContext.hwctx
+ */
+typedef struct AVDXVA2FramesContext {
+ /**
+ * The surface type (e.g. DXVA2_VideoProcessorRenderTarget or
+ * DXVA2_VideoDecoderRenderTarget). Must be set by the caller.
+ */
+ DWORD surface_type;
+
+ /**
+ * The surface pool. When an external pool is not provided by the caller,
+ * this will be managed (allocated and filled on init, freed on uninit) by
+ * libavutil.
+ */
+ IDirect3DSurface9 **surfaces;
+ int nb_surfaces;
+
+ /**
+ * Certain drivers require the decoder to be destroyed before the surfaces.
+ * To allow internally managed pools to work properly in such cases, this
+ * field is provided.
+ *
+ * If it is non-NULL, libavutil will call IDirectXVideoDecoder_Release() on
+ * it just before the internal surface pool is freed.
+ *
+ * This is for convenience only. Some code uses other methods to manage the
+ * decoder reference.
+ */
+ IDirectXVideoDecoder *decoder_to_release;
+} AVDXVA2FramesContext;
+
+#endif /* AVUTIL_HWCONTEXT_DXVA2_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavfilter/avfiltergraph.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_mediacodec.h
similarity index 63%
rename from neo/libs/ffmpeg-win64/include/libavfilter/avfiltergraph.h
rename to neo/libs/ffmpeg-win64/include/libavutil/hwcontext_mediacodec.h
index b31d581c..101a9806 100644
--- a/neo/libs/ffmpeg-win64/include/libavfilter/avfiltergraph.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_mediacodec.h
@@ -1,7 +1,4 @@
/*
- * Filter graphs
- * copyright (c) 2007 Bobby Bingham
- *
* This file is part of FFmpeg.
*
* FFmpeg is free software; you can redistribute it and/or
@@ -19,10 +16,21 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef AVFILTER_AVFILTERGRAPH_H
-#define AVFILTER_AVFILTERGRAPH_H
+#ifndef AVUTIL_HWCONTEXT_MEDIACODEC_H
+#define AVUTIL_HWCONTEXT_MEDIACODEC_H
-#include "avfilter.h"
-#include "libavutil/log.h"
+/**
+ * MediaCodec details.
+ *
+ * Allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVMediaCodecDeviceContext {
+ /**
+ * android/view/Surface handle, to be filled by the user.
+ *
+ * This is the default surface used by decoders on this device.
+ */
+ void *surface;
+} AVMediaCodecDeviceContext;
-#endif /* AVFILTER_AVFILTERGRAPH_H */
+#endif /* AVUTIL_HWCONTEXT_MEDIACODEC_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_qsv.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_qsv.h
new file mode 100644
index 00000000..b98d611c
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_qsv.h
@@ -0,0 +1,53 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_QSV_H
+#define AVUTIL_HWCONTEXT_QSV_H
+
+#include
+
+/**
+ * @file
+ * An API-specific header for AV_HWDEVICE_TYPE_QSV.
+ *
+ * This API does not support dynamic frame pools. AVHWFramesContext.pool must
+ * contain AVBufferRefs whose data pointer points to an mfxFrameSurface1 struct.
+ */
+
+/**
+ * This struct is allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVQSVDeviceContext {
+ mfxSession session;
+} AVQSVDeviceContext;
+
+/**
+ * This struct is allocated as AVHWFramesContext.hwctx
+ */
+typedef struct AVQSVFramesContext {
+ mfxFrameSurface1 *surfaces;
+ int nb_surfaces;
+
+ /**
+ * A combination of MFX_MEMTYPE_* describing the frame pool.
+ */
+ int frame_type;
+} AVQSVFramesContext;
+
+#endif /* AVUTIL_HWCONTEXT_QSV_H */
+
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_vaapi.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_vaapi.h
new file mode 100644
index 00000000..0b2e071c
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_vaapi.h
@@ -0,0 +1,117 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_VAAPI_H
+#define AVUTIL_HWCONTEXT_VAAPI_H
+
+#include
+
+/**
+ * @file
+ * API-specific header for AV_HWDEVICE_TYPE_VAAPI.
+ *
+ * Dynamic frame pools are supported, but note that any pool used as a render
+ * target is required to be of fixed size in order to be be usable as an
+ * argument to vaCreateContext().
+ *
+ * For user-allocated pools, AVHWFramesContext.pool must return AVBufferRefs
+ * with the data pointer set to a VASurfaceID.
+ */
+
+enum {
+ /**
+ * The quirks field has been set by the user and should not be detected
+ * automatically by av_hwdevice_ctx_init().
+ */
+ AV_VAAPI_DRIVER_QUIRK_USER_SET = (1 << 0),
+ /**
+ * The driver does not destroy parameter buffers when they are used by
+ * vaRenderPicture(). Additional code will be required to destroy them
+ * separately afterwards.
+ */
+ AV_VAAPI_DRIVER_QUIRK_RENDER_PARAM_BUFFERS = (1 << 1),
+
+ /**
+ * The driver does not support the VASurfaceAttribMemoryType attribute,
+ * so the surface allocation code will not try to use it.
+ */
+ AV_VAAPI_DRIVER_QUIRK_ATTRIB_MEMTYPE = (1 << 2),
+
+ /**
+ * The driver does not support surface attributes at all.
+ * The surface allocation code will never pass them to surface allocation,
+ * and the results of the vaQuerySurfaceAttributes() call will be faked.
+ */
+ AV_VAAPI_DRIVER_QUIRK_SURFACE_ATTRIBUTES = (1 << 3),
+};
+
+/**
+ * VAAPI connection details.
+ *
+ * Allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVVAAPIDeviceContext {
+ /**
+ * The VADisplay handle, to be filled by the user.
+ */
+ VADisplay display;
+ /**
+ * Driver quirks to apply - this is filled by av_hwdevice_ctx_init(),
+ * with reference to a table of known drivers, unless the
+ * AV_VAAPI_DRIVER_QUIRK_USER_SET bit is already present. The user
+ * may need to refer to this field when performing any later
+ * operations using VAAPI with the same VADisplay.
+ */
+ unsigned int driver_quirks;
+} AVVAAPIDeviceContext;
+
+/**
+ * VAAPI-specific data associated with a frame pool.
+ *
+ * Allocated as AVHWFramesContext.hwctx.
+ */
+typedef struct AVVAAPIFramesContext {
+ /**
+ * Set by the user to apply surface attributes to all surfaces in
+ * the frame pool. If null, default settings are used.
+ */
+ VASurfaceAttrib *attributes;
+ int nb_attributes;
+ /**
+ * The surfaces IDs of all surfaces in the pool after creation.
+ * Only valid if AVHWFramesContext.initial_pool_size was positive.
+ * These are intended to be used as the render_targets arguments to
+ * vaCreateContext().
+ */
+ VASurfaceID *surface_ids;
+ int nb_surfaces;
+} AVVAAPIFramesContext;
+
+/**
+ * VAAPI hardware pipeline configuration details.
+ *
+ * Allocated with av_hwdevice_hwconfig_alloc().
+ */
+typedef struct AVVAAPIHWConfig {
+ /**
+ * ID of a VAAPI pipeline configuration.
+ */
+ VAConfigID config_id;
+} AVVAAPIHWConfig;
+
+#endif /* AVUTIL_HWCONTEXT_VAAPI_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_vdpau.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_vdpau.h
new file mode 100644
index 00000000..1b7ea1e4
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_vdpau.h
@@ -0,0 +1,44 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_VDPAU_H
+#define AVUTIL_HWCONTEXT_VDPAU_H
+
+#include
+
+/**
+ * @file
+ * An API-specific header for AV_HWDEVICE_TYPE_VDPAU.
+ *
+ * This API supports dynamic frame pools. AVHWFramesContext.pool must return
+ * AVBufferRefs whose data pointer is a VdpVideoSurface.
+ */
+
+/**
+ * This struct is allocated as AVHWDeviceContext.hwctx
+ */
+typedef struct AVVDPAUDeviceContext {
+ VdpDevice device;
+ VdpGetProcAddress *get_proc_address;
+} AVVDPAUDeviceContext;
+
+/**
+ * AVHWFramesContext.hwctx is currently not used
+ */
+
+#endif /* AVUTIL_HWCONTEXT_VDPAU_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_videotoolbox.h b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_videotoolbox.h
new file mode 100644
index 00000000..380918d9
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/hwcontext_videotoolbox.h
@@ -0,0 +1,54 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_HWCONTEXT_VIDEOTOOLBOX_H
+#define AVUTIL_HWCONTEXT_VIDEOTOOLBOX_H
+
+#include
+
+#include
+
+#include "pixfmt.h"
+
+/**
+ * @file
+ * An API-specific header for AV_HWDEVICE_TYPE_VIDEOTOOLBOX.
+ *
+ * This API currently does not support frame allocation, as the raw VideoToolbox
+ * API does allocation, and FFmpeg itself never has the need to allocate frames.
+ *
+ * If the API user sets a custom pool, AVHWFramesContext.pool must return
+ * AVBufferRefs whose data pointer is a CVImageBufferRef or CVPixelBufferRef.
+ *
+ * Currently AVHWDeviceContext.hwctx and AVHWFramesContext.hwctx are always
+ * NULL.
+ */
+
+/**
+ * Convert a VideoToolbox (actually CoreVideo) format to AVPixelFormat.
+ * Returns AV_PIX_FMT_NONE if no known equivalent was found.
+ */
+enum AVPixelFormat av_map_videotoolbox_format_to_pixfmt(uint32_t cv_fmt);
+
+/**
+ * Convert an AVPixelFormat to a VideoToolbox (actually CoreVideo) format.
+ * Returns 0 if no known equivalent was found.
+ */
+uint32_t av_map_videotoolbox_format_from_pixfmt(enum AVPixelFormat pix_fmt);
+
+#endif /* AVUTIL_HWCONTEXT_VIDEOTOOLBOX_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/imgutils.h b/neo/libs/ffmpeg-win64/include/libavutil/imgutils.h
index 23282a38..5b790ecf 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/imgutils.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/imgutils.h
@@ -120,6 +120,24 @@ void av_image_copy(uint8_t *dst_data[4], int dst_linesizes[4],
const uint8_t *src_data[4], const int src_linesizes[4],
enum AVPixelFormat pix_fmt, int width, int height);
+/**
+ * Copy image data located in uncacheable (e.g. GPU mapped) memory. Where
+ * available, this function will use special functionality for reading from such
+ * memory, which may result in greatly improved performance compared to plain
+ * av_image_copy().
+ *
+ * The data pointers and the linesizes must be aligned to the maximum required
+ * by the CPU architecture.
+ *
+ * @note The linesize parameters have the type ptrdiff_t here, while they are
+ * int for av_image_copy().
+ * @note On x86, the linesizes currently need to be aligned to the cacheline
+ * size (i.e. 64) to get improved performance.
+ */
+void av_image_copy_uc_from(uint8_t *dst_data[4], const ptrdiff_t dst_linesizes[4],
+ const uint8_t *src_data[4], const ptrdiff_t src_linesizes[4],
+ enum AVPixelFormat pix_fmt, int width, int height);
+
/**
* Setup the data pointers and linesizes based on the specified image
* parameters and the provided array.
@@ -137,7 +155,7 @@ void av_image_copy(uint8_t *dst_data[4], int dst_linesizes[4],
* one call, use av_image_alloc().
*
* @param dst_data data pointers to be filled in
- * @param dst_linesizes linesizes for the image in dst_data to be filled in
+ * @param dst_linesize linesizes for the image in dst_data to be filled in
* @param src buffer which will contain or contains the actual image data, can be NULL
* @param pix_fmt the pixel format of the image
* @param width the width of the image in pixels
@@ -154,7 +172,11 @@ int av_image_fill_arrays(uint8_t *dst_data[4], int dst_linesize[4],
* Return the size in bytes of the amount of data required to store an
* image with the given parameters.
*
- * @param[in] align the assumed linesize alignment
+ * @param pix_fmt the pixel format of the image
+ * @param width the width of the image in pixels
+ * @param height the height of the image in pixels
+ * @param align the assumed linesize alignment
+ * @return the buffer size in bytes, a negative error code in case of failure
*/
int av_image_get_buffer_size(enum AVPixelFormat pix_fmt, int width, int height, int align);
@@ -167,7 +189,7 @@ int av_image_get_buffer_size(enum AVPixelFormat pix_fmt, int width, int height,
* @param dst a buffer into which picture data will be copied
* @param dst_size the size in bytes of dst
* @param src_data pointers containing the source image data
- * @param src_linesizes linesizes for the image in src_data
+ * @param src_linesize linesizes for the image in src_data
* @param pix_fmt the pixel format of the source image
* @param width the width of the source image in pixels
* @param height the height of the source image in pixels
@@ -191,6 +213,21 @@ int av_image_copy_to_buffer(uint8_t *dst, int dst_size,
*/
int av_image_check_size(unsigned int w, unsigned int h, int log_offset, void *log_ctx);
+/**
+ * Check if the given dimension of an image is valid, meaning that all
+ * bytes of a plane of an image with the specified pix_fmt can be addressed
+ * with a signed int.
+ *
+ * @param w the width of the picture
+ * @param h the height of the picture
+ * @param max_pixels the maximum number of pixels the user wants to accept
+ * @param pix_fmt the pixel format, can be AV_PIX_FMT_NONE if unknown.
+ * @param log_offset the offset to sum to the log level for logging with log_ctx
+ * @param log_ctx the parent logging context, it may be NULL
+ * @return >= 0 if valid, a negative error code otherwise
+ */
+int av_image_check_size2(unsigned int w, unsigned int h, int64_t max_pixels, enum AVPixelFormat pix_fmt, int log_offset, void *log_ctx);
+
/**
* Check if the given sample aspect ratio of an image is valid.
*
@@ -205,6 +242,33 @@ int av_image_check_size(unsigned int w, unsigned int h, int log_offset, void *lo
*/
int av_image_check_sar(unsigned int w, unsigned int h, AVRational sar);
+/**
+ * Overwrite the image data with black. This is suitable for filling a
+ * sub-rectangle of an image, meaning the padding between the right most pixel
+ * and the left most pixel on the next line will not be overwritten. For some
+ * formats, the image size might be rounded up due to inherent alignment.
+ *
+ * If the pixel format has alpha, the alpha is cleared to opaque.
+ *
+ * This can return an error if the pixel format is not supported. Normally, all
+ * non-hwaccel pixel formats should be supported.
+ *
+ * Passing NULL for dst_data is allowed. Then the function returns whether the
+ * operation would have succeeded. (It can return an error if the pix_fmt is
+ * not supported.)
+ *
+ * @param dst_data data pointers to destination image
+ * @param dst_linesize linesizes for the destination image
+ * @param pix_fmt the pixel format of the image
+ * @param range the color range of the image (important for colorspaces such as YUV)
+ * @param width the width of the image in pixels
+ * @param height the height of the image in pixels
+ * @return 0 if the image data was cleared, a negative AVERROR code otherwise
+ */
+int av_image_fill_black(uint8_t *dst_data[4], const ptrdiff_t dst_linesize[4],
+ enum AVPixelFormat pix_fmt, enum AVColorRange range,
+ int width, int height);
+
/**
* @}
*/
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/intreadwrite.h b/neo/libs/ffmpeg-win64/include/libavutil/intreadwrite.h
index 51fbe30a..4c8413a5 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/intreadwrite.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/intreadwrite.h
@@ -215,7 +215,7 @@ typedef union {
* by per-arch headers.
*/
-#if defined(__GNUC__) && !defined(__TI_COMPILER_VERSION__)
+#if defined(__GNUC__)
union unaligned_64 { uint64_t l; } __attribute__((packed)) av_alias;
union unaligned_32 { uint32_t l; } __attribute__((packed)) av_alias;
@@ -224,7 +224,7 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
# define AV_RN(s, p) (((const union unaligned_##s *) (p))->l)
# define AV_WN(s, p, v) ((((union unaligned_##s *) (p))->l) = (v))
-#elif defined(__DECC)
+#elif defined(_MSC_VER) && (defined(_M_ARM) || defined(_M_X64) || defined(_M_ARM64)) && AV_HAVE_FAST_UNALIGNED
# define AV_RN(s, p) (*((const __unaligned uint##s##_t*)(p)))
# define AV_WN(s, p, v) (*((__unaligned uint##s##_t*)(p)) = (v))
@@ -242,8 +242,8 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
((const uint8_t*)(x))[1])
#endif
#ifndef AV_WB16
-# define AV_WB16(p, darg) do { \
- unsigned d = (darg); \
+# define AV_WB16(p, val) do { \
+ uint16_t d = (val); \
((uint8_t*)(p))[1] = (d); \
((uint8_t*)(p))[0] = (d)>>8; \
} while(0)
@@ -255,8 +255,8 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
((const uint8_t*)(x))[0])
#endif
#ifndef AV_WL16
-# define AV_WL16(p, darg) do { \
- unsigned d = (darg); \
+# define AV_WL16(p, val) do { \
+ uint16_t d = (val); \
((uint8_t*)(p))[0] = (d); \
((uint8_t*)(p))[1] = (d)>>8; \
} while(0)
@@ -270,8 +270,8 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
((const uint8_t*)(x))[3])
#endif
#ifndef AV_WB32
-# define AV_WB32(p, darg) do { \
- unsigned d = (darg); \
+# define AV_WB32(p, val) do { \
+ uint32_t d = (val); \
((uint8_t*)(p))[3] = (d); \
((uint8_t*)(p))[2] = (d)>>8; \
((uint8_t*)(p))[1] = (d)>>16; \
@@ -287,8 +287,8 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
((const uint8_t*)(x))[0])
#endif
#ifndef AV_WL32
-# define AV_WL32(p, darg) do { \
- unsigned d = (darg); \
+# define AV_WL32(p, val) do { \
+ uint32_t d = (val); \
((uint8_t*)(p))[0] = (d); \
((uint8_t*)(p))[1] = (d)>>8; \
((uint8_t*)(p))[2] = (d)>>16; \
@@ -308,8 +308,8 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
(uint64_t)((const uint8_t*)(x))[7])
#endif
#ifndef AV_WB64
-# define AV_WB64(p, darg) do { \
- uint64_t d = (darg); \
+# define AV_WB64(p, val) do { \
+ uint64_t d = (val); \
((uint8_t*)(p))[7] = (d); \
((uint8_t*)(p))[6] = (d)>>8; \
((uint8_t*)(p))[5] = (d)>>16; \
@@ -333,8 +333,8 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
(uint64_t)((const uint8_t*)(x))[0])
#endif
#ifndef AV_WL64
-# define AV_WL64(p, darg) do { \
- uint64_t d = (darg); \
+# define AV_WL64(p, val) do { \
+ uint64_t d = (val); \
((uint8_t*)(p))[0] = (d); \
((uint8_t*)(p))[1] = (d)>>8; \
((uint8_t*)(p))[2] = (d)>>16; \
@@ -542,6 +542,21 @@ union unaligned_16 { uint16_t l; } __attribute__((packed)) av_alias;
# define AV_WN64A(p, v) AV_WNA(64, p, v)
#endif
+#if AV_HAVE_BIGENDIAN
+# define AV_RLA(s, p) av_bswap##s(AV_RN##s##A(p))
+# define AV_WLA(s, p, v) AV_WN##s##A(p, av_bswap##s(v))
+#else
+# define AV_RLA(s, p) AV_RN##s##A(p)
+# define AV_WLA(s, p, v) AV_WN##s##A(p, v)
+#endif
+
+#ifndef AV_RL64A
+# define AV_RL64A(p) AV_RLA(64, p)
+#endif
+#ifndef AV_WL64A
+# define AV_WL64A(p, v) AV_WLA(64, p, v)
+#endif
+
/*
* The AV_COPYxxU macros are suitable for copying data to/from unaligned
* memory locations.
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/lfg.h b/neo/libs/ffmpeg-win64/include/libavutil/lfg.h
index ec90562c..2b669205 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/lfg.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/lfg.h
@@ -22,6 +22,14 @@
#ifndef AVUTIL_LFG_H
#define AVUTIL_LFG_H
+#include
+
+/**
+ * Context structure for the Lagged Fibonacci PRNG.
+ * The exact layout, types and content of this struct may change and should
+ * not be accessed directly. Only its sizeof() is guranteed to stay the same
+ * to allow easy instanciation.
+ */
typedef struct AVLFG {
unsigned int state[64];
int index;
@@ -29,6 +37,13 @@ typedef struct AVLFG {
void av_lfg_init(AVLFG *c, unsigned int seed);
+/**
+ * Seed the state of the ALFG using binary data.
+ *
+ * Return value: 0 on success, negative value (AVERROR) on failure.
+ */
+int av_lfg_init_from_data(AVLFG *c, const uint8_t *data, unsigned int length);
+
/**
* Get the next random unsigned 32-bit number using an ALFG.
*
@@ -36,8 +51,9 @@ void av_lfg_init(AVLFG *c, unsigned int seed);
* it may be good enough and faster for your specific use case.
*/
static inline unsigned int av_lfg_get(AVLFG *c){
- c->state[c->index & 63] = c->state[(c->index-24) & 63] + c->state[(c->index-55) & 63];
- return c->state[c->index++ & 63];
+ unsigned a = c->state[c->index & 63] = c->state[(c->index-24) & 63] + c->state[(c->index-55) & 63];
+ c->index += 1U;
+ return a;
}
/**
@@ -48,7 +64,9 @@ static inline unsigned int av_lfg_get(AVLFG *c){
static inline unsigned int av_mlfg_get(AVLFG *c){
unsigned int a= c->state[(c->index-55) & 63];
unsigned int b= c->state[(c->index-24) & 63];
- return c->state[c->index++ & 63] = 2*a*b+a+b;
+ a = c->state[c->index & 63] = 2*a*b+a+b;
+ c->index += 1U;
+ return a;
}
/**
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/log.h b/neo/libs/ffmpeg-win64/include/libavutil/log.h
index 321748cd..d9554e60 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/log.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/log.h
@@ -44,7 +44,7 @@ typedef enum {
AV_CLASS_CATEGORY_DEVICE_AUDIO_INPUT,
AV_CLASS_CATEGORY_DEVICE_OUTPUT,
AV_CLASS_CATEGORY_DEVICE_INPUT,
- AV_CLASS_CATEGORY_NB, ///< not part of ABI/API
+ AV_CLASS_CATEGORY_NB ///< not part of ABI/API
}AVClassCategory;
#define AV_IS_INPUT_DEVICE(category) \
@@ -317,19 +317,22 @@ AVClassCategory av_default_get_category(void *ptr);
void av_log_format_line(void *ptr, int level, const char *fmt, va_list vl,
char *line, int line_size, int *print_prefix);
-#if FF_API_DLOG
/**
- * av_dlog macros
- * @deprecated unused
- * Useful to print debug messages that shouldn't get compiled in normally.
+ * Format a line of log the same way as the default callback.
+ * @param line buffer to receive the formatted line;
+ * may be NULL if line_size is 0
+ * @param line_size size of the buffer; at most line_size-1 characters will
+ * be written to the buffer, plus one null terminator
+ * @param print_prefix used to store whether the prefix must be printed;
+ * must point to a persistent integer initially set to 1
+ * @return Returns a negative value if an error occurred, otherwise returns
+ * the number of characters that would have been written for a
+ * sufficiently large buffer, not including the terminating null
+ * character. If the return value is not less than line_size, it means
+ * that the log message was truncated to fit the buffer.
*/
-
-#ifdef DEBUG
-# define av_dlog(pctx, ...) av_log(pctx, AV_LOG_DEBUG, __VA_ARGS__)
-#else
-# define av_dlog(pctx, ...) do { if (0) av_log(pctx, AV_LOG_DEBUG, __VA_ARGS__); } while (0)
-#endif
-#endif /* FF_API_DLOG */
+int av_log_format_line2(void *ptr, int level, const char *fmt, va_list vl,
+ char *line, int line_size, int *print_prefix);
/**
* Skip repeated messages, this requires the user app to use av_log() instead of
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/macros.h b/neo/libs/ffmpeg-win64/include/libavutil/macros.h
index 44653237..2007ee56 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/macros.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/macros.h
@@ -45,4 +45,6 @@
#define AV_PRAGMA(s) _Pragma(#s)
+#define FFALIGN(x, a) (((x)+(a)-1)&~((a)-1))
+
#endif /* AVUTIL_MACROS_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/mastering_display_metadata.h b/neo/libs/ffmpeg-win64/include/libavutil/mastering_display_metadata.h
new file mode 100644
index 00000000..c23b07c3
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/mastering_display_metadata.h
@@ -0,0 +1,128 @@
+/*
+ * Copyright (c) 2016 Neil Birkbeck
+ *
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_MASTERING_DISPLAY_METADATA_H
+#define AVUTIL_MASTERING_DISPLAY_METADATA_H
+
+#include "frame.h"
+#include "rational.h"
+
+
+/**
+ * Mastering display metadata capable of representing the color volume of
+ * the display used to master the content (SMPTE 2086:2014).
+ *
+ * To be used as payload of a AVFrameSideData or AVPacketSideData with the
+ * appropriate type.
+ *
+ * @note The struct should be allocated with av_mastering_display_metadata_alloc()
+ * and its size is not a part of the public ABI.
+ */
+typedef struct AVMasteringDisplayMetadata {
+ /**
+ * CIE 1931 xy chromaticity coords of color primaries (r, g, b order).
+ */
+ AVRational display_primaries[3][2];
+
+ /**
+ * CIE 1931 xy chromaticity coords of white point.
+ */
+ AVRational white_point[2];
+
+ /**
+ * Min luminance of mastering display (cd/m^2).
+ */
+ AVRational min_luminance;
+
+ /**
+ * Max luminance of mastering display (cd/m^2).
+ */
+ AVRational max_luminance;
+
+ /**
+ * Flag indicating whether the display primaries (and white point) are set.
+ */
+ int has_primaries;
+
+ /**
+ * Flag indicating whether the luminance (min_ and max_) have been set.
+ */
+ int has_luminance;
+
+} AVMasteringDisplayMetadata;
+
+/**
+ * Allocate an AVMasteringDisplayMetadata structure and set its fields to
+ * default values. The resulting struct can be freed using av_freep().
+ *
+ * @return An AVMasteringDisplayMetadata filled with default values or NULL
+ * on failure.
+ */
+AVMasteringDisplayMetadata *av_mastering_display_metadata_alloc(void);
+
+/**
+ * Allocate a complete AVMasteringDisplayMetadata and add it to the frame.
+ *
+ * @param frame The frame which side data is added to.
+ *
+ * @return The AVMasteringDisplayMetadata structure to be filled by caller.
+ */
+AVMasteringDisplayMetadata *av_mastering_display_metadata_create_side_data(AVFrame *frame);
+
+/**
+ * Content light level needed by to transmit HDR over HDMI (CTA-861.3).
+ *
+ * To be used as payload of a AVFrameSideData or AVPacketSideData with the
+ * appropriate type.
+ *
+ * @note The struct should be allocated with av_content_light_metadata_alloc()
+ * and its size is not a part of the public ABI.
+ */
+typedef struct AVContentLightMetadata {
+ /**
+ * Max content light level (cd/m^2).
+ */
+ unsigned MaxCLL;
+
+ /**
+ * Max average light level per frame (cd/m^2).
+ */
+ unsigned MaxFALL;
+} AVContentLightMetadata;
+
+/**
+ * Allocate an AVContentLightMetadata structure and set its fields to
+ * default values. The resulting struct can be freed using av_freep().
+ *
+ * @return An AVContentLightMetadata filled with default values or NULL
+ * on failure.
+ */
+AVContentLightMetadata *av_content_light_metadata_alloc(size_t *size);
+
+/**
+ * Allocate a complete AVContentLightMetadata and add it to the frame.
+ *
+ * @param frame The frame which side data is added to.
+ *
+ * @return The AVContentLightMetadata structure to be filled by caller.
+ */
+AVContentLightMetadata *av_content_light_metadata_create_side_data(AVFrame *frame);
+
+#endif /* AVUTIL_MASTERING_DISPLAY_METADATA_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/mathematics.h b/neo/libs/ffmpeg-win64/include/libavutil/mathematics.h
index 57c44f84..54901800 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/mathematics.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/mathematics.h
@@ -18,6 +18,12 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @addtogroup lavu_math
+ * Mathematical utilities for working with timestamp and time base.
+ */
+
#ifndef AVUTIL_MATHEMATICS_H
#define AVUTIL_MATHEMATICS_H
@@ -63,84 +69,155 @@
/**
* @addtogroup lavu_math
+ *
* @{
*/
-
+/**
+ * Rounding methods.
+ */
enum AVRounding {
AV_ROUND_ZERO = 0, ///< Round toward zero.
AV_ROUND_INF = 1, ///< Round away from zero.
AV_ROUND_DOWN = 2, ///< Round toward -infinity.
AV_ROUND_UP = 3, ///< Round toward +infinity.
AV_ROUND_NEAR_INF = 5, ///< Round to nearest and halfway cases away from zero.
- AV_ROUND_PASS_MINMAX = 8192, ///< Flag to pass INT64_MIN/MAX through instead of rescaling, this avoids special cases for AV_NOPTS_VALUE
+ /**
+ * Flag telling rescaling functions to pass `INT64_MIN`/`MAX` through
+ * unchanged, avoiding special cases for #AV_NOPTS_VALUE.
+ *
+ * Unlike other values of the enumeration AVRounding, this value is a
+ * bitmask that must be used in conjunction with another value of the
+ * enumeration through a bitwise OR, in order to set behavior for normal
+ * cases.
+ *
+ * @code{.c}
+ * av_rescale_rnd(3, 1, 2, AV_ROUND_UP | AV_ROUND_PASS_MINMAX);
+ * // Rescaling 3:
+ * // Calculating 3 * 1 / 2
+ * // 3 / 2 is rounded up to 2
+ * // => 2
+ *
+ * av_rescale_rnd(AV_NOPTS_VALUE, 1, 2, AV_ROUND_UP | AV_ROUND_PASS_MINMAX);
+ * // Rescaling AV_NOPTS_VALUE:
+ * // AV_NOPTS_VALUE == INT64_MIN
+ * // AV_NOPTS_VALUE is passed through
+ * // => AV_NOPTS_VALUE
+ * @endcode
+ */
+ AV_ROUND_PASS_MINMAX = 8192,
};
/**
- * Compute the greatest common divisor of a and b.
+ * Compute the greatest common divisor of two integer operands.
*
- * @return gcd of a and b up to sign; if a >= 0 and b >= 0, return value is >= 0;
+ * @param a,b Operands
+ * @return GCD of a and b up to sign; if a >= 0 and b >= 0, return value is >= 0;
* if a == 0 and b == 0, returns 0.
*/
int64_t av_const av_gcd(int64_t a, int64_t b);
/**
* Rescale a 64-bit integer with rounding to nearest.
- * A simple a*b/c isn't possible as it can overflow.
+ *
+ * The operation is mathematically equivalent to `a * b / c`, but writing that
+ * directly can overflow.
+ *
+ * This function is equivalent to av_rescale_rnd() with #AV_ROUND_NEAR_INF.
+ *
+ * @see av_rescale_rnd(), av_rescale_q(), av_rescale_q_rnd()
*/
int64_t av_rescale(int64_t a, int64_t b, int64_t c) av_const;
/**
* Rescale a 64-bit integer with specified rounding.
- * A simple a*b/c isn't possible as it can overflow.
*
- * @return rescaled value a, or if AV_ROUND_PASS_MINMAX is set and a is
- * INT64_MIN or INT64_MAX then a is passed through unchanged.
+ * The operation is mathematically equivalent to `a * b / c`, but writing that
+ * directly can overflow, and does not support different rounding methods.
+ *
+ * @see av_rescale(), av_rescale_q(), av_rescale_q_rnd()
*/
-int64_t av_rescale_rnd(int64_t a, int64_t b, int64_t c, enum AVRounding) av_const;
+int64_t av_rescale_rnd(int64_t a, int64_t b, int64_t c, enum AVRounding rnd) av_const;
/**
* Rescale a 64-bit integer by 2 rational numbers.
+ *
+ * The operation is mathematically equivalent to `a * bq / cq`.
+ *
+ * This function is equivalent to av_rescale_q_rnd() with #AV_ROUND_NEAR_INF.
+ *
+ * @see av_rescale(), av_rescale_rnd(), av_rescale_q_rnd()
*/
int64_t av_rescale_q(int64_t a, AVRational bq, AVRational cq) av_const;
/**
* Rescale a 64-bit integer by 2 rational numbers with specified rounding.
*
- * @return rescaled value a, or if AV_ROUND_PASS_MINMAX is set and a is
- * INT64_MIN or INT64_MAX then a is passed through unchanged.
+ * The operation is mathematically equivalent to `a * bq / cq`.
+ *
+ * @see av_rescale(), av_rescale_rnd(), av_rescale_q()
*/
int64_t av_rescale_q_rnd(int64_t a, AVRational bq, AVRational cq,
- enum AVRounding) av_const;
+ enum AVRounding rnd) av_const;
/**
- * Compare 2 timestamps each in its own timebases.
- * The result of the function is undefined if one of the timestamps
- * is outside the int64_t range when represented in the others timebase.
- * @return -1 if ts_a is before ts_b, 1 if ts_a is after ts_b or 0 if they represent the same position
+ * Compare two timestamps each in its own time base.
+ *
+ * @return One of the following values:
+ * - -1 if `ts_a` is before `ts_b`
+ * - 1 if `ts_a` is after `ts_b`
+ * - 0 if they represent the same position
+ *
+ * @warning
+ * The result of the function is undefined if one of the timestamps is outside
+ * the `int64_t` range when represented in the other's timebase.
*/
int av_compare_ts(int64_t ts_a, AVRational tb_a, int64_t ts_b, AVRational tb_b);
/**
- * Compare 2 integers modulo mod.
- * That is we compare integers a and b for which only the least
- * significant log2(mod) bits are known.
+ * Compare the remainders of two integer operands divided by a common divisor.
*
- * @param mod must be a power of 2
- * @return a negative value if a is smaller than b
- * a positive value if a is greater than b
- * 0 if a equals b
+ * In other words, compare the least significant `log2(mod)` bits of integers
+ * `a` and `b`.
+ *
+ * @code{.c}
+ * av_compare_mod(0x11, 0x02, 0x10) < 0 // since 0x11 % 0x10 (0x1) < 0x02 % 0x10 (0x2)
+ * av_compare_mod(0x11, 0x02, 0x20) > 0 // since 0x11 % 0x20 (0x11) > 0x02 % 0x20 (0x02)
+ * @endcode
+ *
+ * @param a,b Operands
+ * @param mod Divisor; must be a power of 2
+ * @return
+ * - a negative value if `a % mod < b % mod`
+ * - a positive value if `a % mod > b % mod`
+ * - zero if `a % mod == b % mod`
*/
int64_t av_compare_mod(uint64_t a, uint64_t b, uint64_t mod);
/**
* Rescale a timestamp while preserving known durations.
*
- * @param in_ts Input timestamp
- * @param in_tb Input timebase
- * @param fs_tb Duration and *last timebase
- * @param duration duration till the next call
- * @param out_tb Output timebase
+ * This function is designed to be called per audio packet to scale the input
+ * timestamp to a different time base. Compared to a simple av_rescale_q()
+ * call, this function is robust against possible inconsistent frame durations.
+ *
+ * The `last` parameter is a state variable that must be preserved for all
+ * subsequent calls for the same stream. For the first call, `*last` should be
+ * initialized to #AV_NOPTS_VALUE.
+ *
+ * @param[in] in_tb Input time base
+ * @param[in] in_ts Input timestamp
+ * @param[in] fs_tb Duration time base; typically this is finer-grained
+ * (greater) than `in_tb` and `out_tb`
+ * @param[in] duration Duration till the next call to this function (i.e.
+ * duration of the current packet/frame)
+ * @param[in,out] last Pointer to a timestamp expressed in terms of
+ * `fs_tb`, acting as a state variable
+ * @param[in] out_tb Output timebase
+ * @return Timestamp expressed in terms of `out_tb`
+ *
+ * @note In the context of this function, "duration" is in term of samples, not
+ * seconds.
*/
int64_t av_rescale_delta(AVRational in_tb, int64_t in_ts, AVRational fs_tb, int duration, int64_t *last, AVRational out_tb);
@@ -150,15 +227,15 @@ int64_t av_rescale_delta(AVRational in_tb, int64_t in_ts, AVRational fs_tb, int
* This function guarantees that when the same value is repeatly added that
* no accumulation of rounding errors occurs.
*
- * @param ts Input timestamp
- * @param ts_tb Input timestamp timebase
- * @param inc value to add to ts
- * @param inc_tb inc timebase
+ * @param[in] ts Input timestamp
+ * @param[in] ts_tb Input timestamp time base
+ * @param[in] inc Value to be added
+ * @param[in] inc_tb Time base of `inc`
*/
int64_t av_add_stable(AVRational ts_tb, int64_t ts, AVRational inc_tb, int64_t inc);
- /**
+/**
* @}
*/
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/md5.h b/neo/libs/ffmpeg-win64/include/libavutil/md5.h
index 79702c88..ca72ccbf 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/md5.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/md5.h
@@ -18,9 +18,16 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_md5
+ * Public header for MD5 hash function implementation.
+ */
+
#ifndef AVUTIL_MD5_H
#define AVUTIL_MD5_H
+#include
#include
#include "attributes.h"
@@ -28,7 +35,9 @@
/**
* @defgroup lavu_md5 MD5
- * @ingroup lavu_crypto
+ * @ingroup lavu_hash
+ * MD5 hash function implementation.
+ *
* @{
*/
@@ -55,7 +64,11 @@ void av_md5_init(struct AVMD5 *ctx);
* @param src input data to update hash with
* @param len input data length
*/
+#if FF_API_CRYPTO_SIZE_T
void av_md5_update(struct AVMD5 *ctx, const uint8_t *src, int len);
+#else
+void av_md5_update(struct AVMD5 *ctx, const uint8_t *src, size_t len);
+#endif
/**
* Finish hashing and output digest value.
@@ -72,7 +85,11 @@ void av_md5_final(struct AVMD5 *ctx, uint8_t *dst);
* @param src The data to hash
* @param len The length of the data, in bytes
*/
+#if FF_API_CRYPTO_SIZE_T
void av_md5_sum(uint8_t *dst, const uint8_t *src, const int len);
+#else
+void av_md5_sum(uint8_t *dst, const uint8_t *src, size_t len);
+#endif
/**
* @}
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/mem.h b/neo/libs/ffmpeg-win64/include/libavutil/mem.h
index a8eb14ee..5fb1a02d 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/mem.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/mem.h
@@ -20,7 +20,8 @@
/**
* @file
- * memory handling functions
+ * @ingroup lavu_mem
+ * Memory handling functions
*/
#ifndef AVUTIL_MEM_H
@@ -35,37 +36,133 @@
/**
* @addtogroup lavu_mem
+ * Utilities for manipulating memory.
+ *
+ * FFmpeg has several applications of memory that are not required of a typical
+ * program. For example, the computing-heavy components like video decoding and
+ * encoding can be sped up significantly through the use of aligned memory.
+ *
+ * However, for each of FFmpeg's applications of memory, there might not be a
+ * recognized or standardized API for that specific use. Memory alignment, for
+ * instance, varies wildly depending on operating systems, architectures, and
+ * compilers. Hence, this component of @ref libavutil is created to make
+ * dealing with memory consistently possible on all platforms.
+ *
+ * @{
+ *
+ * @defgroup lavu_mem_macros Alignment Macros
+ * Helper macros for declaring aligned variables.
* @{
*/
+/**
+ * @def DECLARE_ALIGNED(n,t,v)
+ * Declare a variable that is aligned in memory.
+ *
+ * @code{.c}
+ * DECLARE_ALIGNED(16, uint16_t, aligned_int) = 42;
+ * DECLARE_ALIGNED(32, uint8_t, aligned_array)[128];
+ *
+ * // The default-alignment equivalent would be
+ * uint16_t aligned_int = 42;
+ * uint8_t aligned_array[128];
+ * @endcode
+ *
+ * @param n Minimum alignment in bytes
+ * @param t Type of the variable (or array element)
+ * @param v Name of the variable
+ */
+
+/**
+ * @def DECLARE_ASM_ALIGNED(n,t,v)
+ * Declare an aligned variable appropriate for use in inline assembly code.
+ *
+ * @code{.c}
+ * DECLARE_ASM_ALIGNED(16, uint64_t, pw_08) = UINT64_C(0x0008000800080008);
+ * @endcode
+ *
+ * @param n Minimum alignment in bytes
+ * @param t Type of the variable (or array element)
+ * @param v Name of the variable
+ */
+
+/**
+ * @def DECLARE_ASM_CONST(n,t,v)
+ * Declare a static constant aligned variable appropriate for use in inline
+ * assembly code.
+ *
+ * @code{.c}
+ * DECLARE_ASM_CONST(16, uint64_t, pw_08) = UINT64_C(0x0008000800080008);
+ * @endcode
+ *
+ * @param n Minimum alignment in bytes
+ * @param t Type of the variable (or array element)
+ * @param v Name of the variable
+ */
#if defined(__INTEL_COMPILER) && __INTEL_COMPILER < 1110 || defined(__SUNPRO_C)
#define DECLARE_ALIGNED(n,t,v) t __attribute__ ((aligned (n))) v
+ #define DECLARE_ASM_ALIGNED(n,t,v) t __attribute__ ((aligned (n))) v
#define DECLARE_ASM_CONST(n,t,v) const t __attribute__ ((aligned (n))) v
-#elif defined(__TI_COMPILER_VERSION__)
- #define DECLARE_ALIGNED(n,t,v) \
- AV_PRAGMA(DATA_ALIGN(v,n)) \
- t __attribute__((aligned(n))) v
- #define DECLARE_ASM_CONST(n,t,v) \
- AV_PRAGMA(DATA_ALIGN(v,n)) \
- static const t __attribute__((aligned(n))) v
-#elif defined(__GNUC__)
+#elif defined(__DJGPP__)
+ #define DECLARE_ALIGNED(n,t,v) t __attribute__ ((aligned (FFMIN(n, 16)))) v
+ #define DECLARE_ASM_ALIGNED(n,t,v) t av_used __attribute__ ((aligned (FFMIN(n, 16)))) v
+ #define DECLARE_ASM_CONST(n,t,v) static const t av_used __attribute__ ((aligned (FFMIN(n, 16)))) v
+#elif defined(__GNUC__) || defined(__clang__)
#define DECLARE_ALIGNED(n,t,v) t __attribute__ ((aligned (n))) v
+ #define DECLARE_ASM_ALIGNED(n,t,v) t av_used __attribute__ ((aligned (n))) v
#define DECLARE_ASM_CONST(n,t,v) static const t av_used __attribute__ ((aligned (n))) v
#elif defined(_MSC_VER)
#define DECLARE_ALIGNED(n,t,v) __declspec(align(n)) t v
+ #define DECLARE_ASM_ALIGNED(n,t,v) __declspec(align(n)) t v
#define DECLARE_ASM_CONST(n,t,v) __declspec(align(n)) static const t v
#else
#define DECLARE_ALIGNED(n,t,v) t v
+ #define DECLARE_ASM_ALIGNED(n,t,v) t v
#define DECLARE_ASM_CONST(n,t,v) static const t v
#endif
+/**
+ * @}
+ */
+
+/**
+ * @defgroup lavu_mem_attrs Function Attributes
+ * Function attributes applicable to memory handling functions.
+ *
+ * These function attributes can help compilers emit more useful warnings, or
+ * generate better code.
+ * @{
+ */
+
+/**
+ * @def av_malloc_attrib
+ * Function attribute denoting a malloc-like function.
+ *
+ * @see Function attribute `malloc` in GCC's documentation
+ */
+
#if AV_GCC_VERSION_AT_LEAST(3,1)
#define av_malloc_attrib __attribute__((__malloc__))
#else
#define av_malloc_attrib
#endif
+/**
+ * @def av_alloc_size(...)
+ * Function attribute used on a function that allocates memory, whose size is
+ * given by the specified parameter(s).
+ *
+ * @code{.c}
+ * void *av_malloc(size_t size) av_alloc_size(1);
+ * void *av_calloc(size_t nmemb, size_t size) av_alloc_size(1, 2);
+ * @endcode
+ *
+ * @param ... One or two parameter indexes, separated by a comma
+ *
+ * @see Function attribute `alloc_size` in GCC's documentation
+ */
+
#if AV_GCC_VERSION_AT_LEAST(4,3)
#define av_alloc_size(...) __attribute__((alloc_size(__VA_ARGS__)))
#else
@@ -73,204 +170,423 @@
#endif
/**
- * Allocate a block of size bytes with alignment suitable for all
- * memory accesses (including vectors if available on the CPU).
- * @param size Size in bytes for the memory block to be allocated.
- * @return Pointer to the allocated block, NULL if the block cannot
- * be allocated.
+ * @}
+ */
+
+/**
+ * @defgroup lavu_mem_funcs Heap Management
+ * Functions responsible for allocating, freeing, and copying memory.
+ *
+ * All memory allocation functions have a built-in upper limit of `INT_MAX`
+ * bytes. This may be changed with av_max_alloc(), although exercise extreme
+ * caution when doing so.
+ *
+ * @{
+ */
+
+/**
+ * Allocate a memory block with alignment suitable for all memory accesses
+ * (including vectors if available on the CPU).
+ *
+ * @param size Size in bytes for the memory block to be allocated
+ * @return Pointer to the allocated block, or `NULL` if the block cannot
+ * be allocated
* @see av_mallocz()
*/
void *av_malloc(size_t size) av_malloc_attrib av_alloc_size(1);
/**
- * Allocate a block of size * nmemb bytes with av_malloc().
- * @param nmemb Number of elements
- * @param size Size of the single element
- * @return Pointer to the allocated block, NULL if the block cannot
- * be allocated.
- * @see av_malloc()
- */
-av_alloc_size(1, 2) static inline void *av_malloc_array(size_t nmemb, size_t size)
-{
- if (!size || nmemb >= INT_MAX / size)
- return NULL;
- return av_malloc(nmemb * size);
-}
-
-/**
- * Allocate or reallocate a block of memory.
- * If ptr is NULL and size > 0, allocate a new block. If
- * size is zero, free the memory block pointed to by ptr.
- * @param ptr Pointer to a memory block already allocated with
- * av_realloc() or NULL.
- * @param size Size in bytes of the memory block to be allocated or
- * reallocated.
- * @return Pointer to a newly-reallocated block or NULL if the block
- * cannot be reallocated or the function is used to free the memory block.
- * @warning Pointers originating from the av_malloc() family of functions must
- * not be passed to av_realloc(). The former can be implemented using
- * memalign() (or other functions), and there is no guarantee that
- * pointers from such functions can be passed to realloc() at all.
- * The situation is undefined according to POSIX and may crash with
- * some libc implementations.
- * @see av_fast_realloc()
- */
-void *av_realloc(void *ptr, size_t size) av_alloc_size(2);
-
-/**
- * Allocate or reallocate a block of memory.
- * This function does the same thing as av_realloc, except:
- * - It takes two arguments and checks the result of the multiplication for
- * integer overflow.
- * - It frees the input block in case of failure, thus avoiding the memory
- * leak with the classic "buf = realloc(buf); if (!buf) return -1;".
- */
-void *av_realloc_f(void *ptr, size_t nelem, size_t elsize);
-
-/**
- * Allocate or reallocate a block of memory.
- * If *ptr is NULL and size > 0, allocate a new block. If
- * size is zero, free the memory block pointed to by ptr.
- * @param ptr Pointer to a pointer to a memory block already allocated
- * with av_realloc(), or pointer to a pointer to NULL.
- * The pointer is updated on success, or freed on failure.
- * @param size Size in bytes for the memory block to be allocated or
- * reallocated
- * @return Zero on success, an AVERROR error code on failure.
- * @warning Pointers originating from the av_malloc() family of functions must
- * not be passed to av_reallocp(). The former can be implemented using
- * memalign() (or other functions), and there is no guarantee that
- * pointers from such functions can be passed to realloc() at all.
- * The situation is undefined according to POSIX and may crash with
- * some libc implementations.
- */
-av_warn_unused_result
-int av_reallocp(void *ptr, size_t size);
-
-/**
- * Allocate or reallocate an array.
- * If ptr is NULL and nmemb > 0, allocate a new block. If
- * nmemb is zero, free the memory block pointed to by ptr.
- * @param ptr Pointer to a memory block already allocated with
- * av_realloc() or NULL.
- * @param nmemb Number of elements
- * @param size Size of the single element
- * @return Pointer to a newly-reallocated block or NULL if the block
- * cannot be reallocated or the function is used to free the memory block.
- * @warning Pointers originating from the av_malloc() family of functions must
- * not be passed to av_realloc(). The former can be implemented using
- * memalign() (or other functions), and there is no guarantee that
- * pointers from such functions can be passed to realloc() at all.
- * The situation is undefined according to POSIX and may crash with
- * some libc implementations.
- */
-av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size);
-
-/**
- * Allocate or reallocate an array through a pointer to a pointer.
- * If *ptr is NULL and nmemb > 0, allocate a new block. If
- * nmemb is zero, free the memory block pointed to by ptr.
- * @param ptr Pointer to a pointer to a memory block already allocated
- * with av_realloc(), or pointer to a pointer to NULL.
- * The pointer is updated on success, or freed on failure.
- * @param nmemb Number of elements
- * @param size Size of the single element
- * @return Zero on success, an AVERROR error code on failure.
- * @warning Pointers originating from the av_malloc() family of functions must
- * not be passed to av_realloc(). The former can be implemented using
- * memalign() (or other functions), and there is no guarantee that
- * pointers from such functions can be passed to realloc() at all.
- * The situation is undefined according to POSIX and may crash with
- * some libc implementations.
- */
-av_alloc_size(2, 3) int av_reallocp_array(void *ptr, size_t nmemb, size_t size);
-
-/**
- * Free a memory block which has been allocated with av_malloc(z)() or
- * av_realloc().
- * @param ptr Pointer to the memory block which should be freed.
- * @note ptr = NULL is explicitly allowed.
- * @note It is recommended that you use av_freep() instead.
- * @see av_freep()
- */
-void av_free(void *ptr);
-
-/**
- * Allocate a block of size bytes with alignment suitable for all
- * memory accesses (including vectors if available on the CPU) and
- * zero all the bytes of the block.
- * @param size Size in bytes for the memory block to be allocated.
- * @return Pointer to the allocated block, NULL if it cannot be allocated.
+ * Allocate a memory block with alignment suitable for all memory accesses
+ * (including vectors if available on the CPU) and zero all the bytes of the
+ * block.
+ *
+ * @param size Size in bytes for the memory block to be allocated
+ * @return Pointer to the allocated block, or `NULL` if it cannot be allocated
* @see av_malloc()
*/
void *av_mallocz(size_t size) av_malloc_attrib av_alloc_size(1);
/**
- * Allocate a block of nmemb * size bytes with alignment suitable for all
- * memory accesses (including vectors if available on the CPU) and
- * zero all the bytes of the block.
- * The allocation will fail if nmemb * size is greater than or equal
- * to INT_MAX.
- * @param nmemb
- * @param size
- * @return Pointer to the allocated block, NULL if it cannot be allocated.
+ * Allocate a memory block for an array with av_malloc().
+ *
+ * The allocated memory will have size `size * nmemb` bytes.
+ *
+ * @param nmemb Number of element
+ * @param size Size of a single element
+ * @return Pointer to the allocated block, or `NULL` if the block cannot
+ * be allocated
+ * @see av_malloc()
+ */
+av_alloc_size(1, 2) void *av_malloc_array(size_t nmemb, size_t size);
+
+/**
+ * Allocate a memory block for an array with av_mallocz().
+ *
+ * The allocated memory will have size `size * nmemb` bytes.
+ *
+ * @param nmemb Number of elements
+ * @param size Size of the single element
+ * @return Pointer to the allocated block, or `NULL` if the block cannot
+ * be allocated
+ *
+ * @see av_mallocz()
+ * @see av_malloc_array()
+ */
+av_alloc_size(1, 2) void *av_mallocz_array(size_t nmemb, size_t size);
+
+/**
+ * Non-inlined equivalent of av_mallocz_array().
+ *
+ * Created for symmetry with the calloc() C function.
*/
void *av_calloc(size_t nmemb, size_t size) av_malloc_attrib;
/**
- * Allocate a block of size * nmemb bytes with av_mallocz().
- * @param nmemb Number of elements
- * @param size Size of the single element
- * @return Pointer to the allocated block, NULL if the block cannot
- * be allocated.
- * @see av_mallocz()
- * @see av_malloc_array()
+ * Allocate, reallocate, or free a block of memory.
+ *
+ * If `ptr` is `NULL` and `size` > 0, allocate a new block. If `size` is
+ * zero, free the memory block pointed to by `ptr`. Otherwise, expand or
+ * shrink that block of memory according to `size`.
+ *
+ * @param ptr Pointer to a memory block already allocated with
+ * av_realloc() or `NULL`
+ * @param size Size in bytes of the memory block to be allocated or
+ * reallocated
+ *
+ * @return Pointer to a newly-reallocated block or `NULL` if the block
+ * cannot be reallocated or the function is used to free the memory block
+ *
+ * @warning Unlike av_malloc(), the returned pointer is not guaranteed to be
+ * correctly aligned.
+ * @see av_fast_realloc()
+ * @see av_reallocp()
*/
-av_alloc_size(1, 2) static inline void *av_mallocz_array(size_t nmemb, size_t size)
-{
- if (!size || nmemb >= INT_MAX / size)
- return NULL;
- return av_mallocz(nmemb * size);
-}
+void *av_realloc(void *ptr, size_t size) av_alloc_size(2);
/**
- * Duplicate the string s.
- * @param s string to be duplicated
- * @return Pointer to a newly-allocated string containing a
- * copy of s or NULL if the string cannot be allocated.
+ * Allocate, reallocate, or free a block of memory through a pointer to a
+ * pointer.
+ *
+ * If `*ptr` is `NULL` and `size` > 0, allocate a new block. If `size` is
+ * zero, free the memory block pointed to by `*ptr`. Otherwise, expand or
+ * shrink that block of memory according to `size`.
+ *
+ * @param[in,out] ptr Pointer to a pointer to a memory block already allocated
+ * with av_realloc(), or a pointer to `NULL`. The pointer
+ * is updated on success, or freed on failure.
+ * @param[in] size Size in bytes for the memory block to be allocated or
+ * reallocated
+ *
+ * @return Zero on success, an AVERROR error code on failure
+ *
+ * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be
+ * correctly aligned.
*/
-char *av_strdup(const char *s) av_malloc_attrib;
+av_warn_unused_result
+int av_reallocp(void *ptr, size_t size);
/**
- * Duplicate a substring of the string s.
- * @param s string to be duplicated
- * @param len the maximum length of the resulting string (not counting the
- * terminating byte).
- * @return Pointer to a newly-allocated string containing a
- * copy of s or NULL if the string cannot be allocated.
+ * Allocate, reallocate, or free a block of memory.
+ *
+ * This function does the same thing as av_realloc(), except:
+ * - It takes two size arguments and allocates `nelem * elsize` bytes,
+ * after checking the result of the multiplication for integer overflow.
+ * - It frees the input block in case of failure, thus avoiding the memory
+ * leak with the classic
+ * @code{.c}
+ * buf = realloc(buf);
+ * if (!buf)
+ * return -1;
+ * @endcode
+ * pattern.
*/
-char *av_strndup(const char *s, size_t len) av_malloc_attrib;
+void *av_realloc_f(void *ptr, size_t nelem, size_t elsize);
/**
- * Duplicate the buffer p.
- * @param p buffer to be duplicated
- * @return Pointer to a newly allocated buffer containing a
- * copy of p or NULL if the buffer cannot be allocated.
+ * Allocate, reallocate, or free an array.
+ *
+ * If `ptr` is `NULL` and `nmemb` > 0, allocate a new block. If
+ * `nmemb` is zero, free the memory block pointed to by `ptr`.
+ *
+ * @param ptr Pointer to a memory block already allocated with
+ * av_realloc() or `NULL`
+ * @param nmemb Number of elements in the array
+ * @param size Size of the single element of the array
+ *
+ * @return Pointer to a newly-reallocated block or NULL if the block
+ * cannot be reallocated or the function is used to free the memory block
+ *
+ * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be
+ * correctly aligned.
+ * @see av_reallocp_array()
*/
-void *av_memdup(const void *p, size_t size);
+av_alloc_size(2, 3) void *av_realloc_array(void *ptr, size_t nmemb, size_t size);
/**
- * Free a memory block which has been allocated with av_malloc(z)() or
- * av_realloc() and set the pointer pointing to it to NULL.
- * @param ptr Pointer to the pointer to the memory block which should
- * be freed.
- * @note passing a pointer to a NULL pointer is safe and leads to no action.
+ * Allocate, reallocate, or free an array through a pointer to a pointer.
+ *
+ * If `*ptr` is `NULL` and `nmemb` > 0, allocate a new block. If `nmemb` is
+ * zero, free the memory block pointed to by `*ptr`.
+ *
+ * @param[in,out] ptr Pointer to a pointer to a memory block already
+ * allocated with av_realloc(), or a pointer to `NULL`.
+ * The pointer is updated on success, or freed on failure.
+ * @param[in] nmemb Number of elements
+ * @param[in] size Size of the single element
+ *
+ * @return Zero on success, an AVERROR error code on failure
+ *
+ * @warning Unlike av_malloc(), the allocated memory is not guaranteed to be
+ * correctly aligned.
+ */
+int av_reallocp_array(void *ptr, size_t nmemb, size_t size);
+
+/**
+ * Reallocate the given buffer if it is not large enough, otherwise do nothing.
+ *
+ * If the given buffer is `NULL`, then a new uninitialized buffer is allocated.
+ *
+ * If the given buffer is not large enough, and reallocation fails, `NULL` is
+ * returned and `*size` is set to 0, but the original buffer is not changed or
+ * freed.
+ *
+ * A typical use pattern follows:
+ *
+ * @code{.c}
+ * uint8_t *buf = ...;
+ * uint8_t *new_buf = av_fast_realloc(buf, ¤t_size, size_needed);
+ * if (!new_buf) {
+ * // Allocation failed; clean up original buffer
+ * av_freep(&buf);
+ * return AVERROR(ENOMEM);
+ * }
+ * @endcode
+ *
+ * @param[in,out] ptr Already allocated buffer, or `NULL`
+ * @param[in,out] size Pointer to the size of buffer `ptr`. `*size` is
+ * updated to the new allocated size, in particular 0
+ * in case of failure.
+ * @param[in] min_size Desired minimal size of buffer `ptr`
+ * @return `ptr` if the buffer is large enough, a pointer to newly reallocated
+ * buffer if the buffer was not large enough, or `NULL` in case of
+ * error
+ * @see av_realloc()
+ * @see av_fast_malloc()
+ */
+void *av_fast_realloc(void *ptr, unsigned int *size, size_t min_size);
+
+/**
+ * Allocate a buffer, reusing the given one if large enough.
+ *
+ * Contrary to av_fast_realloc(), the current buffer contents might not be
+ * preserved and on error the old buffer is freed, thus no special handling to
+ * avoid memleaks is necessary.
+ *
+ * `*ptr` is allowed to be `NULL`, in which case allocation always happens if
+ * `size_needed` is greater than 0.
+ *
+ * @code{.c}
+ * uint8_t *buf = ...;
+ * av_fast_malloc(&buf, ¤t_size, size_needed);
+ * if (!buf) {
+ * // Allocation failed; buf already freed
+ * return AVERROR(ENOMEM);
+ * }
+ * @endcode
+ *
+ * @param[in,out] ptr Pointer to pointer to an already allocated buffer.
+ * `*ptr` will be overwritten with pointer to new
+ * buffer on success or `NULL` on failure
+ * @param[in,out] size Pointer to the size of buffer `*ptr`. `*size` is
+ * updated to the new allocated size, in particular 0
+ * in case of failure.
+ * @param[in] min_size Desired minimal size of buffer `*ptr`
+ * @see av_realloc()
+ * @see av_fast_mallocz()
+ */
+void av_fast_malloc(void *ptr, unsigned int *size, size_t min_size);
+
+/**
+ * Allocate and clear a buffer, reusing the given one if large enough.
+ *
+ * Like av_fast_malloc(), but all newly allocated space is initially cleared.
+ * Reused buffer is not cleared.
+ *
+ * `*ptr` is allowed to be `NULL`, in which case allocation always happens if
+ * `size_needed` is greater than 0.
+ *
+ * @param[in,out] ptr Pointer to pointer to an already allocated buffer.
+ * `*ptr` will be overwritten with pointer to new
+ * buffer on success or `NULL` on failure
+ * @param[in,out] size Pointer to the size of buffer `*ptr`. `*size` is
+ * updated to the new allocated size, in particular 0
+ * in case of failure.
+ * @param[in] min_size Desired minimal size of buffer `*ptr`
+ * @see av_fast_malloc()
+ */
+void av_fast_mallocz(void *ptr, unsigned int *size, size_t min_size);
+
+/**
+ * Free a memory block which has been allocated with a function of av_malloc()
+ * or av_realloc() family.
+ *
+ * @param ptr Pointer to the memory block which should be freed.
+ *
+ * @note `ptr = NULL` is explicitly allowed.
+ * @note It is recommended that you use av_freep() instead, to prevent leaving
+ * behind dangling pointers.
+ * @see av_freep()
+ */
+void av_free(void *ptr);
+
+/**
+ * Free a memory block which has been allocated with a function of av_malloc()
+ * or av_realloc() family, and set the pointer pointing to it to `NULL`.
+ *
+ * @code{.c}
+ * uint8_t *buf = av_malloc(16);
+ * av_free(buf);
+ * // buf now contains a dangling pointer to freed memory, and accidental
+ * // dereference of buf will result in a use-after-free, which may be a
+ * // security risk.
+ *
+ * uint8_t *buf = av_malloc(16);
+ * av_freep(&buf);
+ * // buf is now NULL, and accidental dereference will only result in a
+ * // NULL-pointer dereference.
+ * @endcode
+ *
+ * @param ptr Pointer to the pointer to the memory block which should be freed
+ * @note `*ptr = NULL` is safe and leads to no action.
* @see av_free()
*/
void av_freep(void *ptr);
/**
- * Add an element to a dynamic array.
+ * Duplicate a string.
+ *
+ * @param s String to be duplicated
+ * @return Pointer to a newly-allocated string containing a
+ * copy of `s` or `NULL` if the string cannot be allocated
+ * @see av_strndup()
+ */
+char *av_strdup(const char *s) av_malloc_attrib;
+
+/**
+ * Duplicate a substring of a string.
+ *
+ * @param s String to be duplicated
+ * @param len Maximum length of the resulting string (not counting the
+ * terminating byte)
+ * @return Pointer to a newly-allocated string containing a
+ * substring of `s` or `NULL` if the string cannot be allocated
+ */
+char *av_strndup(const char *s, size_t len) av_malloc_attrib;
+
+/**
+ * Duplicate a buffer with av_malloc().
+ *
+ * @param p Buffer to be duplicated
+ * @param size Size in bytes of the buffer copied
+ * @return Pointer to a newly allocated buffer containing a
+ * copy of `p` or `NULL` if the buffer cannot be allocated
+ */
+void *av_memdup(const void *p, size_t size);
+
+/**
+ * Overlapping memcpy() implementation.
+ *
+ * @param dst Destination buffer
+ * @param back Number of bytes back to start copying (i.e. the initial size of
+ * the overlapping window); must be > 0
+ * @param cnt Number of bytes to copy; must be >= 0
+ *
+ * @note `cnt > back` is valid, this will copy the bytes we just copied,
+ * thus creating a repeating pattern with a period length of `back`.
+ */
+void av_memcpy_backptr(uint8_t *dst, int back, int cnt);
+
+/**
+ * @}
+ */
+
+/**
+ * @defgroup lavu_mem_dynarray Dynamic Array
+ *
+ * Utilities to make an array grow when needed.
+ *
+ * Sometimes, the programmer would want to have an array that can grow when
+ * needed. The libavutil dynamic array utilities fill that need.
+ *
+ * libavutil supports two systems of appending elements onto a dynamically
+ * allocated array, the first one storing the pointer to the value in the
+ * array, and the second storing the value directly. In both systems, the
+ * caller is responsible for maintaining a variable containing the length of
+ * the array, as well as freeing of the array after use.
+ *
+ * The first system stores pointers to values in a block of dynamically
+ * allocated memory. Since only pointers are stored, the function does not need
+ * to know the size of the type. Both av_dynarray_add() and
+ * av_dynarray_add_nofree() implement this system.
+ *
+ * @code
+ * type **array = NULL; //< an array of pointers to values
+ * int nb = 0; //< a variable to keep track of the length of the array
+ *
+ * type to_be_added = ...;
+ * type to_be_added2 = ...;
+ *
+ * av_dynarray_add(&array, &nb, &to_be_added);
+ * if (nb == 0)
+ * return AVERROR(ENOMEM);
+ *
+ * av_dynarray_add(&array, &nb, &to_be_added2);
+ * if (nb == 0)
+ * return AVERROR(ENOMEM);
+ *
+ * // Now:
+ * // nb == 2
+ * // &to_be_added == array[0]
+ * // &to_be_added2 == array[1]
+ *
+ * av_freep(&array);
+ * @endcode
+ *
+ * The second system stores the value directly in a block of memory. As a
+ * result, the function has to know the size of the type. av_dynarray2_add()
+ * implements this mechanism.
+ *
+ * @code
+ * type *array = NULL; //< an array of values
+ * int nb = 0; //< a variable to keep track of the length of the array
+ *
+ * type to_be_added = ...;
+ * type to_be_added2 = ...;
+ *
+ * type *addr = av_dynarray2_add((void **)&array, &nb, sizeof(*array), NULL);
+ * if (!addr)
+ * return AVERROR(ENOMEM);
+ * memcpy(addr, &to_be_added, sizeof(to_be_added));
+ *
+ * // Shortcut of the above.
+ * type *addr = av_dynarray2_add((void **)&array, &nb, sizeof(*array),
+ * (const void *)&to_be_added2);
+ * if (!addr)
+ * return AVERROR(ENOMEM);
+ *
+ * // Now:
+ * // nb == 2
+ * // to_be_added == array[0]
+ * // to_be_added2 == array[1]
+ *
+ * av_freep(&array);
+ * @endcode
+ *
+ * @{
+ */
+
+/**
+ * Add the pointer to an element to a dynamic array.
*
* The array to grow is supposed to be an array of pointers to
* structures, and the element to add must be a pointer to an already
@@ -280,14 +596,14 @@ void av_freep(void *ptr);
* Therefore, the amortized cost of adding an element is constant.
*
* In case of success, the pointer to the array is updated in order to
- * point to the new grown array, and the number pointed to by nb_ptr
+ * point to the new grown array, and the number pointed to by `nb_ptr`
* is incremented.
- * In case of failure, the array is freed, *tab_ptr is set to NULL and
- * *nb_ptr is set to 0.
+ * In case of failure, the array is freed, `*tab_ptr` is set to `NULL` and
+ * `*nb_ptr` is set to 0.
*
- * @param tab_ptr pointer to the array to grow
- * @param nb_ptr pointer to the number of elements in the array
- * @param elem element to add
+ * @param[in,out] tab_ptr Pointer to the array to grow
+ * @param[in,out] nb_ptr Pointer to the number of elements in the array
+ * @param[in] elem Element to add
* @see av_dynarray_add_nofree(), av_dynarray2_add()
*/
void av_dynarray_add(void *tab_ptr, int *nb_ptr, void *elem);
@@ -299,48 +615,62 @@ void av_dynarray_add(void *tab_ptr, int *nb_ptr, void *elem);
* but it doesn't free memory on fails. It returns error code
* instead and leave current buffer untouched.
*
- * @param tab_ptr pointer to the array to grow
- * @param nb_ptr pointer to the number of elements in the array
- * @param elem element to add
- * @return >=0 on success, negative otherwise.
+ * @return >=0 on success, negative otherwise
* @see av_dynarray_add(), av_dynarray2_add()
*/
av_warn_unused_result
int av_dynarray_add_nofree(void *tab_ptr, int *nb_ptr, void *elem);
/**
- * Add an element of size elem_size to a dynamic array.
+ * Add an element of size `elem_size` to a dynamic array.
*
* The array is reallocated when its number of elements reaches powers of 2.
* Therefore, the amortized cost of adding an element is constant.
*
* In case of success, the pointer to the array is updated in order to
- * point to the new grown array, and the number pointed to by nb_ptr
+ * point to the new grown array, and the number pointed to by `nb_ptr`
* is incremented.
- * In case of failure, the array is freed, *tab_ptr is set to NULL and
- * *nb_ptr is set to 0.
+ * In case of failure, the array is freed, `*tab_ptr` is set to `NULL` and
+ * `*nb_ptr` is set to 0.
*
- * @param tab_ptr pointer to the array to grow
- * @param nb_ptr pointer to the number of elements in the array
- * @param elem_size size in bytes of the elements in the array
- * @param elem_data pointer to the data of the element to add. If NULL, the space of
- * the new added element is not filled.
- * @return pointer to the data of the element to copy in the new allocated space.
- * If NULL, the new allocated space is left uninitialized."
+ * @param[in,out] tab_ptr Pointer to the array to grow
+ * @param[in,out] nb_ptr Pointer to the number of elements in the array
+ * @param[in] elem_size Size in bytes of an element in the array
+ * @param[in] elem_data Pointer to the data of the element to add. If
+ * `NULL`, the space of the newly added element is
+ * allocated but left uninitialized.
+ *
+ * @return Pointer to the data of the element to copy in the newly allocated
+ * space
* @see av_dynarray_add(), av_dynarray_add_nofree()
*/
void *av_dynarray2_add(void **tab_ptr, int *nb_ptr, size_t elem_size,
const uint8_t *elem_data);
/**
- * Multiply two size_t values checking for overflow.
- * @return 0 if success, AVERROR(EINVAL) if overflow.
+ * @}
+ */
+
+/**
+ * @defgroup lavu_mem_misc Miscellaneous Functions
+ *
+ * Other functions related to memory allocation.
+ *
+ * @{
+ */
+
+/**
+ * Multiply two `size_t` values checking for overflow.
+ *
+ * @param[in] a,b Operands of multiplication
+ * @param[out] r Pointer to the result of the operation
+ * @return 0 on success, AVERROR(EINVAL) on overflow
*/
static inline int av_size_mult(size_t a, size_t b, size_t *r)
{
size_t t = a * b;
- /* Hack inspired from glibc: only try the division if nelem and elsize
- * are both greater than sqrt(SIZE_MAX). */
+ /* Hack inspired from glibc: don't try the division if nelem and elsize
+ * are both less than sqrt(SIZE_MAX). */
if ((a | b) >= ((size_t)1 << (sizeof(size_t) * 4)) && a && t / a != b)
return AVERROR(EINVAL);
*r = t;
@@ -348,43 +678,22 @@ static inline int av_size_mult(size_t a, size_t b, size_t *r)
}
/**
- * Set the maximum size that may me allocated in one block.
+ * Set the maximum size that may be allocated in one block.
+ *
+ * The value specified with this function is effective for all libavutil's @ref
+ * lavu_mem_funcs "heap management functions."
+ *
+ * By default, the max value is defined as `INT_MAX`.
+ *
+ * @param max Value to be set as the new maximum size
+ *
+ * @warning Exercise extreme caution when using this function. Don't touch
+ * this if you do not understand the full consequence of doing so.
*/
void av_max_alloc(size_t max);
/**
- * deliberately overlapping memcpy implementation
- * @param dst destination buffer
- * @param back how many bytes back we start (the initial size of the overlapping window), must be > 0
- * @param cnt number of bytes to copy, must be >= 0
- *
- * cnt > back is valid, this will copy the bytes we just copied,
- * thus creating a repeating pattern with a period length of back.
- */
-void av_memcpy_backptr(uint8_t *dst, int back, int cnt);
-
-/**
- * Reallocate the given block if it is not large enough, otherwise do nothing.
- *
- * @see av_realloc
- */
-void *av_fast_realloc(void *ptr, unsigned int *size, size_t min_size);
-
-/**
- * Allocate a buffer, reusing the given one if large enough.
- *
- * Contrary to av_fast_realloc the current buffer contents might not be
- * preserved and on error the old buffer is freed, thus no special
- * handling to avoid memleaks is necessary.
- *
- * @param ptr pointer to pointer to already allocated buffer, overwritten with pointer to new buffer
- * @param size size of the buffer *ptr points to
- * @param min_size minimum size of *ptr buffer after returning, *ptr will be NULL and
- * *size 0 if an error occurred.
- */
-void av_fast_malloc(void *ptr, unsigned int *size, size_t min_size);
-
-/**
+ * @}
* @}
*/
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/motion_vector.h b/neo/libs/ffmpeg-win64/include/libavutil/motion_vector.h
index 30cfb994..ec295563 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/motion_vector.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/motion_vector.h
@@ -45,6 +45,13 @@ typedef struct AVMotionVector {
* Currently unused.
*/
uint64_t flags;
+ /**
+ * Motion vector
+ * src_x = dst_x + motion_x / motion_scale
+ * src_y = dst_y + motion_y / motion_scale
+ */
+ int32_t motion_x, motion_y;
+ uint16_t motion_scale;
} AVMotionVector;
#endif /* AVUTIL_MOTION_VECTOR_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/murmur3.h b/neo/libs/ffmpeg-win64/include/libavutil/murmur3.h
index f29ed973..1b09175c 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/murmur3.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/murmur3.h
@@ -18,15 +18,103 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_murmur3
+ * Public header for MurmurHash3 hash function implementation.
+ */
+
#ifndef AVUTIL_MURMUR3_H
#define AVUTIL_MURMUR3_H
#include
+#include "version.h"
+
+/**
+ * @defgroup lavu_murmur3 Murmur3
+ * @ingroup lavu_hash
+ * MurmurHash3 hash function implementation.
+ *
+ * MurmurHash3 is a non-cryptographic hash function, of which three
+ * incompatible versions were created by its inventor Austin Appleby:
+ *
+ * - 32-bit output
+ * - 128-bit output for 32-bit platforms
+ * - 128-bit output for 64-bit platforms
+ *
+ * FFmpeg only implements the last variant: 128-bit output designed for 64-bit
+ * platforms. Even though the hash function was designed for 64-bit platforms,
+ * the function in reality works on 32-bit systems too, only with reduced
+ * performance.
+ *
+ * @anchor lavu_murmur3_seedinfo
+ * By design, MurmurHash3 requires a seed to operate. In response to this,
+ * libavutil provides two functions for hash initiation, one that requires a
+ * seed (av_murmur3_init_seeded()) and one that uses a fixed arbitrary integer
+ * as the seed, and therefore does not (av_murmur3_init()).
+ *
+ * To make hashes comparable, you should provide the same seed for all calls to
+ * this hash function -- if you are supplying one yourself, that is.
+ *
+ * @{
+ */
+
+/**
+ * Allocate an AVMurMur3 hash context.
+ *
+ * @return Uninitialized hash context or `NULL` in case of error
+ */
struct AVMurMur3 *av_murmur3_alloc(void);
+
+/**
+ * Initialize or reinitialize an AVMurMur3 hash context with a seed.
+ *
+ * @param[out] c Hash context
+ * @param[in] seed Random seed
+ *
+ * @see av_murmur3_init()
+ * @see @ref lavu_murmur3_seedinfo "Detailed description" on a discussion of
+ * seeds for MurmurHash3.
+ */
void av_murmur3_init_seeded(struct AVMurMur3 *c, uint64_t seed);
+
+/**
+ * Initialize or reinitialize an AVMurMur3 hash context.
+ *
+ * Equivalent to av_murmur3_init_seeded() with a built-in seed.
+ *
+ * @param[out] c Hash context
+ *
+ * @see av_murmur3_init_seeded()
+ * @see @ref lavu_murmur3_seedinfo "Detailed description" on a discussion of
+ * seeds for MurmurHash3.
+ */
void av_murmur3_init(struct AVMurMur3 *c);
+
+/**
+ * Update hash context with new data.
+ *
+ * @param[out] c Hash context
+ * @param[in] src Input data to update hash with
+ * @param[in] len Number of bytes to read from `src`
+ */
+#if FF_API_CRYPTO_SIZE_T
void av_murmur3_update(struct AVMurMur3 *c, const uint8_t *src, int len);
+#else
+void av_murmur3_update(struct AVMurMur3 *c, const uint8_t *src, size_t len);
+#endif
+
+/**
+ * Finish hashing and output digest value.
+ *
+ * @param[in,out] c Hash context
+ * @param[out] dst Buffer where output digest value is stored
+ */
void av_murmur3_final(struct AVMurMur3 *c, uint8_t dst[16]);
+/**
+ * @}
+ */
+
#endif /* AVUTIL_MURMUR3_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/opt.h b/neo/libs/ffmpeg-win64/include/libavutil/opt.h
index 753434d6..39f4a8dd 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/opt.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/opt.h
@@ -58,7 +58,7 @@
* The following example illustrates an AVOptions-enabled struct:
* @code
* typedef struct test_struct {
- * AVClass *class;
+ * const AVClass *class;
* int int_opt;
* char *str_opt;
* uint8_t *bin_opt;
@@ -96,7 +96,7 @@
* @code
* test_struct *alloc_test_struct(void)
* {
- * test_struct *ret = av_malloc(sizeof(*ret));
+ * test_struct *ret = av_mallocz(sizeof(*ret));
* ret->class = &test_class;
* av_opt_set_defaults(ret);
* return ret;
@@ -228,15 +228,16 @@ enum AVOptionType{
AV_OPT_TYPE_RATIONAL,
AV_OPT_TYPE_BINARY, ///< offset must point to a pointer immediately followed by an int for the length
AV_OPT_TYPE_DICT,
- AV_OPT_TYPE_CONST = 128,
- AV_OPT_TYPE_IMAGE_SIZE = MKBETAG('S','I','Z','E'), ///< offset must point to two consecutive integers
- AV_OPT_TYPE_PIXEL_FMT = MKBETAG('P','F','M','T'),
- AV_OPT_TYPE_SAMPLE_FMT = MKBETAG('S','F','M','T'),
- AV_OPT_TYPE_VIDEO_RATE = MKBETAG('V','R','A','T'), ///< offset must point to AVRational
- AV_OPT_TYPE_DURATION = MKBETAG('D','U','R',' '),
- AV_OPT_TYPE_COLOR = MKBETAG('C','O','L','R'),
- AV_OPT_TYPE_CHANNEL_LAYOUT = MKBETAG('C','H','L','A'),
- AV_OPT_TYPE_BOOL = MKBETAG('B','O','O','L'),
+ AV_OPT_TYPE_UINT64,
+ AV_OPT_TYPE_CONST,
+ AV_OPT_TYPE_IMAGE_SIZE, ///< offset must point to two consecutive integers
+ AV_OPT_TYPE_PIXEL_FMT,
+ AV_OPT_TYPE_SAMPLE_FMT,
+ AV_OPT_TYPE_VIDEO_RATE, ///< offset must point to AVRational
+ AV_OPT_TYPE_DURATION,
+ AV_OPT_TYPE_COLOR,
+ AV_OPT_TYPE_CHANNEL_LAYOUT,
+ AV_OPT_TYPE_BOOL,
};
/**
@@ -274,14 +275,11 @@ typedef struct AVOption {
int flags;
#define AV_OPT_FLAG_ENCODING_PARAM 1 ///< a generic parameter which can be set by the user for muxing or encoding
#define AV_OPT_FLAG_DECODING_PARAM 2 ///< a generic parameter which can be set by the user for demuxing or decoding
-#if FF_API_OPT_TYPE_METADATA
-#define AV_OPT_FLAG_METADATA 4 ///< some data extracted or inserted into the file like title, comment, ...
-#endif
#define AV_OPT_FLAG_AUDIO_PARAM 8
#define AV_OPT_FLAG_VIDEO_PARAM 16
#define AV_OPT_FLAG_SUBTITLE_PARAM 32
/**
- * The option is inteded for exporting values to the caller.
+ * The option is intended for exporting values to the caller.
*/
#define AV_OPT_FLAG_EXPORT 64
/**
@@ -289,7 +287,9 @@ typedef struct AVOption {
* This flag only makes sense when AV_OPT_FLAG_EXPORT is also set.
*/
#define AV_OPT_FLAG_READONLY 128
+#define AV_OPT_FLAG_BSF_PARAM (1<<8) ///< a generic parameter which can be set by the user for bit stream filtering
#define AV_OPT_FLAG_FILTERING_PARAM (1<<16) ///< a generic parameter which can be set by the user for filtering
+#define AV_OPT_FLAG_DEPRECATED (1<<17) ///< set if option is deprecated, users should refer to AVOption.help text for more information
//FIXME think about enc-audio, ... style flags
/**
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/pixdesc.h b/neo/libs/ffmpeg-win64/include/libavutil/pixdesc.h
index a6056fe1..c055810a 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/pixdesc.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/pixdesc.h
@@ -85,16 +85,16 @@ typedef struct AVPixFmtDescriptor {
/**
* Amount to shift the luma width right to find the chroma width.
* For YV12 this is 1 for example.
- * chroma_width = -((-luma_width) >> log2_chroma_w)
+ * chroma_width = AV_CEIL_RSHIFT(luma_width, log2_chroma_w)
* The note above is needed to ensure rounding up.
* This value only refers to the chroma components.
*/
- uint8_t log2_chroma_w; ///< chroma_width = -((-luma_width )>>log2_chroma_w)
+ uint8_t log2_chroma_w;
/**
* Amount to shift the luma height right to find the chroma height.
* For YV12 this is 1 for example.
- * chroma_height= -((-luma_height) >> log2_chroma_h)
+ * chroma_height= AV_CEIL_RSHIFT(luma_height, log2_chroma_h)
* The note above is needed to ensure rounding up.
* This value only refers to the chroma components.
*/
@@ -154,17 +154,21 @@ typedef struct AVPixFmtDescriptor {
* in some cases be simpler. Or the data can be interpreted purely based on
* the pixel format without using the palette.
* An example of a pseudo-paletted format is AV_PIX_FMT_GRAY8
+ *
+ * @deprecated This flag is deprecated, and will be removed. When it is removed,
+ * the extra palette allocation in AVFrame.data[1] is removed as well. Only
+ * actual paletted formats (as indicated by AV_PIX_FMT_FLAG_PAL) will have a
+ * palette. Starting with FFmpeg versions which have this flag deprecated, the
+ * extra "pseudo" palette is already ignored, and API users are not required to
+ * allocate a palette for AV_PIX_FMT_FLAG_PSEUDOPAL formats (it was required
+ * before the deprecation, though).
*/
#define AV_PIX_FMT_FLAG_PSEUDOPAL (1 << 6)
/**
* The pixel format has an alpha channel. This is set on all formats that
- * support alpha in some way. The exception is AV_PIX_FMT_PAL8, which can
- * carry alpha as part of the palette. Details are explained in the
- * AVPixelFormat enum, and are also encoded in the corresponding
- * AVPixFmtDescriptor.
- *
- * The alpha is always straight, never pre-multiplied.
+ * support alpha in some way, including AV_PIX_FMT_PAL8. The alpha is always
+ * straight, never pre-multiplied.
*
* If a codec or a filter does not support alpha, it should set all alpha to
* opaque, or use the equivalent pixel formats without alpha component, e.g.
@@ -173,76 +177,15 @@ typedef struct AVPixFmtDescriptor {
#define AV_PIX_FMT_FLAG_ALPHA (1 << 7)
/**
- * Read a line from an image, and write the values of the
- * pixel format component c to dst.
- *
- * @param data the array containing the pointers to the planes of the image
- * @param linesize the array containing the linesizes of the image
- * @param desc the pixel format descriptor for the image
- * @param x the horizontal coordinate of the first pixel to read
- * @param y the vertical coordinate of the first pixel to read
- * @param w the width of the line to read, that is the number of
- * values to write to dst
- * @param read_pal_component if not zero and the format is a paletted
- * format writes the values corresponding to the palette
- * component c in data[1] to dst, rather than the palette indexes in
- * data[0]. The behavior is undefined if the format is not paletted.
+ * The pixel format is following a Bayer pattern
*/
-void av_read_image_line(uint16_t *dst, const uint8_t *data[4],
- const int linesize[4], const AVPixFmtDescriptor *desc,
- int x, int y, int c, int w, int read_pal_component);
+#define AV_PIX_FMT_FLAG_BAYER (1 << 8)
/**
- * Write the values from src to the pixel format component c of an
- * image line.
- *
- * @param src array containing the values to write
- * @param data the array containing the pointers to the planes of the
- * image to write into. It is supposed to be zeroed.
- * @param linesize the array containing the linesizes of the image
- * @param desc the pixel format descriptor for the image
- * @param x the horizontal coordinate of the first pixel to write
- * @param y the vertical coordinate of the first pixel to write
- * @param w the width of the line to write, that is the number of
- * values to write to the image line
+ * The pixel format contains IEEE-754 floating point values. Precision (double,
+ * single, or half) should be determined by the pixel size (64, 32, or 16 bits).
*/
-void av_write_image_line(const uint16_t *src, uint8_t *data[4],
- const int linesize[4], const AVPixFmtDescriptor *desc,
- int x, int y, int c, int w);
-
-/**
- * Return the pixel format corresponding to name.
- *
- * If there is no pixel format with name name, then looks for a
- * pixel format with the name corresponding to the native endian
- * format of name.
- * For example in a little-endian system, first looks for "gray16",
- * then for "gray16le".
- *
- * Finally if no pixel format has been found, returns AV_PIX_FMT_NONE.
- */
-enum AVPixelFormat av_get_pix_fmt(const char *name);
-
-/**
- * Return the short name for a pixel format, NULL in case pix_fmt is
- * unknown.
- *
- * @see av_get_pix_fmt(), av_get_pix_fmt_string()
- */
-const char *av_get_pix_fmt_name(enum AVPixelFormat pix_fmt);
-
-/**
- * Print in buf the string corresponding to the pixel format with
- * number pix_fmt, or a header if pix_fmt is negative.
- *
- * @param buf the buffer where to write the string
- * @param buf_size the size of buf
- * @param pix_fmt the number of the pixel format to print the
- * corresponding info string, or a negative value to print the
- * corresponding header.
- */
-char *av_get_pix_fmt_string(char *buf, int buf_size,
- enum AVPixelFormat pix_fmt);
+#define AV_PIX_FMT_FLAG_FLOAT (1 << 9)
/**
* Return the number of bits per pixel used by the pixel format
@@ -286,14 +229,9 @@ enum AVPixelFormat av_pix_fmt_desc_get_id(const AVPixFmtDescriptor *desc);
* Utility function to access log2_chroma_w log2_chroma_h from
* the pixel format AVPixFmtDescriptor.
*
- * See av_get_chroma_sub_sample() for a function that asserts a
- * valid pixel format instead of returning an error code.
- * Its recommended that you use avcodec_get_chroma_sub_sample unless
- * you do check the return code!
- *
* @param[in] pix_fmt the pixel format
- * @param[out] h_shift store log2_chroma_w
- * @param[out] v_shift store log2_chroma_h
+ * @param[out] h_shift store log2_chroma_w (horizontal/width shift)
+ * @param[out] v_shift store log2_chroma_h (vertical/height shift)
*
* @return 0 on success, AVERROR(ENOSYS) on invalid or unknown pixel format
*/
@@ -306,6 +244,139 @@ int av_pix_fmt_get_chroma_sub_sample(enum AVPixelFormat pix_fmt,
*/
int av_pix_fmt_count_planes(enum AVPixelFormat pix_fmt);
+/**
+ * @return the name for provided color range or NULL if unknown.
+ */
+const char *av_color_range_name(enum AVColorRange range);
+
+/**
+ * @return the AVColorRange value for name or an AVError if not found.
+ */
+int av_color_range_from_name(const char *name);
+
+/**
+ * @return the name for provided color primaries or NULL if unknown.
+ */
+const char *av_color_primaries_name(enum AVColorPrimaries primaries);
+
+/**
+ * @return the AVColorPrimaries value for name or an AVError if not found.
+ */
+int av_color_primaries_from_name(const char *name);
+
+/**
+ * @return the name for provided color transfer or NULL if unknown.
+ */
+const char *av_color_transfer_name(enum AVColorTransferCharacteristic transfer);
+
+/**
+ * @return the AVColorTransferCharacteristic value for name or an AVError if not found.
+ */
+int av_color_transfer_from_name(const char *name);
+
+/**
+ * @return the name for provided color space or NULL if unknown.
+ */
+const char *av_color_space_name(enum AVColorSpace space);
+
+/**
+ * @return the AVColorSpace value for name or an AVError if not found.
+ */
+int av_color_space_from_name(const char *name);
+
+/**
+ * @return the name for provided chroma location or NULL if unknown.
+ */
+const char *av_chroma_location_name(enum AVChromaLocation location);
+
+/**
+ * @return the AVChromaLocation value for name or an AVError if not found.
+ */
+int av_chroma_location_from_name(const char *name);
+
+/**
+ * Return the pixel format corresponding to name.
+ *
+ * If there is no pixel format with name name, then looks for a
+ * pixel format with the name corresponding to the native endian
+ * format of name.
+ * For example in a little-endian system, first looks for "gray16",
+ * then for "gray16le".
+ *
+ * Finally if no pixel format has been found, returns AV_PIX_FMT_NONE.
+ */
+enum AVPixelFormat av_get_pix_fmt(const char *name);
+
+/**
+ * Return the short name for a pixel format, NULL in case pix_fmt is
+ * unknown.
+ *
+ * @see av_get_pix_fmt(), av_get_pix_fmt_string()
+ */
+const char *av_get_pix_fmt_name(enum AVPixelFormat pix_fmt);
+
+/**
+ * Print in buf the string corresponding to the pixel format with
+ * number pix_fmt, or a header if pix_fmt is negative.
+ *
+ * @param buf the buffer where to write the string
+ * @param buf_size the size of buf
+ * @param pix_fmt the number of the pixel format to print the
+ * corresponding info string, or a negative value to print the
+ * corresponding header.
+ */
+char *av_get_pix_fmt_string(char *buf, int buf_size,
+ enum AVPixelFormat pix_fmt);
+
+/**
+ * Read a line from an image, and write the values of the
+ * pixel format component c to dst.
+ *
+ * @param data the array containing the pointers to the planes of the image
+ * @param linesize the array containing the linesizes of the image
+ * @param desc the pixel format descriptor for the image
+ * @param x the horizontal coordinate of the first pixel to read
+ * @param y the vertical coordinate of the first pixel to read
+ * @param w the width of the line to read, that is the number of
+ * values to write to dst
+ * @param read_pal_component if not zero and the format is a paletted
+ * format writes the values corresponding to the palette
+ * component c in data[1] to dst, rather than the palette indexes in
+ * data[0]. The behavior is undefined if the format is not paletted.
+ * @param dst_element_size size of elements in dst array (2 or 4 byte)
+ */
+void av_read_image_line2(void *dst, const uint8_t *data[4],
+ const int linesize[4], const AVPixFmtDescriptor *desc,
+ int x, int y, int c, int w, int read_pal_component,
+ int dst_element_size);
+
+void av_read_image_line(uint16_t *dst, const uint8_t *data[4],
+ const int linesize[4], const AVPixFmtDescriptor *desc,
+ int x, int y, int c, int w, int read_pal_component);
+
+/**
+ * Write the values from src to the pixel format component c of an
+ * image line.
+ *
+ * @param src array containing the values to write
+ * @param data the array containing the pointers to the planes of the
+ * image to write into. It is supposed to be zeroed.
+ * @param linesize the array containing the linesizes of the image
+ * @param desc the pixel format descriptor for the image
+ * @param x the horizontal coordinate of the first pixel to write
+ * @param y the vertical coordinate of the first pixel to write
+ * @param w the width of the line to write, that is the number of
+ * values to write to the image line
+ * @param src_element_size size of elements in src array (2 or 4 byte)
+ */
+void av_write_image_line2(const void *src, uint8_t *data[4],
+ const int linesize[4], const AVPixFmtDescriptor *desc,
+ int x, int y, int c, int w, int src_element_size);
+
+void av_write_image_line(const uint16_t *src, uint8_t *data[4],
+ const int linesize[4], const AVPixFmtDescriptor *desc,
+ int x, int y, int c, int w);
+
/**
* Utility function to swap the endianness of a pixel format.
*
@@ -366,29 +437,4 @@ int av_get_pix_fmt_loss(enum AVPixelFormat dst_pix_fmt,
enum AVPixelFormat av_find_best_pix_fmt_of_2(enum AVPixelFormat dst_pix_fmt1, enum AVPixelFormat dst_pix_fmt2,
enum AVPixelFormat src_pix_fmt, int has_alpha, int *loss_ptr);
-/**
- * @return the name for provided color range or NULL if unknown.
- */
-const char *av_color_range_name(enum AVColorRange range);
-
-/**
- * @return the name for provided color primaries or NULL if unknown.
- */
-const char *av_color_primaries_name(enum AVColorPrimaries primaries);
-
-/**
- * @return the name for provided color transfer or NULL if unknown.
- */
-const char *av_color_transfer_name(enum AVColorTransferCharacteristic transfer);
-
-/**
- * @return the name for provided color space or NULL if unknown.
- */
-const char *av_color_space_name(enum AVColorSpace space);
-
-/**
- * @return the name for provided chroma location or NULL if unknown.
- */
-const char *av_chroma_location_name(enum AVChromaLocation location);
-
#endif /* AVUTIL_PIXDESC_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/pixfmt.h b/neo/libs/ffmpeg-win64/include/libavutil/pixfmt.h
index 32044f07..8b54c941 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/pixfmt.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/pixfmt.h
@@ -24,7 +24,6 @@
/**
* @file
* pixel format definitions
- *
*/
#include "libavutil/avconfig.h"
@@ -43,6 +42,10 @@
* This is stored as BGRA on little-endian CPU architectures and ARGB on
* big-endian CPUs.
*
+ * @note
+ * If the resolution is not a multiple of the chroma subsampling factor
+ * then the chroma plane resolution must be rounded up.
+ *
* @par
* When the pixel format is palettized RGB32 (AV_PIX_FMT_PAL8), the palettized
* image data is stored in AVFrame.data[0]. The palette is transported in
@@ -54,7 +57,7 @@
* to run on the IBM VGA graphics adapter use 6-bit palette components.
*
* @par
- * For all the 8bit per pixel formats, an RGB32 palette is in data[1] like
+ * For all the 8 bits per pixel formats, an RGB32 palette is in data[1] like
* for pal8. This palette is filled in automatically by the function
* allocating the picture.
*/
@@ -71,15 +74,10 @@ enum AVPixelFormat {
AV_PIX_FMT_GRAY8, ///< Y , 8bpp
AV_PIX_FMT_MONOWHITE, ///< Y , 1bpp, 0 is white, 1 is black, in each byte pixels are ordered from the msb to the lsb
AV_PIX_FMT_MONOBLACK, ///< Y , 1bpp, 0 is black, 1 is white, in each byte pixels are ordered from the msb to the lsb
- AV_PIX_FMT_PAL8, ///< 8 bit with AV_PIX_FMT_RGB32 palette
+ AV_PIX_FMT_PAL8, ///< 8 bits with AV_PIX_FMT_RGB32 palette
AV_PIX_FMT_YUVJ420P, ///< planar YUV 4:2:0, 12bpp, full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV420P and setting color_range
AV_PIX_FMT_YUVJ422P, ///< planar YUV 4:2:2, 16bpp, full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV422P and setting color_range
AV_PIX_FMT_YUVJ444P, ///< planar YUV 4:4:4, 24bpp, full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV444P and setting color_range
-#if FF_API_XVMC
- AV_PIX_FMT_XVMC_MPEG2_MC,///< XVideo Motion Acceleration via common packet passing
- AV_PIX_FMT_XVMC_MPEG2_IDCT,
-#define AV_PIX_FMT_XVMC AV_PIX_FMT_XVMC_MPEG2_IDCT
-#endif /* FF_API_XVMC */
AV_PIX_FMT_UYVY422, ///< packed YUV 4:2:2, 16bpp, Cb Y0 Cr Y1
AV_PIX_FMT_UYYVYY411, ///< packed YUV 4:1:1, 12bpp, Cb Y0 Y1 Cr Y2 Y3
AV_PIX_FMT_BGR8, ///< packed RGB 3:3:2, 8bpp, (msb)2B 3G 3R(lsb)
@@ -101,13 +99,6 @@ enum AVPixelFormat {
AV_PIX_FMT_YUV440P, ///< planar YUV 4:4:0 (1 Cr & Cb sample per 1x2 Y samples)
AV_PIX_FMT_YUVJ440P, ///< planar YUV 4:4:0 full scale (JPEG), deprecated in favor of AV_PIX_FMT_YUV440P and setting color_range
AV_PIX_FMT_YUVA420P, ///< planar YUV 4:2:0, 20bpp, (1 Cr & Cb sample per 2x2 Y & A samples)
-#if FF_API_VDPAU
- AV_PIX_FMT_VDPAU_H264,///< H.264 HW decoding with VDPAU, data[0] contains a vdpau_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
- AV_PIX_FMT_VDPAU_MPEG1,///< MPEG-1 HW decoding with VDPAU, data[0] contains a vdpau_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
- AV_PIX_FMT_VDPAU_MPEG2,///< MPEG-2 HW decoding with VDPAU, data[0] contains a vdpau_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
- AV_PIX_FMT_VDPAU_WMV3,///< WMV3 HW decoding with VDPAU, data[0] contains a vdpau_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
- AV_PIX_FMT_VDPAU_VC1, ///< VC-1 HW decoding with VDPAU, data[0] contains a vdpau_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
-#endif
AV_PIX_FMT_RGB48BE, ///< packed RGB 16:16:16, 48bpp, 16R, 16G, 16B, the 2-byte value for each R/G/B component is stored as big-endian
AV_PIX_FMT_RGB48LE, ///< packed RGB 16:16:16, 48bpp, 16R, 16G, 16B, the 2-byte value for each R/G/B component is stored as little-endian
@@ -126,7 +117,7 @@ enum AVPixelFormat {
/**@{*/
AV_PIX_FMT_VAAPI_MOCO, ///< HW acceleration through VA API at motion compensation entry-point, Picture.data[3] contains a vaapi_render_state struct which contains macroblocks as well as various fields extracted from headers
AV_PIX_FMT_VAAPI_IDCT, ///< HW acceleration through VA API at IDCT entry-point, Picture.data[3] contains a vaapi_render_state struct which contains fields extracted from headers
- AV_PIX_FMT_VAAPI_VLD, ///< HW decoding through VA API, Picture.data[3] contains a vaapi_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
+ AV_PIX_FMT_VAAPI_VLD, ///< HW decoding through VA API, Picture.data[3] contains a VASurfaceID
/**@}*/
AV_PIX_FMT_VAAPI = AV_PIX_FMT_VAAPI_VLD,
#else
@@ -143,16 +134,13 @@ enum AVPixelFormat {
AV_PIX_FMT_YUV422P16BE, ///< planar YUV 4:2:2, 32bpp, (1 Cr & Cb sample per 2x1 Y samples), big-endian
AV_PIX_FMT_YUV444P16LE, ///< planar YUV 4:4:4, 48bpp, (1 Cr & Cb sample per 1x1 Y samples), little-endian
AV_PIX_FMT_YUV444P16BE, ///< planar YUV 4:4:4, 48bpp, (1 Cr & Cb sample per 1x1 Y samples), big-endian
-#if FF_API_VDPAU
- AV_PIX_FMT_VDPAU_MPEG4, ///< MPEG4 HW decoding with VDPAU, data[0] contains a vdpau_render_state struct which contains the bitstream of the slices as well as various fields extracted from headers
-#endif
AV_PIX_FMT_DXVA2_VLD, ///< HW decoding through DXVA2, Picture.data[3] contains a LPDIRECT3DSURFACE9 pointer
AV_PIX_FMT_RGB444LE, ///< packed RGB 4:4:4, 16bpp, (msb)4X 4R 4G 4B(lsb), little-endian, X=unused/undefined
AV_PIX_FMT_RGB444BE, ///< packed RGB 4:4:4, 16bpp, (msb)4X 4R 4G 4B(lsb), big-endian, X=unused/undefined
AV_PIX_FMT_BGR444LE, ///< packed BGR 4:4:4, 16bpp, (msb)4X 4B 4G 4R(lsb), little-endian, X=unused/undefined
AV_PIX_FMT_BGR444BE, ///< packed BGR 4:4:4, 16bpp, (msb)4X 4B 4G 4R(lsb), big-endian, X=unused/undefined
- AV_PIX_FMT_YA8, ///< 8bit gray, 8bit alpha
+ AV_PIX_FMT_YA8, ///< 8 bits gray, 8 bits alpha
AV_PIX_FMT_Y400A = AV_PIX_FMT_YA8, ///< alias for AV_PIX_FMT_YA8
AV_PIX_FMT_GRAY8A= AV_PIX_FMT_YA8, ///< alias for AV_PIX_FMT_YA8
@@ -177,8 +165,8 @@ enum AVPixelFormat {
AV_PIX_FMT_YUV444P10LE,///< planar YUV 4:4:4, 30bpp, (1 Cr & Cb sample per 1x1 Y samples), little-endian
AV_PIX_FMT_YUV422P9BE, ///< planar YUV 4:2:2, 18bpp, (1 Cr & Cb sample per 2x1 Y samples), big-endian
AV_PIX_FMT_YUV422P9LE, ///< planar YUV 4:2:2, 18bpp, (1 Cr & Cb sample per 2x1 Y samples), little-endian
- AV_PIX_FMT_VDA_VLD, ///< hardware decoding through VDA
AV_PIX_FMT_GBRP, ///< planar GBR 4:4:4 24bpp
+ AV_PIX_FMT_GBR24P = AV_PIX_FMT_GBRP, // alias for #AV_PIX_FMT_GBRP
AV_PIX_FMT_GBRP9BE, ///< planar GBR 4:4:4 27bpp, big-endian
AV_PIX_FMT_GBRP9LE, ///< planar GBR 4:4:4 27bpp, little-endian
AV_PIX_FMT_GBRP10BE, ///< planar GBR 4:4:4 30bpp, big-endian
@@ -221,10 +209,8 @@ enum AVPixelFormat {
AV_PIX_FMT_YVYU422, ///< packed YUV 4:2:2, 16bpp, Y0 Cr Y1 Cb
- AV_PIX_FMT_VDA, ///< HW acceleration through VDA, data[3] contains a CVPixelBufferRef
-
- AV_PIX_FMT_YA16BE, ///< 16bit gray, 16bit alpha (big-endian)
- AV_PIX_FMT_YA16LE, ///< 16bit gray, 16bit alpha (little-endian)
+ AV_PIX_FMT_YA16BE, ///< 16 bits gray, 16 bits alpha (big-endian)
+ AV_PIX_FMT_YA16LE, ///< 16 bits gray, 16 bits alpha (little-endian)
AV_PIX_FMT_GBRAP, ///< planar GBRA 4:4:4:4 32bpp
AV_PIX_FMT_GBRAP16BE, ///< planar GBRA 4:4:4:4 64bpp, big-endian
@@ -240,9 +226,15 @@ enum AVPixelFormat {
*/
AV_PIX_FMT_MMAL,
- AV_PIX_FMT_D3D11VA_VLD, ///< HW decoding through Direct3D11, Picture.data[3] contains a ID3D11VideoDecoderOutputView pointer
+ AV_PIX_FMT_D3D11VA_VLD, ///< HW decoding through Direct3D11 via old API, Picture.data[3] contains a ID3D11VideoDecoderOutputView pointer
- AV_PIX_FMT_0RGB=0x123+4,///< packed RGB 8:8:8, 32bpp, XRGBXRGB... X=unused/undefined
+ /**
+ * HW acceleration through CUDA. data[i] contain CUdeviceptr pointers
+ * exactly as for system memory frames.
+ */
+ AV_PIX_FMT_CUDA,
+
+ AV_PIX_FMT_0RGB, ///< packed RGB 8:8:8, 32bpp, XRGBXRGB... X=unused/undefined
AV_PIX_FMT_RGB0, ///< packed RGB 8:8:8, 32bpp, RGBXRGBX... X=unused/undefined
AV_PIX_FMT_0BGR, ///< packed BGR 8:8:8, 32bpp, XBGRXBGR... X=unused/undefined
AV_PIX_FMT_BGR0, ///< packed BGR 8:8:8, 32bpp, BGRXBGRX... X=unused/undefined
@@ -277,9 +269,9 @@ enum AVPixelFormat {
AV_PIX_FMT_BAYER_GBRG16BE, ///< bayer, GBGB..(odd line), RGRG..(even line), 16-bit samples, big-endian */
AV_PIX_FMT_BAYER_GRBG16LE, ///< bayer, GRGR..(odd line), BGBG..(even line), 16-bit samples, little-endian */
AV_PIX_FMT_BAYER_GRBG16BE, ///< bayer, GRGR..(odd line), BGBG..(even line), 16-bit samples, big-endian */
-#if !FF_API_XVMC
+
AV_PIX_FMT_XVMC,///< XVideo Motion Acceleration via common packet passing
-#endif /* !FF_API_XVMC */
+
AV_PIX_FMT_YUV440P10LE, ///< planar YUV 4:4:0,20bpp, (1 Cr & Cb sample per 1x2 Y samples), little-endian
AV_PIX_FMT_YUV440P10BE, ///< planar YUV 4:4:0,20bpp, (1 Cr & Cb sample per 1x2 Y samples), big-endian
AV_PIX_FMT_YUV440P12LE, ///< planar YUV 4:4:0,24bpp, (1 Cr & Cb sample per 1x2 Y samples), little-endian
@@ -289,11 +281,75 @@ enum AVPixelFormat {
AV_PIX_FMT_VIDEOTOOLBOX, ///< hardware decoding through Videotoolbox
- AV_PIX_FMT_NB, ///< number of pixel formats, DO NOT USE THIS if you want to link with shared libav* because the number of formats might differ between versions
-};
+ AV_PIX_FMT_P010LE, ///< like NV12, with 10bpp per component, data in the high bits, zeros in the low bits, little-endian
+ AV_PIX_FMT_P010BE, ///< like NV12, with 10bpp per component, data in the high bits, zeros in the low bits, big-endian
-#define AV_PIX_FMT_Y400A AV_PIX_FMT_GRAY8A
-#define AV_PIX_FMT_GBR24P AV_PIX_FMT_GBRP
+ AV_PIX_FMT_GBRAP12BE, ///< planar GBR 4:4:4:4 48bpp, big-endian
+ AV_PIX_FMT_GBRAP12LE, ///< planar GBR 4:4:4:4 48bpp, little-endian
+
+ AV_PIX_FMT_GBRAP10BE, ///< planar GBR 4:4:4:4 40bpp, big-endian
+ AV_PIX_FMT_GBRAP10LE, ///< planar GBR 4:4:4:4 40bpp, little-endian
+
+ AV_PIX_FMT_MEDIACODEC, ///< hardware decoding through MediaCodec
+
+ AV_PIX_FMT_GRAY12BE, ///< Y , 12bpp, big-endian
+ AV_PIX_FMT_GRAY12LE, ///< Y , 12bpp, little-endian
+ AV_PIX_FMT_GRAY10BE, ///< Y , 10bpp, big-endian
+ AV_PIX_FMT_GRAY10LE, ///< Y , 10bpp, little-endian
+
+ AV_PIX_FMT_P016LE, ///< like NV12, with 16bpp per component, little-endian
+ AV_PIX_FMT_P016BE, ///< like NV12, with 16bpp per component, big-endian
+
+ /**
+ * Hardware surfaces for Direct3D11.
+ *
+ * This is preferred over the legacy AV_PIX_FMT_D3D11VA_VLD. The new D3D11
+ * hwaccel API and filtering support AV_PIX_FMT_D3D11 only.
+ *
+ * data[0] contains a ID3D11Texture2D pointer, and data[1] contains the
+ * texture array index of the frame as intptr_t if the ID3D11Texture2D is
+ * an array texture (or always 0 if it's a normal texture).
+ */
+ AV_PIX_FMT_D3D11,
+
+ AV_PIX_FMT_GRAY9BE, ///< Y , 9bpp, big-endian
+ AV_PIX_FMT_GRAY9LE, ///< Y , 9bpp, little-endian
+
+ AV_PIX_FMT_GBRPF32BE, ///< IEEE-754 single precision planar GBR 4:4:4, 96bpp, big-endian
+ AV_PIX_FMT_GBRPF32LE, ///< IEEE-754 single precision planar GBR 4:4:4, 96bpp, little-endian
+ AV_PIX_FMT_GBRAPF32BE, ///< IEEE-754 single precision planar GBRA 4:4:4:4, 128bpp, big-endian
+ AV_PIX_FMT_GBRAPF32LE, ///< IEEE-754 single precision planar GBRA 4:4:4:4, 128bpp, little-endian
+
+ /**
+ * DRM-managed buffers exposed through PRIME buffer sharing.
+ *
+ * data[0] points to an AVDRMFrameDescriptor.
+ */
+ AV_PIX_FMT_DRM_PRIME,
+ /**
+ * Hardware surfaces for OpenCL.
+ *
+ * data[i] contain 2D image objects (typed in C as cl_mem, used
+ * in OpenCL as image2d_t) for each plane of the surface.
+ */
+ AV_PIX_FMT_OPENCL,
+
+ AV_PIX_FMT_GRAY14BE, ///< Y , 14bpp, big-endian
+ AV_PIX_FMT_GRAY14LE, ///< Y , 14bpp, little-endian
+
+ AV_PIX_FMT_GRAYF32BE, ///< IEEE-754 single precision Y, 32bpp, big-endian
+ AV_PIX_FMT_GRAYF32LE, ///< IEEE-754 single precision Y, 32bpp, little-endian
+
+ AV_PIX_FMT_YUVA422P12BE, ///< planar YUV 4:2:2,24bpp, (1 Cr & Cb sample per 2x1 Y samples), 12b alpha, big-endian
+ AV_PIX_FMT_YUVA422P12LE, ///< planar YUV 4:2:2,24bpp, (1 Cr & Cb sample per 2x1 Y samples), 12b alpha, little-endian
+ AV_PIX_FMT_YUVA444P12BE, ///< planar YUV 4:4:4,36bpp, (1 Cr & Cb sample per 1x1 Y samples), 12b alpha, big-endian
+ AV_PIX_FMT_YUVA444P12LE, ///< planar YUV 4:4:4,36bpp, (1 Cr & Cb sample per 1x1 Y samples), 12b alpha, little-endian
+
+ AV_PIX_FMT_NV24, ///< planar YUV 4:4:4, 24bpp, 1 plane for Y and 1 plane for the UV components, which are interleaved (first byte U and the following byte V)
+ AV_PIX_FMT_NV42, ///< as above, but U and V bytes are swapped
+
+ AV_PIX_FMT_NB ///< number of pixel formats, DO NOT USE THIS if you want to link with shared libav* because the number of formats might differ between versions
+};
#if AV_HAVE_BIGENDIAN
# define AV_PIX_FMT_NE(be, le) AV_PIX_FMT_##be
@@ -308,6 +364,10 @@ enum AVPixelFormat {
#define AV_PIX_FMT_0RGB32 AV_PIX_FMT_NE(0RGB, BGR0)
#define AV_PIX_FMT_0BGR32 AV_PIX_FMT_NE(0BGR, RGB0)
+#define AV_PIX_FMT_GRAY9 AV_PIX_FMT_NE(GRAY9BE, GRAY9LE)
+#define AV_PIX_FMT_GRAY10 AV_PIX_FMT_NE(GRAY10BE, GRAY10LE)
+#define AV_PIX_FMT_GRAY12 AV_PIX_FMT_NE(GRAY12BE, GRAY12LE)
+#define AV_PIX_FMT_GRAY14 AV_PIX_FMT_NE(GRAY14BE, GRAY14LE)
#define AV_PIX_FMT_GRAY16 AV_PIX_FMT_NE(GRAY16BE, GRAY16LE)
#define AV_PIX_FMT_YA16 AV_PIX_FMT_NE(YA16BE, YA16LE)
#define AV_PIX_FMT_RGB48 AV_PIX_FMT_NE(RGB48BE, RGB48LE)
@@ -344,6 +404,8 @@ enum AVPixelFormat {
#define AV_PIX_FMT_GBRP12 AV_PIX_FMT_NE(GBRP12BE, GBRP12LE)
#define AV_PIX_FMT_GBRP14 AV_PIX_FMT_NE(GBRP14BE, GBRP14LE)
#define AV_PIX_FMT_GBRP16 AV_PIX_FMT_NE(GBRP16BE, GBRP16LE)
+#define AV_PIX_FMT_GBRAP10 AV_PIX_FMT_NE(GBRAP10BE, GBRAP10LE)
+#define AV_PIX_FMT_GBRAP12 AV_PIX_FMT_NE(GBRAP12BE, GBRAP12LE)
#define AV_PIX_FMT_GBRAP16 AV_PIX_FMT_NE(GBRAP16BE, GBRAP16LE)
#define AV_PIX_FMT_BAYER_BGGR16 AV_PIX_FMT_NE(BAYER_BGGR16BE, BAYER_BGGR16LE)
@@ -351,6 +413,10 @@ enum AVPixelFormat {
#define AV_PIX_FMT_BAYER_GBRG16 AV_PIX_FMT_NE(BAYER_GBRG16BE, BAYER_GBRG16LE)
#define AV_PIX_FMT_BAYER_GRBG16 AV_PIX_FMT_NE(BAYER_GRBG16BE, BAYER_GRBG16LE)
+#define AV_PIX_FMT_GBRPF32 AV_PIX_FMT_NE(GBRPF32BE, GBRPF32LE)
+#define AV_PIX_FMT_GBRAPF32 AV_PIX_FMT_NE(GBRAPF32BE, GBRAPF32LE)
+
+#define AV_PIX_FMT_GRAYF32 AV_PIX_FMT_NE(GRAYF32BE, GRAYF32LE)
#define AV_PIX_FMT_YUVA420P9 AV_PIX_FMT_NE(YUVA420P9BE , YUVA420P9LE)
#define AV_PIX_FMT_YUVA422P9 AV_PIX_FMT_NE(YUVA422P9BE , YUVA422P9LE)
@@ -358,6 +424,8 @@ enum AVPixelFormat {
#define AV_PIX_FMT_YUVA420P10 AV_PIX_FMT_NE(YUVA420P10BE, YUVA420P10LE)
#define AV_PIX_FMT_YUVA422P10 AV_PIX_FMT_NE(YUVA422P10BE, YUVA422P10LE)
#define AV_PIX_FMT_YUVA444P10 AV_PIX_FMT_NE(YUVA444P10BE, YUVA444P10LE)
+#define AV_PIX_FMT_YUVA422P12 AV_PIX_FMT_NE(YUVA422P12BE, YUVA422P12LE)
+#define AV_PIX_FMT_YUVA444P12 AV_PIX_FMT_NE(YUVA444P12BE, YUVA444P12LE)
#define AV_PIX_FMT_YUVA420P16 AV_PIX_FMT_NE(YUVA420P16BE, YUVA420P16LE)
#define AV_PIX_FMT_YUVA422P16 AV_PIX_FMT_NE(YUVA422P16BE, YUVA422P16LE)
#define AV_PIX_FMT_YUVA444P16 AV_PIX_FMT_NE(YUVA444P16BE, YUVA444P16LE)
@@ -365,9 +433,12 @@ enum AVPixelFormat {
#define AV_PIX_FMT_XYZ12 AV_PIX_FMT_NE(XYZ12BE, XYZ12LE)
#define AV_PIX_FMT_NV20 AV_PIX_FMT_NE(NV20BE, NV20LE)
#define AV_PIX_FMT_AYUV64 AV_PIX_FMT_NE(AYUV64BE, AYUV64LE)
+#define AV_PIX_FMT_P010 AV_PIX_FMT_NE(P010BE, P010LE)
+#define AV_PIX_FMT_P016 AV_PIX_FMT_NE(P016BE, P016LE)
/**
* Chromaticity coordinates of the source primaries.
+ * These values match the ones defined by ISO/IEC 23001-8_2013 § 7.1.
*/
enum AVColorPrimaries {
AVCOL_PRI_RESERVED0 = 0,
@@ -381,12 +452,17 @@ enum AVColorPrimaries {
AVCOL_PRI_SMPTE240M = 7, ///< functionally identical to above
AVCOL_PRI_FILM = 8, ///< colour filters using Illuminant C
AVCOL_PRI_BT2020 = 9, ///< ITU-R BT2020
- AVCOL_PRI_SMPTEST428_1= 10, ///< SMPTE ST 428-1 (CIE 1931 XYZ)
- AVCOL_PRI_NB, ///< Not part of ABI
+ AVCOL_PRI_SMPTE428 = 10, ///< SMPTE ST 428-1 (CIE 1931 XYZ)
+ AVCOL_PRI_SMPTEST428_1 = AVCOL_PRI_SMPTE428,
+ AVCOL_PRI_SMPTE431 = 11, ///< SMPTE ST 431-2 (2011) / DCI P3
+ AVCOL_PRI_SMPTE432 = 12, ///< SMPTE ST 432-1 (2010) / P3 D65 / Display P3
+ AVCOL_PRI_JEDEC_P22 = 22, ///< JEDEC P22 phosphors
+ AVCOL_PRI_NB ///< Not part of ABI
};
/**
* Color Transfer Characteristic.
+ * These values match the ones defined by ISO/IEC 23001-8_2013 § 7.2.
*/
enum AVColorTransferCharacteristic {
AVCOL_TRC_RESERVED0 = 0,
@@ -403,15 +479,19 @@ enum AVColorTransferCharacteristic {
AVCOL_TRC_IEC61966_2_4 = 11, ///< IEC 61966-2-4
AVCOL_TRC_BT1361_ECG = 12, ///< ITU-R BT1361 Extended Colour Gamut
AVCOL_TRC_IEC61966_2_1 = 13, ///< IEC 61966-2-1 (sRGB or sYCC)
- AVCOL_TRC_BT2020_10 = 14, ///< ITU-R BT2020 for 10 bit system
- AVCOL_TRC_BT2020_12 = 15, ///< ITU-R BT2020 for 12 bit system
- AVCOL_TRC_SMPTEST2084 = 16, ///< SMPTE ST 2084 for 10, 12, 14 and 16 bit systems
- AVCOL_TRC_SMPTEST428_1 = 17, ///< SMPTE ST 428-1
- AVCOL_TRC_NB, ///< Not part of ABI
+ AVCOL_TRC_BT2020_10 = 14, ///< ITU-R BT2020 for 10-bit system
+ AVCOL_TRC_BT2020_12 = 15, ///< ITU-R BT2020 for 12-bit system
+ AVCOL_TRC_SMPTE2084 = 16, ///< SMPTE ST 2084 for 10-, 12-, 14- and 16-bit systems
+ AVCOL_TRC_SMPTEST2084 = AVCOL_TRC_SMPTE2084,
+ AVCOL_TRC_SMPTE428 = 17, ///< SMPTE ST 428-1
+ AVCOL_TRC_SMPTEST428_1 = AVCOL_TRC_SMPTE428,
+ AVCOL_TRC_ARIB_STD_B67 = 18, ///< ARIB STD-B67, known as "Hybrid log-gamma"
+ AVCOL_TRC_NB ///< Not part of ABI
};
/**
* YUV colorspace type.
+ * These values match the ones defined by ISO/IEC 23001-8_2013 § 7.3.
*/
enum AVColorSpace {
AVCOL_SPC_RGB = 0, ///< order of coefficients is actually GBR, also IEC 61966-2-1 (sRGB)
@@ -420,15 +500,18 @@ enum AVColorSpace {
AVCOL_SPC_RESERVED = 3,
AVCOL_SPC_FCC = 4, ///< FCC Title 47 Code of Federal Regulations 73.682 (a)(20)
AVCOL_SPC_BT470BG = 5, ///< also ITU-R BT601-6 625 / ITU-R BT1358 625 / ITU-R BT1700 625 PAL & SECAM / IEC 61966-2-4 xvYCC601
- AVCOL_SPC_SMPTE170M = 6, ///< also ITU-R BT601-6 525 / ITU-R BT1358 525 / ITU-R BT1700 NTSC / functionally identical to above
- AVCOL_SPC_SMPTE240M = 7,
- AVCOL_SPC_YCOCG = 8, ///< Used by Dirac / VC-2 and H.264 FRext, see ITU-T SG16
+ AVCOL_SPC_SMPTE170M = 6, ///< also ITU-R BT601-6 525 / ITU-R BT1358 525 / ITU-R BT1700 NTSC
+ AVCOL_SPC_SMPTE240M = 7, ///< functionally identical to above
+ AVCOL_SPC_YCGCO = 8, ///< Used by Dirac / VC-2 and H.264 FRext, see ITU-T SG16
+ AVCOL_SPC_YCOCG = AVCOL_SPC_YCGCO,
AVCOL_SPC_BT2020_NCL = 9, ///< ITU-R BT2020 non-constant luminance system
AVCOL_SPC_BT2020_CL = 10, ///< ITU-R BT2020 constant luminance system
- AVCOL_SPC_NB, ///< Not part of ABI
+ AVCOL_SPC_SMPTE2085 = 11, ///< SMPTE 2085, Y'D'zD'x
+ AVCOL_SPC_CHROMA_DERIVED_NCL = 12, ///< Chromaticity-derived non-constant luminance system
+ AVCOL_SPC_CHROMA_DERIVED_CL = 13, ///< Chromaticity-derived constant luminance system
+ AVCOL_SPC_ICTCP = 14, ///< ITU-R BT.2100-0, ICtCp
+ AVCOL_SPC_NB ///< Not part of ABI
};
-#define AVCOL_SPC_YCGCO AVCOL_SPC_YCOCG
-
/**
* MPEG vs JPEG YUV range.
@@ -437,7 +520,7 @@ enum AVColorRange {
AVCOL_RANGE_UNSPECIFIED = 0,
AVCOL_RANGE_MPEG = 1, ///< the normal 219*2^(n-8) "MPEG" YUV ranges
AVCOL_RANGE_JPEG = 2, ///< the normal 2^n-1 "JPEG" YUV ranges
- AVCOL_RANGE_NB, ///< Not part of ABI
+ AVCOL_RANGE_NB ///< Not part of ABI
};
/**
@@ -457,13 +540,13 @@ enum AVColorRange {
*/
enum AVChromaLocation {
AVCHROMA_LOC_UNSPECIFIED = 0,
- AVCHROMA_LOC_LEFT = 1, ///< mpeg2/4 4:2:0, h264 default for 4:2:0
- AVCHROMA_LOC_CENTER = 2, ///< mpeg1 4:2:0, jpeg 4:2:0, h263 4:2:0
+ AVCHROMA_LOC_LEFT = 1, ///< MPEG-2/4 4:2:0, H.264 default for 4:2:0
+ AVCHROMA_LOC_CENTER = 2, ///< MPEG-1 4:2:0, JPEG 4:2:0, H.263 4:2:0
AVCHROMA_LOC_TOPLEFT = 3, ///< ITU-R 601, SMPTE 274M 296M S314M(DV 4:1:1), mpeg2 4:2:2
AVCHROMA_LOC_TOP = 4,
AVCHROMA_LOC_BOTTOMLEFT = 5,
AVCHROMA_LOC_BOTTOM = 6,
- AVCHROMA_LOC_NB, ///< Not part of ABI
+ AVCHROMA_LOC_NB ///< Not part of ABI
};
#endif /* AVUTIL_PIXFMT_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/rational.h b/neo/libs/ffmpeg-win64/include/libavutil/rational.h
index 28974696..5c6b67b4 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/rational.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/rational.h
@@ -21,7 +21,8 @@
/**
* @file
- * rational numbers
+ * @ingroup lavu_math_rational
+ * Utilties for rational number calculation.
* @author Michael Niedermayer
*/
@@ -33,22 +34,39 @@
#include "attributes.h"
/**
- * @addtogroup lavu_math
+ * @defgroup lavu_math_rational AVRational
+ * @ingroup lavu_math
+ * Rational number calculation.
+ *
+ * While rational numbers can be expressed as floating-point numbers, the
+ * conversion process is a lossy one, so are floating-point operations. On the
+ * other hand, the nature of FFmpeg demands highly accurate calculation of
+ * timestamps. This set of rational number utilities serves as a generic
+ * interface for manipulating rational numbers as pairs of numerators and
+ * denominators.
+ *
+ * Many of the functions that operate on AVRational's have the suffix `_q`, in
+ * reference to the mathematical symbol "ℚ" (Q) which denotes the set of all
+ * rational numbers.
+ *
* @{
*/
/**
- * rational number numerator/denominator
+ * Rational number (pair of numerator and denominator).
*/
typedef struct AVRational{
- int num; ///< numerator
- int den; ///< denominator
+ int num; ///< Numerator
+ int den; ///< Denominator
} AVRational;
/**
- * Create a rational.
+ * Create an AVRational.
+ *
* Useful for compilers that do not support compound literals.
- * @note The return value is not reduced.
+ *
+ * @note The return value is not reduced.
+ * @see av_reduce()
*/
static inline AVRational av_make_q(int num, int den)
{
@@ -58,10 +76,15 @@ static inline AVRational av_make_q(int num, int den)
/**
* Compare two rationals.
- * @param a first rational
- * @param b second rational
- * @return 0 if a==b, 1 if a>b, -1 if a b`
+ * - -1 if `a < b`
+ * - `INT_MIN` if one of the values is of the form `0 / 0`
*/
static inline int av_cmp_q(AVRational a, AVRational b){
const int64_t tmp= a.num * (int64_t)b.den - b.num * (int64_t)a.den;
@@ -73,9 +96,10 @@ static inline int av_cmp_q(AVRational a, AVRational b){
}
/**
- * Convert rational to double.
- * @param a rational to convert
- * @return (double) a
+ * Convert an AVRational to a `double`.
+ * @param a AVRational to convert
+ * @return `a` in floating-point form
+ * @see av_d2q()
*/
static inline double av_q2d(AVRational a){
return a.num / (double) a.den;
@@ -83,44 +107,46 @@ static inline double av_q2d(AVRational a){
/**
* Reduce a fraction.
+ *
* This is useful for framerate calculations.
- * @param dst_num destination numerator
- * @param dst_den destination denominator
- * @param num source numerator
- * @param den source denominator
- * @param max the maximum allowed for dst_num & dst_den
- * @return 1 if exact, 0 otherwise
+ *
+ * @param[out] dst_num Destination numerator
+ * @param[out] dst_den Destination denominator
+ * @param[in] num Source numerator
+ * @param[in] den Source denominator
+ * @param[in] max Maximum allowed values for `dst_num` & `dst_den`
+ * @return 1 if the operation is exact, 0 otherwise
*/
int av_reduce(int *dst_num, int *dst_den, int64_t num, int64_t den, int64_t max);
/**
* Multiply two rationals.
- * @param b first rational
- * @param c second rational
+ * @param b First rational
+ * @param c Second rational
* @return b*c
*/
AVRational av_mul_q(AVRational b, AVRational c) av_const;
/**
* Divide one rational by another.
- * @param b first rational
- * @param c second rational
+ * @param b First rational
+ * @param c Second rational
* @return b/c
*/
AVRational av_div_q(AVRational b, AVRational c) av_const;
/**
* Add two rationals.
- * @param b first rational
- * @param c second rational
+ * @param b First rational
+ * @param c Second rational
* @return b+c
*/
AVRational av_add_q(AVRational b, AVRational c) av_const;
/**
* Subtract one rational from another.
- * @param b first rational
- * @param c second rational
+ * @param b First rational
+ * @param c Second rational
* @return b-c
*/
AVRational av_sub_q(AVRational b, AVRational c) av_const;
@@ -138,31 +164,46 @@ static av_always_inline AVRational av_inv_q(AVRational q)
/**
* Convert a double precision floating point number to a rational.
- * inf is expressed as {1,0} or {-1,0} depending on the sign.
*
- * @param d double to convert
- * @param max the maximum allowed numerator and denominator
- * @return (AVRational) d
+ * In case of infinity, the returned value is expressed as `{1, 0}` or
+ * `{-1, 0}` depending on the sign.
+ *
+ * @param d `double` to convert
+ * @param max Maximum allowed numerator and denominator
+ * @return `d` in AVRational form
+ * @see av_q2d()
*/
AVRational av_d2q(double d, int max) av_const;
/**
- * @return 1 if q1 is nearer to q than q2, -1 if q2 is nearer
- * than q1, 0 if they have the same distance.
+ * Find which of the two rationals is closer to another rational.
+ *
+ * @param q Rational to be compared against
+ * @param q1,q2 Rationals to be tested
+ * @return One of the following values:
+ * - 1 if `q1` is nearer to `q` than `q2`
+ * - -1 if `q2` is nearer to `q` than `q1`
+ * - 0 if they have the same distance
*/
int av_nearer_q(AVRational q, AVRational q1, AVRational q2);
/**
- * Find the nearest value in q_list to q.
- * @param q_list an array of rationals terminated by {0, 0}
- * @return the index of the nearest value found in the array
+ * Find the value in a list of rationals nearest a given reference rational.
+ *
+ * @param q Reference rational
+ * @param q_list Array of rationals terminated by `{0, 0}`
+ * @return Index of the nearest value found in the array
*/
int av_find_nearest_q_idx(AVRational q, const AVRational* q_list);
/**
- * Converts a AVRational to a IEEE 32bit float.
+ * Convert an AVRational to a IEEE 32-bit `float` expressed in fixed-point
+ * format.
*
- * The float is returned in a uint32_t and its value is platform indepenant.
+ * @param q Rational to be converted
+ * @return Equivalent floating-point value, expressed as an unsigned 32-bit
+ * integer.
+ * @note The returned value is platform-indepedant.
*/
uint32_t av_q2intfloat(AVRational q);
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/replaygain.h b/neo/libs/ffmpeg-win64/include/libavutil/replaygain.h
index 5c03e199..b49bf1a3 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/replaygain.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/replaygain.h
@@ -1,5 +1,4 @@
/*
- *
* This file is part of FFmpeg.
*
* FFmpeg is free software; you can redistribute it and/or
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/ripemd.h b/neo/libs/ffmpeg-win64/include/libavutil/ripemd.h
index 7b0c8bc8..0db6858f 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/ripemd.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/ripemd.h
@@ -19,6 +19,12 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_ripemd
+ * Public header for RIPEMD hash function implementation.
+ */
+
#ifndef AVUTIL_RIPEMD_H
#define AVUTIL_RIPEMD_H
@@ -29,7 +35,9 @@
/**
* @defgroup lavu_ripemd RIPEMD
- * @ingroup lavu_crypto
+ * @ingroup lavu_hash
+ * RIPEMD hash function implementation.
+ *
* @{
*/
@@ -58,7 +66,11 @@ int av_ripemd_init(struct AVRIPEMD* context, int bits);
* @param data input data to update hash with
* @param len input data length
*/
+#if FF_API_CRYPTO_SIZE_T
void av_ripemd_update(struct AVRIPEMD* context, const uint8_t* data, unsigned int len);
+#else
+void av_ripemd_update(struct AVRIPEMD* context, const uint8_t* data, size_t len);
+#endif
/**
* Finish hashing and output digest value.
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/samplefmt.h b/neo/libs/ffmpeg-win64/include/libavutil/samplefmt.h
index 6a8a031c..8cd43ae8 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/samplefmt.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/samplefmt.h
@@ -32,7 +32,6 @@
*
* Audio sample format enumeration and related convenience functions.
* @{
- *
*/
/**
@@ -69,6 +68,8 @@ enum AVSampleFormat {
AV_SAMPLE_FMT_S32P, ///< signed 32 bits, planar
AV_SAMPLE_FMT_FLTP, ///< float, planar
AV_SAMPLE_FMT_DBLP, ///< double, planar
+ AV_SAMPLE_FMT_S64, ///< signed 64 bits
+ AV_SAMPLE_FMT_S64P, ///< signed 64 bits, planar
AV_SAMPLE_FMT_NB ///< Number of sample formats. DO NOT USE if linking dynamically
};
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/sha.h b/neo/libs/ffmpeg-win64/include/libavutil/sha.h
index bf4377e5..c0180e57 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/sha.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/sha.h
@@ -18,9 +18,16 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_sha
+ * Public header for SHA-1 & SHA-256 hash function implementations.
+ */
+
#ifndef AVUTIL_SHA_H
#define AVUTIL_SHA_H
+#include
#include
#include "attributes.h"
@@ -28,7 +35,17 @@
/**
* @defgroup lavu_sha SHA
- * @ingroup lavu_crypto
+ * @ingroup lavu_hash
+ * SHA-1 and SHA-256 (Secure Hash Algorithm) hash function implementations.
+ *
+ * This module supports the following SHA hash functions:
+ *
+ * - SHA-1: 160 bits
+ * - SHA-224: 224 bits, as a variant of SHA-2
+ * - SHA-256: 256 bits, as a variant of SHA-2
+ *
+ * @see For SHA-384, SHA-512, and variants thereof, see @ref lavu_sha512.
+ *
* @{
*/
@@ -53,11 +70,15 @@ int av_sha_init(struct AVSHA* context, int bits);
/**
* Update hash value.
*
- * @param context hash function context
+ * @param ctx hash function context
* @param data input data to update hash with
* @param len input data length
*/
-void av_sha_update(struct AVSHA* context, const uint8_t* data, unsigned int len);
+#if FF_API_CRYPTO_SIZE_T
+void av_sha_update(struct AVSHA *ctx, const uint8_t *data, unsigned int len);
+#else
+void av_sha_update(struct AVSHA *ctx, const uint8_t *data, size_t len);
+#endif
/**
* Finish hashing and output digest value.
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/sha512.h b/neo/libs/ffmpeg-win64/include/libavutil/sha512.h
index 7b087014..bef714b4 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/sha512.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/sha512.h
@@ -19,17 +19,35 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu_sha512
+ * Public header for SHA-512 implementation.
+ */
+
#ifndef AVUTIL_SHA512_H
#define AVUTIL_SHA512_H
+#include
#include
#include "attributes.h"
#include "version.h"
/**
- * @defgroup lavu_sha512 SHA512
- * @ingroup lavu_crypto
+ * @defgroup lavu_sha512 SHA-512
+ * @ingroup lavu_hash
+ * SHA-512 (Secure Hash Algorithm) hash function implementations.
+ *
+ * This module supports the following SHA-2 hash functions:
+ *
+ * - SHA-512/224: 224 bits
+ * - SHA-512/256: 256 bits
+ * - SHA-384: 384 bits
+ * - SHA-512: 512 bits
+ *
+ * @see For SHA-1, SHA-256, and variants thereof, see @ref lavu_sha.
+ *
* @{
*/
@@ -58,7 +76,11 @@ int av_sha512_init(struct AVSHA512* context, int bits);
* @param data input data to update hash with
* @param len input data length
*/
+#if FF_API_CRYPTO_SIZE_T
void av_sha512_update(struct AVSHA512* context, const uint8_t* data, unsigned int len);
+#else
+void av_sha512_update(struct AVSHA512* context, const uint8_t* data, size_t len);
+#endif
/**
* Finish hashing and output digest value.
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/spherical.h b/neo/libs/ffmpeg-win64/include/libavutil/spherical.h
new file mode 100644
index 00000000..cef759cf
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/spherical.h
@@ -0,0 +1,232 @@
+/*
+ * Copyright (c) 2016 Vittorio Giovara
+ *
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+/**
+ * @file
+ * Spherical video
+ */
+
+#ifndef AVUTIL_SPHERICAL_H
+#define AVUTIL_SPHERICAL_H
+
+#include
+#include
+
+/**
+ * @addtogroup lavu_video
+ * @{
+ *
+ * @defgroup lavu_video_spherical Spherical video mapping
+ * @{
+ */
+
+/**
+ * @addtogroup lavu_video_spherical
+ * A spherical video file contains surfaces that need to be mapped onto a
+ * sphere. Depending on how the frame was converted, a different distortion
+ * transformation or surface recomposition function needs to be applied before
+ * the video should be mapped and displayed.
+ */
+
+/**
+ * Projection of the video surface(s) on a sphere.
+ */
+enum AVSphericalProjection {
+ /**
+ * Video represents a sphere mapped on a flat surface using
+ * equirectangular projection.
+ */
+ AV_SPHERICAL_EQUIRECTANGULAR,
+
+ /**
+ * Video frame is split into 6 faces of a cube, and arranged on a
+ * 3x2 layout. Faces are oriented upwards for the front, left, right,
+ * and back faces. The up face is oriented so the top of the face is
+ * forwards and the down face is oriented so the top of the face is
+ * to the back.
+ */
+ AV_SPHERICAL_CUBEMAP,
+
+ /**
+ * Video represents a portion of a sphere mapped on a flat surface
+ * using equirectangular projection. The @ref bounding fields indicate
+ * the position of the current video in a larger surface.
+ */
+ AV_SPHERICAL_EQUIRECTANGULAR_TILE,
+};
+
+/**
+ * This structure describes how to handle spherical videos, outlining
+ * information about projection, initial layout, and any other view modifier.
+ *
+ * @note The struct must be allocated with av_spherical_alloc() and
+ * its size is not a part of the public ABI.
+ */
+typedef struct AVSphericalMapping {
+ /**
+ * Projection type.
+ */
+ enum AVSphericalProjection projection;
+
+ /**
+ * @name Initial orientation
+ * @{
+ * There fields describe additional rotations applied to the sphere after
+ * the video frame is mapped onto it. The sphere is rotated around the
+ * viewer, who remains stationary. The order of transformation is always
+ * yaw, followed by pitch, and finally by roll.
+ *
+ * The coordinate system matches the one defined in OpenGL, where the
+ * forward vector (z) is coming out of screen, and it is equivalent to
+ * a rotation matrix of R = r_y(yaw) * r_x(pitch) * r_z(roll).
+ *
+ * A positive yaw rotates the portion of the sphere in front of the viewer
+ * toward their right. A positive pitch rotates the portion of the sphere
+ * in front of the viewer upwards. A positive roll tilts the portion of
+ * the sphere in front of the viewer to the viewer's right.
+ *
+ * These values are exported as 16.16 fixed point.
+ *
+ * See this equirectangular projection as example:
+ *
+ * @code{.unparsed}
+ * Yaw
+ * -180 0 180
+ * 90 +-------------+-------------+ 180
+ * | | | up
+ * P | | | y| forward
+ * i | ^ | | /z
+ * t 0 +-------------X-------------+ 0 Roll | /
+ * c | | | | /
+ * h | | | 0|/_____right
+ * | | | x
+ * -90 +-------------+-------------+ -180
+ *
+ * X - the default camera center
+ * ^ - the default up vector
+ * @endcode
+ */
+ int32_t yaw; ///< Rotation around the up vector [-180, 180].
+ int32_t pitch; ///< Rotation around the right vector [-90, 90].
+ int32_t roll; ///< Rotation around the forward vector [-180, 180].
+ /**
+ * @}
+ */
+
+ /**
+ * @name Bounding rectangle
+ * @anchor bounding
+ * @{
+ * These fields indicate the location of the current tile, and where
+ * it should be mapped relative to the original surface. They are
+ * exported as 0.32 fixed point, and can be converted to classic
+ * pixel values with av_spherical_bounds().
+ *
+ * @code{.unparsed}
+ * +----------------+----------+
+ * | |bound_top |
+ * | +--------+ |
+ * | bound_left |tile | |
+ * +<---------->| |<--->+bound_right
+ * | +--------+ |
+ * | | |
+ * | bound_bottom| |
+ * +----------------+----------+
+ * @endcode
+ *
+ * If needed, the original video surface dimensions can be derived
+ * by adding the current stream or frame size to the related bounds,
+ * like in the following example:
+ *
+ * @code{c}
+ * original_width = tile->width + bound_left + bound_right;
+ * original_height = tile->height + bound_top + bound_bottom;
+ * @endcode
+ *
+ * @note These values are valid only for the tiled equirectangular
+ * projection type (@ref AV_SPHERICAL_EQUIRECTANGULAR_TILE),
+ * and should be ignored in all other cases.
+ */
+ uint32_t bound_left; ///< Distance from the left edge
+ uint32_t bound_top; ///< Distance from the top edge
+ uint32_t bound_right; ///< Distance from the right edge
+ uint32_t bound_bottom; ///< Distance from the bottom edge
+ /**
+ * @}
+ */
+
+ /**
+ * Number of pixels to pad from the edge of each cube face.
+ *
+ * @note This value is valid for only for the cubemap projection type
+ * (@ref AV_SPHERICAL_CUBEMAP), and should be ignored in all other
+ * cases.
+ */
+ uint32_t padding;
+} AVSphericalMapping;
+
+/**
+ * Allocate a AVSphericalVideo structure and initialize its fields to default
+ * values.
+ *
+ * @return the newly allocated struct or NULL on failure
+ */
+AVSphericalMapping *av_spherical_alloc(size_t *size);
+
+/**
+ * Convert the @ref bounding fields from an AVSphericalVideo
+ * from 0.32 fixed point to pixels.
+ *
+ * @param map The AVSphericalVideo map to read bound values from.
+ * @param width Width of the current frame or stream.
+ * @param height Height of the current frame or stream.
+ * @param left Pixels from the left edge.
+ * @param top Pixels from the top edge.
+ * @param right Pixels from the right edge.
+ * @param bottom Pixels from the bottom edge.
+ */
+void av_spherical_tile_bounds(const AVSphericalMapping *map,
+ size_t width, size_t height,
+ size_t *left, size_t *top,
+ size_t *right, size_t *bottom);
+
+/**
+ * Provide a human-readable name of a given AVSphericalProjection.
+ *
+ * @param projection The input AVSphericalProjection.
+ *
+ * @return The name of the AVSphericalProjection, or "unknown".
+ */
+const char *av_spherical_projection_name(enum AVSphericalProjection projection);
+
+/**
+ * Get the AVSphericalProjection form a human-readable name.
+ *
+ * @param name The input string.
+ *
+ * @return The AVSphericalProjection value, or -1 if not found.
+ */
+int av_spherical_from_name(const char *name);
+/**
+ * @}
+ * @}
+ */
+
+#endif /* AVUTIL_SPHERICAL_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/stereo3d.h b/neo/libs/ffmpeg-win64/include/libavutil/stereo3d.h
index 1135dc9d..d421aac2 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/stereo3d.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/stereo3d.h
@@ -18,6 +18,11 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * Stereoscopic video
+ */
+
#ifndef AVUTIL_STEREO3D_H
#define AVUTIL_STEREO3D_H
@@ -25,6 +30,21 @@
#include "frame.h"
+/**
+ * @addtogroup lavu_video
+ * @{
+ *
+ * @defgroup lavu_video_stereo3d Stereo3D types and functions
+ * @{
+ */
+
+/**
+ * @addtogroup lavu_video_stereo3d
+ * A stereoscopic video file consists in multiple views embedded in a single
+ * frame, usually describing two views of a scene. This file describes all
+ * possible codec-independent view arrangements.
+ * */
+
/**
* List of possible 3D Types
*/
@@ -37,41 +57,49 @@ enum AVStereo3DType {
/**
* Views are next to each other.
*
+ * @code{.unparsed}
* LLLLRRRR
* LLLLRRRR
* LLLLRRRR
* ...
+ * @endcode
*/
AV_STEREO3D_SIDEBYSIDE,
/**
* Views are on top of each other.
*
+ * @code{.unparsed}
* LLLLLLLL
* LLLLLLLL
* RRRRRRRR
* RRRRRRRR
+ * @endcode
*/
AV_STEREO3D_TOPBOTTOM,
/**
* Views are alternated temporally.
*
+ * @code{.unparsed}
* frame0 frame1 frame2 ...
* LLLLLLLL RRRRRRRR LLLLLLLL
* LLLLLLLL RRRRRRRR LLLLLLLL
* LLLLLLLL RRRRRRRR LLLLLLLL
* ... ... ...
+ * @endcode
*/
AV_STEREO3D_FRAMESEQUENCE,
/**
* Views are packed in a checkerboard-like structure per pixel.
*
+ * @code{.unparsed}
* LRLRLRLR
* RLRLRLRL
* LRLRLRLR
* ...
+ * @endcode
*/
AV_STEREO3D_CHECKERBOARD,
@@ -79,34 +107,59 @@ enum AVStereo3DType {
* Views are next to each other, but when upscaling
* apply a checkerboard pattern.
*
+ * @code{.unparsed}
* LLLLRRRR L L L L R R R R
* LLLLRRRR => L L L L R R R R
* LLLLRRRR L L L L R R R R
* LLLLRRRR L L L L R R R R
+ * @endcode
*/
AV_STEREO3D_SIDEBYSIDE_QUINCUNX,
/**
* Views are packed per line, as if interlaced.
*
+ * @code{.unparsed}
* LLLLLLLL
* RRRRRRRR
* LLLLLLLL
* ...
+ * @endcode
*/
AV_STEREO3D_LINES,
/**
* Views are packed per column.
*
+ * @code{.unparsed}
* LRLRLRLR
* LRLRLRLR
* LRLRLRLR
* ...
+ * @endcode
*/
AV_STEREO3D_COLUMNS,
};
+/**
+ * List of possible view types.
+ */
+enum AVStereo3DView {
+ /**
+ * Frame contains two packed views.
+ */
+ AV_STEREO3D_VIEW_PACKED,
+
+ /**
+ * Frame contains only the left view.
+ */
+ AV_STEREO3D_VIEW_LEFT,
+
+ /**
+ * Frame contains only the right view.
+ */
+ AV_STEREO3D_VIEW_RIGHT,
+};
/**
* Inverted views, Right/Bottom represents the left view.
@@ -130,6 +183,11 @@ typedef struct AVStereo3D {
* Additional information about the frame packing.
*/
int flags;
+
+ /**
+ * Determines which views are packed.
+ */
+ enum AVStereo3DView view;
} AVStereo3D;
/**
@@ -149,4 +207,27 @@ AVStereo3D *av_stereo3d_alloc(void);
*/
AVStereo3D *av_stereo3d_create_side_data(AVFrame *frame);
+/**
+ * Provide a human-readable name of a given stereo3d type.
+ *
+ * @param type The input stereo3d type value.
+ *
+ * @return The name of the stereo3d value, or "unknown".
+ */
+const char *av_stereo3d_type_name(unsigned int type);
+
+/**
+ * Get the AVStereo3DType form a human-readable name.
+ *
+ * @param name The input string.
+ *
+ * @return The AVStereo3DType value, or -1 if not found.
+ */
+int av_stereo3d_from_name(const char *name);
+
+/**
+ * @}
+ * @}
+ */
+
#endif /* AVUTIL_STEREO3D_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/threadmessage.h b/neo/libs/ffmpeg-win64/include/libavutil/threadmessage.h
index a8481d8e..42ce655f 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/threadmessage.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/threadmessage.h
@@ -69,10 +69,10 @@ int av_thread_message_queue_recv(AVThreadMessageQueue *mq,
/**
* Set the sending error code.
*
- * If the error code is set to non-zero, av_thread_message_queue_recv() will
- * return it immediately when there are no longer available messages.
- * Conventional values, such as AVERROR_EOF or AVERROR(EAGAIN), can be used
- * to cause the receiving thread to stop or suspend its operation.
+ * If the error code is set to non-zero, av_thread_message_queue_send() will
+ * return it immediately. Conventional values, such as AVERROR_EOF or
+ * AVERROR(EAGAIN), can be used to cause the sending thread to stop or
+ * suspend its operation.
*/
void av_thread_message_queue_set_err_send(AVThreadMessageQueue *mq,
int err);
@@ -80,12 +80,36 @@ void av_thread_message_queue_set_err_send(AVThreadMessageQueue *mq,
/**
* Set the receiving error code.
*
- * If the error code is set to non-zero, av_thread_message_queue_send() will
- * return it immediately. Conventional values, such as AVERROR_EOF or
- * AVERROR(EAGAIN), can be used to cause the sending thread to stop or
- * suspend its operation.
+ * If the error code is set to non-zero, av_thread_message_queue_recv() will
+ * return it immediately when there are no longer available messages.
+ * Conventional values, such as AVERROR_EOF or AVERROR(EAGAIN), can be used
+ * to cause the receiving thread to stop or suspend its operation.
*/
void av_thread_message_queue_set_err_recv(AVThreadMessageQueue *mq,
int err);
+/**
+ * Set the optional free message callback function which will be called if an
+ * operation is removing messages from the queue.
+ */
+void av_thread_message_queue_set_free_func(AVThreadMessageQueue *mq,
+ void (*free_func)(void *msg));
+
+/**
+ * Return the current number of messages in the queue.
+ *
+ * @return the current number of messages or AVERROR(ENOSYS) if lavu was built
+ * without thread support
+ */
+int av_thread_message_queue_nb_elems(AVThreadMessageQueue *mq);
+
+/**
+ * Flush the message queue
+ *
+ * This function is mostly equivalent to reading and free-ing every message
+ * except that it will be done in a single operation (no lock/unlock between
+ * reads).
+ */
+void av_thread_message_flush(AVThreadMessageQueue *mq);
+
#endif /* AVUTIL_THREADMESSAGE_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/timecode.h b/neo/libs/ffmpeg-win64/include/libavutil/timecode.h
index 56e3975f..37c1361b 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/timecode.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/timecode.h
@@ -30,7 +30,7 @@
#include
#include "rational.h"
-#define AV_TIMECODE_STR_SIZE 16
+#define AV_TIMECODE_STR_SIZE 23
enum AVTimecodeFlag {
AV_TIMECODE_FLAG_DROPFRAME = 1<<0, ///< timecode is drop frame
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/timestamp.h b/neo/libs/ffmpeg-win64/include/libavutil/timestamp.h
index f010a7ee..e082f01b 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/timestamp.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/timestamp.h
@@ -43,7 +43,7 @@
static inline char *av_ts_make_string(char *buf, int64_t ts)
{
if (ts == AV_NOPTS_VALUE) snprintf(buf, AV_TS_MAX_STRING_SIZE, "NOPTS");
- else snprintf(buf, AV_TS_MAX_STRING_SIZE, "%"PRId64, ts);
+ else snprintf(buf, AV_TS_MAX_STRING_SIZE, "%" PRId64, ts);
return buf;
}
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/tree.h b/neo/libs/ffmpeg-win64/include/libavutil/tree.h
index e1aefaa9..d5e0aebf 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/tree.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/tree.h
@@ -58,7 +58,7 @@ struct AVTreeNode *av_tree_node_alloc(void);
* then the corresponding entry in next is unchanged.
* @param cmp compare function used to compare elements in the tree,
* API identical to that of Standard C's qsort
- * It is guranteed that the first and only the first argument to cmp()
+ * It is guaranteed that the first and only the first argument to cmp()
* will be the key parameter to av_tree_find(), thus it could if the
* user wants, be a different type (like an opaque context).
* @return An element with cmp(key, elem) == 0 or NULL if no such element
@@ -120,8 +120,8 @@ void av_tree_destroy(struct AVTreeNode *t);
/**
* Apply enu(opaque, &elem) to all the elements in the tree in a given range.
*
- * @param cmp a comparison function that returns < 0 for a element below the
- * range, > 0 for a element above the range and == 0 for a
+ * @param cmp a comparison function that returns < 0 for an element below the
+ * range, > 0 for an element above the range and == 0 for an
* element inside the range
*
* @note The cmp function should use the same ordering used to construct the
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/tx.h b/neo/libs/ffmpeg-win64/include/libavutil/tx.h
new file mode 100644
index 00000000..b1f2d963
--- /dev/null
+++ b/neo/libs/ffmpeg-win64/include/libavutil/tx.h
@@ -0,0 +1,81 @@
+/*
+ * This file is part of FFmpeg.
+ *
+ * FFmpeg is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2.1 of the License, or (at your option) any later version.
+ *
+ * FFmpeg is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with FFmpeg; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#ifndef AVUTIL_TX_H
+#define AVUTIL_TX_H
+
+#include
+#include
+
+typedef struct AVTXContext AVTXContext;
+
+typedef struct AVComplexFloat {
+ float re, im;
+} AVComplexFloat;
+
+enum AVTXType {
+ /**
+ * Standard complex to complex FFT with sample data type AVComplexFloat.
+ * Scaling currently unsupported
+ */
+ AV_TX_FLOAT_FFT = 0,
+ /**
+ * Standard MDCT with sample data type of float and a scale type of
+ * float. Length is the frame size, not the window size (which is 2x frame)
+ */
+ AV_TX_FLOAT_MDCT = 1,
+};
+
+/**
+ * Function pointer to a function to perform the transform.
+ *
+ * @note Using a different context than the one allocated during av_tx_init()
+ * is not allowed.
+ *
+ * @param s the transform context
+ * @param out the output array
+ * @param in the input array
+ * @param stride the input or output stride (depending on transform direction)
+ * in bytes, currently implemented for all MDCT transforms
+ */
+typedef void (*av_tx_fn)(AVTXContext *s, void *out, void *in, ptrdiff_t stride);
+
+/**
+ * Initialize a transform context with the given configuration
+ * Currently power of two lengths from 4 to 131072 are supported, along with
+ * any length decomposable to a power of two and either 3, 5 or 15.
+ *
+ * @param ctx the context to allocate, will be NULL on error
+ * @param tx pointer to the transform function pointer to set
+ * @param type type the type of transform
+ * @param inv whether to do an inverse or a forward transform
+ * @param len the size of the transform in samples
+ * @param scale pointer to the value to scale the output if supported by type
+ * @param flags currently unused
+ *
+ * @return 0 on success, negative error code on failure
+ */
+int av_tx_init(AVTXContext **ctx, av_tx_fn *tx, enum AVTXType type,
+ int inv, int len, const void *scale, uint64_t flags);
+
+/**
+ * Frees a context and sets ctx to NULL, does nothing when ctx == NULL
+ */
+void av_tx_uninit(AVTXContext **ctx);
+
+#endif /* AVUTIL_TX_H */
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/version.h b/neo/libs/ffmpeg-win64/include/libavutil/version.h
index 909f9a62..24ca8ab7 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/version.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/version.h
@@ -18,6 +18,12 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
+/**
+ * @file
+ * @ingroup lavu
+ * Libavutil version macros
+ */
+
#ifndef AVUTIL_VERSION_H
#define AVUTIL_VERSION_H
@@ -29,6 +35,21 @@
* Useful to check and match library version in order to maintain
* backward compatibility.
*
+ * The FFmpeg libraries follow a versioning sheme very similar to
+ * Semantic Versioning (http://semver.org/)
+ * The difference is that the component called PATCH is called MICRO in FFmpeg
+ * and its value is reset to 100 instead of 0 to keep it above or equal to 100.
+ * Also we do not increase MICRO for every bugfix or change in git master.
+ *
+ * Prior to FFmpeg 3.2 point releases did not change any lib version number to
+ * avoid aliassing different git master checkouts.
+ * Starting with FFmpeg 3.2, the released library versions will occupy
+ * a separate MAJOR.MINOR that is not used on the master development branch.
+ * That is if we branch a release of master 55.10.123 we will bump to 55.11.100
+ * for the release and master will continue at 55.12.100 after it. Each new
+ * point release will then bump the MICRO improving the usefulness of the lib
+ * versions.
+ *
* @{
*/
@@ -37,13 +58,15 @@
#define AV_VERSION(a, b, c) AV_VERSION_DOT(a, b, c)
/**
- * @}
+ * Extract version components from the full ::AV_VERSION_INT int as returned
+ * by functions like ::avformat_version() and ::avcodec_version()
*/
+#define AV_VERSION_MAJOR(a) ((a) >> 16)
+#define AV_VERSION_MINOR(a) (((a) & 0x00FF00) >> 8)
+#define AV_VERSION_MICRO(a) ((a) & 0xFF)
/**
- * @file
- * @ingroup lavu
- * Libavutil version macros
+ * @}
*/
/**
@@ -55,8 +78,8 @@
* @{
*/
-#define LIBAVUTIL_VERSION_MAJOR 55
-#define LIBAVUTIL_VERSION_MINOR 5
+#define LIBAVUTIL_VERSION_MAJOR 56
+#define LIBAVUTIL_VERSION_MINOR 31
#define LIBAVUTIL_VERSION_MICRO 100
#define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
@@ -70,9 +93,7 @@
#define LIBAVUTIL_IDENT "Lavu" AV_STRINGIFY(LIBAVUTIL_VERSION)
/**
- * @}
- *
- * @defgroup depr_guards Deprecation guards
+ * @defgroup lavu_depr_guards Deprecation Guards
* FF_API_* defines may be placed below to indicate public API that will be
* dropped at a future version bump. The defines themselves are not part of
* the public API and may change, break or disappear at any time.
@@ -84,35 +105,35 @@
* @{
*/
-#ifndef FF_API_VDPAU
-#define FF_API_VDPAU (LIBAVUTIL_VERSION_MAJOR < 56)
-#endif
-#ifndef FF_API_XVMC
-#define FF_API_XVMC (LIBAVUTIL_VERSION_MAJOR < 56)
-#endif
-#ifndef FF_API_OPT_TYPE_METADATA
-#define FF_API_OPT_TYPE_METADATA (LIBAVUTIL_VERSION_MAJOR < 56)
-#endif
-#ifndef FF_API_DLOG
-#define FF_API_DLOG (LIBAVUTIL_VERSION_MAJOR < 56)
-#endif
#ifndef FF_API_VAAPI
-#define FF_API_VAAPI (LIBAVUTIL_VERSION_MAJOR < 56)
+#define FF_API_VAAPI (LIBAVUTIL_VERSION_MAJOR < 57)
#endif
#ifndef FF_API_FRAME_QP
-#define FF_API_FRAME_QP (LIBAVUTIL_VERSION_MAJOR < 56)
+#define FF_API_FRAME_QP (LIBAVUTIL_VERSION_MAJOR < 57)
#endif
#ifndef FF_API_PLUS1_MINUS1
-#define FF_API_PLUS1_MINUS1 (LIBAVUTIL_VERSION_MAJOR < 56)
+#define FF_API_PLUS1_MINUS1 (LIBAVUTIL_VERSION_MAJOR < 57)
#endif
#ifndef FF_API_ERROR_FRAME
-#define FF_API_ERROR_FRAME (LIBAVUTIL_VERSION_MAJOR < 56)
+#define FF_API_ERROR_FRAME (LIBAVUTIL_VERSION_MAJOR < 57)
+#endif
+#ifndef FF_API_PKT_PTS
+#define FF_API_PKT_PTS (LIBAVUTIL_VERSION_MAJOR < 57)
+#endif
+#ifndef FF_API_CRYPTO_SIZE_T
+#define FF_API_CRYPTO_SIZE_T (LIBAVUTIL_VERSION_MAJOR < 57)
+#endif
+#ifndef FF_API_FRAME_GET_SET
+#define FF_API_FRAME_GET_SET (LIBAVUTIL_VERSION_MAJOR < 57)
+#endif
+#ifndef FF_API_PSEUDOPAL
+#define FF_API_PSEUDOPAL (LIBAVUTIL_VERSION_MAJOR < 57)
#endif
/**
+ * @}
* @}
*/
#endif /* AVUTIL_VERSION_H */
-
diff --git a/neo/libs/ffmpeg-win64/include/libavutil/xtea.h b/neo/libs/ffmpeg-win64/include/libavutil/xtea.h
index bcf786cc..735427c1 100644
--- a/neo/libs/ffmpeg-win64/include/libavutil/xtea.h
+++ b/neo/libs/ffmpeg-win64/include/libavutil/xtea.h
@@ -45,12 +45,23 @@ AVXTEA *av_xtea_alloc(void);
* Initialize an AVXTEA context.
*
* @param ctx an AVXTEA context
- * @param key a key of 16 bytes used for encryption/decryption
+ * @param key a key of 16 bytes used for encryption/decryption,
+ * interpreted as big endian 32 bit numbers
*/
void av_xtea_init(struct AVXTEA *ctx, const uint8_t key[16]);
/**
- * Encrypt or decrypt a buffer using a previously initialized context.
+ * Initialize an AVXTEA context.
+ *
+ * @param ctx an AVXTEA context
+ * @param key a key of 16 bytes used for encryption/decryption,
+ * interpreted as little endian 32 bit numbers
+ */
+void av_xtea_le_init(struct AVXTEA *ctx, const uint8_t key[16]);
+
+/**
+ * Encrypt or decrypt a buffer using a previously initialized context,
+ * in big endian format.
*
* @param ctx an AVXTEA context
* @param dst destination array, can be equal to src
@@ -62,6 +73,20 @@ void av_xtea_init(struct AVXTEA *ctx, const uint8_t key[16]);
void av_xtea_crypt(struct AVXTEA *ctx, uint8_t *dst, const uint8_t *src,
int count, uint8_t *iv, int decrypt);
+/**
+ * Encrypt or decrypt a buffer using a previously initialized context,
+ * in little endian format.
+ *
+ * @param ctx an AVXTEA context
+ * @param dst destination array, can be equal to src
+ * @param src source array, can be equal to dst
+ * @param count number of 8 byte blocks
+ * @param iv initialization vector for CBC mode, if NULL then ECB will be used
+ * @param decrypt 0 for encryption, 1 for decryption
+ */
+void av_xtea_le_crypt(struct AVXTEA *ctx, uint8_t *dst, const uint8_t *src,
+ int count, uint8_t *iv, int decrypt);
+
/**
* @}
*/
diff --git a/neo/libs/ffmpeg-win64/include/libpostproc/postprocess.h b/neo/libs/ffmpeg-win64/include/libpostproc/postprocess.h
index 2b55ed67..348ee7cc 100644
--- a/neo/libs/ffmpeg-win64/include/libpostproc/postprocess.h
+++ b/neo/libs/ffmpeg-win64/include/libpostproc/postprocess.h
@@ -28,7 +28,9 @@
*/
/**
- * @defgroup lpp Libpostproc
+ * @defgroup lpp libpostproc
+ * Video postprocessing library.
+ *
* @{
*/
@@ -51,10 +53,6 @@ const char *postproc_license(void);
#define PP_QUALITY_MAX 6
-#if FF_API_QP_TYPE
-#define QP_STORE_T int8_t //deprecated
-#endif
-
#include
typedef void pp_context;
diff --git a/neo/libs/ffmpeg-win64/include/libpostproc/version.h b/neo/libs/ffmpeg-win64/include/libpostproc/version.h
index db557a5b..fa6d12c8 100644
--- a/neo/libs/ffmpeg-win64/include/libpostproc/version.h
+++ b/neo/libs/ffmpeg-win64/include/libpostproc/version.h
@@ -18,8 +18,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef POSTPROC_POSTPROCESS_VERSION_H
-#define POSTPROC_POSTPROCESS_VERSION_H
+#ifndef POSTPROC_VERSION_H
+#define POSTPROC_VERSION_H
/**
* @file
@@ -28,8 +28,8 @@
#include "libavutil/avutil.h"
-#define LIBPOSTPROC_VERSION_MAJOR 54
-#define LIBPOSTPROC_VERSION_MINOR 0
+#define LIBPOSTPROC_VERSION_MAJOR 55
+#define LIBPOSTPROC_VERSION_MINOR 5
#define LIBPOSTPROC_VERSION_MICRO 100
#define LIBPOSTPROC_VERSION_INT AV_VERSION_INT(LIBPOSTPROC_VERSION_MAJOR, \
@@ -42,8 +42,4 @@
#define LIBPOSTPROC_IDENT "postproc" AV_STRINGIFY(LIBPOSTPROC_VERSION)
-#ifndef FF_API_QP_TYPE
-#define FF_API_QP_TYPE (LIBPOSTPROC_VERSION_MAJOR < 55)
-#endif
-
-#endif /* POSTPROC_POSTPROCESS_VERSION_H */
+#endif /* POSTPROC_VERSION_H */
diff --git a/neo/libs/ffmpeg-win64/include/libswresample/swresample.h b/neo/libs/ffmpeg-win64/include/libswresample/swresample.h
index 10eaebc4..c7b84fbc 100644
--- a/neo/libs/ffmpeg-win64/include/libswresample/swresample.h
+++ b/neo/libs/ffmpeg-win64/include/libswresample/swresample.h
@@ -28,11 +28,10 @@
*/
/**
- * @defgroup lswr Libswresample
+ * @defgroup lswr libswresample
* @{
*
- * Libswresample (lswr) is a library that handles audio resampling, sample
- * format conversion and mixing.
+ * Audio resampling, sample format conversion and mixing library.
*
* Interaction with lswr is done through SwrContext, which is
* allocated with swr_alloc() or swr_alloc_set_opts(). It is opaque, so all parameters
@@ -121,15 +120,12 @@
*/
#include
+#include "libavutil/channel_layout.h"
#include "libavutil/frame.h"
#include "libavutil/samplefmt.h"
#include "libswresample/version.h"
-#if LIBSWRESAMPLE_VERSION_MAJOR < 1
-#define SWR_CH_MAX 32 ///< Maximum number of channels
-#endif
-
/**
* @name Option constants
* These constants are used for the @ref avoptions interface for lswr.
@@ -366,6 +362,36 @@ int swr_set_compensation(struct SwrContext *s, int sample_delta, int compensatio
*/
int swr_set_channel_mapping(struct SwrContext *s, const int *channel_map);
+/**
+ * Generate a channel mixing matrix.
+ *
+ * This function is the one used internally by libswresample for building the
+ * default mixing matrix. It is made public just as a utility function for
+ * building custom matrices.
+ *
+ * @param in_layout input channel layout
+ * @param out_layout output channel layout
+ * @param center_mix_level mix level for the center channel
+ * @param surround_mix_level mix level for the surround channel(s)
+ * @param lfe_mix_level mix level for the low-frequency effects channel
+ * @param rematrix_maxval if 1.0, coefficients will be normalized to prevent
+ * overflow. if INT_MAX, coefficients will not be
+ * normalized.
+ * @param[out] matrix mixing coefficients; matrix[i + stride * o] is
+ * the weight of input channel i in output channel o.
+ * @param stride distance between adjacent input channels in the
+ * matrix array
+ * @param matrix_encoding matrixed stereo downmix mode (e.g. dplii)
+ * @param log_ctx parent logging context, can be NULL
+ * @return 0 on success, negative AVERROR code on failure
+ */
+int swr_build_matrix(uint64_t in_layout, uint64_t out_layout,
+ double center_mix_level, double surround_mix_level,
+ double lfe_mix_level, double rematrix_maxval,
+ double rematrix_volume, double *matrix,
+ int stride, enum AVMatrixEncoding matrix_encoding,
+ void *log_ctx);
+
/**
* Set a customized remix matrix.
*
diff --git a/neo/libs/ffmpeg-win64/include/libswresample/version.h b/neo/libs/ffmpeg-win64/include/libswresample/version.h
index 12b32826..a0b361bc 100644
--- a/neo/libs/ffmpeg-win64/include/libswresample/version.h
+++ b/neo/libs/ffmpeg-win64/include/libswresample/version.h
@@ -18,8 +18,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef SWR_VERSION_H
-#define SWR_VERSION_H
+#ifndef SWRESAMPLE_VERSION_H
+#define SWRESAMPLE_VERSION_H
/**
* @file
@@ -28,8 +28,8 @@
#include "libavutil/avutil.h"
-#define LIBSWRESAMPLE_VERSION_MAJOR 2
-#define LIBSWRESAMPLE_VERSION_MINOR 0
+#define LIBSWRESAMPLE_VERSION_MAJOR 3
+#define LIBSWRESAMPLE_VERSION_MINOR 5
#define LIBSWRESAMPLE_VERSION_MICRO 100
#define LIBSWRESAMPLE_VERSION_INT AV_VERSION_INT(LIBSWRESAMPLE_VERSION_MAJOR, \
@@ -42,4 +42,4 @@
#define LIBSWRESAMPLE_IDENT "SwR" AV_STRINGIFY(LIBSWRESAMPLE_VERSION)
-#endif /* SWR_VERSION_H */
+#endif /* SWRESAMPLE_VERSION_H */
diff --git a/neo/libs/ffmpeg-win64/include/libswscale/swscale.h b/neo/libs/ffmpeg-win64/include/libswscale/swscale.h
index da9dd2ea..7713f51e 100644
--- a/neo/libs/ffmpeg-win64/include/libswscale/swscale.h
+++ b/neo/libs/ffmpeg-win64/include/libswscale/swscale.h
@@ -35,7 +35,9 @@
#include "version.h"
/**
- * @defgroup libsws Color conversion and scaling
+ * @defgroup libsws libswscale
+ * Color conversion and scaling library.
+ *
* @{
*
* Return the LIBSWSCALE_VERSION_INT constant.
@@ -73,7 +75,7 @@ const char *swscale_license(void);
#define SWS_PRINT_INFO 0x1000
//the following 3 flags are not completely implemented
-//internal chrominace subsampling info
+//internal chrominance subsampling info
#define SWS_FULL_CHR_H_INT 0x2000
//input subsampling info
#define SWS_FULL_CHR_H_INP 0x4000
@@ -91,6 +93,7 @@ const char *swscale_license(void);
#define SWS_CS_SMPTE170M 5
#define SWS_CS_SMPTE240M 7
#define SWS_CS_DEFAULT 5
+#define SWS_CS_BT2020 9
/**
* Return a pointer to yuv<->rgb coefficients for the given colorspace
@@ -247,18 +250,6 @@ SwsVector *sws_allocVec(int length);
*/
SwsVector *sws_getGaussianVec(double variance, double quality);
-/**
- * Allocate and return a vector with length coefficients, all
- * with the same value c.
- */
-SwsVector *sws_getConstVec(double c, int length);
-
-/**
- * Allocate and return a vector with just one coefficient, with
- * value 1.0.
- */
-SwsVector *sws_getIdentityVec(void);
-
/**
* Scale all the coefficients of a by the scalar value.
*/
@@ -268,22 +259,17 @@ void sws_scaleVec(SwsVector *a, double scalar);
* Scale all the coefficients of a so that their sum equals height.
*/
void sws_normalizeVec(SwsVector *a, double height);
-void sws_convVec(SwsVector *a, SwsVector *b);
-void sws_addVec(SwsVector *a, SwsVector *b);
-void sws_subVec(SwsVector *a, SwsVector *b);
-void sws_shiftVec(SwsVector *a, int shift);
-/**
- * Allocate and return a clone of the vector a, that is a vector
- * with the same coefficients as a.
- */
-SwsVector *sws_cloneVec(SwsVector *a);
-
-/**
- * Print with av_log() a textual representation of the vector a
- * if log_level <= av_log_level.
- */
-void sws_printVec2(SwsVector *a, AVClass *log_ctx, int log_level);
+#if FF_API_SWS_VECTOR
+attribute_deprecated SwsVector *sws_getConstVec(double c, int length);
+attribute_deprecated SwsVector *sws_getIdentityVec(void);
+attribute_deprecated void sws_convVec(SwsVector *a, SwsVector *b);
+attribute_deprecated void sws_addVec(SwsVector *a, SwsVector *b);
+attribute_deprecated void sws_subVec(SwsVector *a, SwsVector *b);
+attribute_deprecated void sws_shiftVec(SwsVector *a, int shift);
+attribute_deprecated SwsVector *sws_cloneVec(SwsVector *a);
+attribute_deprecated void sws_printVec2(SwsVector *a, AVClass *log_ctx, int log_level);
+#endif
void sws_freeVec(SwsVector *a);
diff --git a/neo/libs/ffmpeg-win64/include/libswscale/version.h b/neo/libs/ffmpeg-win64/include/libswscale/version.h
index 24908b89..acb289d7 100644
--- a/neo/libs/ffmpeg-win64/include/libswscale/version.h
+++ b/neo/libs/ffmpeg-win64/include/libswscale/version.h
@@ -26,8 +26,8 @@
#include "libavutil/version.h"
-#define LIBSWSCALE_VERSION_MAJOR 4
-#define LIBSWSCALE_VERSION_MINOR 0
+#define LIBSWSCALE_VERSION_MAJOR 5
+#define LIBSWSCALE_VERSION_MINOR 5
#define LIBSWSCALE_VERSION_MICRO 100
#define LIBSWSCALE_VERSION_INT AV_VERSION_INT(LIBSWSCALE_VERSION_MAJOR, \
@@ -46,4 +46,8 @@
* the public API and may change, break or disappear at any time.
*/
+#ifndef FF_API_SWS_VECTOR
+#define FF_API_SWS_VECTOR (LIBSWSCALE_VERSION_MAJOR < 6)
+#endif
+
#endif /* SWSCALE_VERSION_H */
diff --git a/neo/libs/ffmpeg-win64/lib/avcodec-57.def b/neo/libs/ffmpeg-win64/lib/avcodec-58.def
similarity index 68%
rename from neo/libs/ffmpeg-win64/lib/avcodec-57.def
rename to neo/libs/ffmpeg-win64/lib/avcodec-58.def
index d0bb554a..afc6144a 100644
--- a/neo/libs/ffmpeg-win64/lib/avcodec-57.def
+++ b/neo/libs/ffmpeg-win64/lib/avcodec-58.def
@@ -1,15 +1,28 @@
EXPORTS
- audio_resample
- audio_resample_close
- av_audio_convert
- av_audio_convert_alloc
- av_audio_convert_free
- av_audio_resample_init
+ av_ac3_parse_header
+ av_adts_header_parse
av_bitstream_filter_close
av_bitstream_filter_filter
av_bitstream_filter_init
av_bitstream_filter_next
- av_codec_ffversion DATA
+ av_bsf_alloc
+ av_bsf_flush
+ av_bsf_free
+ av_bsf_get_by_name
+ av_bsf_get_class
+ av_bsf_get_null_filter
+ av_bsf_init
+ av_bsf_iterate
+ av_bsf_list_alloc
+ av_bsf_list_append
+ av_bsf_list_append2
+ av_bsf_list_finalize
+ av_bsf_list_free
+ av_bsf_list_parse_str
+ av_bsf_next
+ av_bsf_receive_packet
+ av_bsf_send_packet
+ av_codec_ffversion
av_codec_get_chroma_intra_matrix
av_codec_get_codec_descriptor
av_codec_get_codec_properties
@@ -19,6 +32,7 @@ EXPORTS
av_codec_get_seek_preroll
av_codec_is_decoder
av_codec_is_encoder
+ av_codec_iterate
av_codec_next
av_codec_set_chroma_intra_matrix
av_codec_set_codec_descriptor
@@ -27,10 +41,12 @@ EXPORTS
av_codec_set_seek_preroll
av_copy_packet
av_copy_packet_side_data
+ av_cpb_properties_alloc
av_d3d11va_alloc_context
av_dct_calc
av_dct_end
av_dct_init
+ av_dirac_parse_sequence_header
av_dup_packet
av_dv_codec_profile
av_dv_codec_profile2
@@ -43,6 +59,7 @@ EXPORTS
av_fft_permute
av_free_packet
av_get_audio_frame_duration
+ av_get_audio_frame_duration2
av_get_bits_per_sample
av_get_codec_tag_string
av_get_exact_bits_per_sample
@@ -53,13 +70,19 @@ EXPORTS
av_imdct_calc
av_imdct_half
av_init_packet
+ av_jni_get_java_vm
+ av_jni_set_java_vm
av_lockmgr_register
- av_log_ask_for_sample
- av_log_missing_feature
av_mdct_calc
av_mdct_end
av_mdct_init
+ av_mediacodec_alloc_context
+ av_mediacodec_default_free
+ av_mediacodec_default_init
+ av_mediacodec_release_buffer
+ av_mediacodec_render_buffer_at_time
av_new_packet
+ av_packet_add_side_data
av_packet_alloc
av_packet_clone
av_packet_copy_props
@@ -67,6 +90,8 @@ EXPORTS
av_packet_free_side_data
av_packet_from_data
av_packet_get_side_data
+ av_packet_make_refcounted
+ av_packet_make_writable
av_packet_merge_side_data
av_packet_move_ref
av_packet_new_side_data
@@ -81,6 +106,7 @@ EXPORTS
av_parser_change
av_parser_close
av_parser_init
+ av_parser_iterate
av_parser_next
av_parser_parse2
av_picture_copy
@@ -93,10 +119,6 @@ EXPORTS
av_register_bitstream_filter
av_register_codec_parser
av_register_hwaccel
- av_resample
- av_resample_close
- av_resample_compensate
- av_resample_init
av_shrink_packet
av_vorbis_parse_frame
av_vorbis_parse_frame_flags
@@ -104,7 +126,6 @@ EXPORTS
av_vorbis_parse_init
av_vorbis_parse_reset
av_xiphlacing
- available_bits
avcodec_align_dimensions
avcodec_align_dimensions2
avcodec_alloc_context3
@@ -142,8 +163,9 @@ EXPORTS
avcodec_get_chroma_sub_sample
avcodec_get_class
avcodec_get_context_defaults3
- avcodec_get_edge_width
avcodec_get_frame_class
+ avcodec_get_hw_config
+ avcodec_get_hw_frames_parameters
avcodec_get_name
avcodec_get_pix_fmt_loss
avcodec_get_subtitle_rect_class
@@ -151,58 +173,66 @@ EXPORTS
avcodec_is_open
avcodec_license
avcodec_open2
+ avcodec_parameters_alloc
+ avcodec_parameters_copy
+ avcodec_parameters_free
+ avcodec_parameters_from_context
+ avcodec_parameters_to_context
avcodec_pix_fmt_to_codec_tag
+ avcodec_profile_name
+ avcodec_receive_frame
+ avcodec_receive_packet
avcodec_register
avcodec_register_all
- avcodec_set_dimensions
+ avcodec_send_frame
+ avcodec_send_packet
avcodec_string
avcodec_version
- aver_isf_history
- average_split_mvs
avpicture_alloc
avpicture_fill
avpicture_free
avpicture_get_size
avpicture_layout
- avpriv_aac_parse_header
- avpriv_ac3_channel_layout_tab DATA
+ avpriv_ac3_channel_layout_tab
avpriv_ac3_parse_header
avpriv_align_put_bits
avpriv_bprint_to_extradata
+ avpriv_codec2_mode_bit_rate
+ avpriv_codec2_mode_block_align
+ avpriv_codec2_mode_frame_size
+ avpriv_codec_get_cap_skip_frame_fill_param
avpriv_copy_bits
- avpriv_copy_pce_data
avpriv_dca_convert_bitstream
- avpriv_dca_sample_rates DATA
- avpriv_dirac_parse_sequence_header
+ avpriv_dca_parse_core_frame_header
+ avpriv_dca_sample_rates
avpriv_dnxhd_get_frame_size
+ avpriv_dnxhd_get_hr_frame_size
avpriv_dnxhd_get_interlaced
avpriv_do_elbg
avpriv_exif_decode_ifd
avpriv_find_pix_fmt
avpriv_find_start_code
+ avpriv_fits_header_init
+ avpriv_fits_header_parse_line
avpriv_get_raw_pix_fmt_tags
avpriv_h264_has_num_reorder_frames
avpriv_init_elbg
- avpriv_lock_avformat
- avpriv_mjpeg_bits_ac_chrominance DATA
- avpriv_mjpeg_bits_ac_luminance DATA
- avpriv_mjpeg_bits_dc_chrominance DATA
- avpriv_mjpeg_bits_dc_luminance DATA
- avpriv_mjpeg_val_ac_chrominance DATA
- avpriv_mjpeg_val_ac_luminance DATA
- avpriv_mjpeg_val_dc DATA
- avpriv_mpa_bitrate_tab DATA
- avpriv_mpa_decode_header
- avpriv_mpa_decode_header2
- avpriv_mpa_freq_tab DATA
+ avpriv_mjpeg_bits_ac_chrominance
+ avpriv_mjpeg_bits_ac_luminance
+ avpriv_mjpeg_bits_dc_chrominance
+ avpriv_mjpeg_bits_dc_luminance
+ avpriv_mjpeg_val_ac_chrominance
+ avpriv_mjpeg_val_ac_luminance
+ avpriv_mjpeg_val_dc
+ avpriv_mpa_bitrate_tab
+ avpriv_mpa_freq_tab
avpriv_mpeg4audio_get_config
- avpriv_mpeg4audio_sample_rates DATA
+ avpriv_mpeg4audio_sample_rates
avpriv_mpegaudio_decode_header
- avpriv_pix_fmt_bps_avi DATA
- avpriv_pix_fmt_bps_mov DATA
+ avpriv_pix_fmt_bps_avi
+ avpriv_pix_fmt_bps_mov
avpriv_put_string
avpriv_split_xiph_headers
avpriv_tak_parse_streaminfo
avpriv_toupper4
- avpriv_unlock_avformat
avsubtitle_free
diff --git a/neo/libs/ffmpeg-win64/lib/avcodec.lib b/neo/libs/ffmpeg-win64/lib/avcodec.lib
index fa24c593..340dd3ec 100644
Binary files a/neo/libs/ffmpeg-win64/lib/avcodec.lib and b/neo/libs/ffmpeg-win64/lib/avcodec.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/avdevice-57.def b/neo/libs/ffmpeg-win64/lib/avdevice-58.def
similarity index 88%
rename from neo/libs/ffmpeg-win64/lib/avdevice-57.def
rename to neo/libs/ffmpeg-win64/lib/avdevice-58.def
index f453187e..01682fc5 100644
--- a/neo/libs/ffmpeg-win64/lib/avdevice-57.def
+++ b/neo/libs/ffmpeg-win64/lib/avdevice-58.def
@@ -1,6 +1,6 @@
EXPORTS
- av_device_capabilities DATA
- av_device_ffversion DATA
+ av_device_capabilities
+ av_device_ffversion
av_input_audio_device_next
av_input_video_device_next
av_output_audio_device_next
diff --git a/neo/libs/ffmpeg-win64/lib/avdevice.lib b/neo/libs/ffmpeg-win64/lib/avdevice.lib
index 57715828..1aa39d69 100644
Binary files a/neo/libs/ffmpeg-win64/lib/avdevice.lib and b/neo/libs/ffmpeg-win64/lib/avdevice.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/avfilter-6.def b/neo/libs/ffmpeg-win64/lib/avfilter-7.def
similarity index 75%
rename from neo/libs/ffmpeg-win64/lib/avfilter-6.def
rename to neo/libs/ffmpeg-win64/lib/avfilter-7.def
index 5c5a4dcc..db3fe973 100644
--- a/neo/libs/ffmpeg-win64/lib/avfilter-6.def
+++ b/neo/libs/ffmpeg-win64/lib/avfilter-7.def
@@ -1,26 +1,38 @@
EXPORTS
av_abuffersink_params_alloc
+ av_buffersink_get_channel_layout
+ av_buffersink_get_channels
+ av_buffersink_get_format
av_buffersink_get_frame
av_buffersink_get_frame_flags
av_buffersink_get_frame_rate
+ av_buffersink_get_h
+ av_buffersink_get_hw_frames_ctx
+ av_buffersink_get_sample_aspect_ratio
+ av_buffersink_get_sample_rate
av_buffersink_get_samples
+ av_buffersink_get_time_base
+ av_buffersink_get_type
+ av_buffersink_get_w
av_buffersink_params_alloc
av_buffersink_set_frame_size
av_buffersrc_add_frame
av_buffersrc_add_frame_flags
+ av_buffersrc_close
av_buffersrc_get_nb_failed_requests
+ av_buffersrc_parameters_alloc
+ av_buffersrc_parameters_set
av_buffersrc_write_frame
- av_filter_ffversion DATA
- av_filter_next
+ av_filter_ffversion
+ av_filter_iterate
avfilter_add_matrix
- avfilter_all_channel_layouts DATA
+ avfilter_all_channel_layouts
avfilter_config_links
avfilter_configuration
avfilter_free
avfilter_get_by_name
avfilter_get_class
avfilter_get_matrix
- avfilter_graph_add_filter
avfilter_graph_alloc
avfilter_graph_alloc_filter
avfilter_graph_config
@@ -36,7 +48,6 @@ EXPORTS
avfilter_graph_send_command
avfilter_graph_set_auto_convert
avfilter_init_dict
- avfilter_init_filter
avfilter_init_str
avfilter_inout_alloc
avfilter_inout_free
@@ -49,7 +60,6 @@ EXPORTS
avfilter_make_format64_list
avfilter_mul_matrix
avfilter_next
- avfilter_open
avfilter_pad_count
avfilter_pad_get_name
avfilter_pad_get_type
@@ -58,5 +68,4 @@ EXPORTS
avfilter_register_all
avfilter_sub_matrix
avfilter_transform
- avfilter_uninit
avfilter_version
diff --git a/neo/libs/ffmpeg-win64/lib/avfilter.lib b/neo/libs/ffmpeg-win64/lib/avfilter.lib
index 289e546d..09c19f75 100644
Binary files a/neo/libs/ffmpeg-win64/lib/avfilter.lib and b/neo/libs/ffmpeg-win64/lib/avfilter.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/avformat-57.def b/neo/libs/ffmpeg-win64/lib/avformat-58.def
similarity index 89%
rename from neo/libs/ffmpeg-win64/lib/avformat-57.def
rename to neo/libs/ffmpeg-win64/lib/avformat-58.def
index 77dd6f0b..b00793e9 100644
--- a/neo/libs/ffmpeg-win64/lib/avformat-57.def
+++ b/neo/libs/ffmpeg-win64/lib/avformat-58.def
@@ -1,10 +1,11 @@
EXPORTS
av_add_index_entry
av_append_packet
+ av_apply_bitstream_filters
av_codec_get_id
av_codec_get_tag
av_codec_get_tag2
- av_convert_lang_to
+ av_demuxer_iterate
av_demuxer_open
av_dump_format
av_filename_number_test
@@ -13,7 +14,7 @@ EXPORTS
av_find_input_format
av_find_program_from_stream
av_fmt_ctx_get_duration_estimation_method
- av_format_ffversion DATA
+ av_format_ffversion
av_format_get_audio_codec
av_format_get_control_message_cb
av_format_get_data_codec
@@ -33,6 +34,7 @@ EXPORTS
av_format_set_subtitle_codec
av_format_set_video_codec
av_get_frame_filename
+ av_get_frame_filename2
av_get_output_timestamp
av_get_packet
av_guess_codec
@@ -46,6 +48,7 @@ EXPORTS
av_interleaved_write_frame
av_interleaved_write_uncoded_frame
av_match_ext
+ av_muxer_iterate
av_new_program
av_oformat_next
av_pkt_dump2
@@ -55,6 +58,7 @@ EXPORTS
av_probe_input_format
av_probe_input_format2
av_probe_input_format3
+ av_program_add_stream_index
av_read_frame
av_read_pause
av_read_play
@@ -63,11 +67,14 @@ EXPORTS
av_register_output_format
av_sdp_create
av_seek_frame
+ av_stream_add_side_data
+ av_stream_get_codec_timebase
av_stream_get_end_pts
av_stream_get_parser
av_stream_get_r_frame_rate
av_stream_get_recommended_encoder_configuration
av_stream_get_side_data
+ av_stream_new_side_data
av_stream_set_r_frame_rate
av_stream_set_recommended_encoder_configuration
av_url_split
@@ -87,6 +94,7 @@ EXPORTS
avformat_get_mov_video_tags
avformat_get_riff_audio_tags
avformat_get_riff_video_tags
+ avformat_init_output
avformat_license
avformat_match_stream_specifier
avformat_network_deinit
@@ -96,6 +104,7 @@ EXPORTS
avformat_query_codec
avformat_queue_attached_pictures
avformat_seek_file
+ avformat_transfer_internal_stream_timing_info
avformat_version
avformat_write_header
avio_accept
@@ -105,11 +114,13 @@ EXPORTS
avio_close_dir
avio_close_dyn_buf
avio_closep
+ avio_context_free
avio_enum_protocols
avio_feof
avio_find_protocol_name
avio_flush
avio_free_directory_entry
+ avio_get_dyn_buf
avio_get_str
avio_get_str16be
avio_get_str16le
@@ -130,6 +141,7 @@ EXPORTS
avio_rb64
avio_read
avio_read_dir
+ avio_read_partial
avio_read_to_bprint
avio_rl16
avio_rl24
@@ -149,6 +161,7 @@ EXPORTS
avio_wl32
avio_wl64
avio_write
+ avio_write_marker
avpriv_dv_get_packet
avpriv_dv_init_demux
avpriv_dv_produce_packet
@@ -158,15 +171,5 @@ EXPORTS
avpriv_mpegts_parse_open
avpriv_mpegts_parse_packet
avpriv_new_chapter
+ avpriv_register_devices
avpriv_set_pts_info
- ff_inet_aton
- ff_rtp_get_local_rtcp_port
- ff_rtp_get_local_rtp_port
- ff_rtsp_parse_line
- ff_socket_nonblock
- ffio_open_dyn_packet_buf
- ffio_set_buf_size
- ffurl_close
- ffurl_open
- ffurl_write
- url_feof
diff --git a/neo/libs/ffmpeg-win64/lib/avformat.lib b/neo/libs/ffmpeg-win64/lib/avformat.lib
index 43fd2d97..78e52f2b 100644
Binary files a/neo/libs/ffmpeg-win64/lib/avformat.lib and b/neo/libs/ffmpeg-win64/lib/avformat.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/avutil-55.def b/neo/libs/ffmpeg-win64/lib/avutil-56.def
similarity index 77%
rename from neo/libs/ffmpeg-win64/lib/avutil-55.def
rename to neo/libs/ffmpeg-win64/lib/avutil-56.def
index 1dbb8595..84ea685e 100644
--- a/neo/libs/ffmpeg-win64/lib/avutil-55.def
+++ b/neo/libs/ffmpeg-win64/lib/avutil-56.def
@@ -1,17 +1,29 @@
EXPORTS
+ av_add_i
av_add_q
av_add_stable
av_adler32_update
av_aes_alloc
av_aes_crypt
+ av_aes_ctr_alloc
+ av_aes_ctr_crypt
+ av_aes_ctr_free
+ av_aes_ctr_get_iv
+ av_aes_ctr_increment_iv
+ av_aes_ctr_init
+ av_aes_ctr_set_full_iv
+ av_aes_ctr_set_iv
+ av_aes_ctr_set_random_iv
av_aes_init
- av_aes_size DATA
+ av_aes_size
av_append_path_component
av_asprintf
+ av_assert0_fpu
av_audio_fifo_alloc
av_audio_fifo_drain
av_audio_fifo_free
av_audio_fifo_peek
+ av_audio_fifo_peek_at
av_audio_fifo_read
av_audio_fifo_realloc
av_audio_fifo_reset
@@ -47,6 +59,7 @@ EXPORTS
av_buffer_make_writable
av_buffer_pool_get
av_buffer_pool_init
+ av_buffer_pool_init2
av_buffer_pool_uninit
av_buffer_realloc
av_buffer_ref
@@ -55,21 +68,30 @@ EXPORTS
av_camellia_alloc
av_camellia_crypt
av_camellia_init
- av_camellia_size DATA
+ av_camellia_size
av_cast5_alloc
av_cast5_crypt
av_cast5_crypt2
av_cast5_init
- av_cast5_size DATA
+ av_cast5_size
av_channel_layout_extract_channel
+ av_chroma_location_from_name
av_chroma_location_name
+ av_cmp_i
+ av_color_primaries_from_name
av_color_primaries_name
+ av_color_range_from_name
av_color_range_name
+ av_color_space_from_name
av_color_space_name
+ av_color_transfer_from_name
av_color_transfer_name
av_compare_mod
av_compare_ts
+ av_content_light_metadata_alloc
+ av_content_light_metadata_create_side_data
av_cpu_count
+ av_cpu_max_align
av_crc
av_crc_get_table
av_crc_init
@@ -93,17 +115,30 @@ EXPORTS
av_display_matrix_flip
av_display_rotation_get
av_display_rotation_set
+ av_div_i
av_div_q
av_downmix_info_update_side_data
+ av_dynamic_hdr_plus_alloc
+ av_dynamic_hdr_plus_create_side_data
av_dynarray2_add
av_dynarray_add
av_dynarray_add_nofree
+ av_encryption_info_add_side_data
+ av_encryption_info_alloc
+ av_encryption_info_clone
+ av_encryption_info_free
+ av_encryption_info_get_side_data
+ av_encryption_init_info_add_side_data
+ av_encryption_init_info_alloc
+ av_encryption_init_info_free
+ av_encryption_init_info_get_side_data
av_escape
av_expr_eval
av_expr_free
av_expr_parse
av_expr_parse_and_eval
av_fast_malloc
+ av_fast_mallocz
av_fast_realloc
av_fifo_alloc
av_fifo_alloc_array
@@ -126,7 +161,9 @@ EXPORTS
av_find_nearest_q_idx
av_fopen_utf8
av_force_cpu_flags
+ av_fourcc_make_string
av_frame_alloc
+ av_frame_apply_cropping
av_frame_clone
av_frame_copy
av_frame_copy_props
@@ -150,6 +187,7 @@ EXPORTS
av_frame_make_writable
av_frame_move_ref
av_frame_new_side_data
+ av_frame_new_side_data_from_buf
av_frame_ref
av_frame_remove_side_data
av_frame_set_best_effort_timestamp
@@ -181,6 +219,7 @@ EXPORTS
av_get_colorspace_name
av_get_cpu_flags
av_get_default_channel_layout
+ av_get_extended_channel_layout
av_get_known_color_name
av_get_media_type_string
av_get_packed_sample_fmt
@@ -218,25 +257,50 @@ EXPORTS
av_hmac_free
av_hmac_init
av_hmac_update
+ av_hwdevice_ctx_alloc
+ av_hwdevice_ctx_create
+ av_hwdevice_ctx_create_derived
+ av_hwdevice_ctx_init
+ av_hwdevice_find_type_by_name
+ av_hwdevice_get_hwframe_constraints
+ av_hwdevice_get_type_name
+ av_hwdevice_hwconfig_alloc
+ av_hwdevice_iterate_types
+ av_hwframe_constraints_free
+ av_hwframe_ctx_alloc
+ av_hwframe_ctx_create_derived
+ av_hwframe_ctx_init
+ av_hwframe_get_buffer
+ av_hwframe_map
+ av_hwframe_transfer_data
+ av_hwframe_transfer_get_formats
+ av_i2int
av_image_alloc
av_image_check_sar
av_image_check_size
+ av_image_check_size2
av_image_copy
av_image_copy_plane
av_image_copy_to_buffer
+ av_image_copy_uc_from
av_image_fill_arrays
+ av_image_fill_black
av_image_fill_linesizes
av_image_fill_max_pixsteps
av_image_fill_pointers
av_image_get_buffer_size
av_image_get_linesize
+ av_int2i
av_int_list_length_for_size
av_lfg_init
+ av_lfg_init_from_data
av_log
av_log2
av_log2_16bit
+ av_log2_i
av_log_default_callback
av_log_format_line
+ av_log_format_line2
av_log_get_flags
av_log_get_level
av_log_set_callback
@@ -244,18 +308,24 @@ EXPORTS
av_log_set_level
av_lzo1x_decode
av_malloc
+ av_malloc_array
av_mallocz
+ av_mallocz_array
+ av_mastering_display_metadata_alloc
+ av_mastering_display_metadata_create_side_data
av_match_list
av_match_name
av_max_alloc
av_md5_alloc
av_md5_final
av_md5_init
- av_md5_size DATA
+ av_md5_size
av_md5_sum
av_md5_update
av_memcpy_backptr
av_memdup
+ av_mod_i
+ av_mul_i
av_mul_q
av_murmur3_alloc
av_murmur3_final
@@ -331,6 +401,7 @@ EXPORTS
av_rc4_crypt
av_rc4_init
av_read_image_line
+ av_read_image_line2
av_realloc
av_realloc_array
av_realloc_f
@@ -345,7 +416,7 @@ EXPORTS
av_ripemd_alloc
av_ripemd_final
av_ripemd_init
- av_ripemd_size DATA
+ av_ripemd_size
av_ripemd_update
av_sample_fmt_is_planar
av_samples_alloc
@@ -359,19 +430,28 @@ EXPORTS
av_sha512_alloc
av_sha512_final
av_sha512_init
- av_sha512_size DATA
+ av_sha512_size
av_sha512_update
av_sha_alloc
av_sha_final
av_sha_init
- av_sha_size DATA
+ av_sha_size
av_sha_update
+ av_shr_i
av_small_strptime
+ av_spherical_alloc
+ av_spherical_from_name
+ av_spherical_projection_name
+ av_spherical_tile_bounds
+ av_sscanf
av_stereo3d_alloc
av_stereo3d_create_side_data
+ av_stereo3d_from_name
+ av_stereo3d_type_name
av_strcasecmp
av_strdup
av_strerror
+ av_strireplace
av_stristart
av_stristr
av_strlcat
@@ -383,18 +463,22 @@ EXPORTS
av_strstart
av_strtod
av_strtok
+ av_sub_i
av_sub_q
av_tea_alloc
av_tea_crypt
av_tea_init
- av_tea_size DATA
+ av_tea_size
av_tempfile
+ av_thread_message_flush
av_thread_message_queue_alloc
av_thread_message_queue_free
+ av_thread_message_queue_nb_elems
av_thread_message_queue_recv
av_thread_message_queue_send
av_thread_message_queue_set_err_recv
av_thread_message_queue_set_err_send
+ av_thread_message_queue_set_free_func
av_timecode_adjust_ntsc_framenum2
av_timecode_check_frame_rate
av_timecode_get_smpte_from_framenum
@@ -409,25 +493,30 @@ EXPORTS
av_tree_find
av_tree_insert
av_tree_node_alloc
- av_tree_node_size DATA
+ av_tree_node_size
av_twofish_alloc
av_twofish_crypt
av_twofish_init
- av_twofish_size DATA
+ av_twofish_size
+ av_tx_init
+ av_tx_uninit
av_usleep
av_utf8_decode
- av_util_ffversion DATA
+ av_util_ffversion
av_vbprintf
av_version_info
av_vlog
av_write_image_line
+ av_write_image_line2
av_xtea_alloc
av_xtea_crypt
av_xtea_init
+ av_xtea_le_crypt
+ av_xtea_le_init
avpriv_alloc_fixed_dsp
- avpriv_cga_font DATA
+ avpriv_cga_font
+ avpriv_dict_set_timestamp
avpriv_float_dsp_alloc
- avpriv_frame_get_metadatap
avpriv_get_gamma_from_trc
avpriv_get_trc_function_from_trc
avpriv_init_lls
@@ -436,8 +525,12 @@ EXPORTS
avpriv_request_sample
avpriv_scalarproduct_float_c
avpriv_set_systematic_pal2
+ avpriv_slicethread_create
+ avpriv_slicethread_execute
+ avpriv_slicethread_free
avpriv_solve_lls
- avpriv_vga16_font DATA
+ avpriv_tempfile
+ avpriv_vga16_font
avutil_configuration
avutil_license
avutil_version
diff --git a/neo/libs/ffmpeg-win64/lib/avutil.lib b/neo/libs/ffmpeg-win64/lib/avutil.lib
index e529f827..7c82a714 100644
Binary files a/neo/libs/ffmpeg-win64/lib/avutil.lib and b/neo/libs/ffmpeg-win64/lib/avutil.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/libavcodec.dll.a b/neo/libs/ffmpeg-win64/lib/libavcodec.dll.a
index 7866052c..015fc05d 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libavcodec.dll.a and b/neo/libs/ffmpeg-win64/lib/libavcodec.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libavdevice.dll.a b/neo/libs/ffmpeg-win64/lib/libavdevice.dll.a
index cb1a9b55..4cde80c0 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libavdevice.dll.a and b/neo/libs/ffmpeg-win64/lib/libavdevice.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libavfilter.dll.a b/neo/libs/ffmpeg-win64/lib/libavfilter.dll.a
index 88c7557c..792e78b6 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libavfilter.dll.a and b/neo/libs/ffmpeg-win64/lib/libavfilter.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libavformat.dll.a b/neo/libs/ffmpeg-win64/lib/libavformat.dll.a
index 2fb5749c..98cebc92 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libavformat.dll.a and b/neo/libs/ffmpeg-win64/lib/libavformat.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libavutil.dll.a b/neo/libs/ffmpeg-win64/lib/libavutil.dll.a
index 84b93eaf..f3819f7a 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libavutil.dll.a and b/neo/libs/ffmpeg-win64/lib/libavutil.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libpostproc.dll.a b/neo/libs/ffmpeg-win64/lib/libpostproc.dll.a
index a7ea4b4b..b9432834 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libpostproc.dll.a and b/neo/libs/ffmpeg-win64/lib/libpostproc.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libswresample.dll.a b/neo/libs/ffmpeg-win64/lib/libswresample.dll.a
index 8952d361..5a408358 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libswresample.dll.a and b/neo/libs/ffmpeg-win64/lib/libswresample.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/libswscale.dll.a b/neo/libs/ffmpeg-win64/lib/libswscale.dll.a
index 401045f5..7f44d670 100644
Binary files a/neo/libs/ffmpeg-win64/lib/libswscale.dll.a and b/neo/libs/ffmpeg-win64/lib/libswscale.dll.a differ
diff --git a/neo/libs/ffmpeg-win64/lib/postproc-54.def b/neo/libs/ffmpeg-win64/lib/postproc-55.def
similarity index 80%
rename from neo/libs/ffmpeg-win64/lib/postproc-54.def
rename to neo/libs/ffmpeg-win64/lib/postproc-55.def
index 62c4c69d..1dd67ee9 100644
--- a/neo/libs/ffmpeg-win64/lib/postproc-54.def
+++ b/neo/libs/ffmpeg-win64/lib/postproc-55.def
@@ -1,11 +1,11 @@
EXPORTS
postproc_configuration
- postproc_ffversion DATA
+ postproc_ffversion
postproc_license
postproc_version
pp_free_context
pp_free_mode
pp_get_context
pp_get_mode_by_name_and_quality
- pp_help DATA
+ pp_help
pp_postprocess
diff --git a/neo/libs/ffmpeg-win64/lib/postproc.lib b/neo/libs/ffmpeg-win64/lib/postproc.lib
index cb353015..be3c2d96 100644
Binary files a/neo/libs/ffmpeg-win64/lib/postproc.lib and b/neo/libs/ffmpeg-win64/lib/postproc.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/swresample-2.def b/neo/libs/ffmpeg-win64/lib/swresample-3.def
similarity index 91%
rename from neo/libs/ffmpeg-win64/lib/swresample-2.def
rename to neo/libs/ffmpeg-win64/lib/swresample-3.def
index 38644766..4ca6d903 100644
--- a/neo/libs/ffmpeg-win64/lib/swresample-2.def
+++ b/neo/libs/ffmpeg-win64/lib/swresample-3.def
@@ -1,12 +1,13 @@
EXPORTS
swr_alloc
swr_alloc_set_opts
+ swr_build_matrix
swr_close
swr_config_frame
swr_convert
swr_convert_frame
swr_drop_output
- swr_ffversion DATA
+ swr_ffversion
swr_free
swr_get_class
swr_get_delay
diff --git a/neo/libs/ffmpeg-win64/lib/swresample.lib b/neo/libs/ffmpeg-win64/lib/swresample.lib
index cf7dc746..67a91b47 100644
Binary files a/neo/libs/ffmpeg-win64/lib/swresample.lib and b/neo/libs/ffmpeg-win64/lib/swresample.lib differ
diff --git a/neo/libs/ffmpeg-win64/lib/swscale-4.def b/neo/libs/ffmpeg-win64/lib/swscale-5.def
similarity index 100%
rename from neo/libs/ffmpeg-win64/lib/swscale-4.def
rename to neo/libs/ffmpeg-win64/lib/swscale-5.def
diff --git a/neo/libs/ffmpeg-win64/lib/swscale.lib b/neo/libs/ffmpeg-win64/lib/swscale.lib
index 64f0dd6c..c80624de 100644
Binary files a/neo/libs/ffmpeg-win64/lib/swscale.lib and b/neo/libs/ffmpeg-win64/lib/swscale.lib differ