Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFmpeg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
libremedia
Tethys
FFmpeg
Commits
d1529273
Commit
d1529273
authored
10 years ago
by
Clément Bœsch
Browse files
Options
Downloads
Patches
Plain Diff
avfilter/xbr: make xbr[234]x a bit more consistent
parent
a99004a9
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libavfilter/vf_xbr.c
+12
-13
12 additions, 13 deletions
libavfilter/vf_xbr.c
with
12 additions
and
13 deletions
libavfilter/vf_xbr.c
+
12
−
13
View file @
d1529273
...
@@ -181,8 +181,8 @@ static uint32_t pixel_diff(uint32_t x, uint32_t y, const uint32_t *r2y)
...
@@ -181,8 +181,8 @@ static uint32_t pixel_diff(uint32_t x, uint32_t y, const uint32_t *r2y)
static
void
xbr2x
(
AVFrame
*
input
,
AVFrame
*
output
,
const
uint32_t
*
r2y
)
static
void
xbr2x
(
AVFrame
*
input
,
AVFrame
*
output
,
const
uint32_t
*
r2y
)
{
{
int
x
,
y
;
int
x
,
y
;
int
next_line
=
output
->
linesize
[
0
]
>>
2
;
const
int
nl
=
output
->
linesize
[
0
]
>>
2
;
for
(
y
=
0
;
y
<
input
->
height
;
y
++
)
{
for
(
y
=
0
;
y
<
input
->
height
;
y
++
)
{
INIT_SRC_DST_POINTERS
(
2
)
INIT_SRC_DST_POINTERS
(
2
)
...
@@ -190,12 +190,12 @@ static void xbr2x(AVFrame * input, AVFrame * output, const uint32_t * r2y)
...
@@ -190,12 +190,12 @@ static void xbr2x(AVFrame * input, AVFrame * output, const uint32_t * r2y)
for
(
x
=
0
;
x
<
input
->
width
;
x
++
)
{
for
(
x
=
0
;
x
<
input
->
width
;
x
++
)
{
INIT_21_PIXELS
INIT_21_PIXELS
E
[
0
]
=
E
[
1
]
=
E
[
n
ext_line
]
=
E
[
next_line
+
1
]
=
PE
;
// 0, 1, 2, 3
E
[
0
]
=
E
[
1
]
=
E
[
n
l
]
=
E
[
nl
+
1
]
=
PE
;
// 0, 1, 2, 3
FILT2
(
PE
,
PI
,
PH
,
PF
,
PG
,
PC
,
PD
,
PB
,
PA
,
G5
,
C4
,
G0
,
D0
,
C1
,
B1
,
F4
,
I4
,
H5
,
I5
,
A0
,
A1
,
0
,
1
,
n
ext_line
,
next_line
+
1
);
FILT2
(
PE
,
PI
,
PH
,
PF
,
PG
,
PC
,
PD
,
PB
,
PA
,
G5
,
C4
,
G0
,
D0
,
C1
,
B1
,
F4
,
I4
,
H5
,
I5
,
A0
,
A1
,
0
,
1
,
n
l
,
nl
+
1
);
FILT2
(
PE
,
PC
,
PF
,
PB
,
PI
,
PA
,
PH
,
PD
,
PG
,
I4
,
A1
,
I5
,
H5
,
A0
,
D0
,
B1
,
C1
,
F4
,
C4
,
G5
,
G0
,
n
ext_line
,
0
,
next_line
+
1
,
1
);
FILT2
(
PE
,
PC
,
PF
,
PB
,
PI
,
PA
,
PH
,
PD
,
PG
,
I4
,
A1
,
I5
,
H5
,
A0
,
D0
,
B1
,
C1
,
F4
,
C4
,
G5
,
G0
,
n
l
,
0
,
nl
+
1
,
1
);
FILT2
(
PE
,
PA
,
PB
,
PD
,
PC
,
PG
,
PF
,
PH
,
PI
,
C1
,
G0
,
C4
,
F4
,
G5
,
H5
,
D0
,
A0
,
B1
,
A1
,
I4
,
I5
,
n
ext_line
+
1
,
next_line
,
1
,
0
);
FILT2
(
PE
,
PA
,
PB
,
PD
,
PC
,
PG
,
PF
,
PH
,
PI
,
C1
,
G0
,
C4
,
F4
,
G5
,
H5
,
D0
,
A0
,
B1
,
A1
,
I4
,
I5
,
n
l
+
1
,
nl
,
1
,
0
);
FILT2
(
PE
,
PG
,
PD
,
PH
,
PA
,
PI
,
PB
,
PF
,
PC
,
A0
,
I5
,
A1
,
B1
,
I4
,
F4
,
H5
,
G5
,
D0
,
G0
,
C1
,
C4
,
1
,
n
ext_line
+
1
,
0
,
next_line
);
FILT2
(
PE
,
PG
,
PD
,
PH
,
PA
,
PI
,
PB
,
PF
,
PC
,
A0
,
I5
,
A1
,
B1
,
I4
,
F4
,
H5
,
G5
,
D0
,
G0
,
C1
,
C4
,
1
,
n
l
+
1
,
0
,
nl
);
sa0
+=
1
;
sa0
+=
1
;
sa1
+=
1
;
sa1
+=
1
;
...
@@ -250,14 +250,14 @@ static void xbr2x(AVFrame * input, AVFrame * output, const uint32_t * r2y)
...
@@ -250,14 +250,14 @@ static void xbr2x(AVFrame * input, AVFrame * output, const uint32_t * r2y)
static
void
xbr3x
(
AVFrame
*
input
,
AVFrame
*
output
,
const
uint32_t
*
r2y
)
static
void
xbr3x
(
AVFrame
*
input
,
AVFrame
*
output
,
const
uint32_t
*
r2y
)
{
{
const
int
nl
=
output
->
linesize
[
0
]
>>
2
;
int
x
,
y
;
const
int
nl
=
output
->
linesize
[
0
]
>>
2
;
const
int
nl1
=
nl
+
nl
;
const
int
nl1
=
nl
+
nl
;
int
x
,
y
;
for
(
y
=
0
;
y
<
input
->
height
;
y
++
)
{
for
(
y
=
0
;
y
<
input
->
height
;
y
++
)
{
INIT_SRC_DST_POINTERS
(
3
)
INIT_SRC_DST_POINTERS
(
3
)
for
(
x
=
0
;
x
<
input
->
width
;
x
++
){
for
(
x
=
0
;
x
<
input
->
width
;
x
++
)
{
INIT_21_PIXELS
INIT_21_PIXELS
E
[
0
]
=
E
[
1
]
=
E
[
2
]
=
PE
;
E
[
0
]
=
E
[
1
]
=
E
[
2
]
=
PE
;
...
@@ -326,11 +326,10 @@ static void xbr3x(AVFrame *input, AVFrame *output, const uint32_t *r2y)
...
@@ -326,11 +326,10 @@ static void xbr3x(AVFrame *input, AVFrame *output, const uint32_t *r2y)
static
void
xbr4x
(
AVFrame
*
input
,
AVFrame
*
output
,
const
uint32_t
*
r2y
)
static
void
xbr4x
(
AVFrame
*
input
,
AVFrame
*
output
,
const
uint32_t
*
r2y
)
{
{
int
x
,
y
;
const
int
nl
=
output
->
linesize
[
0
]
>>
2
;
const
int
nl
=
output
->
linesize
[
0
]
>>
2
;
const
int
nl1
=
nl
+
nl
;
const
int
nl1
=
nl
+
nl
;
const
int
nl2
=
nl1
+
nl
;
const
int
nl2
=
nl1
+
nl
;
int
x
,
y
;
for
(
y
=
0
;
y
<
input
->
height
;
y
++
)
{
for
(
y
=
0
;
y
<
input
->
height
;
y
++
)
{
INIT_SRC_DST_POINTERS
(
4
)
INIT_SRC_DST_POINTERS
(
4
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment