DiscardPadding is a signed int.
this change fixes 2 things:
- allows negative values for discard padding
- fixes cases where an unsigned value would be written such that on read
the sign would be flipped
Change-Id: I9418da7a22c09768e02d5b61da8d01c2bccb5dee
Change acf788 added Crop* elements support, but they were not
added when calculating size of Video element.
Change-Id: I64495cc35406a28b86b40d915dbc291f45aa1263
the element length was being read twice; the second attempt would
consume a portion of the discard padding field often failing due to
limitations in GetUIntLength.
Change-Id: Ibbe3f082e2d05460734a0e1f7d23f3c665e3f24b
Reject frames if an invalid track number is passed. Also change sample_muxer
to reject files which have Block elements with invalid track numbers.
Fixes Issue #659: https://code.google.com/p/webm/issues/detail?id=659
Change-Id: Ie6cf39a409b68bb4d2261f308409ee0c36d5dd8e
codec_id element for a Track is mandatory and it does not have a default.
Rejecting the file if that happens.
Change-Id: I4fb0dfcd4c09eeabf22634db7fdf6ca818c93917
mkvparser::UnserializeUInt() assumes that unsigned values never have
their high bit set. This is too limiting for UUIDs. In addition, the
Chapters::Atom::Parse() method would truncate a "negative" 64-bit UUID
value to 32 bits and return the truncated value as a status code.
This value then might or might not be treated as an error by the caller
depending on whether the truncated value was itself negative.
Change-Id: I15624ac62d0b02691a1405ee6a5f7eb441b3bc48
According to matroska specification, TrackType is a mandatory element without a
default value [1]. But we have been producing invalid matroska files when
TrackType is never specified because we write 0 by default.
This patch will reject writing a track without specifying the TrackType value.
Specifically, this path will be triggered when Segment::AddTrack() is called
but there is no subsequent call to Track::set_type().
[1] http://www.matroska.org/technical/specs/index.html#TrackType
Fixes issue #769: https://code.google.com/p/webm/issues/detail?id=769
Change-Id: I4d75d169fd96c7e1fad278561f0e7a3e1135989c
Update .clang-format so that it allows short functions and constructors in a
single line if it fits.
Change-Id: I60788089fc7a4e2f4c4df6947368ebc0f3fa8c49
Replacing a reinterpret_cast from float& to uint32& with a union to get rid of
"dereferencing type-punned pointer will break strict-aliasing rules" warning.
This warning is produced on passing -O3 in gcc.
Change-Id: Ie942597f418e3659e3ff29a909c43dd99266c04d
Overloading MkvWriter's constructor so that it can wrap a user owned
FILE pointer. Doing this so that applications which handle the file opening
and closing by themselves don't have to have their own implementation of the
IMkvWriter interface.
Change-Id: I69c57f3e6927ea13b616c425e3b5f179d2e69215