avcodec/vorbis: Use void* logctx instead of AVCodecContext*

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
Andreas Rheinhardt 2023-09-28 21:01:34 +02:00
parent bdbf9aa402
commit 0e18f1e9a3
2 changed files with 6 additions and 6 deletions

View File

@ -27,8 +27,10 @@
*/
#include "libavutil/common.h"
#include "libavutil/error.h"
#include "libavutil/log.h"
#include "libavutil/macros.h"
#include "avcodec.h"
#include "vorbis.h"
#include "vorbis_data.h"
@ -104,7 +106,7 @@ int ff_vorbis_len2vlc(uint8_t *bits, uint32_t *codes, unsigned num)
return 0;
}
int ff_vorbis_ready_floor1_list(AVCodecContext *avctx,
int ff_vorbis_ready_floor1_list(void *logctx,
vorbis_floor1_entry *list, int values)
{
int i;
@ -130,7 +132,7 @@ int ff_vorbis_ready_floor1_list(AVCodecContext *avctx,
int j;
for (j = i + 1; j < values; j++) {
if (list[i].x == list[j].x) {
av_log(avctx, AV_LOG_ERROR,
av_log(logctx, AV_LOG_ERROR,
"Duplicate value found in floor 1 X coordinates\n");
return AVERROR_INVALIDDATA;
}

View File

@ -23,8 +23,6 @@
#include <stdint.h>
#include "avcodec.h"
typedef struct vorbis_floor1_entry {
uint16_t x;
uint16_t sort;
@ -32,7 +30,7 @@ typedef struct vorbis_floor1_entry {
uint16_t high;
} vorbis_floor1_entry;
int ff_vorbis_ready_floor1_list(AVCodecContext *avctx,
int ff_vorbis_ready_floor1_list(void *logctx,
vorbis_floor1_entry *list, int values);
unsigned int ff_vorbis_nth_root(unsigned int x, unsigned int n); // x^(1/n)
int ff_vorbis_len2vlc(uint8_t *bits, uint32_t *codes, unsigned num);