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
8eecae77
Commit
8eecae77
authored
Mar 23, 2016
by
Anton Khirnov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
svq3: move edge_emu_buffer to the SVQ3Context
parent
527bf5f7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
7 deletions
+10
-7
svq3.c
libavcodec/svq3.c
+10
-7
No files found.
libavcodec/svq3.c
View file @
8eecae77
...
...
@@ -103,6 +103,8 @@ typedef struct SVQ3Context {
unsigned
int
top_samples_available
;
unsigned
int
topright_samples_available
;
unsigned
int
left_samples_available
;
uint8_t
*
edge_emu_buffer
;
}
SVQ3Context
;
#define FULLPEL_MODE 1
...
...
@@ -336,11 +338,11 @@ static inline void svq3_mc_dir_part(SVQ3Context *s,
src
=
pic
->
f
->
data
[
0
]
+
mx
+
my
*
sl
->
linesize
;
if
(
emu
)
{
s
->
vdsp
.
emulated_edge_mc
(
s
l
->
edge_emu_buffer
,
src
,
s
->
vdsp
.
emulated_edge_mc
(
s
->
edge_emu_buffer
,
src
,
sl
->
linesize
,
sl
->
linesize
,
width
+
1
,
height
+
1
,
mx
,
my
,
s
->
h_edge_pos
,
s
->
v_edge_pos
);
src
=
s
l
->
edge_emu_buffer
;
src
=
s
->
edge_emu_buffer
;
}
if
(
thirdpel
)
(
avg
?
s
->
tdsp
.
avg_tpel_pixels_tab
...
...
@@ -363,12 +365,12 @@ static inline void svq3_mc_dir_part(SVQ3Context *s,
src
=
pic
->
f
->
data
[
i
]
+
mx
+
my
*
sl
->
uvlinesize
;
if
(
emu
)
{
s
->
vdsp
.
emulated_edge_mc
(
s
l
->
edge_emu_buffer
,
src
,
s
->
vdsp
.
emulated_edge_mc
(
s
->
edge_emu_buffer
,
src
,
sl
->
uvlinesize
,
sl
->
uvlinesize
,
width
+
1
,
height
+
1
,
mx
,
my
,
(
s
->
h_edge_pos
>>
1
),
s
->
v_edge_pos
>>
1
);
src
=
s
l
->
edge_emu_buffer
;
src
=
s
->
edge_emu_buffer
;
}
if
(
thirdpel
)
(
avg
?
s
->
tdsp
.
avg_tpel_pixels_tab
...
...
@@ -1264,9 +1266,9 @@ static int get_buffer(AVCodecContext *avctx, H264Picture *pic)
if
(
ret
<
0
)
goto
fail
;
if
(
!
s
l
->
edge_emu_buffer
)
{
s
l
->
edge_emu_buffer
=
av_mallocz
(
pic
->
f
->
linesize
[
0
]
*
17
);
if
(
!
s
l
->
edge_emu_buffer
)
if
(
!
s
->
edge_emu_buffer
)
{
s
->
edge_emu_buffer
=
av_mallocz
(
pic
->
f
->
linesize
[
0
]
*
17
);
if
(
!
s
->
edge_emu_buffer
)
return
AVERROR
(
ENOMEM
);
}
...
...
@@ -1491,6 +1493,7 @@ static av_cold int svq3_decode_end(AVCodecContext *avctx)
av_freep
(
&
s
->
last_pic
);
av_freep
(
&
s
->
slice_buf
);
av_freep
(
&
s
->
intra4x4_pred_mode
);
av_freep
(
&
s
->
edge_emu_buffer
);
memset
(
&
h
->
cur_pic
,
0
,
sizeof
(
h
->
cur_pic
));
...
...
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