Commit cc715089 authored by Yushin Cho's avatar Yushin Cho Committed by Urvang Joshi
Browse files

Another fix for building pvq and palette together

Fixes that pack_palette_tokens() was disabled when pvq is enabled and
av1_decode_palette_tokens() was not complied.

Change-Id: I468bdc4d77ae7ddbca7fb5ed8e1da5506486a58c
parent 81760810
...@@ -9,15 +9,16 @@ ...@@ -9,15 +9,16 @@
* PATENTS file, you can obtain it at www.aomedia.org/license/patent. * PATENTS file, you can obtain it at www.aomedia.org/license/patent.
*/ */
#if !CONFIG_PVQ
#ifndef AV1_DECODER_DETOKENIZE_H_ #ifndef AV1_DECODER_DETOKENIZE_H_
#define AV1_DECODER_DETOKENIZE_H_ #define AV1_DECODER_DETOKENIZE_H_
#if !CONFIG_PVQ
#include "av1/decoder/decoder.h" #include "av1/decoder/decoder.h"
#if CONFIG_ANS #if CONFIG_ANS
#include "aom_dsp/ans.h" #include "aom_dsp/ans.h"
#endif // CONFIG_ANS #endif // CONFIG_ANS
#include "av1/common/scan.h" #include "av1/common/scan.h"
#endif // !CONFIG_PVQ
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
...@@ -27,13 +28,13 @@ extern "C" { ...@@ -27,13 +28,13 @@ extern "C" {
void av1_decode_palette_tokens(MACROBLOCKD *const xd, int plane, aom_reader *r); void av1_decode_palette_tokens(MACROBLOCKD *const xd, int plane, aom_reader *r);
#endif // CONFIG_PALETTE #endif // CONFIG_PALETTE
#if !CONFIG_PVQ
int av1_decode_block_tokens(MACROBLOCKD *const xd, int plane, int av1_decode_block_tokens(MACROBLOCKD *const xd, int plane,
const SCAN_ORDER *sc, int x, int y, TX_SIZE tx_size, const SCAN_ORDER *sc, int x, int y, TX_SIZE tx_size,
TX_TYPE tx_type, int16_t *max_scan_line, TX_TYPE tx_type, int16_t *max_scan_line,
aom_reader *r, int seg_id); aom_reader *r, int seg_id);
#endif // !CONFIG_PVQ
#ifdef __cplusplus #ifdef __cplusplus
} // extern "C" } // extern "C"
#endif #endif
#endif // AV1_DECODER_DETOKENIZE_H_ #endif // AV1_DECODER_DETOKENIZE_H_
#endif
...@@ -2065,7 +2065,6 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile, ...@@ -2065,7 +2065,6 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile,
adapt = &cpi->td.mb.daala_enc.state.adapt; adapt = &cpi->td.mb.daala_enc.state.adapt;
#endif #endif
#if !CONFIG_PVQ
#if CONFIG_PALETTE #if CONFIG_PALETTE
for (plane = 0; plane <= 1; ++plane) { for (plane = 0; plane <= 1; ++plane) {
const uint8_t palette_size_plane = const uint8_t palette_size_plane =
...@@ -2081,6 +2080,7 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile, ...@@ -2081,6 +2080,7 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile,
} }
#endif // CONFIG_PALETTE #endif // CONFIG_PALETTE
#if !CONFIG_PVQ
#if CONFIG_COEF_INTERLEAVE #if CONFIG_COEF_INTERLEAVE
if (!m->mbmi.skip) { if (!m->mbmi.skip) {
const struct macroblockd_plane *const pd_y = &xd->plane[0]; const struct macroblockd_plane *const pd_y = &xd->plane[0];
...@@ -2242,7 +2242,7 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile, ...@@ -2242,7 +2242,7 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile,
} }
} }
#endif // CONFIG_COEF_INTERLEAVE #endif // CONFIG_COEF_INTERLEAVE
#else #else // !CONFIG_PVQ
// PVQ writes its tokens (i.e. symbols) here. // PVQ writes its tokens (i.e. symbols) here.
if (!m->mbmi.skip) { if (!m->mbmi.skip) {
for (plane = 0; plane < MAX_MB_PLANE; ++plane) { for (plane = 0; plane < MAX_MB_PLANE; ++plane) {
...@@ -2320,7 +2320,7 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile, ...@@ -2320,7 +2320,7 @@ static void write_tokens_b(AV1_COMP *cpi, const TileInfo *const tile,
} // for (idy = 0; } // for (idy = 0;
} // for (plane = } // for (plane =
} // if (!m->mbmi.skip) } // if (!m->mbmi.skip)
#endif #endif // !CONFIG_PVQ
} }
#if CONFIG_MOTION_VAR && CONFIG_NCOBMC #if CONFIG_MOTION_VAR && CONFIG_NCOBMC
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment