32 #define DECORRELATE_FUNCS(fmt, opt) \
33 void ff_flac_decorrelate_ls_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
34 int len, int shift); \
35 void ff_flac_decorrelate_rs_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
36 int len, int shift); \
37 void ff_flac_decorrelate_ms_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
38 int len, int shift); \
39 void ff_flac_decorrelate_indep2_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
40 int len, int shift); \
41 void ff_flac_decorrelate_indep4_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
42 int len, int shift); \
43 void ff_flac_decorrelate_indep6_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
44 int len, int shift); \
45 void ff_flac_decorrelate_indep8_##fmt##_##opt(uint8_t **out, int32_t **in, int channels, \
59 #if CONFIG_FLAC_DECODER
63 c->
decorrelate[0] = ff_flac_decorrelate_indep2_16_sse2;
64 else if (channels == 4)
65 c->
decorrelate[0] = ff_flac_decorrelate_indep4_16_sse2;
66 else if (channels == 6)
67 c->
decorrelate[0] = ff_flac_decorrelate_indep6_16_sse2;
68 else if (ARCH_X86_64 && channels == 8)
69 c->
decorrelate[0] = ff_flac_decorrelate_indep8_16_sse2;
75 c->
decorrelate[0] = ff_flac_decorrelate_indep2_32_sse2;
76 else if (channels == 4)
77 c->
decorrelate[0] = ff_flac_decorrelate_indep4_32_sse2;
78 else if (channels == 6)
79 c->
decorrelate[0] = ff_flac_decorrelate_indep6_32_sse2;
80 else if (ARCH_X86_64 && channels == 8)
81 c->
decorrelate[0] = ff_flac_decorrelate_indep8_32_sse2;
92 if (ARCH_X86_64 && channels == 8)
93 c->
decorrelate[0] = ff_flac_decorrelate_indep8_16_avx;
96 c->
decorrelate[0] = ff_flac_decorrelate_indep4_32_avx;
97 else if (channels == 6)
98 c->
decorrelate[0] = ff_flac_decorrelate_indep6_32_avx;
99 else if (ARCH_X86_64 && channels == 8)
100 c->
decorrelate[0] = ff_flac_decorrelate_indep8_32_avx;
108 #if CONFIG_FLAC_ENCODER
void ff_flac_lpc_32_sse4(int32_t *samples, const int coeffs[32], int order, int qlevel, int len)
static atomic_int cpu_flags
void ff_flac_lpc_32_xop(int32_t *samples, const int coeffs[32], int order, int qlevel, int len)
#define EXTERNAL_SSE4(flags)
void(* lpc32)(int32_t *samples, const int coeffs[32], int order, int qlevel, int len)
#define EXTERNAL_SSE2(flags)
#define DECORRELATE_FUNCS(fmt, opt)
void(* lpc16_encode)(int32_t *res, const int32_t *smp, int len, int order, const int32_t coefs[32], int shift)
void ff_flac_enc_lpc_16_sse4(int32_t *, const int32_t *, int, int, const int32_t *, int)
AVSampleFormat
Audio sample formats.
int av_get_cpu_flags(void)
Return the flags which specify extensions supported by the CPU.
av_cold void ff_flacdsp_init_x86(FLACDSPContext *c, enum AVSampleFormat fmt, int channels, int bps)
static const int16_t coeffs[]
#define EXTERNAL_XOP(flags)
#define EXTERNAL_AVX(flags)
void(* decorrelate[4])(uint8_t **out, int32_t **in, int channels, int len, int shift)