* [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
@ 2024-04-02 19:04 James Almer
2024-04-02 19:25 ` Andreas Rheinhardt
0 siblings, 1 reply; 7+ messages in thread
From: James Almer @ 2024-04-02 19:04 UTC (permalink / raw)
To: ffmpeg-devel
As it's the main file declaring the AVCodec.
Signed-off-by: James Almer <jamrial@gmail.com>
---
libavcodec/Makefile | 1 +
libavcodec/vvc/Makefile | 3 +--
libavcodec/vvc/vvc_ctu.h | 2 +-
libavcodec/vvc/vvc_filter.h | 2 +-
libavcodec/vvc/vvc_intra_utils.c | 2 +-
libavcodec/vvc/vvc_ps.c | 2 +-
libavcodec/vvc/vvc_refs.h | 2 +-
libavcodec/vvc/vvc_thread.h | 2 +-
libavcodec/vvc/vvcdsp_template.c | 2 +-
libavcodec/{vvc => }/vvcdec.c | 8 ++++----
libavcodec/{vvc => }/vvcdec.h | 10 +++++-----
libavcodec/x86/vvc/vvcdsp_init.c | 2 +-
12 files changed, 19 insertions(+), 19 deletions(-)
rename libavcodec/{vvc => }/vvcdec.c (99%)
rename libavcodec/{vvc => }/vvcdec.h (98%)
diff --git a/libavcodec/Makefile b/libavcodec/Makefile
index eef936944d..1b79472f10 100644
--- a/libavcodec/Makefile
+++ b/libavcodec/Makefile
@@ -794,6 +794,7 @@ OBJS-$(CONFIG_VPLAYER_DECODER) += textdec.o ass.o
OBJS-$(CONFIG_VP9_V4L2M2M_DECODER) += v4l2_m2m_dec.o
OBJS-$(CONFIG_VQA_DECODER) += vqavideo.o
OBJS-$(CONFIG_VQC_DECODER) += vqcdec.o
+OBJS-$(CONFIG_VVC_DECODER) += vvcdec.o
OBJS-$(CONFIG_WADY_DPCM_DECODER) += dpcm.o
OBJS-$(CONFIG_WAVARC_DECODER) += wavarc.o
OBJS-$(CONFIG_WAVPACK_DECODER) += wavpack.o wavpackdata.o dsd.o
diff --git a/libavcodec/vvc/Makefile b/libavcodec/vvc/Makefile
index 2a0055d494..9c72f2d543 100644
--- a/libavcodec/vvc/Makefile
+++ b/libavcodec/vvc/Makefile
@@ -1,8 +1,7 @@
clean::
$(RM) $(CLEANSUFFIXES:%=libavcodec/vvc/%)
-OBJS-$(CONFIG_VVC_DECODER) += vvc/vvcdec.o \
- vvc/vvcdsp.o \
+OBJS-$(CONFIG_VVC_DECODER) += vvc/vvcdsp.o \
vvc/vvc_cabac.o \
vvc/vvc_ctu.o \
vvc/vvc_data.o \
diff --git a/libavcodec/vvc/vvc_ctu.h b/libavcodec/vvc/vvc_ctu.h
index 460dbdba59..82ee033a70 100644
--- a/libavcodec/vvc/vvc_ctu.h
+++ b/libavcodec/vvc/vvc_ctu.h
@@ -26,7 +26,7 @@
#include "libavcodec/cabac.h"
#include "libavutil/mem_internal.h"
-#include "vvcdec.h"
+#include "libavcodec/vvcdec.h"
#define MAX_CTU_SIZE 128
diff --git a/libavcodec/vvc/vvc_filter.h b/libavcodec/vvc/vvc_filter.h
index 9597437d83..0df5e1250d 100644
--- a/libavcodec/vvc/vvc_filter.h
+++ b/libavcodec/vvc/vvc_filter.h
@@ -23,7 +23,7 @@
#ifndef AVCODEC_VVC_VVC_FILTER_H
#define AVCODEC_VVC_VVC_FILTER_H
-#include "vvcdec.h"
+#include "libavcodec/vvcdec.h"
/**
* lmcs filter for the CTU
diff --git a/libavcodec/vvc/vvc_intra_utils.c b/libavcodec/vvc/vvc_intra_utils.c
index 7d34cff023..0cc21f99bb 100644
--- a/libavcodec/vvc/vvc_intra_utils.c
+++ b/libavcodec/vvc/vvc_intra_utils.c
@@ -25,10 +25,10 @@
#include "libavutil/avassert.h"
#include "libavutil/macros.h"
#include "libavutil/common.h"
+#include "libavcodec/vvcdec.h"
#include "vvc_ctu.h"
#include "vvc_intra.h"
#include "vvc_ps.h"
-#include "vvcdec.h"
int ff_vvc_get_mip_size_id(const int w, const int h)
{
diff --git a/libavcodec/vvc/vvc_ps.c b/libavcodec/vvc/vvc_ps.c
index 301fa16400..8560c72c2e 100644
--- a/libavcodec/vvc/vvc_ps.c
+++ b/libavcodec/vvc/vvc_ps.c
@@ -25,9 +25,9 @@
#include "libavutil/mem.h"
#include "libavutil/pixdesc.h"
#include "libavcodec/refstruct.h"
+#include "libavcodec/vvcdec.h"
#include "vvc_data.h"
#include "vvc_ps.h"
-#include "vvcdec.h"
static int sps_map_pixel_format(VVCSPS *sps, void *log_ctx)
{
diff --git a/libavcodec/vvc/vvc_refs.h b/libavcodec/vvc/vvc_refs.h
index eba4422fb4..6d2c6d9107 100644
--- a/libavcodec/vvc/vvc_refs.h
+++ b/libavcodec/vvc/vvc_refs.h
@@ -23,7 +23,7 @@
#ifndef AVCODEC_VVC_VVC_REFS_H
#define AVCODEC_VVC_VVC_REFS_H
-#include "vvcdec.h"
+#include "libavcodec/vvcdec.h"
int ff_vvc_output_frame(VVCContext *s, VVCFrameContext *fc, struct AVFrame *out, int no_output_of_prior_pics_flag, int flush);
void ff_vvc_bump_frame(VVCContext *s, VVCFrameContext *fc);
diff --git a/libavcodec/vvc/vvc_thread.h b/libavcodec/vvc/vvc_thread.h
index 6c726744f8..29c56b9aa0 100644
--- a/libavcodec/vvc/vvc_thread.h
+++ b/libavcodec/vvc/vvc_thread.h
@@ -23,7 +23,7 @@
#ifndef AVCODEC_VVC_VVC_THREAD_H
#define AVCODEC_VVC_VVC_THREAD_H
-#include "vvcdec.h"
+#include "libavcodec/vvcdec.h"
struct AVExecutor* ff_vvc_executor_alloc(VVCContext *s, int thread_count);
void ff_vvc_executor_free(struct AVExecutor **e);
diff --git a/libavcodec/vvc/vvcdsp_template.c b/libavcodec/vvc/vvcdsp_template.c
index 33815d6765..ac0107740d 100644
--- a/libavcodec/vvc/vvcdsp_template.c
+++ b/libavcodec/vvc/vvcdsp_template.c
@@ -21,8 +21,8 @@
*/
#include "libavutil/frame.h"
#include "libavcodec/bit_depth_template.c"
+#include "libavcodec/vvcdec.h"
-#include "vvcdec.h"
#include "vvc_data.h"
#include "vvc_inter_template.c"
diff --git a/libavcodec/vvc/vvcdec.c b/libavcodec/vvcdec.c
similarity index 99%
rename from libavcodec/vvc/vvcdec.c
rename to libavcodec/vvcdec.c
index d7a89f7488..1c004ef763 100644
--- a/libavcodec/vvc/vvcdec.c
+++ b/libavcodec/vvcdec.c
@@ -29,10 +29,10 @@
#include "libavutil/thread.h"
#include "vvcdec.h"
-#include "vvc_ctu.h"
-#include "vvc_data.h"
-#include "vvc_refs.h"
-#include "vvc_thread.h"
+#include "vvc/vvc_ctu.h"
+#include "vvc/vvc_data.h"
+#include "vvc/vvc_refs.h"
+#include "vvc/vvc_thread.h"
#define TAB_MAX 32
diff --git a/libavcodec/vvc/vvcdec.h b/libavcodec/vvcdec.h
similarity index 98%
rename from libavcodec/vvc/vvcdec.h
rename to libavcodec/vvcdec.h
index aa3d715524..41b0522771 100644
--- a/libavcodec/vvc/vvcdec.h
+++ b/libavcodec/vvcdec.h
@@ -21,14 +21,14 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#ifndef AVCODEC_VVC_VVCDEC_H
-#define AVCODEC_VVC_VVCDEC_H
+#ifndef AVCODEC_VVCDEC_H
+#define AVCODEC_VVCDEC_H
#include "libavcodec/videodsp.h"
#include "libavcodec/vvc.h"
-#include "vvc_ps.h"
-#include "vvcdsp.h"
+#include "vvc/vvc_ps.h"
+#include "vvc/vvcdsp.h"
#define LUMA 0
#define CHROMA 1
@@ -226,4 +226,4 @@ typedef struct VVCContext {
int nb_delayed; ///< delayed frames
} VVCContext ;
-#endif /* AVCODEC_VVC_VVCDEC_H */
+#endif /* AVCODEC_VVCDEC_H */
diff --git a/libavcodec/x86/vvc/vvcdsp_init.c b/libavcodec/x86/vvc/vvcdsp_init.c
index 0d2c683f0f..c57f0939ca 100644
--- a/libavcodec/x86/vvc/vvcdsp_init.c
+++ b/libavcodec/x86/vvc/vvcdsp_init.c
@@ -26,7 +26,7 @@
#include "libavutil/cpu.h"
#include "libavutil/x86/asm.h"
#include "libavutil/x86/cpu.h"
-#include "libavcodec/vvc/vvcdec.h"
+#include "libavcodec/vvcdec.h"
#include "libavcodec/vvc/vvc_ctu.h"
#include "libavcodec/vvc/vvcdsp.h"
#include "libavcodec/x86/h26x/h2656dsp.h"
--
2.44.0
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
2024-04-02 19:04 [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory James Almer
@ 2024-04-02 19:25 ` Andreas Rheinhardt
2024-04-02 19:28 ` James Almer
0 siblings, 1 reply; 7+ messages in thread
From: Andreas Rheinhardt @ 2024-04-02 19:25 UTC (permalink / raw)
To: ffmpeg-devel
James Almer:
> As it's the main file declaring the AVCodec.
And why is that supposed to be an advantage?
- Andreas
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
2024-04-02 19:25 ` Andreas Rheinhardt
@ 2024-04-02 19:28 ` James Almer
2024-04-03 8:35 ` Anton Khirnov
0 siblings, 1 reply; 7+ messages in thread
From: James Almer @ 2024-04-02 19:28 UTC (permalink / raw)
To: ffmpeg-devel
On 4/2/2024 4:25 PM, Andreas Rheinhardt wrote:
> James Almer:
>> As it's the main file declaring the AVCodec.
>
> And why is that supposed to be an advantage?
It's not, it's a cosmetic change. Makes it easier to find at least one
file containing the core code in the base directory.
And I'd like to do the same for other big modules with 3+ source files.
hevc, h264, vp9, etc.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
2024-04-02 19:28 ` James Almer
@ 2024-04-03 8:35 ` Anton Khirnov
2024-04-03 14:46 ` James Almer
0 siblings, 1 reply; 7+ messages in thread
From: Anton Khirnov @ 2024-04-03 8:35 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Quoting James Almer (2024-04-02 21:28:28)
> On 4/2/2024 4:25 PM, Andreas Rheinhardt wrote:
> > James Almer:
> >> As it's the main file declaring the AVCodec.
> >
> > And why is that supposed to be an advantage?
>
> It's not, it's a cosmetic change. Makes it easier to find at least one
> file containing the core code in the base directory.
> And I'd like to do the same for other big modules with 3+ source files.
> hevc, h264, vp9, etc.
I dislike this.
Though I would be in favor of removing the vvc prefix from the file
names, as it's redundant with dirname.
--
Anton Khirnov
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
2024-04-03 8:35 ` Anton Khirnov
@ 2024-04-03 14:46 ` James Almer
2024-04-03 14:52 ` Anton Khirnov
0 siblings, 1 reply; 7+ messages in thread
From: James Almer @ 2024-04-03 14:46 UTC (permalink / raw)
To: ffmpeg-devel
On 4/3/2024 5:35 AM, Anton Khirnov wrote:
> Quoting James Almer (2024-04-02 21:28:28)
>> On 4/2/2024 4:25 PM, Andreas Rheinhardt wrote:
>>> James Almer:
>>>> As it's the main file declaring the AVCodec.
>>>
>>> And why is that supposed to be an advantage?
>>
>> It's not, it's a cosmetic change. Makes it easier to find at least one
>> file containing the core code in the base directory.
>> And I'd like to do the same for other big modules with 3+ source files.
>> hevc, h264, vp9, etc.
>
> I dislike this.
Any particular reason why? I'd really like to get some consistency in
the lavc folder. bsfs are currently all in their own folder, but
decoders, encoders and hwaccels are in the top directory alongside all
the generic code, save for vvc and a h26x shared folder. And then
there's the arch folders.
My idea was something like
libavcodec/foodec.{c,h}
libavcodec/fooenc.{c,h}
libavcodec/foo/foo_$bar.{c,h}
libavcodec/foo/$arch/foo*.{asm,c,h}
>
> Though I would be in favor of removing the vvc prefix from the file
> names, as it's redundant with dirname.
I wouldn't oppose.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
2024-04-03 14:46 ` James Almer
@ 2024-04-03 14:52 ` Anton Khirnov
2024-04-03 15:39 ` Andreas Rheinhardt
0 siblings, 1 reply; 7+ messages in thread
From: Anton Khirnov @ 2024-04-03 14:52 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Quoting James Almer (2024-04-03 16:46:14)
> On 4/3/2024 5:35 AM, Anton Khirnov wrote:
> > Quoting James Almer (2024-04-02 21:28:28)
> >> On 4/2/2024 4:25 PM, Andreas Rheinhardt wrote:
> >>> James Almer:
> >>>> As it's the main file declaring the AVCodec.
> >>>
> >>> And why is that supposed to be an advantage?
> >>
> >> It's not, it's a cosmetic change. Makes it easier to find at least one
> >> file containing the core code in the base directory.
> >> And I'd like to do the same for other big modules with 3+ source files.
> >> hevc, h264, vp9, etc.
> >
> > I dislike this.
>
> Any particular reason why? I'd really like to get some consistency in
> the lavc folder.
So would I, but it seems inconsistent to me to have everything
foo-related in a directory, except this one special file.
If we have a directory for codec X, it seems most consistent to me to
put EVERYTHING in that directory.
--
Anton Khirnov
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory
2024-04-03 14:52 ` Anton Khirnov
@ 2024-04-03 15:39 ` Andreas Rheinhardt
0 siblings, 0 replies; 7+ messages in thread
From: Andreas Rheinhardt @ 2024-04-03 15:39 UTC (permalink / raw)
To: ffmpeg-devel
Anton Khirnov:
> Quoting James Almer (2024-04-03 16:46:14)
>> On 4/3/2024 5:35 AM, Anton Khirnov wrote:
>>> Quoting James Almer (2024-04-02 21:28:28)
>>>> On 4/2/2024 4:25 PM, Andreas Rheinhardt wrote:
>>>>> James Almer:
>>>>>> As it's the main file declaring the AVCodec.
>>>>>
>>>>> And why is that supposed to be an advantage?
>>>>
>>>> It's not, it's a cosmetic change. Makes it easier to find at least one
>>>> file containing the core code in the base directory.
>>>> And I'd like to do the same for other big modules with 3+ source files.
>>>> hevc, h264, vp9, etc.
>>>
>>> I dislike this.
>>
>> Any particular reason why? I'd really like to get some consistency in
>> the lavc folder.
>
> So would I, but it seems inconsistent to me to have everything
> foo-related in a directory, except this one special file.
>
> If we have a directory for codec X, it seems most consistent to me to
> put EVERYTHING in that directory.
>
+1.
- Andreas
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2024-04-03 15:39 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-02 19:04 [FFmpeg-devel] [PATCH] avcodec/vvcdec: move vvcdec.{c, h} to the top directory James Almer
2024-04-02 19:25 ` Andreas Rheinhardt
2024-04-02 19:28 ` James Almer
2024-04-03 8:35 ` Anton Khirnov
2024-04-03 14:46 ` James Almer
2024-04-03 14:52 ` Anton Khirnov
2024-04-03 15:39 ` Andreas Rheinhardt
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git