mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-05 14:30:00 +01:00
ffv1enc_vulkan: fix encoding with large contexts
When RGB_LINECACHE == 2, then top2 is not the current line.
This commit is contained in:
@@ -124,8 +124,12 @@ ivec2 get_pred(readonly uimage2D pred, ivec2 sp, ivec2 off,
|
|||||||
}
|
}
|
||||||
base += quant_table[quant_table_idx][3][(cur2 - cur) & MAX_QUANT_TABLE_MASK];
|
base += quant_table[quant_table_idx][3][(cur2 - cur) & MAX_QUANT_TABLE_MASK];
|
||||||
|
|
||||||
|
#if RGB_LINECACHE == 2
|
||||||
/* top-2 became current upon swap */
|
/* top-2 became current upon swap */
|
||||||
TYPE top2 = TYPE(imageLoad(pred, sp + LADDR(off))[comp]);
|
TYPE top2 = TYPE(imageLoad(pred, sp + LADDR(off))[comp]);
|
||||||
|
#else
|
||||||
|
TYPE top2 = TYPE(imageLoad(pred, sp + LADDR(off + ivec2(0, -2)))[comp]);
|
||||||
|
#endif
|
||||||
base += quant_table[quant_table_idx][4][(top2 - top[1]) & MAX_QUANT_TABLE_MASK];
|
base += quant_table[quant_table_idx][4][(top2 - top[1]) & MAX_QUANT_TABLE_MASK];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user