Commit Graph

2546 Commits

Author SHA1 Message Date
David Conrad 0580a12256 Use assert for conditions that must be true
Originally committed as revision 10366 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:22 +00:00
David Conrad 203cce9a92 Simplify
Originally committed as revision 10365 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:20 +00:00
David Conrad 8cf3bb2674 Grammar nits
Originally committed as revision 10364 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:18 +00:00
David Conrad cfde5d18f5 Break long comments
Originally committed as revision 10363 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:16 +00:00
David Conrad a6da1aa057 Use sample format for bit depth if av_get_bits_per_sample() doesn't give one
Originally committed as revision 10362 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:14 +00:00
David Conrad 8eb1915395 Calculate and store DAR rather than SAR
Originally committed as revision 10361 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:07 +00:00
David Conrad 5045da831b Clarify comments
Originally committed as revision 10360 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:25:04 +00:00
David Conrad 5b66fc16af Use PRIu64/PRId64
Originally committed as revision 10359 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:58 +00:00
David Conrad baf71dca28 Calculate the size of key EBML master elements beforehand so only just enough size is reserved for the size
Originally committed as revision 10358 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:56 +00:00
David Conrad cce800b456 Use cluster_pos when checking cluster position
Originally committed as revision 10357 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:53 +00:00
David Conrad f0e9f44271 Modify put_ebml_size() so that the bytes parameter is exact rather than minimum
Originally committed as revision 10356 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:50 +00:00
David Conrad c635497cb4 Set default subtitle_codec to CODEC_ID_TEXT
Originally committed as revision 10355 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:48 +00:00
David Conrad ddf1646729 Simplify
Originally committed as revision 10354 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:44 +00:00
David Conrad 1c73478c8e Move calculating the bytes needed to represent a size in EBML to its own function
Originally committed as revision 10353 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:42 +00:00
David Conrad 9f38fd7efa Make a byte always mean a byte
Originally committed as revision 10352 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:39 +00:00
David Conrad 432adc130c Simplify put_ebml_id()
Originally committed as revision 10351 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:36 +00:00
David Conrad 22ccb69a7f Move ebml_id_size()
Originally committed as revision 10350 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:34 +00:00
David Conrad ec8f4ad909 Correct handling of smaller unknown sizes
Originally committed as revision 10349 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:31 +00:00
David Conrad 541d443c03 Use a MD5 hash of some frames to write the segment uid
Originally committed as revision 10348 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:29 +00:00
David Conrad f095a17423 Revert using the time to generate the segment uid
Originally committed as revision 10347 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:27 +00:00
David Conrad 57848e9abd Doxygenize some comments
Originally committed as revision 10346 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:25 +00:00
David Conrad fd150eb629 Set the language to undefined if no language specified
Originally committed as revision 10345 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:22 +00:00
David Conrad 55c151efb3 Add mka muxer
Originally committed as revision 10344 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:19 +00:00
David Conrad c1f5aa2186 Add some debug logging
Originally committed as revision 10343 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:17 +00:00
David Conrad 7332adddae Write the display size elements
Originally committed as revision 10342 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:15 +00:00
David Conrad d1a8d959fd Revert writing the file creation date
Originally committed as revision 10341 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:12 +00:00
David Conrad 409533622e Codec Private should be correct for all but Real codecs now
Originally committed as revision 10340 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:10 +00:00
David Conrad 8a39497c13 Write FLAC codec private correctly
Originally committed as revision 10339 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:08 +00:00
David Conrad 86be66378b Move writing Xiph-style sizes to its own function
Originally committed as revision 10338 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:06 +00:00
David Conrad 4b8f58eea5 Write segment UID
Originally committed as revision 10337 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:03 +00:00
David Conrad 80380a0f71 Write the creation time
Originally committed as revision 10336 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:24:01 +00:00
David Conrad 5fd35c6e00 Cosmetics
Originally committed as revision 10335 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:59 +00:00
David Conrad 440e090121 Using LIBAVFORMAT_IDENT for both muxing and writing app is good enough
Originally committed as revision 10334 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:57 +00:00
David Conrad dcbfe3f099 Floats aren't used enough to justify writing any with single precision
Originally committed as revision 10333 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:55 +00:00
David Conrad 9245c5ca08 Simplify
Originally committed as revision 10332 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:53 +00:00
David Conrad 56e4540d3a Indentation
Originally committed as revision 10331 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:52 +00:00
David Conrad 663a5d9d2d Write subtitle tracks
Originally committed as revision 10330 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:49 +00:00
David Conrad 95527e0669 Move writing a block to its own function
Originally committed as revision 10329 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:47 +00:00
David Conrad 8bea4aee4f Only write extradata if it exists
Originally committed as revision 10328 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:46 +00:00
David Conrad 07918a227a Determine the output sample rate for SBR AAC and write it
Originally committed as revision 10327 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:43 +00:00
David Conrad 6b9a10fbd3 Simplify
Originally committed as revision 10326 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:41 +00:00
David Conrad f9c8d57b79 Keyframe is the first bit not last
Originally committed as revision 10325 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:39 +00:00
David Conrad 357eba6f0b Simplify
Originally committed as revision 10324 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:38 +00:00
David Conrad d22f88cb19 Use av_get_bits_per_sample
Originally committed as revision 10323 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:34 +00:00
David Conrad 44008871ef Write bit depth for PCM audio
Originally committed as revision 10322 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:31 +00:00
David Conrad 1a302a5c2a Write wav header if there is no native audio codec ID
Originally committed as revision 10321 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:29 +00:00
David Conrad 6364d534ea Write the cues element
Originally committed as revision 10320 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:27 +00:00
David Conrad 1b66d31467 Doxygenize comments
Originally committed as revision 10319 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:26 +00:00
David Conrad 4d1fd70cac Calculate the size of a SimpleBlock before writing it so that bytes aren't wasted in writing the size
Originally committed as revision 10318 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:23 +00:00
David Conrad 7973dd0bf1 Indentation
Originally committed as revision 10317 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:21 +00:00
David Conrad 967d815ae5 Write the Seek Head element
Originally committed as revision 10316 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:19 +00:00
David Conrad 801edb42d1 Make sure to return a value in functions that return a value
Originally committed as revision 10315 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:17 +00:00
David Conrad 5034ab9024 Move writing the tracks element to its own function
Originally committed as revision 10314 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:15 +00:00
David Conrad 56d55a3bcf Move Xiph's CodecPrivate writing code to its own function
Originally committed as revision 10313 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:13 +00:00
David Conrad 02f487fc77 Write the duration of the file
Originally committed as revision 10312 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:11 +00:00
David Conrad f57b85a569 put_ebml_void()
Originally committed as revision 10311 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:09 +00:00
David Conrad ab41602755 Remove unused prototype
Originally committed as revision 10310 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:07 +00:00
David Conrad ffb880c278 Write unknown size if the size given is too large for EBML (greater than 2^56-1)
Originally committed as revision 10309 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:06 +00:00
David Conrad 815eb6a2fe Track number and UID only have to be nonzero
Originally committed as revision 10308 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:03 +00:00
David Conrad 90c02d93ff SimpleBlocks are Matroska v2
Originally committed as revision 10307 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:01 +00:00
David Conrad 98186e416d Start a new cluster every 5 MB or 5 seconds
Originally committed as revision 10306 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:23:00 +00:00
David Conrad 6d50a935c9 Fix writing Xiph header sizes
Originally committed as revision 10305 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:58 +00:00
David Conrad 89e81bbbb9 Correctly write CodecPrivate element for Vorbis and Theora
Originally committed as revision 10304 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:56 +00:00
David Conrad 79a58e91db Compile fix; missed a variable declaration in the last commit
Originally committed as revision 10303 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:54 +00:00
David Conrad b1adb69c5b Write one cluster and SimpleBlocks for the frames. Should now create playable mkv files for some video codecs (H.264 and VP3 checked)
Originally committed as revision 10302 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:52 +00:00
David Conrad f622c4f45c First stab at writing the tracks element, still needs some additional cases for certain codecs
Originally committed as revision 10301 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:50 +00:00
David Conrad f8e65a3271 Remove useless debug write
Originally committed as revision 10300 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:48 +00:00
David Conrad 9b6b0c7926 put_ebml_float()
Originally committed as revision 10299 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:47 +00:00
David Conrad 1e18c4d097 Const correctness
Originally committed as revision 10298 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:45 +00:00
David Conrad 81efc03f58 Get rid of put_ebml_utf8(); the error checking that would have distinguished it from put_ebml_string() belongs elsewhere in lavf.
Originally committed as revision 10297 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:43 +00:00
David Conrad dbf653f766 Cosmetics: align nicely for better readibility
Originally committed as revision 10296 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:41 +00:00
David Conrad cf4f763be1 Simplify
Originally committed as revision 10295 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:39 +00:00
David Conrad 67143c0f69 Beginning of mkv muxer, only EBML head is written correctly
Originally committed as revision 10294 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-05 00:22:37 +00:00
Ramiro Polla f7b8bffe47 Treat dc1394 as a library
Originally committed as revision 10292 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-04 22:03:32 +00:00
Mike Melanson 80a16ccf82 simplify PTS handling
Originally committed as revision 10291 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-04 17:33:35 +00:00
Luca Abeni 5f2cbb53b4 Fill the buffer with 0 before writing an SDP in it
Originally committed as revision 10287 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-03 09:00:40 +00:00
Neil Brown 9fcbcca60a If a stream has no start time, but the first packet has a 'pts', use that
pts to set the start_time.
patch by Neil Brown: [neilb suse de]
original thread: [FFmpeg-devel] [patch 3/3] Make timing calculations less
dependant on start_time being defined.
date: 08/16/2007 08:27 AM

