diff mbox series

[FFmpeg-devel,06/11] avcodec/jpeg2000: Make ff_tag_tree_size() static

Message ID AM7PR03MB6660820379859A3D56AF36BB8FD29@AM7PR03MB6660.eurprd03.prod.outlook.com
State Accepted
Commit faa62773cb944726440f2b6ea721086beaa09375
Headers show
Series [FFmpeg-devel,01/11] avcodec/bsf: ff_list_bsf static | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished
andriy/make_ppc success Make finished
andriy/make_fate_ppc success Make fate finished

Commit Message

Andreas Rheinhardt Sept. 6, 2021, 12:42 p.m. UTC
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavcodec/jpeg2000.c | 8 ++++----
 libavcodec/jpeg2000.h | 1 -
 2 files changed, 4 insertions(+), 5 deletions(-)
diff mbox series

Patch

diff --git a/libavcodec/jpeg2000.c b/libavcodec/jpeg2000.c
index 324908d833..2fbdb64280 100644
--- a/libavcodec/jpeg2000.c
+++ b/libavcodec/jpeg2000.c
@@ -39,8 +39,7 @@ 
 
 /* tag tree routines */
 
-/* allocate the memory for tag tree */
-int32_t ff_tag_tree_size(int w, int h)
+static int32_t tag_tree_size(int w, int h)
 {
     int64_t res = 0;
     while (w > 1 || h > 1) {
@@ -52,13 +51,14 @@  int32_t ff_tag_tree_size(int w, int h)
     return (int32_t)(res + 1);
 }
 
+/* allocate the memory for tag tree */
 static Jpeg2000TgtNode *ff_jpeg2000_tag_tree_init(int w, int h)
 {
     int pw = w, ph = h;
     Jpeg2000TgtNode *res, *t, *t2;
     int32_t tt_size;
 
-    tt_size = ff_tag_tree_size(w, h);
+    tt_size = tag_tree_size(w, h);
 
     t = res = av_mallocz_array(tt_size, sizeof(*t));
     if (!res)
@@ -85,7 +85,7 @@  static Jpeg2000TgtNode *ff_jpeg2000_tag_tree_init(int w, int h)
 
 void ff_tag_tree_zero(Jpeg2000TgtNode *t, int w, int h, int val)
 {
-    int i, siz = ff_tag_tree_size(w, h);
+    int i, siz = tag_tree_size(w, h);
 
     for (i = 0; i < siz; i++) {
         t[i].val = val;
diff --git a/libavcodec/jpeg2000.h b/libavcodec/jpeg2000.h
index 612832c872..d06313425e 100644
--- a/libavcodec/jpeg2000.h
+++ b/libavcodec/jpeg2000.h
@@ -301,7 +301,6 @@  static inline int needs_termination(int style, int passno) {
     return 0;
 }
 
-int32_t ff_tag_tree_size(int w, int h);
 void ff_tag_tree_zero(Jpeg2000TgtNode *t, int w, int h, int val);
 
 #endif /* AVCODEC_JPEG2000_H */