[FFmpeg-cvslog] libavfilter/dnn: move dnn files from libavfilter to libavfilter/dnn

Guo, Yejun git at videolan.org
Fri Jul 26 19:09:21 EEST 2019


ffmpeg | branch: master | Guo, Yejun <yejun.guo at intel.com> | Tue Jul 16 13:55:45 2019 +0800| [1b9064e3f4ca4cf744f5112c02b31ffd1b44f4c4] | committer: Pedro Arthur

libavfilter/dnn: move dnn files from libavfilter to libavfilter/dnn

it is expected that there will be more files to support native mode,
so put all the dnn codes under libavfilter/dnn

The main change of this patch is to move the file location, see below:
modified:   libavfilter/Makefile
new file:   libavfilter/dnn/Makefile
renamed:    libavfilter/dnn_backend_native.c -> libavfilter/dnn/dnn_backend_native.c
renamed:    libavfilter/dnn_backend_native.h -> libavfilter/dnn/dnn_backend_native.h
renamed:    libavfilter/dnn_backend_tf.c -> libavfilter/dnn/dnn_backend_tf.c
renamed:    libavfilter/dnn_backend_tf.h -> libavfilter/dnn/dnn_backend_tf.h
renamed:    libavfilter/dnn_interface.c -> libavfilter/dnn/dnn_interface.c

Signed-off-by: Guo, Yejun <yejun.guo at intel.com>
Signed-off-by: Pedro Arthur <bygrandao at gmail.com>

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

 libavfilter/Makefile                       | 3 +--
 libavfilter/dnn/Makefile                   | 6 ++++++
 libavfilter/{ => dnn}/dnn_backend_native.c | 0
 libavfilter/{ => dnn}/dnn_backend_native.h | 6 +++---
 libavfilter/{ => dnn}/dnn_backend_tf.c     | 0
 libavfilter/{ => dnn}/dnn_backend_tf.h     | 6 +++---
 libavfilter/{ => dnn}/dnn_interface.c      | 2 +-
 7 files changed, 14 insertions(+), 9 deletions(-)

diff --git a/libavfilter/Makefile b/libavfilter/Makefile
index 455c809b15..450d7810ef 100644
--- a/libavfilter/Makefile
+++ b/libavfilter/Makefile
@@ -26,9 +26,8 @@ OBJS-$(HAVE_THREADS)                         += pthread.o
 
 # subsystems
 OBJS-$(CONFIG_QSVVPP)                        += qsvvpp.o
-DNN-OBJS-$(CONFIG_LIBTENSORFLOW)             += dnn_backend_tf.o
-OBJS-$(CONFIG_DNN)                           += dnn_interface.o dnn_backend_native.o $(DNN-OBJS-yes)
 OBJS-$(CONFIG_SCENE_SAD)                     += scene_sad.o
+include $(SRC_PATH)/libavfilter/dnn/Makefile
 
 # audio filters
 OBJS-$(CONFIG_ABENCH_FILTER)                 += f_bench.o
diff --git a/libavfilter/dnn/Makefile b/libavfilter/dnn/Makefile
new file mode 100644
index 0000000000..1d12ade165
--- /dev/null
+++ b/libavfilter/dnn/Makefile
@@ -0,0 +1,6 @@
+OBJS-$(CONFIG_DNN)                           += dnn/dnn_interface.o
+OBJS-$(CONFIG_DNN)                           += dnn/dnn_backend_native.o
+
+DNN-OBJS-$(CONFIG_LIBTENSORFLOW)             += dnn/dnn_backend_tf.o
+
+OBJS-$(CONFIG_DNN)                           += $(DNN-OBJS-yes)
diff --git a/libavfilter/dnn_backend_native.c b/libavfilter/dnn/dnn_backend_native.c
similarity index 100%
rename from libavfilter/dnn_backend_native.c
rename to libavfilter/dnn/dnn_backend_native.c
diff --git a/libavfilter/dnn_backend_native.h b/libavfilter/dnn/dnn_backend_native.h
similarity index 94%
rename from libavfilter/dnn_backend_native.h
rename to libavfilter/dnn/dnn_backend_native.h
index 5917955733..8ef1855e45 100644
--- a/libavfilter/dnn_backend_native.h
+++ b/libavfilter/dnn/dnn_backend_native.h
@@ -24,10 +24,10 @@
  */
 
 
-#ifndef AVFILTER_DNN_BACKEND_NATIVE_H
-#define AVFILTER_DNN_BACKEND_NATIVE_H
+#ifndef AVFILTER_DNN_DNN_BACKEND_NATIVE_H
+#define AVFILTER_DNN_DNN_BACKEND_NATIVE_H
 
-#include "dnn_interface.h"
+#include "../dnn_interface.h"
 #include "libavformat/avio.h"
 
 typedef enum {INPUT, CONV, DEPTH_TO_SPACE} DNNLayerType;
diff --git a/libavfilter/dnn_backend_tf.c b/libavfilter/dnn/dnn_backend_tf.c
similarity index 100%
rename from libavfilter/dnn_backend_tf.c
rename to libavfilter/dnn/dnn_backend_tf.c
diff --git a/libavfilter/dnn_backend_tf.h b/libavfilter/dnn/dnn_backend_tf.h
similarity index 91%
rename from libavfilter/dnn_backend_tf.h
rename to libavfilter/dnn/dnn_backend_tf.h
index 07877b1209..3e4508912e 100644
--- a/libavfilter/dnn_backend_tf.h
+++ b/libavfilter/dnn/dnn_backend_tf.h
@@ -24,10 +24,10 @@
  */
 
 
-#ifndef AVFILTER_DNN_BACKEND_TF_H
-#define AVFILTER_DNN_BACKEND_TF_H
+#ifndef AVFILTER_DNN_DNN_BACKEND_TF_H
+#define AVFILTER_DNN_DNN_BACKEND_TF_H
 
-#include "dnn_interface.h"
+#include "../dnn_interface.h"
 
 DNNModel *ff_dnn_load_model_tf(const char *model_filename);
 
diff --git a/libavfilter/dnn_interface.c b/libavfilter/dnn/dnn_interface.c
similarity index 98%
rename from libavfilter/dnn_interface.c
rename to libavfilter/dnn/dnn_interface.c
index 86fc283024..62da55f43e 100644
--- a/libavfilter/dnn_interface.c
+++ b/libavfilter/dnn/dnn_interface.c
@@ -23,7 +23,7 @@
  * Implements DNN module initialization with specified backend.
  */
 
-#include "dnn_interface.h"
+#include "../dnn_interface.h"
 #include "dnn_backend_native.h"
 #include "dnn_backend_tf.h"
 #include "libavutil/mem.h"



More information about the ffmpeg-cvslog mailing list