aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2023-08-08 10:52:44 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2023-08-10 23:56:35 +0200
commita08ff2805982bcf5128c396314f6424c5e1a250a (patch)
tree15f8ef517a97607c184de5bc8350892a4f87ce26
parent3b75375c9c4175e760a998e3d3619bb5883e90ac (diff)
downloadffmpeg-a08ff2805982bcf5128c396314f6424c5e1a250a.tar.gz
avformat/dovi_isom: Don't use AVFormatContext* for logctx
Pass it as void* instead. While just at it, also constify the pointee of AVDOVIDecoderConfigurationRecord* in ff_isom_put_dvcc_dvvc(). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
-rw-r--r--libavformat/dovi_isom.c12
-rw-r--r--libavformat/dovi_isom.h7
2 files changed, 11 insertions, 8 deletions
diff --git a/libavformat/dovi_isom.c b/libavformat/dovi_isom.c
index 76681b9451..c8fdf566e4 100644
--- a/libavformat/dovi_isom.c
+++ b/libavformat/dovi_isom.c
@@ -28,7 +28,8 @@
#include "avformat.h"
#include "dovi_isom.h"
-int ff_isom_parse_dvcc_dvvc(AVFormatContext *s, AVStream *st, const uint8_t *buf_ptr, uint64_t size)
+int ff_isom_parse_dvcc_dvvc(void *logctx, AVStream *st,
+ const uint8_t *buf_ptr, uint64_t size)
{
uint32_t buf;
AVDOVIDecoderConfigurationRecord *dovi;
@@ -70,7 +71,7 @@ int ff_isom_parse_dvcc_dvvc(AVFormatContext *s, AVStream *st, const uint8_t *buf
return ret;
}
- av_log(s, AV_LOG_TRACE, "DOVI in dvcC/dvvC/dvwC box, version: %d.%d, profile: %d, level: %d, "
+ av_log(logctx, AV_LOG_TRACE, "DOVI in dvcC/dvvC/dvwC box, version: %d.%d, profile: %d, level: %d, "
"rpu flag: %d, el flag: %d, bl flag: %d, compatibility id: %d\n",
dovi->dv_version_major, dovi->dv_version_minor,
dovi->dv_profile, dovi->dv_level,
@@ -82,8 +83,8 @@ int ff_isom_parse_dvcc_dvvc(AVFormatContext *s, AVStream *st, const uint8_t *buf
return 0;
}
-void ff_isom_put_dvcc_dvvc(AVFormatContext *s, uint8_t out[ISOM_DVCC_DVVC_SIZE],
- AVDOVIDecoderConfigurationRecord *dovi)
+void ff_isom_put_dvcc_dvvc(void *logctx, uint8_t out[ISOM_DVCC_DVVC_SIZE],
+ const AVDOVIDecoderConfigurationRecord *dovi)
{
PutBitContext pb;
@@ -106,7 +107,8 @@ void ff_isom_put_dvcc_dvvc(AVFormatContext *s, uint8_t out[ISOM_DVCC_DVVC_SIZE],
flush_put_bits(&pb);
- av_log(s, AV_LOG_DEBUG, "DOVI in %s box, version: %d.%d, profile: %d, level: %d, "
+ av_log(logctx, AV_LOG_DEBUG,
+ "DOVI in %s box, version: %d.%d, profile: %d, level: %d, "
"rpu flag: %d, el flag: %d, bl flag: %d, compatibility id: %d\n",
dovi->dv_profile > 10 ? "dvwC" : (dovi->dv_profile > 7 ? "dvvC" : "dvcC"),
dovi->dv_version_major, dovi->dv_version_minor,
diff --git a/libavformat/dovi_isom.h b/libavformat/dovi_isom.h
index 1526164319..1221a52793 100644
--- a/libavformat/dovi_isom.h
+++ b/libavformat/dovi_isom.h
@@ -28,8 +28,9 @@
#define ISOM_DVCC_DVVC_SIZE 24
-int ff_isom_parse_dvcc_dvvc(AVFormatContext *s, AVStream *st, const uint8_t *buf_ptr, uint64_t size);
-void ff_isom_put_dvcc_dvvc(AVFormatContext *s, uint8_t out[ISOM_DVCC_DVVC_SIZE],
- AVDOVIDecoderConfigurationRecord *dovi);
+int ff_isom_parse_dvcc_dvvc(void *logctx, AVStream *st,
+ const uint8_t *buf_ptr, uint64_t size);
+void ff_isom_put_dvcc_dvvc(void *logctx, uint8_t out[ISOM_DVCC_DVVC_SIZE],
+ const AVDOVIDecoderConfigurationRecord *dovi);
#endif /* AVFORMAT_DOVI_ISOM_H */