FFmpeg
opusdsp_init.c
Go to the documentation of this file.
1 /*
2  * Copyright © 2022 Rémi Denis-Courmont.
3  *
4  * This file is part of FFmpeg.
5  *
6  * FFmpeg is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * FFmpeg is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with FFmpeg; if not, write to the Free Software
18  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19  */
20 
21 #include "config.h"
22 
23 #include "libavutil/attributes.h"
24 #include "libavutil/cpu.h"
25 #include "libavutil/riscv/cpu.h"
26 #include "libavcodec/opusdsp.h"
27 
28 void ff_opus_postfilter_rvv(float *data, int period, float *g, int len);
29 
31 {
32 #if HAVE_RVV
33  int flags = av_get_cpu_flags();
34 
37  d->postfilter = ff_opus_postfilter_rvv;
38 #endif
39 }
AV_CPU_FLAG_RVB_BASIC
#define AV_CPU_FLAG_RVB_BASIC
Basic bit-manipulations.
Definition: cpu.h:91
opusdsp.h
data
const char data[16]
Definition: mxf.c:148
av_get_cpu_flags
int av_get_cpu_flags(void)
Return the flags which specify extensions supported by the CPU.
Definition: cpu.c:103
ff_opus_dsp_init_riscv
av_cold void ff_opus_dsp_init_riscv(OpusDSP *d)
Definition: opusdsp_init.c:30
AV_CPU_FLAG_RVV_F32
#define AV_CPU_FLAG_RVV_F32
Vectors of float's *‍/.
Definition: cpu.h:88
av_cold
#define av_cold
Definition: attributes.h:90
g
const char * g
Definition: vf_curves.c:127
cpu.h
AV_CPU_FLAG_RVB_ADDR
#define AV_CPU_FLAG_RVB_ADDR
Address bit-manipulations.
Definition: cpu.h:92
ff_opus_postfilter_rvv
void ff_opus_postfilter_rvv(float *data, int period, float *g, int len)
period
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf default minimum maximum flags name is the option keep it simple and lowercase description are in without period
Definition: writing_filters.txt:89
cpu.h
attributes.h
len
int len
Definition: vorbis_enc_data.h:426
d
d
Definition: ffmpeg_filter.c:424
flags
#define flags(name, subs,...)
Definition: cbs_av1.c:474
OpusDSP
Definition: opusdsp.h:24