avfilter/vf_vif: Make ff_compute_vif2 static
Only used here; the vif.h header can then be removed. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
71eb8f8fa9
commit
465ddcb600
@ -35,7 +35,6 @@
|
|||||||
#include "drawutils.h"
|
#include "drawutils.h"
|
||||||
#include "formats.h"
|
#include "formats.h"
|
||||||
#include "internal.h"
|
#include "internal.h"
|
||||||
#include "vif.h"
|
|
||||||
#include "video.h"
|
#include "video.h"
|
||||||
|
|
||||||
#define NUM_DATA_BUFS 13
|
#define NUM_DATA_BUFS 13
|
||||||
@ -285,11 +284,11 @@ static int vif_filter1d(AVFilterContext *ctx, void *arg, int jobnr, int nb_jobs)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int ff_compute_vif2(AVFilterContext *ctx,
|
static int compute_vif2(AVFilterContext *ctx,
|
||||||
const float *ref, const float *main, int w, int h,
|
const float *ref, const float *main, int w, int h,
|
||||||
int ref_stride, int main_stride, float *score,
|
int ref_stride, int main_stride, float *score,
|
||||||
float *data_buf[NUM_DATA_BUFS], float **temp,
|
float *const data_buf[NUM_DATA_BUFS], float **temp,
|
||||||
int gnb_threads)
|
int gnb_threads)
|
||||||
{
|
{
|
||||||
ThreadData td;
|
ThreadData td;
|
||||||
float *ref_scale = data_buf[0];
|
float *ref_scale = data_buf[0];
|
||||||
@ -450,11 +449,9 @@ static AVFrame *do_vif(AVFilterContext *ctx, AVFrame *main, const AVFrame *ref)
|
|||||||
offset_16bit(s, ref, main, s->width);
|
offset_16bit(s, ref, main, s->width);
|
||||||
}
|
}
|
||||||
|
|
||||||
ff_compute_vif2(ctx,
|
compute_vif2(ctx, s->ref_data, s->main_data,
|
||||||
s->ref_data, s->main_data, s->width,
|
s->width, s->height, s->width, s->width,
|
||||||
s->height, s->width, s->width,
|
score, s->data_buf, s->temp, s->nb_threads);
|
||||||
score, s->data_buf, s->temp,
|
|
||||||
s->nb_threads);
|
|
||||||
|
|
||||||
set_meta(metadata, "lavfi.vif.scale.0", score[0]);
|
set_meta(metadata, "lavfi.vif.scale.0", score[0]);
|
||||||
set_meta(metadata, "lavfi.vif.scale.1", score[1]);
|
set_meta(metadata, "lavfi.vif.scale.1", score[1]);
|
||||||
|
@ -1,32 +0,0 @@
|
|||||||
/*
|
|
||||||
* Copyright (c) 2017 Ronald S. Bultje <rsbultje@gmail.com>
|
|
||||||
* Copyright (c) 2017 Ashish Pratap Singh <ashk43712@gmail.com>
|
|
||||||
*
|
|
||||||
* This file is part of FFmpeg.
|
|
||||||
*
|
|
||||||
* FFmpeg is free software; you can redistribute it and/or
|
|
||||||
* modify it under the terms of the GNU Lesser General Public
|
|
||||||
* License as published by the Free Software Foundation; either
|
|
||||||
* version 2.1 of the License, or (at your option) any later version.
|
|
||||||
*
|
|
||||||
* FFmpeg is distributed in the hope that it will be useful,
|
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
* Lesser General Public License for more details.
|
|
||||||
*
|
|
||||||
* You should have received a copy of the GNU Lesser General Public
|
|
||||||
* License along with FFmpeg; if not, write to the Free Software
|
|
||||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef AVFILTER_VIF_H
|
|
||||||
#define AVFILTER_VIF_H
|
|
||||||
|
|
||||||
#include "avfilter.h"
|
|
||||||
|
|
||||||
int ff_compute_vif2(AVFilterContext *ctx,
|
|
||||||
const float *ref, const float *main, int w, int h,
|
|
||||||
int ref_stride, int main_stride, float *score,
|
|
||||||
float *data_buf[13], float **temp, int nb_threads);
|
|
||||||
|
|
||||||
#endif /* AVFILTER_VIF_H */
|
|
Loading…
x
Reference in New Issue
Block a user