src/audio/fusionsound/SDL_fsaudio.h
author Sam Lantinga
Thu, 01 Jan 2009 21:34:22 +0000
changeset 2947 fec0db6c44b7
child 3697 f7b03b6838cb
permissions -rw-r--r--
Date: Thu, 01 Jan 2009 21:32:12 +0100
From: Couriersud
Subject: Fusionsound audio driver

attached is a diff containing a audio driver for the FusionSound
library. This sound library is closely related to DirectFB and uses the
same transport (fusion) as DirectFB when running applications "remote",
i.e. over the network. As such, it natively redirects sound where
DirectFB redirects video. This may be handy for everyone using SDL over
DirectFB.
slouken@2947
     1
/*
slouken@2947
     2
    SDL - Simple DirectMedia Layer
slouken@2947
     3
    Copyright (C) 1997-2009 Sam Lantinga
slouken@2947
     4
slouken@2947
     5
    This library is free software; you can redistribute it and/or
slouken@2947
     6
    modify it under the terms of the GNU Lesser General Public
slouken@2947
     7
    License as published by the Free Software Foundation; either
slouken@2947
     8
    version 2.1 of the License, or (at your option) any later version.
slouken@2947
     9
slouken@2947
    10
    This library is distributed in the hope that it will be useful,
slouken@2947
    11
    but WITHOUT ANY WARRANTY; without even the implied warranty of
slouken@2947
    12
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
slouken@2947
    13
    Lesser General Public License for more details.
slouken@2947
    14
slouken@2947
    15
    You should have received a copy of the GNU Lesser General Public
slouken@2947
    16
    License along with this library; if not, write to the Free Software
slouken@2947
    17
    Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
slouken@2947
    18
slouken@2947
    19
    Sam Lantinga
slouken@2947
    20
    slouken@libsdl.org
slouken@2947
    21
*/
slouken@2947
    22
#include "SDL_config.h"
slouken@2947
    23
slouken@2947
    24
#ifndef _SDL_fsaudio_h
slouken@2947
    25
#define _SDL_fsaudio_h
slouken@2947
    26
slouken@2947
    27
#include <fusionsound/fusionsound.h>
slouken@2947
    28
slouken@2947
    29
#include "../SDL_sysaudio.h"
slouken@2947
    30
slouken@2947
    31
/* Hidden "this" pointer for the audio functions */
slouken@2947
    32
#define _THIS	SDL_AudioDevice *this
slouken@2947
    33
slouken@2947
    34
struct SDL_PrivateAudioData
slouken@2947
    35
{
slouken@2947
    36
    /* Interface */
slouken@2947
    37
    IFusionSound *fs;
slouken@2947
    38
slouken@2947
    39
    /* The stream interface for the audio device */
slouken@2947
    40
    IFusionSoundStream *stream;
slouken@2947
    41
slouken@2947
    42
    /* Raw mixing buffer */
slouken@2947
    43
    Uint8 *mixbuf;
slouken@2947
    44
    int mixlen;
slouken@2947
    45
    int mixsamples;
slouken@2947
    46
slouken@2947
    47
};
slouken@2947
    48
slouken@2947
    49
#endif /* _SDL_fsaudio_h */
slouken@2947
    50
/* vi: set ts=4 sw=4 expandtab: */