Originally committed as revision 10285 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-03 07:56:26 +00:00
Luca Abeni 3f19004e46 Set the "B" flag in the payload header
Originally committed as revision 10284 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-03 07:28:58 +00:00
Luca Abeni 2d7d6d4203 Set the "TR" field in the payload header
Originally committed as revision 10283 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-03 07:22:37 +00:00
Luca Abeni 73130dfee2 Correctly set the "P" field in the payload header
Originally committed as revision 10282 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-03 07:14:10 +00:00
Wolfram Gloger 9be5181587 fix probe buffer issue. patch by Wolfram Gloger {wmglo at dent.med.uni-muenchen.de}.
[FFmpeg-devel] [PATCH] ac3_probe input buffer overrun
Aug 28, 2007

Originally committed as revision 10281 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-03 05:19:59 +00:00
Michael Niedermayer da0b94f539 workaround ms (lack of) intelligence in their design of dvr-ms
yes kids you do not make 90% of your file contain empty dummy packets
closes issue76

Originally committed as revision 10280 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-09-02 15:58:43 +00:00
David Conrad 84fa6e23fb SimpleBlock keyframe flag is the most significant bit
Originally committed as revision 10274 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-31 18:24:09 +00:00
Diego Biurrun 1e97ce4a31 cosmetics: Sort some lines, whitespace changes.
Originally committed as revision 10268 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-30 23:11:24 +00:00
Luca Abeni 46b274d4e5 Correct packetization for MPEG video frames, and correct setting of the
"B" and "E" bits in the payload header

