source: trunk/src/dsound/DSOUND.CPP@ 1421

Last change on this file since 1421 was 1421, checked in by sandervl, 26 years ago

Fixed compilation for all files

File size: 1.9 KB
Line 
1/* $Id: DSOUND.CPP,v 1.5 1999-10-23 23:00:49 sandervl Exp $ */
2
3/*
4 * DirectSound exported APIs
5 *
6 * Copyright 1998 Sander van Leeuwen (sandervl@xs4all.nl)
7 *
8 * Project Odin Software License can be found in LICENSE.TXT
9 *
10 */
11
12/*@Header***********************************************************************
13* Header Files *
14*******************************************************************************/
15#include <os2win.h>
16#include <stdlib.h>
17#include <string.h>
18
19#define INITGUID
20#include <dsound.h>
21#include "os2dsound.h"
22
23#include <misc.h>
24
25//******************************************************************************
26//******************************************************************************
27HRESULT WIN32API OS2DirectSoundCreate(const GUID *lpGUID,
28 LPDIRECTSOUND * ppDS,
29 IUnknown *pUnkOuter)
30{
31 OS2IDirectSound *newsound = new OS2IDirectSound(lpGUID);
32 HRESULT rc;
33
34 dprintf(("DirectSoundCreate %X %X %X\n", lpGUID, ppDS, pUnkOuter));
35 if(newsound == NULL) return(DSERR_OUTOFMEMORY);
36
37 rc = newsound->GetLastError();
38 if(rc != DS_OK) {
39 *ppDS = NULL;
40 delete newsound;
41 }
42 else *ppDS = (LPDIRECTSOUND)newsound;
43 return(rc);
44}
45//******************************************************************************
46//******************************************************************************
47HRESULT WIN32API OS2DirectSoundEnumerateA(LPDSENUMCALLBACKA lpCallback,
48 LPVOID lpContext)
49{
50 dprintf(("DirectSoundEnumerateA\n"));
51
52 lpCallback(NULL, "DART DirectSound for OS/2", "DirectSound/2 v0.1",
53 lpContext);
54 return(DS_OK);
55}
56//******************************************************************************
57//******************************************************************************
Note: See TracBrowser for help on using the repository browser.