mirror of https://git.ffmpeg.org/ffmpeg.git
avcodec/tak: Use void* instead of AVCodecContext* for logcontext
Avoids implicit inclusions of avcodec.h in lavf/takdec.c and lavc/tak.c. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
00597af58b
commit
befb7e7d79
|
@ -144,11 +144,11 @@ int avpriv_tak_parse_streaminfo(TAKStreamInfo *s, const uint8_t *buf, int size)
|
||||||
return tak_parse_streaminfo(s, &gb);
|
return tak_parse_streaminfo(s, &gb);
|
||||||
}
|
}
|
||||||
|
|
||||||
int ff_tak_decode_frame_header(AVCodecContext *avctx, GetBitContext *gb,
|
int ff_tak_decode_frame_header(void *logctx, GetBitContext *gb,
|
||||||
TAKStreamInfo *ti, int log_level_offset)
|
TAKStreamInfo *ti, int log_level_offset)
|
||||||
{
|
{
|
||||||
if (get_bits(gb, TAK_FRAME_HEADER_SYNC_ID_BITS) != TAK_FRAME_HEADER_SYNC_ID) {
|
if (get_bits(gb, TAK_FRAME_HEADER_SYNC_ID_BITS) != TAK_FRAME_HEADER_SYNC_ID) {
|
||||||
av_log(avctx, AV_LOG_ERROR + log_level_offset, "missing sync id\n");
|
av_log(logctx, AV_LOG_ERROR + log_level_offset, "missing sync id\n");
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,6 @@
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
#include "avcodec.h"
|
|
||||||
#include "get_bits.h"
|
#include "get_bits.h"
|
||||||
|
|
||||||
#define TAK_FORMAT_DATA_TYPE_BITS 3
|
#define TAK_FORMAT_DATA_TYPE_BITS 3
|
||||||
|
@ -151,13 +150,13 @@ int avpriv_tak_parse_streaminfo(TAKStreamInfo *s, const uint8_t *buf, int size);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Validate and decode a frame header.
|
* Validate and decode a frame header.
|
||||||
* @param avctx AVCodecContext to use as av_log() context
|
* @param logctx for use as av_log() context
|
||||||
* @param[in] gb GetBitContext from which to read frame header
|
* @param[in] gb GetBitContext from which to read frame header
|
||||||
* @param[out] s frame information
|
* @param[out] s frame information
|
||||||
* @param log_level_offset log level offset, can be used to silence
|
* @param log_level_offset log level offset, can be used to silence
|
||||||
* error messages.
|
* error messages.
|
||||||
* @return non-zero on error, 0 if OK
|
* @return non-zero on error, 0 if OK
|
||||||
*/
|
*/
|
||||||
int ff_tak_decode_frame_header(AVCodecContext *avctx, GetBitContext *gb,
|
int ff_tak_decode_frame_header(void *logctx, GetBitContext *gb,
|
||||||
TAKStreamInfo *s, int log_level_offset);
|
TAKStreamInfo *s, int log_level_offset);
|
||||||
#endif /* AVCODEC_TAK_H */
|
#endif /* AVCODEC_TAK_H */
|
||||||
|
|
Loading…
Reference in New Issue