react-native-audio-api 0.8.0-nightly-5a12f24-20250901 → 0.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (225) hide show
  1. package/RNAudioAPI.podspec +15 -6
  2. package/android/build.gradle +11 -2
  3. package/android/src/main/cpp/audioapi/CMakeLists.txt +24 -17
  4. package/android/src/main/cpp/audioapi/android/core/AudioDecoder.cpp +51 -21
  5. package/android/src/main/jniLibs/arm64-v8a/libavcodec.so +0 -0
  6. package/android/src/main/jniLibs/arm64-v8a/libavformat.so +0 -0
  7. package/android/src/main/jniLibs/arm64-v8a/libavutil.so +0 -0
  8. package/android/src/main/jniLibs/arm64-v8a/libswresample.so +0 -0
  9. package/android/src/main/jniLibs/armeabi-v7a/libavcodec.so +0 -0
  10. package/android/src/main/jniLibs/armeabi-v7a/libavformat.so +0 -0
  11. package/android/src/main/jniLibs/armeabi-v7a/libavutil.so +0 -0
  12. package/android/src/main/jniLibs/armeabi-v7a/libswresample.so +0 -0
  13. package/android/src/main/jniLibs/x86/libavcodec.so +0 -0
  14. package/android/src/main/jniLibs/x86/libavformat.so +0 -0
  15. package/android/src/main/jniLibs/x86/libavutil.so +0 -0
  16. package/android/src/main/jniLibs/x86/libswresample.so +0 -0
  17. package/android/src/main/jniLibs/x86_64/libavcodec.so +0 -0
  18. package/android/src/main/jniLibs/x86_64/libavformat.so +0 -0
  19. package/android/src/main/jniLibs/x86_64/libavutil.so +0 -0
  20. package/android/src/main/jniLibs/x86_64/libswresample.so +0 -0
  21. package/common/cpp/audioapi/HostObjects/BaseAudioContextHostObject.h +11 -0
  22. package/common/cpp/audioapi/HostObjects/StreamerNodeHostObject.h +30 -0
  23. package/common/cpp/audioapi/core/BaseAudioContext.cpp +9 -0
  24. package/common/cpp/audioapi/core/BaseAudioContext.h +2 -0
  25. package/common/cpp/audioapi/core/sources/StreamerNode.cpp +299 -0
  26. package/common/cpp/audioapi/core/sources/StreamerNode.h +123 -0
  27. package/common/cpp/audioapi/core/utils/AudioDecoder.h +61 -0
  28. package/common/cpp/audioapi/core/utils/AudioNodeManager.cpp +14 -2
  29. package/common/cpp/audioapi/core/utils/AudioNodeManager.h +3 -0
  30. package/common/cpp/audioapi/external/arm64-v8a/libcrypto.a +0 -0
  31. package/common/cpp/audioapi/external/arm64-v8a/libssl.a +0 -0
  32. package/common/cpp/audioapi/external/armeabi-v7a/libcrypto.a +0 -0
  33. package/common/cpp/audioapi/external/armeabi-v7a/libssl.a +0 -0
  34. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/ac3_parser.h +36 -0
  35. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/adts_parser.h +37 -0
  36. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/avcodec.h +2947 -0
  37. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/avdct.h +88 -0
  38. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/bsf.h +332 -0
  39. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/codec.h +367 -0
  40. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/codec_desc.h +134 -0
  41. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/codec_id.h +681 -0
  42. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/codec_par.h +248 -0
  43. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/d3d11va.h +109 -0
  44. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/defs.h +359 -0
  45. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/dirac.h +135 -0
  46. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/dv_profile.h +82 -0
  47. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/dxva2.h +90 -0
  48. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/jni.h +67 -0
  49. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/mediacodec.h +103 -0
  50. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/packet.h +907 -0
  51. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/qsv.h +109 -0
  52. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/vdpau.h +138 -0
  53. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/version.h +45 -0
  54. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/version_major.h +55 -0
  55. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/videotoolbox.h +85 -0
  56. package/common/cpp/audioapi/external/ffmpeg_include/libavcodec/vorbis_parser.h +74 -0
  57. package/common/cpp/audioapi/external/ffmpeg_include/libavformat/avformat.h +3004 -0
  58. package/common/cpp/audioapi/external/ffmpeg_include/libavformat/avio.h +831 -0
  59. package/common/cpp/audioapi/external/ffmpeg_include/libavformat/version.h +47 -0
  60. package/common/cpp/audioapi/external/ffmpeg_include/libavformat/version_major.h +50 -0
  61. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/adler32.h +63 -0
  62. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/aes.h +69 -0
  63. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/aes_ctr.h +99 -0
  64. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/ambient_viewing_environment.h +72 -0
  65. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/attributes.h +175 -0
  66. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/audio_fifo.h +187 -0
  67. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/avassert.h +120 -0
  68. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/avconfig.h +6 -0
  69. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/avstring.h +428 -0
  70. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/avutil.h +364 -0
  71. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/base64.h +72 -0
  72. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/blowfish.h +82 -0
  73. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/bprint.h +254 -0
  74. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/bswap.h +105 -0
  75. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/buffer.h +322 -0
  76. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/camellia.h +70 -0
  77. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/cast5.h +80 -0
  78. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/channel_layout.h +762 -0
  79. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/common.h +589 -0
  80. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/container_fifo.h +130 -0
  81. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/cpu.h +150 -0
  82. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/crc.h +102 -0
  83. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/csp.h +192 -0
  84. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/des.h +81 -0
  85. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/detection_bbox.h +108 -0
  86. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/dict.h +242 -0
  87. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/display.h +109 -0
  88. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/dovi_meta.h +396 -0
  89. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/downmix_info.h +115 -0
  90. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/encryption_info.h +205 -0
  91. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/error.h +129 -0
  92. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/eval.h +140 -0
  93. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/executor.h +67 -0
  94. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/ffversion.h +5 -0
  95. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/fifo.h +242 -0
  96. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/file.h +62 -0
  97. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/film_grain_params.h +282 -0
  98. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/frame.h +1163 -0
  99. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hash.h +264 -0
  100. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hdr_dynamic_metadata.h +376 -0
  101. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hdr_dynamic_vivid_metadata.h +292 -0
  102. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hmac.h +99 -0
  103. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext.h +601 -0
  104. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_amf.h +46 -0
  105. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_cuda.h +74 -0
  106. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_d3d11va.h +178 -0
  107. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_d3d12va.h +142 -0
  108. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_drm.h +169 -0
  109. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_dxva2.h +75 -0
  110. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_mediacodec.h +61 -0
  111. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_oh.h +34 -0
  112. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_opencl.h +100 -0
  113. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_qsv.h +87 -0
  114. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_vaapi.h +117 -0
  115. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_vdpau.h +44 -0
  116. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_videotoolbox.h +106 -0
  117. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/hwcontext_vulkan.h +377 -0
  118. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/iamf.h +694 -0
  119. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/imgutils.h +377 -0
  120. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/intfloat.h +77 -0
  121. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/intreadwrite.h +677 -0
  122. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/lfg.h +81 -0
  123. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/log.h +427 -0
  124. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/lzo.h +66 -0
  125. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/macros.h +80 -0
  126. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/mastering_display_metadata.h +137 -0
  127. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/mathematics.h +300 -0
  128. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/md5.h +89 -0
  129. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/mem.h +607 -0
  130. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/motion_vector.h +57 -0
  131. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/murmur3.h +115 -0
  132. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/opt.h +1194 -0
  133. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/parseutils.h +197 -0
  134. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/pixdesc.h +440 -0
  135. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/pixelutils.h +51 -0
  136. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/pixfmt.h +797 -0
  137. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/random_seed.h +57 -0
  138. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/rational.h +225 -0
  139. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/rc4.h +69 -0
  140. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/refstruct.h +297 -0
  141. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/replaygain.h +50 -0
  142. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/ripemd.h +83 -0
  143. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/samplefmt.h +269 -0
  144. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/sha.h +90 -0
  145. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/sha512.h +92 -0
  146. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/spherical.h +243 -0
  147. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/stereo3d.h +325 -0
  148. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/tdrdi.h +164 -0
  149. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/tea.h +71 -0
  150. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/threadmessage.h +115 -0
  151. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/timecode.h +199 -0
  152. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/timestamp.h +85 -0
  153. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/tree.h +137 -0
  154. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/twofish.h +70 -0
  155. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/tx.h +210 -0
  156. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/uuid.h +146 -0
  157. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/version.h +119 -0
  158. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/video_enc_params.h +171 -0
  159. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/video_hint.h +107 -0
  160. package/common/cpp/audioapi/external/ffmpeg_include/libavutil/xtea.h +94 -0
  161. package/common/cpp/audioapi/external/ffmpeg_include/libswresample/swresample.h +587 -0
  162. package/common/cpp/audioapi/external/ffmpeg_include/libswresample/version.h +46 -0
  163. package/common/cpp/audioapi/external/ffmpeg_include/libswresample/version_major.h +31 -0
  164. package/common/cpp/audioapi/external/libavcodec.xcframework/Info.plist +44 -0
  165. package/common/cpp/audioapi/external/libavcodec.xcframework/ios-arm64/libavcodec.framework/Info.plist +1 -0
  166. package/common/cpp/audioapi/external/libavcodec.xcframework/ios-arm64/libavcodec.framework/libavcodec +0 -0
  167. package/common/cpp/audioapi/external/libavcodec.xcframework/ios-arm64_x86_64-simulator/libavcodec.framework/Info.plist +1 -0
  168. package/common/cpp/audioapi/external/libavcodec.xcframework/ios-arm64_x86_64-simulator/libavcodec.framework/libavcodec +0 -0
  169. package/common/cpp/audioapi/external/libavformat.xcframework/Info.plist +44 -0
  170. package/common/cpp/audioapi/external/libavformat.xcframework/ios-arm64/libavformat.framework/Info.plist +1 -0
  171. package/common/cpp/audioapi/external/libavformat.xcframework/ios-arm64/libavformat.framework/libavformat +0 -0
  172. package/common/cpp/audioapi/external/libavformat.xcframework/ios-arm64_x86_64-simulator/libavformat.framework/Info.plist +1 -0
  173. package/common/cpp/audioapi/external/libavformat.xcframework/ios-arm64_x86_64-simulator/libavformat.framework/libavformat +0 -0
  174. package/common/cpp/audioapi/external/libavutil.xcframework/Info.plist +44 -0
  175. package/common/cpp/audioapi/external/libavutil.xcframework/ios-arm64/libavutil.framework/Info.plist +1 -0
  176. package/common/cpp/audioapi/external/libavutil.xcframework/ios-arm64/libavutil.framework/libavutil +0 -0
  177. package/common/cpp/audioapi/external/libavutil.xcframework/ios-arm64_x86_64-simulator/libavutil.framework/Info.plist +1 -0
  178. package/common/cpp/audioapi/external/libavutil.xcframework/ios-arm64_x86_64-simulator/libavutil.framework/libavutil +0 -0
  179. package/common/cpp/audioapi/external/libswresample.xcframework/Info.plist +44 -0
  180. package/common/cpp/audioapi/external/libswresample.xcframework/ios-arm64/libswresample.framework/Info.plist +1 -0
  181. package/common/cpp/audioapi/external/libswresample.xcframework/ios-arm64/libswresample.framework/libswresample +0 -0
  182. package/common/cpp/audioapi/external/libswresample.xcframework/ios-arm64_x86_64-simulator/libswresample.framework/Info.plist +1 -0
  183. package/common/cpp/audioapi/external/libswresample.xcframework/ios-arm64_x86_64-simulator/libswresample.framework/libswresample +0 -0
  184. package/common/cpp/audioapi/external/x86/libcrypto.a +0 -0
  185. package/common/cpp/audioapi/external/x86/libssl.a +0 -0
  186. package/common/cpp/audioapi/external/x86_64/libcrypto.a +0 -0
  187. package/common/cpp/audioapi/external/x86_64/libssl.a +0 -0
  188. package/common/cpp/audioapi/libs/ffmpeg/FFmpegDecoding.cpp +402 -0
  189. package/common/cpp/audioapi/libs/ffmpeg/FFmpegDecoding.h +27 -0
  190. package/common/cpp/audioapi/libs/ffmpeg/INSTRUCTIONS.md +26 -0
  191. package/common/cpp/audioapi/libs/ffmpeg/create_xcframework.sh +111 -0
  192. package/common/cpp/audioapi/libs/ffmpeg/ffmpeg_setup.sh +361 -0
  193. package/common/cpp/audioapi/utils/SpscChannel.hpp +47 -38
  194. package/common/cpp/test/CMakeLists.txt +7 -1
  195. package/ios/audioapi/ios/core/AudioDecoder.mm +22 -2
  196. package/lib/commonjs/api.js +7 -0
  197. package/lib/commonjs/api.js.map +1 -1
  198. package/lib/commonjs/core/AudioContext.js.map +1 -1
  199. package/lib/commonjs/core/BaseAudioContext.js +4 -0
  200. package/lib/commonjs/core/BaseAudioContext.js.map +1 -1
  201. package/lib/commonjs/core/StreamerNode.js +15 -0
  202. package/lib/commonjs/core/StreamerNode.js.map +1 -0
  203. package/lib/module/api.js +1 -0
  204. package/lib/module/api.js.map +1 -1
  205. package/lib/module/core/AudioContext.js.map +1 -1
  206. package/lib/module/core/BaseAudioContext.js +4 -0
  207. package/lib/module/core/BaseAudioContext.js.map +1 -1
  208. package/lib/module/core/StreamerNode.js +9 -0
  209. package/lib/module/core/StreamerNode.js.map +1 -0
  210. package/lib/typescript/api.d.ts +1 -0
  211. package/lib/typescript/api.d.ts.map +1 -1
  212. package/lib/typescript/core/AudioContext.d.ts +1 -1
  213. package/lib/typescript/core/AudioContext.d.ts.map +1 -1
  214. package/lib/typescript/core/BaseAudioContext.d.ts +2 -0
  215. package/lib/typescript/core/BaseAudioContext.d.ts.map +1 -1
  216. package/lib/typescript/core/StreamerNode.d.ts +5 -0
  217. package/lib/typescript/core/StreamerNode.d.ts.map +1 -0
  218. package/lib/typescript/interfaces.d.ts +5 -1
  219. package/lib/typescript/interfaces.d.ts.map +1 -1
  220. package/package.json +1 -1
  221. package/src/api.ts +1 -0
  222. package/src/core/AudioContext.ts +1 -1
  223. package/src/core/BaseAudioContext.ts +5 -0
  224. package/src/core/StreamerNode.ts +8 -0
  225. package/src/interfaces.ts +6 -1
