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
530d5740
Commit
530d5740
authored
Feb 19, 2004
by
Ivan Kalvachev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use get_format
Originally committed as revision 2802 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
5e7c25f0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
4 deletions
+19
-4
mpeg12.c
libavcodec/mpeg12.c
+19
-4
No files found.
libavcodec/mpeg12.c
View file @
530d5740
...
@@ -80,6 +80,13 @@ extern void XVMC_pack_pblocks(MpegEncContext *s,int cbp);
...
@@ -80,6 +80,13 @@ extern void XVMC_pack_pblocks(MpegEncContext *s,int cbp);
extern
void
XVMC_init_block
(
MpegEncContext
*
s
);
//set s->block
extern
void
XVMC_init_block
(
MpegEncContext
*
s
);
//set s->block
#endif
#endif
const
enum
PixelFormat
pixfmt_yuv_420
[]
=
{
PIX_FMT_YUV420P
,
-
1
};
const
enum
PixelFormat
pixfmt_yuv_422
[]
=
{
PIX_FMT_YUV422P
,
-
1
};
const
enum
PixelFormat
pixfmt_yuv_444
[]
=
{
PIX_FMT_YUV444P
,
-
1
};
const
enum
PixelFormat
pixfmt_xvmc_mpg2_420
[]
=
{
PIX_FMT_XVMC_MPEG2_IDCT
,
PIX_FMT_XVMC_MPEG2_MC
,
-
1
};
#ifdef CONFIG_ENCODERS
#ifdef CONFIG_ENCODERS
static
uint8_t
(
*
mv_penalty
)[
MAX_MV
*
2
+
1
]
=
NULL
;
static
uint8_t
(
*
mv_penalty
)[
MAX_MV
*
2
+
1
]
=
NULL
;
static
uint8_t
fcode_tab
[
MAX_MV
*
2
+
1
];
static
uint8_t
fcode_tab
[
MAX_MV
*
2
+
1
];
...
@@ -2354,8 +2361,12 @@ static int mpeg1_decode_sequence(AVCodecContext *avctx,
...
@@ -2354,8 +2361,12 @@ static int mpeg1_decode_sequence(AVCodecContext *avctx,
);
);
avctx
->
bit_rate
=
s
->
bit_rate
;
avctx
->
bit_rate
=
s
->
bit_rate
;
//get_format() or set_video(width,height,aspect,pix_fmt);
if
(
avctx
->
xvmc_acceleration
){
//until then pix_fmt may be changed right after codec init
avctx
->
pix_fmt
=
avctx
->
get_format
(
avctx
,
pixfmt_xvmc_mpg2_420
);
}
else
{
avctx
->
pix_fmt
=
avctx
->
get_format
(
avctx
,
pixfmt_yuv_420
);
}
if
(
avctx
->
pix_fmt
==
PIX_FMT_XVMC_MPEG2_IDCT
)
if
(
avctx
->
pix_fmt
==
PIX_FMT_XVMC_MPEG2_IDCT
)
if
(
avctx
->
idct_algo
==
FF_IDCT_AUTO
)
if
(
avctx
->
idct_algo
==
FF_IDCT_AUTO
)
avctx
->
idct_algo
=
FF_IDCT_SIMPLE
;
avctx
->
idct_algo
=
FF_IDCT_SIMPLE
;
...
@@ -2458,8 +2469,12 @@ static int vcr2_init_sequence(AVCodecContext *avctx)
...
@@ -2458,8 +2469,12 @@ static int vcr2_init_sequence(AVCodecContext *avctx)
avctx
->
has_b_frames
=
0
;
//true?
avctx
->
has_b_frames
=
0
;
//true?
s
->
low_delay
=
1
;
s
->
low_delay
=
1
;
//get_format() or set_video(width,height,aspect,pix_fmt);
if
(
avctx
->
xvmc_acceleration
){
//until then pix_fmt may be changed right after codec init
avctx
->
pix_fmt
=
avctx
->
get_format
(
avctx
,
pixfmt_xvmc_mpg2_420
);
}
else
{
avctx
->
pix_fmt
=
avctx
->
get_format
(
avctx
,
pixfmt_yuv_420
);
}
if
(
avctx
->
pix_fmt
==
PIX_FMT_XVMC_MPEG2_IDCT
)
if
(
avctx
->
pix_fmt
==
PIX_FMT_XVMC_MPEG2_IDCT
)
if
(
avctx
->
idct_algo
==
FF_IDCT_AUTO
)
if
(
avctx
->
idct_algo
==
FF_IDCT_AUTO
)
avctx
->
idct_algo
=
FF_IDCT_SIMPLE
;
avctx
->
idct_algo
=
FF_IDCT_SIMPLE
;
...
...
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