Gerald Pfeifer : wineoss.drv: Support platforms that do not feature AFMT_FLOAT.

Alexandre Julliard julliard at winehq.org
Mon May 9 13:34:45 CDT 2011


Module: wine
Branch: master
Commit: bed73e9e736ef2376e762730a30ad5f2611f969c
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=bed73e9e736ef2376e762730a30ad5f2611f969c

Author: Gerald Pfeifer <gerald at pfeifer.com>
Date:   Sun May  8 02:46:37 2011 +0200

wineoss.drv: Support platforms that do not feature AFMT_FLOAT.

---

 dlls/wineoss.drv/mmdevdrv.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/dlls/wineoss.drv/mmdevdrv.c b/dlls/wineoss.drv/mmdevdrv.c
index 64c06cd..7dec1e0 100644
--- a/dlls/wineoss.drv/mmdevdrv.c
+++ b/dlls/wineoss.drv/mmdevdrv.c
@@ -532,6 +532,7 @@ static int get_oss_format(const WAVEFORMATEX *fmt)
         return -1;
     }
 
+#ifdef AFMT_FLOAT
     if(fmt->wFormatTag == WAVE_FORMAT_IEEE_FLOAT ||
             (fmt->wFormatTag == WAVE_FORMAT_EXTENSIBLE &&
              IsEqualGUID(&fmtex->SubFormat, &KSDATAFORMAT_SUBTYPE_IEEE_FLOAT))){
@@ -540,6 +541,7 @@ static int get_oss_format(const WAVEFORMATEX *fmt)
 
         return AFMT_FLOAT;
     }
+#endif
 
     return -1;
 }
@@ -1017,9 +1019,11 @@ static HRESULT WINAPI AudioClient_GetMixFormat(IAudioClient *iface,
     if(formats & AFMT_S16_LE){
         fmt->Format.wBitsPerSample = 16;
         fmt->SubFormat = KSDATAFORMAT_SUBTYPE_PCM;
+#ifdef AFMT_FLOAT
     }else if(formats & AFMT_FLOAT){
         fmt->Format.wBitsPerSample = 32;
         fmt->SubFormat = KSDATAFORMAT_SUBTYPE_IEEE_FLOAT;
+#endif
     }else if(formats & AFMT_U8){
         fmt->Format.wBitsPerSample = 8;
         fmt->SubFormat = KSDATAFORMAT_SUBTYPE_PCM;




More information about the wine-cvs mailing list