@@ -0,0 +1,137 @@
1
+ /*
2
+ * copyright (c) 2006 Michael Niedermayer <michaelni@gmx.at>
3
+ *
4
+ * This file is part of FFmpeg.
5
+ *
6
+ * FFmpeg is free software; you can redistribute it and/or
7
+ * modify it under the terms of the GNU Lesser General Public
8
+ * License as published by the Free Software Foundation; either
9
+ * version 2.1 of the License, or (at your option) any later version.
10
+ *
11
+ * FFmpeg is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14
+ * Lesser General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU Lesser General Public
17
+ * License along with FFmpeg; if not, write to the Free Software
18
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
+ */
20
+
21
+ /**
22
+ * @file
23
+ * A tree container.
24
+ * @author Michael Niedermayer <michaelni@gmx.at>
25
+ */
26
+
27
+ #ifndef AVUTIL_TREE_H
28
+ #define AVUTIL_TREE_H
29
+
30
+ #include "attributes.h"
31
+
32
+ /**
33
+ * @addtogroup lavu_tree AVTree
34
+ * @ingroup lavu_data
35
+ *
36
+ * Low-complexity tree container
37
+ *
38
+ * Insertion, removal, finding equal, largest which is smaller than and
39
+ * smallest which is larger than, all have O(log n) worst-case complexity.
40
+ * @{
41
+ */
42
+
43
+
44
+ struct AVTreeNode;
45
+ extern const int av_tree_node_size;
46
+
47
+ /**
48
+ * Allocate an AVTreeNode.
49
+ */
50
+ struct AVTreeNode *av_tree_node_alloc(void);
51
+
52
+ /**
53
+ * Find an element.
54
+ * @param root a pointer to the root node of the tree
55
+ * @param next If next is not NULL, then next[0] will contain the previous
56
+ * element and next[1] the next element. If either does not exist,
57
+ * then the corresponding entry in next is unchanged.
58
+ * @param cmp compare function used to compare elements in the tree,
59
+ * API identical to that of Standard C's qsort
60
+ * It is guaranteed that the first and only the first argument to cmp()
61
+ * will be the key parameter to av_tree_find(), thus it could if the
62
+ * user wants, be a different type (like an opaque context).
63
+ * @return An element with cmp(key, elem) == 0 or NULL if no such element
64
+ * exists in the tree.
65
+ */
66
+ void *av_tree_find(const struct AVTreeNode *root, void *key,
67
+ int (*cmp)(const void *key, const void *b), void *next[2]);
68
+
69
+ /**
70
+ * Insert or remove an element.
71
+ *
72
+ * If *next is NULL, then the supplied element will be removed if it exists.
73
+ * If *next is non-NULL, then the supplied element will be inserted, unless
74
+ * it already exists in the tree.
75
+ *
76
+ * @param rootp A pointer to a pointer to the root node of the tree; note that
77
+ * the root node can change during insertions, this is required
78
+ * to keep the tree balanced.
79
+ * @param key pointer to the element key to insert in the tree
80
+ * @param next Used to allocate and free AVTreeNodes. For insertion the user
81
+ * must set it to an allocated and zeroed object of at least
82
+ * av_tree_node_size bytes size. av_tree_insert() will set it to
83
+ * NULL if it has been consumed.
84
+ * For deleting elements *next is set to NULL by the user and
85
+ * av_tree_insert() will set it to the AVTreeNode which was
86
+ * used for the removed element.
87
+ * This allows the use of flat arrays, which have
88
+ * lower overhead compared to many malloced elements.
89
+ * You might want to define a function like:
90
+ * @code
91
+ * void *tree_insert(struct AVTreeNode **rootp, void *key,
92
+ * int (*cmp)(void *key, const void *b),
93
+ * AVTreeNode **next)
94
+ * {
95
+ * if (!*next)
96
+ * *next = av_mallocz(av_tree_node_size);
97
+ * return av_tree_insert(rootp, key, cmp, next);
98
+ * }
99
+ * void *tree_remove(struct AVTreeNode **rootp, void *key,
100
+ * int (*cmp)(void *key, const void *b, AVTreeNode **next))
101
+ * {
102
+ * av_freep(next);
103
+ * return av_tree_insert(rootp, key, cmp, next);
104
+ * }
105
+ * @endcode
106
+ * @param cmp compare function used to compare elements in the tree, API identical
107
+ * to that of Standard C's qsort
108
+ * @return If no insertion happened, the found element; if an insertion or
109
+ * removal happened, then either key or NULL will be returned.
110
+ * Which one it is depends on the tree state and the implementation. You
111
+ * should make no assumptions that it's one or the other in the code.
112
+ */
113
+ void *av_tree_insert(struct AVTreeNode **rootp, void *key,
114
+ int (*cmp)(const void *key, const void *b),
115
+ struct AVTreeNode **next);
116
+
117
+ void av_tree_destroy(struct AVTreeNode *t);
118
+
119
+ /**
120
+ * Apply enu(opaque, &elem) to all the elements in the tree in a given range.
121
+ *
122
+ * @param cmp a comparison function that returns < 0 for an element below the
123
+ * range, > 0 for an element above the range and == 0 for an
124
+ * element inside the range
125
+ *
126
+ * @note The cmp function should use the same ordering used to construct the
127
+ * tree.
128
+ */
129
+ void av_tree_enumerate(struct AVTreeNode *t, void *opaque,
130
+ int (*cmp)(void *opaque, void *elem),
131
+ int (*enu)(void *opaque, void *elem));
132
+
133
+ /**
134
+ * @}
135
+ */
136
+
137
+ #endif /* AVUTIL_TREE_H */
@@ -0,0 +1,70 @@
1
+ /*
2
+ * An implementation of the TwoFish algorithm
3
+ * Copyright (c) 2015 Supraja Meedinti
4
+ *
5
+ * This file is part of FFmpeg.
6
+ *
7
+ * FFmpeg is free software; you can redistribute it and/or
8
+ * modify it under the terms of the GNU Lesser General Public
9
+ * License as published by the Free Software Foundation; either
10
+ * version 2.1 of the License, or (at your option) any later version.
11
+ *
12
+ * FFmpeg is distributed in the hope that it will be useful,
13
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15
+ * Lesser General Public License for more details.
16
+ *
17
+ * You should have received a copy of the GNU Lesser General Public
18
+ * License along with FFmpeg; if not, write to the Free Software
19
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
+ */
21
+
22
+ #ifndef AVUTIL_TWOFISH_H
23
+ #define AVUTIL_TWOFISH_H
24
+
25
+ #include <stdint.h>
26
+
27
+
28
+ /**
29
+ * @file
30
+ * @brief Public header for libavutil TWOFISH algorithm
31
+ * @defgroup lavu_twofish TWOFISH
32
+ * @ingroup lavu_crypto
33
+ * @{
34
+ */
35
+
36
+ extern const int av_twofish_size;
37
+
38
+ struct AVTWOFISH;
39
+
40
+ /**
41
+ * Allocate an AVTWOFISH context
42
+ * To free the struct: av_free(ptr)
43
+ */
44
+ struct AVTWOFISH *av_twofish_alloc(void);
45
+
46
+ /**
47
+ * Initialize an AVTWOFISH context.
48
+ *
49
+ * @param ctx an AVTWOFISH context
50
+ * @param key a key of size ranging from 1 to 32 bytes used for encryption/decryption
51
+ * @param key_bits number of keybits: 128, 192, 256 If less than the required, padded with zeroes to nearest valid value; return value is 0 if key_bits is 128/192/256, -1 if less than 0, 1 otherwise
52
+ */
53
+ int av_twofish_init(struct AVTWOFISH *ctx, const uint8_t *key, int key_bits);
54
+
55
+ /**
56
+ * Encrypt or decrypt a buffer using a previously initialized context
57
+ *
58
+ * @param ctx an AVTWOFISH context
59
+ * @param dst destination array, can be equal to src
60
+ * @param src source array, can be equal to dst
61
+ * @param count number of 16 byte blocks
62
+ * @param iv initialization vector for CBC mode, NULL for ECB mode
63
+ * @param decrypt 0 for encryption, 1 for decryption
64
+ */
65
+ void av_twofish_crypt(struct AVTWOFISH *ctx, uint8_t *dst, const uint8_t *src, int count, uint8_t* iv, int decrypt);
66
+
67
+ /**
68
+ * @}
69
+ */
70
+ #endif /* AVUTIL_TWOFISH_H */
@@ -0,0 +1,210 @@
1
+ /*
2
+ * This file is part of FFmpeg.
3
+ *
4
+ * FFmpeg is free software; you can redistribute it and/or
5
+ * modify it under the terms of the GNU Lesser General Public
6
+ * License as published by the Free Software Foundation; either
7
+ * version 2.1 of the License, or (at your option) any later version.
8
+ *
9
+ * FFmpeg is distributed in the hope that it will be useful,
10
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
11
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12
+ * Lesser General Public License for more details.
13
+ *
14
+ * You should have received a copy of the GNU Lesser General Public
15
+ * License along with FFmpeg; if not, write to the Free Software
16
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
17
+ */
18
+
19
+ #ifndef AVUTIL_TX_H
20
+ #define AVUTIL_TX_H
21
+
22
+ #include <stdint.h>
23
+ #include <stddef.h>
24
+
25
+ typedef struct AVTXContext AVTXContext;
26
+
27
+ typedef struct AVComplexFloat {
28
+ float re, im;
29
+ } AVComplexFloat;
30
+
31
+ typedef struct AVComplexDouble {
32
+ double re, im;
33
+ } AVComplexDouble;
34
+
35
+ typedef struct AVComplexInt32 {
36
+ int32_t re, im;
37
+ } AVComplexInt32;
38
+
39
+ enum AVTXType {
40
+ /**
41
+ * Standard complex to complex FFT with sample data type of AVComplexFloat,
42
+ * AVComplexDouble or AVComplexInt32, for each respective variant.
43
+ *
44
+ * Output is not 1/len normalized. Scaling currently unsupported.
45
+ * The stride parameter must be set to the size of a single sample in bytes.
46
+ */
47
+ AV_TX_FLOAT_FFT = 0,
48
+ AV_TX_DOUBLE_FFT = 2,
49
+ AV_TX_INT32_FFT = 4,
50
+
51
+ /**
52
+ * Standard MDCT with a sample data type of float, double or int32_t,
53
+ * respecively. For the float and int32 variants, the scale type is
54
+ * 'float', while for the double variant, it's 'double'.
55
+ * If scale is NULL, 1.0 will be used as a default.
56
+ *
57
+ * Length is the frame size, not the window size (which is 2x frame).
58
+ * For forward transforms, the stride specifies the spacing between each
59
+ * sample in the output array in bytes. The input must be a flat array.
60
+ *
61
+ * For inverse transforms, the stride specifies the spacing between each
62
+ * sample in the input array in bytes. The output must be a flat array.
63
+ *
64
+ * NOTE: the inverse transform is half-length, meaning the output will not
65
+ * contain redundant data. This is what most codecs work with. To do a full
66
+ * inverse transform, set the AV_TX_FULL_IMDCT flag on init.
67
+ */
68
+ AV_TX_FLOAT_MDCT = 1,
69
+ AV_TX_DOUBLE_MDCT = 3,
70
+ AV_TX_INT32_MDCT = 5,
71
+
72
+ /**
73
+ * Real to complex and complex to real DFTs.
74
+ * For the float and int32 variants, the scale type is 'float', while for
75
+ * the double variant, it's a 'double'. If scale is NULL, 1.0 will be used
76
+ * as a default.
77
+ *
78
+ * For forward transforms (R2C), stride must be the spacing between two
79
+ * samples in bytes. For inverse transforms, the stride must be set
80
+ * to the spacing between two complex values in bytes.
81
+ *
82
+ * The forward transform performs a real-to-complex DFT of N samples to
83
+ * N/2+1 complex values.
84
+ *
85
+ * The inverse transform performs a complex-to-real DFT of N/2+1 complex
86
+ * values to N real samples. The output is not normalized, but can be
87
+ * made so by setting the scale value to 1.0/len.
88
+ * NOTE: the inverse transform always overwrites the input.
89
+ */
90
+ AV_TX_FLOAT_RDFT = 6,
91
+ AV_TX_DOUBLE_RDFT = 7,
92
+ AV_TX_INT32_RDFT = 8,
93
+
94
+ /**
95
+ * Real to real (DCT) transforms.
96
+ *
97
+ * The forward transform is a DCT-II.
98
+ * The inverse transform is a DCT-III.
99
+ *
100
+ * The input array is always overwritten. DCT-III requires that the
101
+ * input be padded with 2 extra samples. Stride must be set to the
102
+ * spacing between two samples in bytes.
103
+ */
104
+ AV_TX_FLOAT_DCT = 9,
105
+ AV_TX_DOUBLE_DCT = 10,
106
+ AV_TX_INT32_DCT = 11,
107
+
108
+ /**
109
+ * Discrete Cosine Transform I
110
+ *
111
+ * The forward transform is a DCT-I.
112
+ * The inverse transform is a DCT-I multiplied by 2/(N + 1).
113
+ *
114
+ * The input array is always overwritten.
115
+ */
116
+ AV_TX_FLOAT_DCT_I = 12,
117
+ AV_TX_DOUBLE_DCT_I = 13,
118
+ AV_TX_INT32_DCT_I = 14,
119
+
120
+ /**
121
+ * Discrete Sine Transform I
122
+ *
123
+ * The forward transform is a DST-I.
124
+ * The inverse transform is a DST-I multiplied by 2/(N + 1).
125
+ *
126
+ * The input array is always overwritten.
127
+ */
128
+ AV_TX_FLOAT_DST_I = 15,
129
+ AV_TX_DOUBLE_DST_I = 16,
130
+ AV_TX_INT32_DST_I = 17,
131
+
132
+ /* Not part of the API, do not use */
133
+ AV_TX_NB,
134
+ };
135
+
136
+ /**
137
+ * Function pointer to a function to perform the transform.
138
+ *
139
+ * @note Using a different context than the one allocated during av_tx_init()
140
+ * is not allowed.
141
+ *
142
+ * @param s the transform context
143
+ * @param out the output array
144
+ * @param in the input array
145
+ * @param stride the input or output stride in bytes
146
+ *
147
+ * The out and in arrays must be aligned to the maximum required by the CPU
148
+ * architecture unless the AV_TX_UNALIGNED flag was set in av_tx_init().
149
+ * The stride must follow the constraints the transform type has specified.
150
+ */
151
+ typedef void (*av_tx_fn)(AVTXContext *s, void *out, void *in, ptrdiff_t stride);
152
+
153
+ /**
154
+ * Flags for av_tx_init()
155
+ */
156
+ enum AVTXFlags {
157
+ /**
158
+ * Allows for in-place transformations, where input == output.
159
+ * May be unsupported or slower for some transform types.
160
+ */
161
+ AV_TX_INPLACE = 1ULL << 0,
162
+
163
+ /**
164
+ * Relaxes alignment requirement for the in and out arrays of av_tx_fn().
165
+ * May be slower with certain transform types.
166
+ */
167
+ AV_TX_UNALIGNED = 1ULL << 1,
168
+
169
+ /**
170
+ * Performs a full inverse MDCT rather than leaving out samples that can be
171
+ * derived through symmetry. Requires an output array of 'len' floats,
172
+ * rather than the usual 'len/2' floats.
173
+ * Ignored for all transforms but inverse MDCTs.
174
+ */
175
+ AV_TX_FULL_IMDCT = 1ULL << 2,
176
+
177
+ /**
178
+ * Perform a real to half-complex RDFT.
179
+ * Only the real, or imaginary coefficients will
180
+ * be output, depending on the flag used. Only available for forward RDFTs.
181
+ * Output array must have enough space to hold N complex values
182
+ * (regular size for a real to complex transform).
183
+ */
184
+ AV_TX_REAL_TO_REAL = 1ULL << 3,
185
+ AV_TX_REAL_TO_IMAGINARY = 1ULL << 4,
186
+ };
187
+
188
+ /**
189
+ * Initialize a transform context with the given configuration
190
+ * (i)MDCTs with an odd length are currently not supported.
191
+ *
192
+ * @param ctx the context to allocate, will be NULL on error
193
+ * @param tx pointer to the transform function pointer to set
194
+ * @param type type the type of transform
195
+ * @param inv whether to do an inverse or a forward transform
196
+ * @param len the size of the transform in samples
197
+ * @param scale pointer to the value to scale the output if supported by type
198
+ * @param flags a bitmask of AVTXFlags or 0
199
+ *
200
+ * @return 0 on success, negative error code on failure
201
+ */
202
+ int av_tx_init(AVTXContext **ctx, av_tx_fn *tx, enum AVTXType type,
203
+ int inv, int len, const void *scale, uint64_t flags);
204
+
205
+ /**
206
+ * Frees a context and sets *ctx to NULL, does nothing when *ctx == NULL.
207
+ */
208
+ void av_tx_uninit(AVTXContext **ctx);
209
+
210
+ #endif /* AVUTIL_TX_H */
@@ -0,0 +1,146 @@
1
+ /*
2
+ * Copyright (c) 2022 Pierre-Anthony Lemieux <pal@palemieux.com>
3
+ * Zane van Iperen <zane@zanevaniperen.com>
4
+ *
5
+ * This file is part of FFmpeg.
6
+ *
7
+ * FFmpeg is free software; you can redistribute it and/or
8
+ * modify it under the terms of the GNU Lesser General Public
9
+ * License as published by the Free Software Foundation; either
10
+ * version 2.1 of the License, or (at your option) any later version.
11
+ *
12
+ * FFmpeg is distributed in the hope that it will be useful,
13
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15
+ * Lesser General Public License for more details.
16
+ *
17
+ * You should have received a copy of the GNU Lesser General Public
18
+ * License along with FFmpeg; if not, write to the Free Software
19
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
+ */
21
+
22
+ /**
23
+ * @file
24
+ * UUID parsing and serialization utilities.
25
+ * The library treats the UUID as an opaque sequence of 16 unsigned bytes,
26
+ * i.e. ignoring the internal layout of the UUID, which depends on the type
27
+ * of the UUID.
28
+ *
29
+ * @author Pierre-Anthony Lemieux <pal@palemieux.com>
30
+ * @author Zane van Iperen <zane@zanevaniperen.com>
31
+ */
32
+
33
+ #ifndef AVUTIL_UUID_H
34
+ #define AVUTIL_UUID_H
35
+
36
+ #include <stdint.h>
37
+ #include <string.h>
38
+
39
+ #define AV_PRI_UUID \
40
+ "%02hhx%02hhx%02hhx%02hhx-%02hhx%02hhx-" \
41
+ "%02hhx%02hhx-%02hhx%02hhx-%02hhx%02hhx%02hhx%02hhx%02hhx%02hhx"
42
+
43
+ #define AV_PRI_URN_UUID \
44
+ "urn:uuid:%02hhx%02hhx%02hhx%02hhx-%02hhx%02hhx-" \
45
+ "%02hhx%02hhx-%02hhx%02hhx-%02hhx%02hhx%02hhx%02hhx%02hhx%02hhx"
46
+
47
+ /* AV_UUID_ARG() is used together with AV_PRI_UUID() or AV_PRI_URN_UUID
48
+ * to print UUIDs, e.g.
49
+ * av_log(NULL, AV_LOG_DEBUG, "UUID: " AV_PRI_UUID, AV_UUID_ARG(uuid));
50
+ */
51
+ #define AV_UUID_ARG(x) \
52
+ (x)[ 0], (x)[ 1], (x)[ 2], (x)[ 3], \
53
+ (x)[ 4], (x)[ 5], (x)[ 6], (x)[ 7], \
54
+ (x)[ 8], (x)[ 9], (x)[10], (x)[11], \
55
+ (x)[12], (x)[13], (x)[14], (x)[15]
56
+
57
+ #define AV_UUID_LEN 16
58
+
59
+ /* Binary representation of a UUID */
60
+ typedef uint8_t AVUUID[AV_UUID_LEN];
61
+
62
+ /**
63
+ * Parses a string representation of a UUID formatted according to IETF RFC 4122
64
+ * into an AVUUID. The parsing is case-insensitive. The string must be 37
65
+ * characters long, including the terminating NUL character.
66
+ *
67
+ * Example string representation: "2fceebd0-7017-433d-bafb-d073a7116696"
68
+ *
69
+ * @param[in] in String representation of a UUID,
70
+ * e.g. 2fceebd0-7017-433d-bafb-d073a7116696
71
+ * @param[out] uu AVUUID
72
+ * @return A non-zero value in case of an error.
73
+ */
74
+ int av_uuid_parse(const char *in, AVUUID uu);
75
+
76
+ /**
77
+ * Parses a URN representation of a UUID, as specified at IETF RFC 4122,
78
+ * into an AVUUID. The parsing is case-insensitive. The string must be 46
79
+ * characters long, including the terminating NUL character.
80
+ *
81
+ * Example string representation: "urn:uuid:2fceebd0-7017-433d-bafb-d073a7116696"
82
+ *
83
+ * @param[in] in URN UUID
84
+ * @param[out] uu AVUUID
85
+ * @return A non-zero value in case of an error.
86
+ */
87
+ int av_uuid_urn_parse(const char *in, AVUUID uu);
88
+
89
+ /**
90
+ * Parses a string representation of a UUID formatted according to IETF RFC 4122
91
+ * into an AVUUID. The parsing is case-insensitive.
92
+ *
93
+ * @param[in] in_start Pointer to the first character of the string representation
94
+ * @param[in] in_end Pointer to the character after the last character of the
95
+ * string representation. That memory location is never
96
+ * accessed. It is an error if `in_end - in_start != 36`.
97
+ * @param[out] uu AVUUID
98
+ * @return A non-zero value in case of an error.
99
+ */
100
+ int av_uuid_parse_range(const char *in_start, const char *in_end, AVUUID uu);
101
+
102
+ /**
103
+ * Serializes a AVUUID into a string representation according to IETF RFC 4122.
104
+ * The string is lowercase and always 37 characters long, including the
105
+ * terminating NUL character.
106
+ *
107
+ * @param[in] uu AVUUID
108
+ * @param[out] out Pointer to an array of no less than 37 characters.
109
+ */
110
+ void av_uuid_unparse(const AVUUID uu, char *out);
111
+
112
+ /**
113
+ * Compares two UUIDs for equality.
114
+ *
115
+ * @param[in] uu1 AVUUID
116
+ * @param[in] uu2 AVUUID
117
+ * @return Nonzero if uu1 and uu2 are identical, 0 otherwise
118
+ */
119
+ static inline int av_uuid_equal(const AVUUID uu1, const AVUUID uu2)
120
+ {
121
+ return memcmp(uu1, uu2, AV_UUID_LEN) == 0;
122
+ }
123
+
124
+ /**
125
+ * Copies the bytes of src into dest.
126
+ *
127
+ * @param[out] dest AVUUID
128
+ * @param[in] src AVUUID
129
+ */
130
+ static inline void av_uuid_copy(AVUUID dest, const AVUUID src)
131
+ {
132
+ memcpy(dest, src, AV_UUID_LEN);
133
+ }
134
+
135
+ /**
136
+ * Sets a UUID to the nil UUID, i.e. a UUID with have all
137
+ * its 128 bits set to zero.
138
+ *
139
+ * @param[in,out] uu UUID to be set to the nil UUID
140
+ */
141
+ static inline void av_uuid_nil(AVUUID uu)
142
+ {
143
+ memset(uu, 0, AV_UUID_LEN);
144
+ }
145
+
146
+ #endif /* AVUTIL_UUID_H */
@@ -0,0 +1,119 @@
1
+ /*
2
+ * copyright (c) 2003 Fabrice Bellard
3
+ *
4
+ * This file is part of FFmpeg.
5
+ *
6
+ * FFmpeg is free software; you can redistribute it and/or
7
+ * modify it under the terms of the GNU Lesser General Public
8
+ * License as published by the Free Software Foundation; either
9
+ * version 2.1 of the License, or (at your option) any later version.
10
+ *
11
+ * FFmpeg is distributed in the hope that it will be useful,
12
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
13
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14
+ * Lesser General Public License for more details.
15
+ *
16
+ * You should have received a copy of the GNU Lesser General Public
17
+ * License along with FFmpeg; if not, write to the Free Software
18
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19
+ */
20
+
21
+ /**
22
+ * @file
23
+ * @ingroup lavu
24
+ * Libavutil version macros
25
+ */
26
+
27
+ #ifndef AVUTIL_VERSION_H
28
+ #define AVUTIL_VERSION_H
29
+
30
+ #include "macros.h"
31
+
32
+ /**
33
+ * @addtogroup version_utils
34
+ *
35
+ * Useful to check and match library version in order to maintain
36
+ * backward compatibility.
37
+ *
38
+ * The FFmpeg libraries follow a versioning sheme very similar to
39
+ * Semantic Versioning (http://semver.org/)
40
+ * The difference is that the component called PATCH is called MICRO in FFmpeg
41
+ * and its value is reset to 100 instead of 0 to keep it above or equal to 100.
42
+ * Also we do not increase MICRO for every bugfix or change in git master.
43
+ *
44
+ * Prior to FFmpeg 3.2 point releases did not change any lib version number to
45
+ * avoid aliassing different git master checkouts.
46
+ * Starting with FFmpeg 3.2, the released library versions will occupy
47
+ * a separate MAJOR.MINOR that is not used on the master development branch.
48
+ * That is if we branch a release of master 55.10.123 we will bump to 55.11.100
49
+ * for the release and master will continue at 55.12.100 after it. Each new
50
+ * point release will then bump the MICRO improving the usefulness of the lib
51
+ * versions.
52
+ *
53
+ * @{
54
+ */
55
+
56
+ #define AV_VERSION_INT(a, b, c) ((a)<<16 | (b)<<8 | (c))
57
+ #define AV_VERSION_DOT(a, b, c) a ##.## b ##.## c
58
+ #define AV_VERSION(a, b, c) AV_VERSION_DOT(a, b, c)
59
+
60
+ /**
61
+ * Extract version components from the full ::AV_VERSION_INT int as returned
62
+ * by functions like ::avformat_version() and ::avcodec_version()
63
+ */
64
+ #define AV_VERSION_MAJOR(a) ((a) >> 16)
65
+ #define AV_VERSION_MINOR(a) (((a) & 0x00FF00) >> 8)
66
+ #define AV_VERSION_MICRO(a) ((a) & 0xFF)
67
+
68
+ /**
69
+ * @}
70
+ */
71
+
72
+ /**
73
+ * @defgroup lavu_ver Version and Build diagnostics
74
+ *
75
+ * Macros and function useful to check at compiletime and at runtime
76
+ * which version of libavutil is in use.
77
+ *
78
+ * @{
79
+ */
80
+
81
+ #define LIBAVUTIL_VERSION_MAJOR 60
82
+ #define LIBAVUTIL_VERSION_MINOR 6
83
+ #define LIBAVUTIL_VERSION_MICRO 100
84
+
85
+ #define LIBAVUTIL_VERSION_INT AV_VERSION_INT(LIBAVUTIL_VERSION_MAJOR, \
86
+ LIBAVUTIL_VERSION_MINOR, \
87
+ LIBAVUTIL_VERSION_MICRO)
88
+ #define LIBAVUTIL_VERSION AV_VERSION(LIBAVUTIL_VERSION_MAJOR, \
89
+ LIBAVUTIL_VERSION_MINOR, \
90
+ LIBAVUTIL_VERSION_MICRO)
91
+ #define LIBAVUTIL_BUILD LIBAVUTIL_VERSION_INT
92
+
93
+ #define LIBAVUTIL_IDENT "Lavu" AV_STRINGIFY(LIBAVUTIL_VERSION)
94
+
95
+ /**
96
+ * @defgroup lavu_depr_guards Deprecation Guards
97
+ * FF_API_* defines may be placed below to indicate public API that will be
98
+ * dropped at a future version bump. The defines themselves are not part of
99
+ * the public API and may change, break or disappear at any time.
100
+ *
101
+ * @note, when bumping the major version it is recommended to manually
102
+ * disable each FF_API_* in its own commit instead of disabling them all
103
+ * at once through the bump. This improves the git bisect-ability of the change.
104
+ *
105
+ * @{
106
+ */
107
+
108
+ #define FF_API_MOD_UINTP2 (LIBAVUTIL_VERSION_MAJOR < 61)
109
+ #define FF_API_RISCV_FD_ZBA (LIBAVUTIL_VERSION_MAJOR < 61)
110
+ #define FF_API_VULKAN_FIXED_QUEUES (LIBAVUTIL_VERSION_MAJOR < 61)
111
+ #define FF_API_OPT_INT_LIST (LIBAVUTIL_VERSION_MAJOR < 61)
112
+ #define FF_API_OPT_PTR (LIBAVUTIL_VERSION_MAJOR < 61)
113
+
114
+ /**
115
+ * @}
116
+ * @}
117
+ */
118
+
119
+ #endif /* AVUTIL_VERSION_H */