Commit 6d69ba0c authored by Jonathan Matthews's avatar Jonathan Matthews Committed by Urvang Joshi

Bugfix: decode_palette_tokens inverting stride and width.

Introduced in I745ca032f313c5041aacc98c03ae4bfc33d840de.
Stride should be plane_block_width and width should be cols,
 sanity check: cols <= plane_block_width.

Change-Id: Ic5128e94a909e498010c92fef2013da8df6d6d85
parent cda0b5e4
......@@ -329,7 +329,7 @@ void av1_decode_palette_tokens(MACROBLOCKD *const xd, int plane,
for (i = 0; i < rows; ++i) {
for (j = (i == 0 ? 1 : 0); j < cols; ++j) {
const int color_ctx = av1_get_palette_color_context(
color_map, plane_block_width, cols, i, j, n, color_order, NULL);
color_map, cols, plane_block_width, i, j, n, color_order, NULL);
const int color_idx = aom_read_tree(r, av1_palette_color_tree[n - 2],
prob[n - 2][color_ctx], ACCT_STR);
assert(color_idx >= 0 && color_idx < n);
......
Markdown is supported
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