From patchwork Thu Jan 21 21:39:54 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Thompson X-Patchwork-Id: 25059 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id AC1EF44A469 for ; Thu, 21 Jan 2021 23:42:29 +0200 (EET) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 977B0689E84; Thu, 21 Jan 2021 23:42:29 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-wr1-f45.google.com (mail-wr1-f45.google.com [209.85.221.45]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 3E5D0689D8E for ; Thu, 21 Jan 2021 23:42:21 +0200 (EET) Received: by mail-wr1-f45.google.com with SMTP id m1so2488656wrq.12 for ; Thu, 21 Jan 2021 13:42:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jkqxz-net.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=hXTDBRibOqkd4axE5E6zbNzZ2JjYGXUibQlEgc8mjCQ=; b=ihjsUpHzvSOI8vwSvF/C17MyTVjnrqtrQTcMuuY0KsL/MBGkuy5WiNXbJ1WmLV8HUK fpBcIb/CxZ++FaAf0jVDx7iyE5N7ooqWD+gRqdTpIZezMVT95CDy2QhtPmBhcdI8RZEX UbNwSRL5immkozQY5mQxUx8d9tDU4v25/+45Fhy8M7d83rgsx0l7S6+SEN3+mgRVYCkG bwnc1nBJ5mv50Zyq866wMwUAB3/XrybuvRaRI3l/zEwhoY/8eYKaXARbQe+dCtq/yxRR ondsrvReDRe8AzqAi4vcwwePb4+4IMlulHu2K4Uhl76J9BGhCMdP5SHfbtRNCMtv/BMM UnNA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=hXTDBRibOqkd4axE5E6zbNzZ2JjYGXUibQlEgc8mjCQ=; b=hl/wTCeq0YIAIC/bZm/xBDwOLVrio1R7atkLl8qcz4pkMR41DlGUD+U47d+Y+3LIbg Shs1t5ls4O+n9pB39cikYgcPqGHiEYaoIWvH9LVp67TNMc6OpHPpON9rEHwhTmc9LxGR ZfJ49hJOLyh/DIfjecbeLZ8g0j1uzC+cOJjG/rqc755DZmcjLt4XvKbEjiSNu1OeLwii 0WzSsFgfzyY77VtMR6SOO6nwJE8AyBAKKNhaWVb8wvYtEhh2mR+W+p0MhCnfLh5DT8r9 2Sa/P013ALCe3SIXG4nPOzDkw3iGDGLFMNiyLdJHKIsJQhb3KjAadPPcA5Pe0lI3iz83 L9Sg== X-Gm-Message-State: AOAM530YPqbAcftStt+jOIz9m7gOlbuPSjXqha/wA4r7X7kd9dIkFNGx /Fkil6ohCbCrHesV5dY4apFDuKhNNP0YuA== X-Google-Smtp-Source: ABdhPJxCg82kPN+TCb9I6RTIsjqfxSwvIN2FYl9IYsFdZX0FUu5EmQqw0swiUVbR8VMy46sr5UquhQ== X-Received: by 2002:a5d:6c6b:: with SMTP id r11mr1420503wrz.38.1611265340478; Thu, 21 Jan 2021 13:42:20 -0800 (PST) Received: from localhost.localdomain (cpc91226-cmbg18-2-0-cust7.5-4.cable.virginm.net. [82.0.29.8]) by smtp.gmail.com with ESMTPSA id x10sm1895106wrt.84.2021.01.21.13.42.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 21 Jan 2021 13:42:19 -0800 (PST) From: Mark Thompson To: ffmpeg-devel@ffmpeg.org Date: Thu, 21 Jan 2021 21:39:54 +0000 Message-Id: <20210121213956.991629-3-sw@jkqxz.net> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20210121213956.991629-1-sw@jkqxz.net> References: <20210121213956.991629-1-sw@jkqxz.net> MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH 3/5] libavfilter/dnn: add prefix ff_ for internal functions X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" From: "Guo, Yejun" from proc_from_frame_to_dnn to ff_proc_from_frame_to_dnn, and from proc_from_dnn_to_frame to ff_proc_from_dnn_to_frame. Signed-off-by: Guo, Yejun --- This was sent a few days ago to fix some of these issues, and is included here because it is needed for the test in 5/5 to pass. libavfilter/dnn/dnn_backend_native.c | 4 ++-- libavfilter/dnn/dnn_backend_openvino.c | 4 ++-- libavfilter/dnn/dnn_backend_tf.c | 4 ++-- libavfilter/dnn/dnn_io_proc.c | 4 ++-- libavfilter/dnn/dnn_io_proc.h | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/libavfilter/dnn/dnn_backend_native.c b/libavfilter/dnn/dnn_backend_native.c index ffb79dc000..0094ec5444 100644 --- a/libavfilter/dnn/dnn_backend_native.c +++ b/libavfilter/dnn/dnn_backend_native.c @@ -320,7 +320,7 @@ static DNNReturnType execute_model_native(const DNNModel *model, const char *inp if (native_model->model->pre_proc != NULL) { native_model->model->pre_proc(in_frame, &input, native_model->model->filter_ctx); } else { - proc_from_frame_to_dnn(in_frame, &input, ctx); + ff_proc_from_frame_to_dnn(in_frame, &input, ctx); } } @@ -368,7 +368,7 @@ static DNNReturnType execute_model_native(const DNNModel *model, const char *inp if (native_model->model->post_proc != NULL) { native_model->model->post_proc(out_frame, &output, native_model->model->filter_ctx); } else { - proc_from_dnn_to_frame(out_frame, &output, ctx); + ff_proc_from_dnn_to_frame(out_frame, &output, ctx); } } else { out_frame->width = output.width; diff --git a/libavfilter/dnn/dnn_backend_openvino.c b/libavfilter/dnn/dnn_backend_openvino.c index 8a7abb33f0..d5b83cef97 100644 --- a/libavfilter/dnn/dnn_backend_openvino.c +++ b/libavfilter/dnn/dnn_backend_openvino.c @@ -160,7 +160,7 @@ static DNNReturnType fill_model_input_ov(OVModel *ov_model, RequestItem *request if (ov_model->model->pre_proc != NULL) { ov_model->model->pre_proc(task->in_frame, &input, ov_model->model->filter_ctx); } else { - proc_from_frame_to_dnn(task->in_frame, &input, ctx); + ff_proc_from_frame_to_dnn(task->in_frame, &input, ctx); } } input.data = (uint8_t *)input.data @@ -228,7 +228,7 @@ static void infer_completion_callback(void *args) if (task->ov_model->model->post_proc != NULL) { task->ov_model->model->post_proc(task->out_frame, &output, task->ov_model->model->filter_ctx); } else { - proc_from_dnn_to_frame(task->out_frame, &output, ctx); + ff_proc_from_dnn_to_frame(task->out_frame, &output, ctx); } } else { task->out_frame->width = output.width; diff --git a/libavfilter/dnn/dnn_backend_tf.c b/libavfilter/dnn/dnn_backend_tf.c index b9fe01693b..81a55bfed5 100644 --- a/libavfilter/dnn/dnn_backend_tf.c +++ b/libavfilter/dnn/dnn_backend_tf.c @@ -743,7 +743,7 @@ static DNNReturnType execute_model_tf(const DNNModel *model, const char *input_n if (tf_model->model->pre_proc != NULL) { tf_model->model->pre_proc(in_frame, &input, tf_model->model->filter_ctx); } else { - proc_from_frame_to_dnn(in_frame, &input, ctx); + ff_proc_from_frame_to_dnn(in_frame, &input, ctx); } } @@ -800,7 +800,7 @@ static DNNReturnType execute_model_tf(const DNNModel *model, const char *input_n if (tf_model->model->post_proc != NULL) { tf_model->model->post_proc(out_frame, &output, tf_model->model->filter_ctx); } else { - proc_from_dnn_to_frame(out_frame, &output, ctx); + ff_proc_from_dnn_to_frame(out_frame, &output, ctx); } } else { out_frame->width = output.width; diff --git a/libavfilter/dnn/dnn_io_proc.c b/libavfilter/dnn/dnn_io_proc.c index 2744cb6502..3ed8a98a39 100644 --- a/libavfilter/dnn/dnn_io_proc.c +++ b/libavfilter/dnn/dnn_io_proc.c @@ -22,7 +22,7 @@ #include "libavutil/imgutils.h" #include "libswscale/swscale.h" -DNNReturnType proc_from_dnn_to_frame(AVFrame *frame, DNNData *output, void *log_ctx) +DNNReturnType ff_proc_from_dnn_to_frame(AVFrame *frame, DNNData *output, void *log_ctx) { struct SwsContext *sws_ctx; int bytewidth = av_image_get_linesize(frame->format, frame->width, 0); @@ -93,7 +93,7 @@ DNNReturnType proc_from_dnn_to_frame(AVFrame *frame, DNNData *output, void *log_ return DNN_SUCCESS; } -DNNReturnType proc_from_frame_to_dnn(AVFrame *frame, DNNData *input, void *log_ctx) +DNNReturnType ff_proc_from_frame_to_dnn(AVFrame *frame, DNNData *input, void *log_ctx) { struct SwsContext *sws_ctx; int bytewidth = av_image_get_linesize(frame->format, frame->width, 0); diff --git a/libavfilter/dnn/dnn_io_proc.h b/libavfilter/dnn/dnn_io_proc.h index 4c7dc7c1a2..6a410ccc7b 100644 --- a/libavfilter/dnn/dnn_io_proc.h +++ b/libavfilter/dnn/dnn_io_proc.h @@ -30,7 +30,7 @@ #include "../dnn_interface.h" #include "libavutil/frame.h" -DNNReturnType proc_from_frame_to_dnn(AVFrame *frame, DNNData *input, void *log_ctx); -DNNReturnType proc_from_dnn_to_frame(AVFrame *frame, DNNData *output, void *log_ctx); +DNNReturnType ff_proc_from_frame_to_dnn(AVFrame *frame, DNNData *input, void *log_ctx); +DNNReturnType ff_proc_from_dnn_to_frame(AVFrame *frame, DNNData *output, void *log_ctx); #endif