Showing the changes to libavcodec (2 of 2 files). Show all
Unified · Split
| @@ -457,7 +457,7 @@ static uint8_t *bgmc_lut_getp(uint8_t *lut, int *lut_status, int delta) · 456 unmodified lines | |||
| 457 | 457 | ||
| 458 | 458 | ||
| 459 | /** Initialize the lookup table arrays */ | 459 | /** Initialize the lookup table arrays */ |
| 460 | av_cold int ff_bgmc_init(AVCodecContext *avctx, | 460 | av_cold int ff_bgmc_init(void *logctx, |
| 461 | uint8_t **cf_lut, int **cf_lut_status) | 461 | uint8_t **cf_lut, int **cf_lut_status) |
| 462 | { | 462 | { |
| 463 | *cf_lut = av_malloc(sizeof(**cf_lut) * LUT_BUFF * 16 * LUT_SIZE); | 463 | *cf_lut = av_malloc(sizeof(**cf_lut) * LUT_BUFF * 16 * LUT_SIZE); |
| @@ -465,7 +465,7 @@ av_cold int ff_bgmc_init(AVCodecContext *avctx, · 1 unmodified line | |||
| 465 | 465 | ||
| 466 | if (!*cf_lut || !*cf_lut_status) { | 466 | if (!*cf_lut || !*cf_lut_status) { |
| 467 | ff_bgmc_end(cf_lut, cf_lut_status); | 467 | ff_bgmc_end(cf_lut, cf_lut_status); |
| 468 | av_log(avctx, AV_LOG_ERROR, "Allocating buffer memory failed.\n"); | 468 | av_log(logctx, AV_LOG_ERROR, "Allocating buffer memory failed.\n"); |
| 469 | return AVERROR(ENOMEM); | 469 | return AVERROR(ENOMEM); |
| 470 | } else { | 470 | } else { |
| 471 | // initialize lut_status buffer to a value never used to compare against | 471 | // initialize lut_status buffer to a value never used to compare against |
| @@ -30,11 +30,10 @@ · 29 unmodified lines | |||
| 30 | #define AVCODEC_BGMC_H | 30 | #define AVCODEC_BGMC_H |
| 31 | 31 | ||
| 32 | 32 | ||
| 33 | #include "avcodec.h" | ||
| 34 | #include "get_bits.h" | 33 | #include "get_bits.h" |
| 35 | 34 | ||
| 36 | 35 | ||
| 37 | int ff_bgmc_init(AVCodecContext *avctx, uint8_t **cf_lut, int **cf_lut_status); | 36 | int ff_bgmc_init(void *logctx, uint8_t **cf_lut, int **cf_lut_status); |
| 38 | 37 | ||
| 39 | 38 | ||
| 40 | void ff_bgmc_end(uint8_t **cf_lut, int **cf_lut_status); | 39 | void ff_bgmc_end(uint8_t **cf_lut, int **cf_lut_status); |