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
7a4e30f3
Commit
7a4e30f3
authored
Jul 26, 2012
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
h264_cabac: switch to av_assert
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
d5d5e3da
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
8 deletions
+6
-8
h264_cabac.c
libavcodec/h264_cabac.c
+6
-8
No files found.
libavcodec/h264_cabac.c
View file @
7a4e30f3
...
...
@@ -38,14 +38,12 @@
#include "h264data.h"
#include "h264_mvpred.h"
#include "golomb.h"
#include "libavutil/avassert.h"
#if ARCH_X86
#include "x86/h264_i386.h"
#endif
//#undef NDEBUG
#include <assert.h>
/* Cabac pre state table */
static
const
int8_t
cabac_context_init_I
[
1024
][
2
]
=
...
...
@@ -1672,7 +1670,7 @@ decode_cabac_residual_internal(H264Context *h, DCTELEM *block,
}
#endif
}
a
ssert
(
coeff_count
>
0
);
a
v_assert2
(
coeff_count
>
0
);
if
(
is_dc
)
{
if
(
cat
==
3
)
...
...
@@ -1684,7 +1682,7 @@ decode_cabac_residual_internal(H264Context *h, DCTELEM *block,
if
(
max_coeff
==
64
)
fill_rectangle
(
&
h
->
non_zero_count_cache
[
scan8
[
n
]],
2
,
2
,
8
,
coeff_count
,
1
);
else
{
a
ssert
(
cat
==
1
||
cat
==
2
||
cat
==
4
||
cat
==
7
||
cat
==
8
||
cat
==
11
||
cat
==
12
);
a
v_assert2
(
cat
==
1
||
cat
==
2
||
cat
==
4
||
cat
==
7
||
cat
==
8
||
cat
==
11
||
cat
==
12
);
h
->
non_zero_count_cache
[
scan8
[
n
]]
=
coeff_count
;
}
}
...
...
@@ -1911,7 +1909,7 @@ int ff_h264_decode_mb_cabac(H264Context *h) {
if
(
h
->
slice_type_nos
==
AV_PICTURE_TYPE_B
)
{
int
ctx
=
0
;
a
ssert
(
h
->
slice_type_nos
==
AV_PICTURE_TYPE_B
);
a
v_assert2
(
h
->
slice_type_nos
==
AV_PICTURE_TYPE_B
);
if
(
!
IS_DIRECT
(
h
->
left_type
[
LTOP
]
-
1
)
)
ctx
++
;
...
...
@@ -1964,7 +1962,7 @@ int ff_h264_decode_mb_cabac(H264Context *h) {
mb_type
=
decode_cabac_intra_mb_type
(
h
,
3
,
1
);
if
(
h
->
slice_type
==
AV_PICTURE_TYPE_SI
&&
mb_type
)
mb_type
--
;
a
ssert
(
h
->
slice_type_nos
==
AV_PICTURE_TYPE_I
);
a
v_assert2
(
h
->
slice_type_nos
==
AV_PICTURE_TYPE_I
);
decode_intra_mb:
partition_count
=
0
;
cbp
=
i_mb_type_info
[
mb_type
].
cbp
;
...
...
@@ -2225,7 +2223,7 @@ decode_intra_mb:
}
}
}
else
{
a
ssert
(
IS_8X16
(
mb_type
));
a
v_assert2
(
IS_8X16
(
mb_type
));
for
(
list
=
0
;
list
<
h
->
list_count
;
list
++
){
for
(
i
=
0
;
i
<
2
;
i
++
){
if
(
IS_DIR
(
mb_type
,
i
,
list
)){
//FIXME optimize
...
...
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