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
94ad5d01
Commit
94ad5d01
authored
Dec 23, 2019
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter/vf_readeia608: factor some constants out
parent
94682555
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
6 deletions
+8
-6
vf_readeia608.c
libavfilter/vf_readeia608.c
+8
-6
No files found.
libavfilter/vf_readeia608.c
View file @
94ad5d01
...
@@ -37,8 +37,10 @@
...
@@ -37,8 +37,10 @@
#include "video.h"
#include "video.h"
#define LAG 25
#define LAG 25
#define SYNC_MIN 12.f
#define CLOCK_BITSIZE_MIN 0.2f
#define SYNC_MAX 15.f
#define CLOCK_BITSIZE_MAX 1.5f
#define SYNC_BITSIZE_MIN 12.f
#define SYNC_BITSIZE_MAX 15.f
typedef
struct
LineItem
{
typedef
struct
LineItem
{
int
input
;
int
input
;
...
@@ -314,8 +316,8 @@ static void extract_line(AVFilterContext *ctx, AVFrame *in, int w, int nb_line)
...
@@ -314,8 +316,8 @@ static void extract_line(AVFilterContext *ctx, AVFrame *in, int w, int nb_line)
dump_code
(
ctx
,
len
,
nb_line
);
dump_code
(
ctx
,
len
,
nb_line
);
if
(
len
<
15
||
if
(
len
<
15
||
s
->
code
[
14
].
bit
!=
0
||
s
->
code
[
14
].
bit
!=
0
||
w
/
(
float
)
s
->
code
[
14
].
size
<
SYNC_MIN
||
w
/
(
float
)
s
->
code
[
14
].
size
<
SYNC_
BITSIZE_
MIN
||
w
/
(
float
)
s
->
code
[
14
].
size
>
SYNC_MAX
)
{
w
/
(
float
)
s
->
code
[
14
].
size
>
SYNC_
BITSIZE_
MAX
)
{
return
;
return
;
}
}
...
@@ -325,8 +327,8 @@ static void extract_line(AVFilterContext *ctx, AVFrame *in, int w, int nb_line)
...
@@ -325,8 +327,8 @@ static void extract_line(AVFilterContext *ctx, AVFrame *in, int w, int nb_line)
bit_size
/=
19
.
f
;
bit_size
/=
19
.
f
;
for
(
i
=
1
;
i
<
14
;
i
++
)
{
for
(
i
=
1
;
i
<
14
;
i
++
)
{
if
(
s
->
code
[
i
].
size
>
bit_size
*
1
.
5
f
||
if
(
s
->
code
[
i
].
size
/
bit_size
>
CLOCK_BITSIZE_MAX
||
s
->
code
[
i
].
size
<
bit_size
*
0
.
2
f
)
{
s
->
code
[
i
].
size
/
bit_size
<
CLOCK_BITSIZE_MIN
)
{
return
;
return
;
}
}
}
}
...
...
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