changeset 22425:dacdd07fec16

Set format tag for float samples correctly (currently useless)
author reimar
date Sun, 04 Mar 2007 13:49:55 +0000
parents dacfc7692083
children 807484e8d248
files libmpdemux/demux_avs.c
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/demux_avs.c	Sun Mar 04 13:26:43 2007 +0000
+++ b/libmpdemux/demux_avs.c	Sun Mar 04 13:49:55 2007 +0000
@@ -326,7 +326,8 @@
         sh_audio->ds = demuxer->audio;
         
         sh_audio->wf = (WAVEFORMATEX*) malloc(sizeof(WAVEFORMATEX));
-        sh_audio->wf->wFormatTag = sh_audio->format = 0x1;
+        sh_audio->wf->wFormatTag = sh_audio->format =
+            (AVS->video_info->sample_type == AVS_SAMPLE_FLOAT) ? 0x3 : 0x1;
         sh_audio->wf->nChannels = sh_audio->channels = AVS->video_info->nchannels;
         sh_audio->wf->nSamplesPerSec = sh_audio->samplerate = AVS->video_info->audio_samples_per_second;
         sh_audio->wf->nAvgBytesPerSec = AVS->video_info->audio_samples_per_second * 4;