Mercurial > libavformat.hg
changeset 3068:9cc9ff5aff9c libavformat
set bps to uncompressed original sound data for compressed audio
according to aiff specs, qt set it to 16 for mace and ima4,
fail if block align is not set.
author | bcoudurier |
---|---|
date | Mon, 25 Feb 2008 12:00:31 +0000 |
parents | 2dc78258f848 |
children | 48a89cfefa99 |
files | aiff.c |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/aiff.c Mon Feb 25 11:34:26 2008 +0000 +++ b/aiff.c Mon Feb 25 12:00:31 2008 +0000 @@ -189,7 +189,12 @@ put_be32(pb, 0); /* file length */ put_tag(pb, aifc ? "AIFC" : "AIFF"); - if (aifc) { + if (aifc) { // compressed audio + enc->bits_per_sample = 16; + if (!enc->block_align) { + av_log(s, AV_LOG_ERROR, "block align not set\n"); + return -1; + } /* Version chunk */ put_tag(pb, "FVER"); put_be32(pb, 4);