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
ad0d17f1
Commit
ad0d17f1
authored
Nov 13, 2003
by
Michael Niedermayer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qprd with b frames fix
Originally committed as revision 2518 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
dd3e415e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
mpegvideo.c
libavcodec/mpegvideo.c
+3
-2
No files found.
libavcodec/mpegvideo.c
View file @
ad0d17f1
...
...
@@ -3840,6 +3840,7 @@ static void encode_picture(MpegEncContext *s, int picture_number)
const
int
last_qp
=
backup_s
.
qscale
;
int
dquant
,
dir
,
qp
,
dc
[
6
];
DCTELEM
ac
[
6
][
16
];
const
int
mvdir
=
(
best_s
.
mv_dir
&
MV_DIR_BACKWARD
)
?
1
:
0
;
assert
(
backup_s
.
dquant
==
0
);
...
...
@@ -3853,7 +3854,7 @@ static void encode_picture(MpegEncContext *s, int picture_number)
s
->
mv
[
1
][
0
][
1
]
=
best_s
.
mv
[
1
][
0
][
1
];
dir
=
s
->
pict_type
==
B_TYPE
?
2
:
1
;
if
(
last_qp
+
dir
>
=
s
->
avctx
->
qmax
)
dir
=
-
dir
;
if
(
last_qp
+
dir
>
s
->
avctx
->
qmax
)
dir
=
-
dir
;
for
(
dquant
=
dir
;
dquant
<=
2
&&
dquant
>=-
2
;
dquant
+=
dir
){
qp
=
last_qp
+
dquant
;
if
(
qp
<
s
->
avctx
->
qmin
||
qp
>
s
->
avctx
->
qmax
)
...
...
@@ -3867,7 +3868,7 @@ static void encode_picture(MpegEncContext *s, int picture_number)
}
encode_mb_hq
(
s
,
&
backup_s
,
&
best_s
,
MB_TYPE_INTER
/* wrong but unused */
,
pb
,
pb2
,
tex_pb
,
&
dmin
,
&
next_block
,
s
->
mv
[
0
][
0
][
0
],
s
->
mv
[
0
][
0
][
1
]);
&
dmin
,
&
next_block
,
s
->
mv
[
mvdir
][
0
][
0
],
s
->
mv
[
mvdir
][
0
][
1
]);
if
(
best_s
.
qscale
!=
qp
){
if
(
s
->
mb_intra
){
for
(
i
=
0
;
i
<
6
;
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