diff mbox series

[FFmpeg-devel] avcodec/aaccoder_twoloop: remove unread max scaler

Message ID 20240614102114.981720-1-yotam.ofek@gmail.com
State New
Headers show
Series [FFmpeg-devel] avcodec/aaccoder_twoloop: remove unread max scaler | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Yotam Ofek June 14, 2024, 10:21 a.m. UTC
---
 libavcodec/aaccoder_twoloop.h | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Yotam Ofek July 2, 2024, 8:36 p.m. UTC | #1
Bump :)

On Fri, Jun 14, 2024, 13:21 Yotam Ofek <yotam.ofek@gmail.com> wrote:

> ---
>  libavcodec/aaccoder_twoloop.h | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/libavcodec/aaccoder_twoloop.h b/libavcodec/aaccoder_twoloop.h
> index c1dcdbb5ed..c56abc68a7 100644
> --- a/libavcodec/aaccoder_twoloop.h
> +++ b/libavcodec/aaccoder_twoloop.h
> @@ -101,7 +101,7 @@ static void
> search_for_quantizers_twoloop(AVCodecContext *avctx,
>       */
>      float sfoffs = av_clipf(log2f(120.0f / lambda) * 4.0f, -5, 10);
>
> -    int fflag, minscaler, maxscaler, nminscaler;
> +    int fflag, minscaler, nminscaler;
>      int its  = 0;
>      int maxits = 30;
>      int allz = 0;
> @@ -572,12 +572,10 @@ static void
> search_for_quantizers_twoloop(AVCodecContext *avctx,
>          }
>
>          minscaler = SCALE_MAX_POS;
> -        maxscaler = 0;
>          for (w = 0; w < sce->ics.num_windows; w += sce->ics.group_len[w])
> {
>              for (g = 0;  g < sce->ics.num_swb; g++) {
>                  if (!sce->zeroes[w*16+g]) {
>                      minscaler = FFMIN(minscaler, sce->sf_idx[w*16+g]);
> -                    maxscaler = FFMAX(maxscaler, sce->sf_idx[w*16+g]);
>                  }
>              }
>          }
> --
> 2.40.1
>
>
Lynne July 3, 2024, 12:52 a.m. UTC | #2
On 14/06/2024 12:21, Yotam Ofek wrote:
> ---
>   libavcodec/aaccoder_twoloop.h | 4 +---
>   1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/libavcodec/aaccoder_twoloop.h b/libavcodec/aaccoder_twoloop.h
> index c1dcdbb5ed..c56abc68a7 100644
> --- a/libavcodec/aaccoder_twoloop.h
> +++ b/libavcodec/aaccoder_twoloop.h
> @@ -101,7 +101,7 @@ static void search_for_quantizers_twoloop(AVCodecContext *avctx,
>        */
>       float sfoffs = av_clipf(log2f(120.0f / lambda) * 4.0f, -5, 10);
>   
> -    int fflag, minscaler, maxscaler, nminscaler;
> +    int fflag, minscaler, nminscaler;
>       int its  = 0;
>       int maxits = 30;
>       int allz = 0;
> @@ -572,12 +572,10 @@ static void search_for_quantizers_twoloop(AVCodecContext *avctx,
>           }
>   
>           minscaler = SCALE_MAX_POS;
> -        maxscaler = 0;
>           for (w = 0; w < sce->ics.num_windows; w += sce->ics.group_len[w]) {
>               for (g = 0;  g < sce->ics.num_swb; g++) {
>                   if (!sce->zeroes[w*16+g]) {
>                       minscaler = FFMIN(minscaler, sce->sf_idx[w*16+g]);
> -                    maxscaler = FFMAX(maxscaler, sce->sf_idx[w*16+g]);
>                   }
>               }
>           }

Thanks, pushed both patches.
diff mbox series

Patch

diff --git a/libavcodec/aaccoder_twoloop.h b/libavcodec/aaccoder_twoloop.h
index c1dcdbb5ed..c56abc68a7 100644
--- a/libavcodec/aaccoder_twoloop.h
+++ b/libavcodec/aaccoder_twoloop.h
@@ -101,7 +101,7 @@  static void search_for_quantizers_twoloop(AVCodecContext *avctx,
      */
     float sfoffs = av_clipf(log2f(120.0f / lambda) * 4.0f, -5, 10);
 
-    int fflag, minscaler, maxscaler, nminscaler;
+    int fflag, minscaler, nminscaler;
     int its  = 0;
     int maxits = 30;
     int allz = 0;
@@ -572,12 +572,10 @@  static void search_for_quantizers_twoloop(AVCodecContext *avctx,
         }
 
         minscaler = SCALE_MAX_POS;
-        maxscaler = 0;
         for (w = 0; w < sce->ics.num_windows; w += sce->ics.group_len[w]) {
             for (g = 0;  g < sce->ics.num_swb; g++) {
                 if (!sce->zeroes[w*16+g]) {
                     minscaler = FFMIN(minscaler, sce->sf_idx[w*16+g]);
-                    maxscaler = FFMAX(maxscaler, sce->sf_idx[w*16+g]);
                 }
             }
         }