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
f4bf06eb
Commit
f4bf06eb
authored
Oct 23, 2011
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
sws-test: Fix data alignment
Signed-off-by:
Michael Niedermayer
<
michaelni@gmx.at
>
parent
90640cc7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
swscale-test.c
libswscale/swscale-test.c
+3
-0
No files found.
libswscale/swscale-test.c
View file @
f4bf06eb
...
...
@@ -104,6 +104,7 @@ static int doTest(uint8_t *ref[4], int refStride[4], int w, int h,
av_image_fill_linesizes
(
srcStride
,
srcFormat
,
srcW
);
for
(
p
=
0
;
p
<
4
;
p
++
)
{
srcStride
[
p
]
=
FFALIGN
(
srcStride
[
p
],
16
);
if
(
srcStride
[
p
])
src
[
p
]
=
av_mallocz
(
srcStride
[
p
]
*
srcH
+
16
);
if
(
srcStride
[
p
]
&&
!
src
[
p
])
{
...
...
@@ -139,6 +140,7 @@ static int doTest(uint8_t *ref[4], int refStride[4], int w, int h,
* allocated with av_malloc). */
/* An extra 16 bytes is being allocated because some scalers may write
* out of bounds. */
dstStride
[
i
]
=
FFALIGN
(
dstStride
[
i
],
16
);
if
(
dstStride
[
i
])
dst
[
i
]
=
av_mallocz
(
dstStride
[
i
]
*
dstH
+
16
);
if
(
dstStride
[
i
]
&&
!
dst
[
i
])
{
...
...
@@ -178,6 +180,7 @@ static int doTest(uint8_t *ref[4], int refStride[4], int w, int h,
ssdA
=
r
->
ssdA
;
}
else
{
for
(
i
=
0
;
i
<
4
;
i
++
)
{
refStride
[
i
]
=
FFALIGN
(
refStride
[
i
],
16
);
if
(
refStride
[
i
])
out
[
i
]
=
av_mallocz
(
refStride
[
i
]
*
h
);
if
(
refStride
[
i
]
&&
!
out
[
i
])
{
...
...
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