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
a43b1e74
Commit
a43b1e74
authored
Aug 16, 2011
by
Kostya Shishkov
Committed by
Anton Khirnov
Aug 17, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rmdec: parse FPS in RealMedia properly
Signed-off-by:
Anton Khirnov
<
anton@khirnov.net
>
parent
48ce8b8d
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
352 additions
and
171 deletions
+352
-171
rmdec.c
libavformat/rmdec.c
+8
-8
real-rv40
tests/ref/fate/real-rv40
+236
-119
rv30
tests/ref/fate/rv30
+108
-44
No files found.
libavformat/rmdec.c
View file @
a43b1e74
...
@@ -295,19 +295,19 @@ ff_rm_read_mdpr_codecdata (AVFormatContext *s, AVIOContext *pb,
...
@@ -295,19 +295,19 @@ ff_rm_read_mdpr_codecdata (AVFormatContext *s, AVIOContext *pb,
goto
fail1
;
goto
fail1
;
st
->
codec
->
width
=
avio_rb16
(
pb
);
st
->
codec
->
width
=
avio_rb16
(
pb
);
st
->
codec
->
height
=
avio_rb16
(
pb
);
st
->
codec
->
height
=
avio_rb16
(
pb
);
st
->
codec
->
time_base
.
num
=
1
;
avio_skip
(
pb
,
2
);
// looks like bits per sample
fps
=
avio_rb16
(
pb
);
avio_skip
(
pb
,
4
);
// always zero?
st
->
codec
->
codec_type
=
AVMEDIA_TYPE_VIDEO
;
st
->
codec
->
codec_type
=
AVMEDIA_TYPE_VIDEO
;
st
->
need_parsing
=
AVSTREAM_PARSE_TIMESTAMPS
;
st
->
need_parsing
=
AVSTREAM_PARSE_TIMESTAMPS
;
avio_rb32
(
pb
);
fps
=
avio_rb32
(
pb
);
avio_skip
(
pb
,
2
);
avio_rb16
(
pb
);
if
((
ret
=
rm_read_extradata
(
pb
,
st
->
codec
,
codec_data_size
-
(
avio_tell
(
pb
)
-
codec_pos
)))
<
0
)
if
((
ret
=
rm_read_extradata
(
pb
,
st
->
codec
,
codec_data_size
-
(
avio_tell
(
pb
)
-
codec_pos
)))
<
0
)
return
ret
;
return
ret
;
// av_log(s, AV_LOG_DEBUG, "fps= %d fps2= %d\n", fps, fps2);
av_reduce
(
&
st
->
codec
->
time_base
.
num
,
&
st
->
codec
->
time_base
.
den
,
st
->
codec
->
time_base
.
den
=
fps
*
st
->
codec
->
time_base
.
num
;
0x10000
,
fps
,
(
1
<<
30
)
-
1
);
st
->
avg_frame_rate
.
num
=
st
->
codec
->
time_base
.
den
;
st
->
avg_frame_rate
.
den
=
st
->
codec
->
time_base
.
num
;
}
}
skip:
skip:
...
...
tests/ref/fate/real-rv40
View file @
a43b1e74
This diff is collapsed.
Click to expand it.
tests/ref/fate/rv30
View file @
a43b1e74
0, 0, 126720, 0xcefaec47
0, 0, 126720, 0xcefaec47
0, 7500, 126720, 0xa416ece5
0, 3003, 126720, 0xa416ece5
0, 15000, 126720, 0xa416ece5
0, 6006, 126720, 0xa416ece5
0, 22500, 126720, 0x259af497
0, 9009, 126720, 0xa416ece5
0, 30000, 126720, 0x763ab817
0, 12012, 126720, 0x60d6ed27
0, 37500, 126720, 0xda71b917
0, 15015, 126720, 0x259af497
0, 45000, 126720, 0xbb1abbb7
0, 18018, 126720, 0x5e6ff4d7
0, 52500, 126720, 0x16eebbd7
0, 21021, 126720, 0xcc10f4b7
0, 60000, 126720, 0x722e99f7
0, 24024, 126720, 0x763ab817
0, 67500, 126720, 0x07beba77
0, 27027, 126720, 0xeb6fb8d7
0, 75000, 126720, 0x9ca7aac7
0, 30030, 126720, 0xda71b917
0, 82500, 126720, 0xd115a757
0, 33033, 126720, 0x0967b8f7
0, 90000, 126720, 0xac6c071b
0, 36036, 126720, 0x4b62b947
0, 97500, 126720, 0x5eee050f
0, 39039, 126720, 0xbb1abbb7
0, 105000, 126720, 0x68cfda2b
0, 42042, 126720, 0x273fbc37
0, 112500, 126720, 0x582fb176
0, 45045, 126720, 0x16eebbd7
0, 120000, 126720, 0xcf8cb0e2
0, 48048, 126720, 0x105eb927
0, 127500, 126720, 0xc6e10f9f
0, 51051, 126720, 0x7fa3ae27
0, 135000, 126720, 0x85597543
0, 54054, 126720, 0x722e99f7
0, 142500, 126720, 0x554fe3e4
0, 57057, 126720, 0x5ac9a827
0, 150000, 126720, 0x9bf6a605
0, 60060, 126720, 0x07beba77
0, 157500, 126720, 0x93f7b040
0, 63063, 126720, 0x29d6a887
0, 165000, 126720, 0xe39bba0d
0, 66066, 126720, 0xa5caab87
0, 172500, 126720, 0xa567f25b
0, 69069, 126720, 0x9ca7aac7
0, 180000, 126720, 0x4f639ebe
0, 72072, 126720, 0xb7debcd7
0, 187500, 126720, 0x6cf87d39
0, 75075, 126720, 0xd115a757
0, 195000, 126720, 0xfdca11d3
0, 78078, 126720, 0x6ddaef32
0, 202500, 126720, 0x5fd753d8
0, 81081, 126720, 0xde1bb900
0, 210000, 126720, 0xeaf3dd0b
0, 84084, 126720, 0xac6c071b
0, 217500, 126720, 0xce5e6794
0, 87087, 126720, 0x04e7897c
0, 225000, 126720, 0x14cf7974
0, 90090, 126720, 0x5eee050f
0, 232500, 126720, 0xa3f515ab
0, 93093, 126720, 0xe675be59
0, 240000, 126720, 0xbc303fae
0, 96096, 126720, 0xdc3e0837
0, 247500, 126720, 0x0a22cc69
0, 99099, 126720, 0x68cfda2b
0, 255000, 126720, 0xf92b2a25
0, 102102, 126720, 0xe572dfc9
0, 262500, 126720, 0x3378251f
0, 105105, 126720, 0x582fb176
0, 270000, 126720, 0x8da30275
0, 108108, 126720, 0xa9477df0
0, 277500, 126720, 0xf2942f53
0, 111111, 126720, 0xbc3cc34f
0, 285000, 126720, 0x0a24f256
0, 114114, 126720, 0xcf8cb0e2
0, 292500, 126720, 0x10e939ce
0, 117117, 126720, 0xcff1db35
0, 300000, 126720, 0xfe2e057d
0, 120120, 126720, 0xc6e10f9f
0, 307500, 126720, 0x5284da7b
0, 123123, 126720, 0x75ae61b6
0, 315000, 126720, 0xc9e92bf1
0, 126126, 126720, 0x12af3119
0, 322500, 126720, 0x4d888b2e
0, 129129, 126720, 0x85597543
0, 330000, 126720, 0x08382b8e
0, 132132, 126720, 0x68c27aca
0, 135135, 126720, 0x554fe3e4
0, 138138, 126720, 0x72ecea95
0, 141141, 126720, 0xf4d003d1
0, 144144, 126720, 0x9bf6a605
0, 147147, 126720, 0x5d00b5fe
0, 150150, 126720, 0x93f7b040
0, 153153, 126720, 0x0d6ad154
0, 156156, 126720, 0x4be8b4ea
0, 159159, 126720, 0xe39bba0d
0, 162162, 126720, 0x9c21bad8
0, 165165, 126720, 0xa567f25b
0, 168168, 126720, 0x7a82663a
0, 171171, 126720, 0x72f2a47d
0, 174174, 126720, 0x4f639ebe
0, 177177, 126720, 0xab0fce83
0, 180180, 126720, 0x6cf87d39
0, 183183, 126720, 0x534a10cc
0, 186186, 126720, 0x6bbcf44c
0, 189189, 126720, 0xfdca11d3
0, 192192, 126720, 0x7e58f5a6
0, 195195, 126720, 0x5fd753d8
0, 198198, 126720, 0x0c735615
0, 201201, 126720, 0x2a034ebf
0, 204204, 126720, 0xeaf3dd0b
0, 207207, 126720, 0x0eaf0c1b
0, 210210, 126720, 0xce5e6794
0, 213213, 126720, 0xf27c31c3
0, 216216, 126720, 0xb64af168
0, 219219, 126720, 0x14cf7974
0, 222222, 126720, 0x1c2a513d
0, 225225, 126720, 0xa3f515ab
0, 228228, 126720, 0xcfd62765
0, 231231, 126720, 0xbc513f2a
0, 234234, 126720, 0xbc303fae
0, 237237, 126720, 0x2f8f69b9
0, 240240, 126720, 0x0a22cc69
0, 243243, 126720, 0xd9f67585
0, 246246, 126720, 0x20403001
0, 249249, 126720, 0xf92b2a25
0, 252252, 126720, 0x3c170aad
0, 255255, 126720, 0x3378251f
0, 258258, 126720, 0xb3ed5911
0, 261261, 126720, 0x35d24ef8
0, 264264, 126720, 0x8da30275
0, 267267, 126720, 0xc15a3577
0, 270270, 126720, 0xf2942f53
0, 273273, 126720, 0x44d8304a
0, 276276, 126720, 0xd688a932
0, 279279, 126720, 0x0a24f256
0, 282282, 126720, 0xfab9c45d
0, 285285, 126720, 0x10e939ce
0, 288288, 126720, 0x97fcaa3a
0, 291291, 126720, 0x45464610
0, 294294, 126720, 0xfe2e057d
0, 297297, 126720, 0x0b6718ae
0, 300300, 126720, 0x5284da7b
0, 303303, 126720, 0x23efdc35
0, 306306, 126720, 0xc387b2b3
0, 309309, 126720, 0xc9e92bf1
0, 312312, 126720, 0xfbf20a01
0, 315315, 126720, 0x4d888b2e
0, 318318, 126720, 0xdd0d74df
0, 321321, 126720, 0x49d07aa4
0, 324324, 126720, 0x08382b8e
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