diff options
author | David Conrad <lessen42@gmail.com> | 2007-09-05 00:22:47 +0000 |
---|---|---|
committer | David Conrad <lessen42@gmail.com> | 2007-09-05 00:22:47 +0000 |
commit | 9b6b0c792615a76bf5b4f215ac083c1d41c47ec2 (patch) | |
tree | 13c3482e7df0f31f5bf09a167124f1bdda42f1d3 /libavformat/matroskaenc.c | |
parent | 1e18c4d097992060b6c1270f228bf4d3dbcb0281 (diff) | |
download | ffmpeg-9b6b0c792615a76bf5b4f215ac083c1d41c47ec2.tar.gz |
put_ebml_float()
Originally committed as revision 10299 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/matroskaenc.c')
-rw-r--r-- | libavformat/matroskaenc.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c index 5f18880c42..0324e353d8 100644 --- a/libavformat/matroskaenc.c +++ b/libavformat/matroskaenc.c @@ -67,6 +67,14 @@ static void put_ebml_uint(ByteIOContext *pb, unsigned int elementid, uint64_t va //static void put_ebml_sint(ByteIOContext *pb, unsigned int elementid, int64_t val) +static void put_ebml_float(ByteIOContext *pb, unsigned int elementid, double val) +{ + // XXX: single-precision floats? + put_ebml_id(pb, elementid); + put_ebml_size(pb, 8, 0); + put_be64(pb, av_dbl2int(val)); +} + static void put_ebml_binary(ByteIOContext *pb, unsigned int elementid, const uint8_t *buf, int size) { |