Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
1274ea8d
Commit
1274ea8d
authored
Aug 29, 2014
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Split off floating point AAN (I)DCT into separate components
parent
fcf59762
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
26 additions
and
9 deletions
+26
-9
configure
configure
+7
-0
Makefile
libavcodec/Makefile
+4
-4
dct-test.c
libavcodec/dct-test.c
+7
-3
fdctdsp.c
libavcodec/fdctdsp.c
+2
-0
idctdsp.c
libavcodec/idctdsp.c
+2
-0
mpegvideo_enc.c
libavcodec/mpegvideo_enc.c
+4
-2
No files found.
configure
View file @
1274ea8d
...
@@ -130,6 +130,7 @@ Component options:
...
@@ -130,6 +130,7 @@ Component options:
--disable-mdct disable MDCT code
--disable-mdct disable MDCT code
--disable-rdft disable RDFT code
--disable-rdft disable RDFT code
--disable-fft disable FFT code
--disable-fft disable FFT code
--disable-faan disable floating point AAN (I)DCT code
Hardware accelerators:
Hardware accelerators:
--enable-dxva2 enable DXVA2 code
--enable-dxva2 enable DXVA2 code
...
@@ -1220,6 +1221,7 @@ SUBSYSTEM_LIST="
...
@@ -1220,6 +1221,7 @@ SUBSYSTEM_LIST="
dct
dct
doc
doc
error_resilience
error_resilience
faan
fft
fft
lsp
lsp
lzo
lzo
...
@@ -1547,6 +1549,8 @@ CONFIG_EXTRA="
...
@@ -1547,6 +1549,8 @@ CONFIG_EXTRA="
bswapdsp
bswapdsp
cabac
cabac
dvprofile
dvprofile
faandct
faanidct
fdctdsp
fdctdsp
gcrypt
gcrypt
golomb
golomb
...
@@ -1725,6 +1729,8 @@ threads_if_any="$THREADS_LIST"
...
@@ -1725,6 +1729,8 @@ threads_if_any="$THREADS_LIST"
# subsystems
# subsystems
dct_select
=
"rdft"
dct_select
=
"rdft"
error_resilience_select
=
"me_cmp"
error_resilience_select
=
"me_cmp"
faandct_deps
=
"faan fdctdsp"
faanidct_deps
=
"faan idctdsp"
intrax8_select
=
"error_resilience"
intrax8_select
=
"error_resilience"
mdct_select
=
"fft"
mdct_select
=
"fft"
rdft_select
=
"fft"
rdft_select
=
"fft"
...
@@ -2221,6 +2227,7 @@ enable $EXAMPLE_LIST $LIBRARY_LIST $PROGRAM_LIST
...
@@ -2221,6 +2227,7 @@ enable $EXAMPLE_LIST $LIBRARY_LIST $PROGRAM_LIST
enable
asm
enable
asm
enable
debug
enable
debug
enable
doc
enable
doc
enable
faan faandct faanidct
enable
optimizations
enable
optimizations
enable
safe_bitstream_reader
enable
safe_bitstream_reader
enable
static
enable
static
...
...
libavcodec/Makefile
View file @
1274ea8d
...
@@ -36,8 +36,9 @@ OBJS-$(CONFIG_BSWAPDSP) += bswapdsp.o
...
@@ -36,8 +36,9 @@ OBJS-$(CONFIG_BSWAPDSP) += bswapdsp.o
OBJS-$(CONFIG_CABAC)
+=
cabac.o
OBJS-$(CONFIG_CABAC)
+=
cabac.o
OBJS-$(CONFIG_DCT)
+=
dct.o
dct32_fixed.o
dct32_float.o
OBJS-$(CONFIG_DCT)
+=
dct.o
dct32_fixed.o
dct32_float.o
OBJS-$(CONFIG_ERROR_RESILIENCE)
+=
error_resilience.o
OBJS-$(CONFIG_ERROR_RESILIENCE)
+=
error_resilience.o
OBJS-$(CONFIG_FDCTDSP)
+=
fdctdsp.o
faandct.o
\
OBJS-$(CONFIG_FAANDCT)
+=
faandct.o
jfdctfst.o
jfdctint.o
OBJS-$(CONFIG_FAANIDCT)
+=
faanidct.o
OBJS-$(CONFIG_FDCTDSP)
+=
fdctdsp.o
jfdctfst.o
jfdctint.o
FFT-OBJS-$(CONFIG_HARDCODED_TABLES)
+=
cos_tables.o
cos_fixed_tables.o
FFT-OBJS-$(CONFIG_HARDCODED_TABLES)
+=
cos_tables.o
cos_fixed_tables.o
OBJS-$(CONFIG_FFT)
+=
avfft.o
fft_fixed.o
fft_float.o
\
OBJS-$(CONFIG_FFT)
+=
avfft.o
fft_fixed.o
fft_float.o
\
$(FFT-OBJS-yes)
$(FFT-OBJS-yes)
...
@@ -51,8 +52,7 @@ OBJS-$(CONFIG_HPELDSP) += hpeldsp.o
...
@@ -51,8 +52,7 @@ OBJS-$(CONFIG_HPELDSP) += hpeldsp.o
OBJS-$(CONFIG_HUFFMAN)
+=
huffman.o
OBJS-$(CONFIG_HUFFMAN)
+=
huffman.o
OBJS-$(CONFIG_HUFFYUVDSP)
+=
huffyuvdsp.o
OBJS-$(CONFIG_HUFFYUVDSP)
+=
huffyuvdsp.o
OBJS-$(CONFIG_HUFFYUVENCDSP)
+=
huffyuvencdsp.o
OBJS-$(CONFIG_HUFFYUVENCDSP)
+=
huffyuvencdsp.o
OBJS-$(CONFIG_IDCTDSP)
+=
idctdsp.o
faanidct.o
\
OBJS-$(CONFIG_IDCTDSP)
+=
idctdsp.o
simple_idct.o
jrevdct.o
simple_idct.o
jrevdct.o
OBJS-$(CONFIG_IIRFILTER)
+=
iirfilter.o
OBJS-$(CONFIG_IIRFILTER)
+=
iirfilter.o
OBJS-$(CONFIG_INTRAX8)
+=
intrax8.o
intrax8dsp.o
OBJS-$(CONFIG_INTRAX8)
+=
intrax8.o
intrax8dsp.o
OBJS-$(CONFIG_LIBXVID)
+=
libxvid_rc.o
OBJS-$(CONFIG_LIBXVID)
+=
libxvid_rc.o
...
...
libavcodec/dct-test.c
View file @
1274ea8d
...
@@ -56,18 +56,22 @@ struct algo {
...
@@ -56,18 +56,22 @@ struct algo {
int
nonspec
;
int
nonspec
;
};
};
static
const
struct
algo
fdct_tab
[
4
]
=
{
static
const
struct
algo
fdct_tab
[]
=
{
{
"REF-DBL"
,
ff_ref_fdct
,
FF_IDCT_PERM_NONE
},
{
"REF-DBL"
,
ff_ref_fdct
,
FF_IDCT_PERM_NONE
},
{
"FAAN"
,
ff_faandct
,
FF_IDCT_PERM_NONE
},
{
"IJG-AAN-INT"
,
ff_fdct_ifast
,
FF_IDCT_PERM_NONE
},
{
"IJG-AAN-INT"
,
ff_fdct_ifast
,
FF_IDCT_PERM_NONE
},
{
"IJG-LLM-INT"
,
ff_jpeg_fdct_islow_8
,
FF_IDCT_PERM_NONE
},
{
"IJG-LLM-INT"
,
ff_jpeg_fdct_islow_8
,
FF_IDCT_PERM_NONE
},
#if CONFIG_FAANDCT
{
"FAAN"
,
ff_faandct
,
FF_IDCT_PERM_NONE
},
#endif
/* CONFIG_FAANDCT */
};
};
static
const
struct
algo
idct_tab
[]
=
{
static
const
struct
algo
idct_tab
[]
=
{
{
"FAANI"
,
ff_faanidct
,
FF_IDCT_PERM_NONE
},
{
"REF-DBL"
,
ff_ref_idct
,
FF_IDCT_PERM_NONE
},
{
"REF-DBL"
,
ff_ref_idct
,
FF_IDCT_PERM_NONE
},
{
"INT"
,
ff_j_rev_dct
,
FF_IDCT_PERM_LIBMPEG2
},
{
"INT"
,
ff_j_rev_dct
,
FF_IDCT_PERM_LIBMPEG2
},
{
"SIMPLE-C"
,
ff_simple_idct_8
,
FF_IDCT_PERM_NONE
},
{
"SIMPLE-C"
,
ff_simple_idct_8
,
FF_IDCT_PERM_NONE
},
#if CONFIG_FAANIDCT
{
"FAANI"
,
ff_faanidct
,
FF_IDCT_PERM_NONE
},
#endif
/* CONFIG_FAANIDCT */
#if CONFIG_MPEG4_DECODER
#if CONFIG_MPEG4_DECODER
{
"XVID"
,
ff_xvid_idct
,
FF_IDCT_PERM_NONE
,
0
,
1
},
{
"XVID"
,
ff_xvid_idct
,
FF_IDCT_PERM_NONE
,
0
,
1
},
#endif
/* CONFIG_MPEG4_DECODER */
#endif
/* CONFIG_MPEG4_DECODER */
...
...
libavcodec/fdctdsp.c
View file @
1274ea8d
...
@@ -33,9 +33,11 @@ av_cold void ff_fdctdsp_init(FDCTDSPContext *c, AVCodecContext *avctx)
...
@@ -33,9 +33,11 @@ av_cold void ff_fdctdsp_init(FDCTDSPContext *c, AVCodecContext *avctx)
}
else
if
(
avctx
->
dct_algo
==
FF_DCT_FASTINT
)
{
}
else
if
(
avctx
->
dct_algo
==
FF_DCT_FASTINT
)
{
c
->
fdct
=
ff_fdct_ifast
;
c
->
fdct
=
ff_fdct_ifast
;
c
->
fdct248
=
ff_fdct_ifast248
;
c
->
fdct248
=
ff_fdct_ifast248
;
#if CONFIG_FAANDCT
}
else
if
(
avctx
->
dct_algo
==
FF_DCT_FAAN
)
{
}
else
if
(
avctx
->
dct_algo
==
FF_DCT_FAAN
)
{
c
->
fdct
=
ff_faandct
;
c
->
fdct
=
ff_faandct
;
c
->
fdct248
=
ff_faandct248
;
c
->
fdct248
=
ff_faandct248
;
#endif
/* CONFIG_FAANDCT */
}
else
{
}
else
{
c
->
fdct
=
ff_jpeg_fdct_islow_8
;
// slow/accurate/default
c
->
fdct
=
ff_jpeg_fdct_islow_8
;
// slow/accurate/default
c
->
fdct248
=
ff_fdct248_islow_8
;
c
->
fdct248
=
ff_fdct248_islow_8
;
...
...
libavcodec/idctdsp.c
View file @
1274ea8d
...
@@ -158,11 +158,13 @@ av_cold void ff_idctdsp_init(IDCTDSPContext *c, AVCodecContext *avctx)
...
@@ -158,11 +158,13 @@ av_cold void ff_idctdsp_init(IDCTDSPContext *c, AVCodecContext *avctx)
c
->
idct_add
=
ff_jref_idct_add
;
c
->
idct_add
=
ff_jref_idct_add
;
c
->
idct
=
ff_j_rev_dct
;
c
->
idct
=
ff_j_rev_dct
;
c
->
perm_type
=
FF_IDCT_PERM_LIBMPEG2
;
c
->
perm_type
=
FF_IDCT_PERM_LIBMPEG2
;
#if CONFIG_FAANIDCT
}
else
if
(
avctx
->
idct_algo
==
FF_IDCT_FAAN
)
{
}
else
if
(
avctx
->
idct_algo
==
FF_IDCT_FAAN
)
{
c
->
idct_put
=
ff_faanidct_put
;
c
->
idct_put
=
ff_faanidct_put
;
c
->
idct_add
=
ff_faanidct_add
;
c
->
idct_add
=
ff_faanidct_add
;
c
->
idct
=
ff_faanidct
;
c
->
idct
=
ff_faanidct
;
c
->
perm_type
=
FF_IDCT_PERM_NONE
;
c
->
perm_type
=
FF_IDCT_PERM_NONE
;
#endif
/* CONFIG_FAANIDCT */
}
else
{
// accurate/default
}
else
{
// accurate/default
c
->
idct_put
=
ff_simple_idct_put_8
;
c
->
idct_put
=
ff_simple_idct_put_8
;
c
->
idct_add
=
ff_simple_idct_add_8
;
c
->
idct_add
=
ff_simple_idct_add_8
;
...
...
libavcodec/mpegvideo_enc.c
View file @
1274ea8d
...
@@ -89,8 +89,10 @@ void ff_convert_matrix(MpegEncContext *s, int (*qmat)[64],
...
@@ -89,8 +89,10 @@ void ff_convert_matrix(MpegEncContext *s, int (*qmat)[64],
for
(
qscale
=
qmin
;
qscale
<=
qmax
;
qscale
++
)
{
for
(
qscale
=
qmin
;
qscale
<=
qmax
;
qscale
++
)
{
int
i
;
int
i
;
if
(
fdsp
->
fdct
==
ff_jpeg_fdct_islow_8
||
if
(
fdsp
->
fdct
==
ff_jpeg_fdct_islow_8
||
fdsp
->
fdct
==
ff_jpeg_fdct_islow_10
||
#if CONFIG_FAANDCT
fdsp
->
fdct
==
ff_faandct
)
{
fdsp
->
fdct
==
ff_faandct
||
#endif
/* CONFIG_FAANDCT */
fdsp
->
fdct
==
ff_jpeg_fdct_islow_10
)
{
for
(
i
=
0
;
i
<
64
;
i
++
)
{
for
(
i
=
0
;
i
<
64
;
i
++
)
{
const
int
j
=
s
->
idsp
.
idct_permutation
[
i
];
const
int
j
=
s
->
idsp
.
idct_permutation
[
i
];
/* 16 <= qscale * quant_matrix[i] <= 7905
/* 16 <= qscale * quant_matrix[i] <= 7905
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment