📄 mpegsub.i
字号:
extern void cexp ( cmplx *z, cmplx *w );extern void csin ( cmplx *z, cmplx *w );extern void ccos ( cmplx *z, cmplx *w );extern void ctan ( cmplx *z, cmplx *w );extern void ccot ( cmplx *z, cmplx *w );extern void casin ( cmplx *z, cmplx *w );extern void cacos ( cmplx *z, cmplx *w );extern void catan ( cmplx *z, cmplx *w );extern void csinh ( cmplx *z, cmplx *w );extern void casinh ( cmplx *z, cmplx *w );extern void ccosh ( cmplx *z, cmplx *w );extern void cacosh ( cmplx *z, cmplx *w );extern void ctanh ( cmplx *z, cmplx *w );extern void catanh ( cmplx *z, cmplx *w );extern void cpow ( cmplx *a, cmplx *z, cmplx *w );extern void cadd ( cmplx *a, cmplx *b, cmplx *c );extern void csub ( cmplx *a, cmplx *b, cmplx *c );extern void cmul ( cmplx *a, cmplx *b, cmplx *c );extern void cdiv ( cmplx *a, cmplx *b, cmplx *c );extern void cmov ( void *a, void *b );extern void cneg ( cmplx *a );extern double cabs ( cmplx *z );extern void csqrt ( cmplx *z, cmplx *w );extern double hypot ( double x, double y );extern double cosh ( double x );extern double dawsn ( double xx );extern int drand ( double *a );extern double ei ( double x );extern double ellie ( double phi, double m );extern double ellik ( double phi, double m );extern double ellpe ( double x );extern int ellpj ( double u, double m, double *sn, double *cn, double *dn, double *ph );extern double ellpk ( double x );extern double exp ( double x );extern double exp10 ( double x );extern double exp2 ( double x );extern double expn ( int n, double x );extern double expx2 ( double x, int sign );extern double fabs ( double x );extern double fac ( int i );extern double fdtrc ( int ia, int ib, double x );extern double fdtr ( int ia, int ib, double x );extern double fdtri ( int ia, int ib, double y );extern int fresnl ( double xxa, double *ssa, double *cca );extern double gamma ( double x );extern double lgam ( double x );extern double gdtr ( double a, double b, double x );extern double gdtrc ( double a, double b, double x );extern double hyp2f1 ( double a, double b, double c, double x );extern double hyperg ( double a, double b, double x );extern double hyp2f0 ( double a, double b, double x, int type, double *err );extern double i0 ( double x );extern double i0e ( double x );extern double i1 ( double x );extern double i1e ( double x );extern double igami ( double, double );extern double incbet ( double aa, double bb, double xx );extern double incbi ( double aa, double bb, double yy0 );extern double igamc ( double a, double x );extern double igam ( double a, double x );extern int signbit ( double x );extern int isnan ( double x );extern int isfinite ( double x );extern double iv ( double v, double x );extern double j0 ( double x );extern double y0 ( double x );extern double j1 ( double x );extern double y1 ( double x );extern double jn ( int n, double x );extern double jv ( double n, double x );extern double k0 ( double x );extern double k0e ( double x );extern double k1 ( double x );extern double k1e ( double x );extern double kn ( int nn, double x );extern double smirnov ( int n, double e );extern double kolmogorov ( double y );extern double smirnovi ( int n, double p );extern double kolmogi ( double p );extern double log ( double x );extern double log2 ( double x );extern double log10 ( double x );extern long lrand ( void );extern double nbdtrc ( int k, int n, double p );extern double nbdtr ( int k, int n, double p );extern double nbdtri ( int k, int n, double p );extern double ndtr ( double a );extern double erfc ( double a );extern double erf ( double x );extern double ndtri ( double );extern double pdtrc ( int k, double m );extern double pdtr ( int k, double m );extern double pdtri ( int k, double y );extern double plancki ( double w, double T );extern double planckc ( double w, double T );extern double planckd ( double w, double T );extern double planckw ( double T );extern double polevl ( double x, double coef[], int N );extern double p1evl ( double x, double coef[], int N );extern void polatn ( double num[], double den[], double ans[], int nn );extern void polsqt ( double pol[], double ans[], int nn );extern void polsin ( double x[], double y[], int nn );extern void polcos ( double x[], double y[], int nn );extern double polylog ( int n, double x );extern void polini ( int maxdeg );extern void polprt ( double a[], int na, int d );extern void polclr ( double *a, int n );extern void polmov ( double *a, int na, double *b );extern void polmul ( double a[], int na, double b[], int nb, double c[] );extern void poladd ( double a[], int na, double b[], int nb, double c[] );extern void polsub ( double a[], int na, double b[], int nb, double c[] );extern int poldiv ( double a[], int na, double b[], int nb, double c[] );extern void polsbt ( double a[], int na, double b[], int nb, double c[] );extern double poleva ( double a[], int na, double x );extern double pow ( double x, double y );extern double powi ( double x, int nn );extern double psi ( double x );extern double rgamma ( double x );extern double round ( double x );extern int shichi ( double x, double *si, double *ci );extern int sici ( double x, double *si, double *ci );extern double sin ( double x );extern double cos ( double x );extern double radian ( double d, double m, double s );extern double sindg ( double x );extern double cosdg ( double x );extern double sinh ( double x );extern double spence ( double x );extern double stdtr ( int k, double t );extern double stdtri ( int k, double p );extern double onef2 ( double a, double b, double c, double x, double *err );extern double threef0 ( double a, double b, double c, double x, double *err );extern double struve ( double v, double x );extern double yv ( double v, double x );extern double tan ( double x );extern double cot ( double x );extern double tandg ( double x );extern double cotdg ( double x );extern double tanh ( double x );extern double log1p ( double x );extern double expm1 ( double x );extern double cosm1 ( double x );extern double yn ( int n, double x );extern double zeta ( double x, double q );extern double zetac ( double x );extern double sqrt ( double x );extern double ceil ( double x );extern double floor ( double x );extern double frexp ( double x, int *pw2 );extern double ldexp ( double x, int pw2 );extern int sprec ( void );extern int dprec ( void );extern int ldprec ( void );extern int mtherr ( char *name, int code ); extern float acosf ( float x );extern float acoshf ( float xx );extern int airyf ( float xx, float *ai, float *aip, float *bi, float *bip );extern float asinf ( float xx );extern float asinhf ( float xx );extern float atan2f ( float y, float x );extern float atanf ( float xx );extern float atanhf ( float xx );extern float bdtrcf ( int k, int n, float pp );extern float bdtrf ( int k, int n, float pp );extern float bdtrif ( int k, int n, float yy );extern float betaf ( float aa, float bb );extern float cabsf ( cmplxf *z );extern void cacosf ( cmplxf *z, cmplxf *w );extern void caddf ( cmplxf *a, cmplxf *b, cmplxf *c );extern void casinf ( cmplxf *z, cmplxf *w );extern void catanf ( cmplxf *z, cmplxf *w );extern float cbrtf ( float xx );extern void cchshf ( float xx, float *c, float *s );extern void ccosf ( cmplxf *z, cmplxf *w );extern void ccotf ( cmplxf *z, cmplxf *w );extern void cdivf ( cmplxf *a, cmplxf *b, cmplxf *c );extern float ceilf ( float x );extern void cexpf ( cmplxf *z, cmplxf *w );extern float chbevlf ( float x, float *array, int n );extern float chdtrcf ( float dff, float xx );extern float chdtrf ( float dff, float xx );extern float chdtrif ( float dff, float yy );extern void clogf ( cmplxf *z, cmplxf *w );extern void cmovf ( short *a, short *b );extern void cmulf ( cmplxf *a, cmplxf *b, cmplxf *c );extern void cnegf ( cmplxf *a );extern float cosdgf ( float xx );extern float cosf ( float xx );extern float coshf ( float xx );extern float cotdgf ( float x );extern float cotf ( float x );extern void csinf ( cmplxf *z, cmplxf *w );extern void csqrtf ( cmplxf *z, cmplxf *w );extern void csubf ( cmplxf *a, cmplxf *b, cmplxf *c );extern void ctanf ( cmplxf *z, cmplxf *w );extern float ctansf ( cmplxf *z );extern float dawsnf ( float xxx );extern int dprec ( void );extern float ellief ( float phia, float ma );extern float ellikf ( float phia, float ma );extern float ellpef ( float xx );extern int ellpjf ( float uu, float mm, float *sn, float *cn, float *dn, float *ph );extern float ellpkf ( float xx );extern float erfcf ( float aa );extern float erff ( float xx );extern float exp10f ( float xx );extern float exp2f ( float xx );extern float expf ( float xx );extern float expnf ( int n, float xx );extern float facf ( int i );extern float fdtrcf ( int ia, int ib, float xx );extern float fdtrf ( int ia, int ib, int xx );extern float fdtrif ( int ia, int ib, float yy );extern float floorf ( float x );extern void fresnlf ( float xxa, float *ssa, float *cca );extern float frexpf ( float x, int *pw2 );extern float gammaf ( float xx );extern float gdtrcf ( float aa, float bb, float xx );extern float gdtrf ( float aa, float bb, float xx );extern float hyp2f0f ( float aa, float bb, float xx, int type, float *err );extern float hyp2f1f ( float aa, float bb, float cc, float xx );extern float hypergf ( float aa, float bb, float xx );extern float i0ef ( float x );extern float i0f ( float x );extern float i1ef ( float xx );extern float i1f ( float xx );extern float igamcf ( float aa, float xx );extern float igamf ( float aa, float xx );extern float igamif ( float aa, float yy0 );extern float incbetf ( float aaa, float bbb, float xxx );extern float incbif ( float aaa, float bbb, float yyy0 );extern float incbpsf ( float aa, float bb, float xx );extern float ivf ( float v, float x );extern float j0f ( float xx );extern float j1f ( float xx );extern float jnf ( int n, float xx );extern float jvf ( float nn, float xx );extern float k0ef ( float xx );extern float k0f ( float xx );extern float k1ef ( float xx );extern float k1f ( float xx );extern float knf ( int nnn, float xx );extern float ldexpf ( float x, int pw2 );extern int ldprec ( void );extern float lgamf ( float xx );extern float log10f ( float xx );extern float log2f ( float xx );extern float logf ( float xx );extern int mtherr ( char *name, int code );extern float nbdtrcf ( int k, int n, float pp );extern float nbdtrf ( int k, int n, float pp );extern float ndtrf ( float aa );extern float ndtrif ( float yy0 );extern float onef2f ( float aa, float bb, float cc, float xx, float *err );extern float p1evlf ( float xx, float *coef, int N );extern float pdtrcf ( int k, float mm );extern float pdtrf ( int k, float mm );extern float pdtrif ( int k, float yy );extern void poladdf ( float a[], int na, float b[], int nb, float c[] );extern void polclrf ( float *a, int n );extern int poldivf ( float a[], int na, float b[], int nb, float c[] );extern float polevaf ( float *a, int na, float xx );extern float polevlf ( float xx, float *coef, int N );extern void polinif ( int maxdeg );extern void polmovf ( float *a, int na, float *b );extern void polmulf ( float a[], int na, float b[], int nb, float c[] );extern void polprtf ( float *a, int na, int d );extern void polsbtf ( float a[], int na, float b[], int nb, float c[] );extern void polsubf ( float a[], int na, float b[], int nb, float c[] );extern float powf ( float x, float y );extern float powif ( float x, int nn );extern float psif ( float xx );extern float redupif ( float xx );extern float rgammaf ( float xx );extern int shichif ( float xx, float *si, float *ci );extern int sicif ( float xx, float *si, float *ci );extern float sindgf ( float xx );extern float sinf ( float xx );extern float sinhf ( float xx );extern float spencef ( float xx );extern int sprec ( void );extern float sqrtf ( float xx );extern float stdtrf ( int k, float tt );extern float struvef ( float vv, float xx );extern float tandgf ( float x );extern float tanf ( float x );extern float tanhf ( float xx );extern float threef0f ( float aa, float bb, float cc, float xx, float *err );extern float y0f ( float xx );extern float y1f ( float xx );extern float ynf ( int nn, float xx );extern float yvf ( float vv, float xx );extern float zetacf ( float xx );extern float zetaf ( float xx, float qq );# 452 "/home/gerg/new-wave.5249/lib/libc/include/machine/__math.h" 2 # 1 "/home/gerg/new-wave.5249/lib/libc/include/math.h" 2# 33 "mpegsub.c" 2 # 80 "mpegsub.c" # 117 "mpegsub.c" static void sub_dct(INT32 *p){ INT32 pp[16]; INT32 *d1, *d2, *s1, *s2; d1 = &pp[0]; d2 = &pp[8]; s1 = &p[0]; s2 = &p[16]; *d1++ = *s1 + *--s2; *d2++ = ((( (32927>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (34242>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (37155>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (42390>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (51653>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (69513>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (112882>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (334309>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &p[0]; d2 = &p[4]; s1 = &pp[0]; s2 = &pp[8]; *d1++ = *s1 + *--s2; *d2++ = ((( (33410>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (39410>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (58981>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (167963>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &p[8]; d2 = &p[12]; s1 = &pp[8]; s2 = &pp[16]; *d1++ = *s1 + *--s2; *d2++ = ((( (33410>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (39410>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (58981>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (167963>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &pp[0]; d2 = &pp[2]; s1 = &p[0]; s2 = &p[4]; *d1++ = *s1 + *--s2; *d2++ = ((( (35468>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (85627>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &pp[4]; d2 = &pp[6]; s1 = &p[4]; s2 = &p[8]; *d1++ = *s1 + *--s2; *d2++ = ((( (35468>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (85627>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &pp[8]; d2 = &pp[10]; s1 = &p[8]; s2 = &p[12]; *d1++ = *s1 + *--s2; *d2++ = ((( (35468>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (85627>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &pp[12]; d2 = &pp[14]; s1 = &p[12]; s2 = &p[16]; *d1++ = *s1 + *--s2; *d2++ = ((( (35468>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (85627>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &p[0]; *d1++ = pp[0] + pp[1]; *d1++ = ((( (46341>> 1 ) ) * ( pp[0] - pp[1] ))>>((16- 1 ) )) ; *d1++ = pp[2] + pp[3]; *d1++ = ((( (46341>> 1 ) ) * ( pp[2] - pp[3] ))>>((16- 1 ) )) ; *d1++ = pp[4] + pp[5]; *d1++ = ((( (46341>> 1 ) ) * ( pp[4] - pp[5] ))>>((16- 1 ) )) ; *d1++ = pp[6] + pp[7]; *d1++ = ((( (46341>> 1 ) ) * ( pp[6] - pp[7] ))>>((16- 1 ) )) ; *d1++ = pp[8] + pp[9]; *d1++ = ((( (46341>> 1 ) ) * ( pp[8] - pp[9] ))>>((16- 1 ) )) ; *d1++ = pp[10] + pp[11]; *d1++ = ((( (46341>> 1 ) ) * ( pp[10] - pp[11] ))>>((16- 1 ) )) ; *d1++ = pp[12] + pp[13]; *d1++ = ((( (46341>> 1 ) ) * ( pp[12] - pp[13] ))>>((16- 1 ) )) ; *d1++ = pp[14] + pp[15]; *d1++ = ((( (46341>> 1 ) ) * ( pp[14] - pp[15] ))>>((16- 1 ) )) ;} static void sub_half_dct(INT32 *p){ INT32 pp[8]; INT32 *d1, *d2, *s1, *s2; INT32 p1, p2; d1 = &pp[0]; d2 = &pp[4]; s1 = &p[0]; s2 = &p[8]; *d1++ = *s1 + *--s2; *d2++ = ((( (33410>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (39410>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (58981>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (167963>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &p[0]; d2 = &p[2]; s1 = &pp[0]; s2 = &pp[4]; *d1++ = *s1 + *--s2; *d2++ = ((( (35468>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (85627>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &p[4]; d2 = &p[6]; s1 = &pp[4]; s2 = &pp[8]; *d1++ = *s1 + *--s2; *d2++ = ((( (35468>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; *d1++ = *s1 + *--s2; *d2++ = ((( (85627>> 1 ) ) * ( *s1++ - *s2 ))>>((16- 1 ) )) ; d1 = &p[0]; p1 = *d1; p2 = p[1]; *d1++ = p1 + p2; p1 -= p2; *d1++ = ((( (46341>> 1 ) ) * ( p1 ))>>((16- 1 ) )) ; p1 = *d1; p2 = p[3]; *d1++ = p1 + p2; p1 -= p2; *d1++ = ((( (46341>> 1 ) ) * ( p1 ))>>((16- 1 ) )) ; p1 = *d1; p2 = p[7]; *d1++ = p1 + p2; p1 -= p2; *d1++ = ((( (46341>> 1 ) ) * ( p1 ))>>((16- 1 ) )) ; p1 = *d1; p2 = p[9]; *d1++ = p1 + p2; p1 -= p2; *d1 = ((( (46341>> 1 ) ) * ( p1 ))>>((16- 1 ) )) ;} static void fast_dct(INT16 *samples, INT16 *sy0, INT16 *sy1, INT16 freq_div){ INT16 *x1, *x2; INT32 *d; INT32 s, s0, s1, s2, s3, tmp; INT32 p[16]; static int init = 0; static FILE *fsamp; static FILE *fsamp_in; int i; x1 = samples; x2 = samples + 31; d = p; if (freq_div == 4) { *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d = *x1; sub_half_dct(p); sy0[ 0 *16] = p[1]; sy1[ 0 *16] = -p[1]; s = p[5] + p[7]; sy0[ 4 *16] = s; sy0[ 28 *16] = -s; sy0[ 8 *16] = p[3]; sy0[ 24 *16] = -p[3]; sy0[ 12 *16] = p[7]; sy0[ 20 *16] = -p[7]; sy0[ 16 *16] = (INT32 ) 0; s = p[6] + p[7]; sy1[ 4 *16] = sy1[ 28 *16] = -(p[5] + s); sy1[ 8 *16] = sy1[ 24 *16] = -(p[2] + p[3]); sy1[ 12 *16] = sy1[ 20 *16] = -(p[4] + s); sy1[ 16 *16] = -p[0]; return; } else if (freq_div == 2) { *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d++ = *x1++; *d = *x1; } else { *d++ = *x1++ + *x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2; *d++ = *x1++ + *--x2;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -