src/audio/dummy/SDL_dummyaudio.c
author Ryan C. Gordon
Fri, 06 Oct 2006 01:13:09 +0000
branchSDL-ryan-multiple-audio-device
changeset 3811 d980c4dcad0f
parent 3809 7852b5b78af5
child 3816 9d070c1a45fa
permissions -rw-r--r--
Removed some prototypes for non-existant functions in dummy audio driver.
     1 /*
     2     SDL - Simple DirectMedia Layer
     3     Copyright (C) 1997-2006 Sam Lantinga
     4 
     5     This library is free software; you can redistribute it and/or
     6     modify it under the terms of the GNU Lesser General Public
     7     License as published by the Free Software Foundation; either
     8     version 2.1 of the License, or (at your option) any later version.
     9 
    10     This library is distributed in the hope that it will be useful,
    11     but WITHOUT ANY WARRANTY; without even the implied warranty of
    12     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    13     Lesser General Public License for more details.
    14 
    15     You should have received a copy of the GNU Lesser General Public
    16     License along with this library; if not, write to the Free Software
    17     Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
    18 
    19     Sam Lantinga
    20     slouken@libsdl.org
    21 
    22     This file written by Ryan C. Gordon (icculus@icculus.org)
    23 */
    24 #include "SDL_config.h"
    25 
    26 /* Output audio to nowhere... */
    27 
    28 #include "SDL_rwops.h"
    29 #include "SDL_timer.h"
    30 #include "SDL_audio.h"
    31 #include "../SDL_audiomem.h"
    32 #include "../SDL_audio_c.h"
    33 #include "SDL_dummyaudio.h"
    34 
    35 /* The tag name used by DUMMY audio */
    36 #define DUMMYAUD_DRIVER_NAME         "dummy"
    37 
    38 /* Audio driver functions */
    39 static int DUMMYAUD_OpenDevice(_THIS, const char *devname, int iscapture);
    40 
    41 /* Audio driver bootstrap functions */
    42 static int
    43 DUMMYAUD_Available(void)
    44 {
    45     return 1;  /* always available. */
    46 }
    47 
    48 static int
    49 DUMMYAUD_Init(SDL_AudioDriverImpl *impl)
    50 {
    51     /* Set the function pointers */
    52     impl->OpenDevice = DUMMYAUD_OpenDevice;
    53     impl->OnlyHasDefaultOutputDevice = 1;
    54 
    55     return 1;
    56 }
    57 
    58 AudioBootStrap DUMMYAUD_bootstrap = {
    59     DUMMYAUD_DRIVER_NAME, "SDL dummy audio driver",
    60     DUMMYAUD_Available, DUMMYAUD_Init, 1
    61 };
    62 
    63 static int
    64 DUMMYAUD_OpenDevice(_THIS, const char *devname, int iscapture)
    65 {
    66     return 1;   /* always succeeds. */
    67 }
    68 
    69 /* vi: set ts=4 sw=4 expandtab: */