Originally committed as revision 10260 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-29 10:47:15 +00:00
Luca Abeni 7c8133aa44 Remove commented code (payload header extension)
Originally committed as revision 10259 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-29 10:42:13 +00:00
Luca Barbato f6df400c0c Backport fix for mpegvideo rtp, fixes Issue119, original fix from Dario Gallucci <dariodotgallucciatpolito.it> in feng
Originally committed as revision 10257 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-28 13:43:39 +00:00
Roberto Togni b6f508bbcc Change 4xm demuxer and video decoder to pass the video format version in
extradata instead of codec_tag.

Originally committed as revision 10253 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-27 21:58:39 +00:00
Diego Biurrun 30a987ece9 Remove unused variable.
Originally committed as revision 10251 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-27 12:36:19 +00:00
Luca Abeni 50755217f8 Use correct timescale in RTSP seeking
Originally committed as revision 10222 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-25 15:12:38 +00:00
Luca Abeni 7fa9d0dd8f Remove copyright from a function prototype
Originally committed as revision 10214 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-24 17:40:43 +00:00
Luca Abeni 98561024ac Move the RTP packetization code for MPEG12 video in its own file (rtp_mpv.c)
Originally committed as revision 10201 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-24 07:13:34 +00:00
David Conrad b75c8d16e7 Add V_SNOW
Originally committed as revision 10200 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-24 00:49:46 +00:00
Kostya Shishkov 2b71ddd96e Take ring frame into account when demuxing.
This fixes issue 97.

Originally committed as revision 10192 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-23 06:59:19 +00:00
Diego Biurrun 57b499c7da Identifiers starting with underscores are reserved.
Originally committed as revision 10179 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-22 12:41:16 +00:00
Baptiste Coudurier 1f794d69c0 support swink created files which have soi/eoi broken tags reversed
Originally committed as revision 10152 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-20 19:55:37 +00:00
Neil Brown 9f32041d89 Do not butcher start_time in av_estimate_timings_from_bit_rate().
from a patch by neilb suse de

Originally committed as revision 10140 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-18 01:26:06 +00:00
Neil Brown d6a0906ad1 When looking for the last packet in each
stream, so as to calculate the duration, don't stop
as soon as all streams have seen at least one packet.
Otherwise the duration will be shorter than it
should be.  We must keep reading to the end-of-file.
patch by neilb suse de

Originally committed as revision 10139 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-18 00:52:05 +00:00
Neil Brown bf494092b0 There is no guarantee that every stream will
have a start_time found (though it is likely),
so check that the start_time is defined before
calculating a duration.
 (patch by neilb suse de)

Originally committed as revision 10138 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-18 00:45:44 +00:00
Michael Niedermayer df886e7e02 fix cur_dts at the end of av_estimate_timings_from_pts()
Originally committed as revision 10137 to svn://svn.ffmpeg.org/ffmpeg/trunk
2007-08-18 00:44:14 +00:00