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
00e96613
Commit
00e96613
authored
Jan 03, 2016
by
Clément Bœsch
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lavc/ccaption_dec: use ff_parity()
parent
2ce29d17
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
36 deletions
+2
-36
ccaption_dec.c
libavcodec/ccaption_dec.c
+2
-36
No files found.
libavcodec/ccaption_dec.c
View file @
00e96613
...
...
@@ -100,40 +100,6 @@ static const unsigned char pac2_attribs[32][3] = // Color, font, ident
/* total 32 entries */
};
/* 0-255 needs 256 spaces */
static
const
uint8_t
parity_table
[
256
]
=
{
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
,
1
,
0
,
0
,
1
,
1
,
0
,
0
,
1
,
0
,
1
,
1
,
0
};
struct
Screen
{
/* +1 is used to compensate null character of string */
uint8_t
characters
[
SCREEN_ROWS
][
SCREEN_COLUMNS
+
1
];
...
...
@@ -236,10 +202,10 @@ static int validate_cc_data_pair(uint8_t *cc_data_pair)
// if EIA-608 data then verify parity.
if
(
cc_type
==
0
||
cc_type
==
1
)
{
if
(
!
parity_table
[
cc_data_pair
[
2
]]
)
{
if
(
!
ff_parity
(
cc_data_pair
[
2
])
)
{
return
AVERROR_INVALIDDATA
;
}
if
(
!
parity_table
[
cc_data_pair
[
1
]]
)
{
if
(
!
ff_parity
(
cc_data_pair
[
1
])
)
{
cc_data_pair
[
1
]
=
0x7F
;
}
}
...
...
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