ffmpeg | branch: master | Lynne <d...@lynne.ee> | Tue May 27 06:32:55 2025 
+0900| [c395ad7c2cdc18dea2b604e7471643b20fb2716e] | committer: Lynne

vulkan_ffv1: small cleanup for golomb

Split up computation of the offset in the same way that
the range coder version does it.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c395ad7c2cdc18dea2b604e7471643b20fb2716e
---

 libavcodec/vulkan/ffv1_dec.comp | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/libavcodec/vulkan/ffv1_dec.comp b/libavcodec/vulkan/ffv1_dec.comp
index a90bac321b..f78a86b059 100644
--- a/libavcodec/vulkan/ffv1_dec.comp
+++ b/libavcodec/vulkan/ffv1_dec.comp
@@ -139,7 +139,8 @@ void decode_line(inout SliceContext sc, ivec2 sp, int w,
         ivec2 pr = get_pred(dec[p], sp, ivec2(x, y), 0, w,
                             quant_table_idx, extend_lookup[quant_table_idx] > 
0);
 
-        VlcState sb = VlcState(uint64_t(slice_state) + state_off + 
VLC_STATE_SIZE*abs(pr[0]));
+        uint context_off = state_off + VLC_STATE_SIZE*abs(pr[0]);
+        VlcState sb = VlcState(uint64_t(slice_state) + context_off);
 
         if (pr[0] == 0 && run_mode == 0)
             run_mode = 1;

_______________________________________________
ffmpeg-cvslog mailing list
ffmpeg-cvslog@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog

To unsubscribe, visit link above, or email
ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to