Unified · Split
| @@ -747,6 +747,7 @@ static void filter_stereo(AVFilterContext *ctx) · 746 unmodified lines | |||
| 747 | const float *srcl = (const float *)s->input->extended_data[0]; | 747 | const float *srcl = (const float *)s->input->extended_data[0]; |
| 748 | const float *srcr = (const float *)s->input->extended_data[1]; | 748 | const float *srcr = (const float *)s->input->extended_data[1]; |
| 749 | const int output_lfe = s->output_lfe && s->create_lfe; | 749 | const int output_lfe = s->output_lfe && s->create_lfe; |
| 750 | const int rdft_size = s->rdft_size; | ||
| 750 | const int lfe_mode = s->lfe_mode; | 751 | const int lfe_mode = s->lfe_mode; |
| 751 | const float highcut = s->highcut; | 752 | const float highcut = s->highcut; |
| 752 | const float lowcut = s->lowcut; | 753 | const float lowcut = s->lowcut; |
| @@ -761,7 +762,7 @@ static void filter_stereo(AVFilterContext *ctx) · 8 unmodified lines | |||
| 761 | float *xpos = s->x_pos; | 762 | float *xpos = s->x_pos; |
| 762 | float *ypos = s->y_pos; | 763 | float *ypos = s->y_pos; |
| 763 | 764 | ||
| 764 | for (int n = 0; n < s->rdft_size; n++) { | 765 | for (int n = 0; n < rdft_size; n++) { |
| 765 | float l_re = srcl[2 * n], r_re = srcr[2 * n]; | 766 | float l_re = srcl[2 * n], r_re = srcr[2 * n]; |
| 766 | float l_im = srcl[2 * n + 1], r_im = srcr[2 * n + 1]; | 767 | float l_im = srcl[2 * n + 1], r_im = srcr[2 * n + 1]; |
| 767 | float c_phase = atan2f(l_im + r_im, l_re + r_re); | 768 | float c_phase = atan2f(l_im + r_im, l_re + r_re); |
| @@ -801,6 +802,7 @@ static void filter_2_1(AVFilterContext *ctx) · 33 unmodified lines | |||
| 801 | const float *srcl = (const float *)s->input->extended_data[0]; | 802 | const float *srcl = (const float *)s->input->extended_data[0]; |
| 802 | const float *srcr = (const float *)s->input->extended_data[1]; | 803 | const float *srcr = (const float *)s->input->extended_data[1]; |
| 803 | const float *srclfe = (const float *)s->input->extended_data[2]; | 804 | const float *srclfe = (const float *)s->input->extended_data[2]; |
| 805 | const int rdft_size = s->rdft_size; | ||
| 804 | const float angle = s->angle; | 806 | const float angle = s->angle; |
| 805 | const float focus = s->focus; | 807 | const float focus = s->focus; |
| 806 | float *magtotal = s->mag_total; | 808 | float *magtotal = s->mag_total; |
| @@ -813,7 +815,7 @@ static void filter_2_1(AVFilterContext *ctx) · 6 unmodified lines | |||
| 813 | float *xpos = s->x_pos; | 815 | float *xpos = s->x_pos; |
| 814 | float *ypos = s->y_pos; | 816 | float *ypos = s->y_pos; |
| 815 | 817 | ||
| 816 | for (int n = 0; n < s->rdft_size; n++) { | 818 | for (int n = 0; n < rdft_size; n++) { |
| 817 | float l_re = srcl[2 * n], r_re = srcr[2 * n]; | 819 | float l_re = srcl[2 * n], r_re = srcr[2 * n]; |
| 818 | float l_im = srcl[2 * n + 1], r_im = srcr[2 * n + 1]; | 820 | float l_im = srcl[2 * n + 1], r_im = srcr[2 * n + 1]; |
| 819 | float lfe_re = srclfe[2 * n], lfe_im = srclfe[2 * n + 1]; | 821 | float lfe_re = srclfe[2 * n], lfe_im = srclfe[2 * n + 1]; |
| @@ -858,6 +860,7 @@ static void filter_surround(AVFilterContext *ctx) · 38 unmodified lines | |||
| 858 | const float *srcr = (const float *)s->input->extended_data[1]; | 860 | const float *srcr = (const float *)s->input->extended_data[1]; |
| 859 | const float *srcc = (const float *)s->input->extended_data[2]; | 861 | const float *srcc = (const float *)s->input->extended_data[2]; |
| 860 | const int output_lfe = s->output_lfe && s->create_lfe; | 862 | const int output_lfe = s->output_lfe && s->create_lfe; |
| 863 | const int rdft_size = s->rdft_size; | ||
| 861 | const int lfe_mode = s->lfe_mode; | 864 | const int lfe_mode = s->lfe_mode; |
| 862 | const float highcut = s->highcut; | 865 | const float highcut = s->highcut; |
| 863 | const float lowcut = s->lowcut; | 866 | const float lowcut = s->lowcut; |
| @@ -872,7 +875,7 @@ static void filter_surround(AVFilterContext *ctx) · 8 unmodified lines | |||
| 872 | float *xpos = s->x_pos; | 875 | float *xpos = s->x_pos; |
| 873 | float *ypos = s->y_pos; | 876 | float *ypos = s->y_pos; |
| 874 | 877 | ||
| 875 | for (int n = 0; n < s->rdft_size; n++) { | 878 | for (int n = 0; n < rdft_size; n++) { |
| 876 | float l_re = srcl[2 * n], r_re = srcr[2 * n]; | 879 | float l_re = srcl[2 * n], r_re = srcr[2 * n]; |
| 877 | float l_im = srcl[2 * n + 1], r_im = srcr[2 * n + 1]; | 880 | float l_im = srcl[2 * n + 1], r_im = srcr[2 * n + 1]; |
| 878 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; | 881 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; |
| @@ -910,6 +913,7 @@ static void filter_surround(AVFilterContext *ctx) · 31 unmodified lines | |||
| 910 | static void filter_5_0_side(AVFilterContext *ctx) | 913 | static void filter_5_0_side(AVFilterContext *ctx) |
| 911 | { | 914 | { |
| 912 | AudioSurroundContext *s = ctx->priv; | 915 | AudioSurroundContext *s = ctx->priv; |
| 916 | const int rdft_size = s->rdft_size; | ||
| 913 | float *srcl, *srcr, *srcc, *srcsl, *srcsr; | 917 | float *srcl, *srcr, *srcc, *srcsl, *srcsr; |
| 914 | int n; | 918 | int n; |
| 915 | 919 | ||
| @@ -919,7 +923,7 @@ static void filter_5_0_side(AVFilterContext *ctx) · 3 unmodified lines | |||
| 919 | srcsl = (float *)s->input->extended_data[3]; | 923 | srcsl = (float *)s->input->extended_data[3]; |
| 920 | srcsr = (float *)s->input->extended_data[4]; | 924 | srcsr = (float *)s->input->extended_data[4]; |
| 921 | 925 | ||
| 922 | for (n = 0; n < s->rdft_size; n++) { | 926 | for (n = 0; n < rdft_size; n++) { |
| 923 | float fl_re = srcl[2 * n], fr_re = srcr[2 * n]; | 927 | float fl_re = srcl[2 * n], fr_re = srcr[2 * n]; |
| 924 | float fl_im = srcl[2 * n + 1], fr_im = srcr[2 * n + 1]; | 928 | float fl_im = srcl[2 * n + 1], fr_im = srcr[2 * n + 1]; |
| 925 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; | 929 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; |
| @@ -967,6 +971,7 @@ static void filter_5_0_side(AVFilterContext *ctx) · 41 unmodified lines | |||
| 967 | static void filter_5_1_side(AVFilterContext *ctx) | 971 | static void filter_5_1_side(AVFilterContext *ctx) |
| 968 | { | 972 | { |
| 969 | AudioSurroundContext *s = ctx->priv; | 973 | AudioSurroundContext *s = ctx->priv; |
| 974 | const int rdft_size = s->rdft_size; | ||
| 970 | float *srcl, *srcr, *srcc, *srclfe, *srcsl, *srcsr; | 975 | float *srcl, *srcr, *srcc, *srclfe, *srcsl, *srcsr; |
| 971 | int n; | 976 | int n; |
| 972 | 977 | ||
| @@ -977,7 +982,7 @@ static void filter_5_1_side(AVFilterContext *ctx) · 4 unmodified lines | |||
| 977 | srcsl = (float *)s->input->extended_data[4]; | 982 | srcsl = (float *)s->input->extended_data[4]; |
| 978 | srcsr = (float *)s->input->extended_data[5]; | 983 | srcsr = (float *)s->input->extended_data[5]; |
| 979 | 984 | ||
| 980 | for (n = 0; n < s->rdft_size; n++) { | 985 | for (n = 0; n < rdft_size; n++) { |
| 981 | float fl_re = srcl[2 * n], fr_re = srcr[2 * n]; | 986 | float fl_re = srcl[2 * n], fr_re = srcr[2 * n]; |
| 982 | float fl_im = srcl[2 * n + 1], fr_im = srcr[2 * n + 1]; | 987 | float fl_im = srcl[2 * n + 1], fr_im = srcr[2 * n + 1]; |
| 983 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; | 988 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; |
| @@ -1026,6 +1031,7 @@ static void filter_5_1_side(AVFilterContext *ctx) · 42 unmodified lines | |||
| 1026 | static void filter_5_1_back(AVFilterContext *ctx) | 1031 | static void filter_5_1_back(AVFilterContext *ctx) |
| 1027 | { | 1032 | { |
| 1028 | AudioSurroundContext *s = ctx->priv; | 1033 | AudioSurroundContext *s = ctx->priv; |
| 1034 | const int rdft_size = s->rdft_size; | ||
| 1029 | float *srcl, *srcr, *srcc, *srclfe, *srcbl, *srcbr; | 1035 | float *srcl, *srcr, *srcc, *srclfe, *srcbl, *srcbr; |
| 1030 | int n; | 1036 | int n; |
| 1031 | 1037 | ||
| @@ -1036,7 +1042,7 @@ static void filter_5_1_back(AVFilterContext *ctx) · 4 unmodified lines | |||
| 1036 | srcbl = (float *)s->input->extended_data[4]; | 1042 | srcbl = (float *)s->input->extended_data[4]; |
| 1037 | srcbr = (float *)s->input->extended_data[5]; | 1043 | srcbr = (float *)s->input->extended_data[5]; |
| 1038 | 1044 | ||
| 1039 | for (n = 0; n < s->rdft_size; n++) { | 1045 | for (n = 0; n < rdft_size; n++) { |
| 1040 | float fl_re = srcl[2 * n], fr_re = srcr[2 * n]; | 1046 | float fl_re = srcl[2 * n], fr_re = srcr[2 * n]; |
| 1041 | float fl_im = srcl[2 * n + 1], fr_im = srcr[2 * n + 1]; | 1047 | float fl_im = srcl[2 * n + 1], fr_im = srcr[2 * n + 1]; |
| 1042 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; | 1048 | float c_re = srcc[2 * n], c_im = srcc[2 * n + 1]; |