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
20429ba9
Commit
20429ba9
authored
Apr 05, 2013
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
h261: Move encoder/decoder shared table init to common code
parent
8a776ad9
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
7 deletions
+14
-7
h261.c
libavcodec/h261.c
+11
-0
h261.h
libavcodec/h261.h
+1
-0
h261dec.c
libavcodec/h261dec.c
+1
-1
h261enc.c
libavcodec/h261enc.c
+1
-6
No files found.
libavcodec/h261.c
View file @
20429ba9
...
...
@@ -79,3 +79,14 @@ void ff_h261_loop_filter(MpegEncContext *s)
h261_loop_filter
(
dest_cb
,
uvlinesize
);
h261_loop_filter
(
dest_cr
,
uvlinesize
);
}
av_cold
void
ff_h261_common_init
(
void
)
{
static
int
done
=
0
;
if
(
done
)
return
;
ff_init_rl
(
&
ff_h261_rl_tcoeff
,
ff_h261_rl_table_store
);
done
=
1
;
}
libavcodec/h261.h
View file @
20429ba9
...
...
@@ -61,6 +61,7 @@ extern const uint8_t ff_h261_cbp_tab[63][2];
extern
RLTable
ff_h261_rl_tcoeff
;
void
ff_h261_loop_filter
(
MpegEncContext
*
s
);
void
ff_h261_common_init
(
void
);
int
ff_h261_get_picture_format
(
int
width
,
int
height
);
void
ff_h261_reorder_mb_index
(
MpegEncContext
*
s
);
...
...
libavcodec/h261dec.c
View file @
20429ba9
...
...
@@ -61,7 +61,6 @@ static av_cold void h261_decode_init_vlc(H261Context *h)
INIT_VLC_STATIC
(
&
h261_cbp_vlc
,
H261_CBP_VLC_BITS
,
63
,
&
ff_h261_cbp_tab
[
0
][
1
],
2
,
1
,
&
ff_h261_cbp_tab
[
0
][
0
],
2
,
1
,
512
);
ff_init_rl
(
&
ff_h261_rl_tcoeff
,
ff_h261_rl_table_store
);
INIT_VLC_RL
(
ff_h261_rl_tcoeff
,
552
);
}
}
...
...
@@ -82,6 +81,7 @@ static av_cold int h261_decode_init(AVCodecContext *avctx)
avctx
->
pix_fmt
=
AV_PIX_FMT_YUV420P
;
s
->
codec_id
=
avctx
->
codec
->
id
;
ff_h261_common_init
();
h261_decode_init_vlc
(
h
);
h
->
gob_start_code_skipped
=
0
;
...
...
libavcodec/h261enc.c
View file @
20429ba9
...
...
@@ -313,12 +313,7 @@ void ff_h261_encode_mb(MpegEncContext *s, int16_t block[6][64],
void
ff_h261_encode_init
(
MpegEncContext
*
s
)
{
static
int
done
=
0
;
if
(
!
done
)
{
done
=
1
;
ff_init_rl
(
&
ff_h261_rl_tcoeff
,
ff_h261_rl_table_store
);
}
ff_h261_common_init
();
s
->
min_qcoeff
=
-
127
;
s
->
max_qcoeff
=
127
;
...
...
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