[FFmpeg-cvslog] avcodec/hevc_cabac: Don't cast const away unnecessarily

Andreas Rheinhardt git at videolan.org
Sat Jul 9 21:41:42 EEST 2022


ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Wed Jun 29 17:04:35 2022 +0200| [8393c0721a76d72ec73935ce58934c0ae40774e5] | committer: Andreas Rheinhardt

avcodec/hevc_cabac: Don't cast const away unnecessarily

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>

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

 libavcodec/hevc_cabac.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/libavcodec/hevc_cabac.c b/libavcodec/hevc_cabac.c
index 9b8c8e342d..a194f8a02a 100644
--- a/libavcodec/hevc_cabac.c
+++ b/libavcodec/hevc_cabac.c
@@ -1282,7 +1282,7 @@ void ff_hevc_hls_residual_coding(HEVCContext *s, int x0, int y0,
             int scf_offset = 0;
             if (s->ps.sps->transform_skip_context_enabled_flag &&
                 (transform_skip_flag || lc->cu.cu_transquant_bypass_flag)) {
-                ctx_idx_map_p = (uint8_t*) &ctx_idx_map[4 * 16];
+                ctx_idx_map_p = &ctx_idx_map[4 * 16];
                 if (c_idx == 0) {
                     scf_offset = 40;
                 } else {
@@ -1292,9 +1292,9 @@ void ff_hevc_hls_residual_coding(HEVCContext *s, int x0, int y0,
                 if (c_idx != 0)
                     scf_offset = 27;
                 if (log2_trafo_size == 2) {
-                    ctx_idx_map_p = (uint8_t*) &ctx_idx_map[0];
+                    ctx_idx_map_p = &ctx_idx_map[0];
                 } else {
-                    ctx_idx_map_p = (uint8_t*) &ctx_idx_map[(prev_sig + 1) << 4];
+                    ctx_idx_map_p = &ctx_idx_map[(prev_sig + 1) << 4];
                     if (c_idx == 0) {
                         if ((x_cg > 0 || y_cg > 0))
                             scf_offset += 3;



More information about the ffmpeg-cvslog mailing list