git.videolan.org
/
ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
bfccd76
)
sol: set channel layout
author
Justin Ruggles
<justin.ruggles@gmail.com>
Sat, 7 Apr 2012 22:38:29 +0000
(18:38 -0400)
committer
Justin Ruggles
<justin.ruggles@gmail.com>
Mon, 12 Nov 2012 15:33:22 +0000
(10:33 -0500)
libavformat/sol.c
patch
|
blob
|
history
diff --git
a/libavformat/sol.c
b/libavformat/sol.c
index
da84600
..
92599b1
100644
(file)
--- a/
libavformat/sol.c
+++ b/
libavformat/sol.c
@@
-23,6
+23,7
@@
* Based on documents from Game Audio Player and own research
*/
* Based on documents from Game Audio Player and own research
*/
+#include "libavutil/channel_layout.h"
#include "libavutil/intreadwrite.h"
#include "avformat.h"
#include "internal.h"
#include "libavutil/intreadwrite.h"
#include "avformat.h"
#include "internal.h"
@@
-116,6
+117,8
@@
static int sol_read_header(AVFormatContext *s)
st->codec->codec_tag = id;
st->codec->codec_id = codec;
st->codec->channels = channels;
st->codec->codec_tag = id;
st->codec->codec_id = codec;
st->codec->channels = channels;
+ st->codec->channel_layout = channels == 1 ? AV_CH_LAYOUT_MONO :
+ AV_CH_LAYOUT_STEREO;
st->codec->sample_rate = rate;
avpriv_set_pts_info(st, 64, 1, rate);
return 0;
st->codec->sample_rate = rate;
avpriv_set_pts_info(st, 64, 1, rate);
return 0;