src/audio/macosx/SDL_coreaudio.h
author Sam Lantinga
Sat, 21 Aug 2004 02:06:30 +0000
changeset 935 f8d5ddc7aef1
child 1312 c9b51268668f
permissions -rw-r--r--
Audio improvements from Max Horn, including a new CoreAudio driver for MacOSX
slouken@935
     1
/*
slouken@935
     2
    SDL - Simple DirectMedia Layer
slouken@935
     3
    Copyright (C) 1997-2004 Sam Lantinga
slouken@935
     4
slouken@935
     5
    This library is free software; you can redistribute it and/or
slouken@935
     6
    modify it under the terms of the GNU Library General Public
slouken@935
     7
    License as published by the Free Software Foundation; either
slouken@935
     8
    version 2 of the License, or (at your option) any later version.
slouken@935
     9
slouken@935
    10
    This library is distributed in the hope that it will be useful,
slouken@935
    11
    but WITHOUT ANY WARRANTY; without even the implied warranty of
slouken@935
    12
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
slouken@935
    13
    Library General Public License for more details.
slouken@935
    14
slouken@935
    15
    You should have received a copy of the GNU Library General Public
slouken@935
    16
    License along with this library; if not, write to the Free
slouken@935
    17
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
slouken@935
    18
slouken@935
    19
    Sam Lantinga
slouken@935
    20
    slouken@libsdl.org
slouken@935
    21
*/
slouken@935
    22
slouken@935
    23
#ifdef SAVE_RCSID
slouken@935
    24
static char rcsid =
slouken@935
    25
 "@(#) $Id$";
slouken@935
    26
#endif
slouken@935
    27
slouken@935
    28
#ifndef _SDL_coreaudio_h
slouken@935
    29
#define _SDL_coreaudio_h
slouken@935
    30
slouken@935
    31
#include "SDL_sysaudio.h"
slouken@935
    32
slouken@935
    33
/* Hidden "this" pointer for the video functions */
slouken@935
    34
#define _THIS	SDL_AudioDevice *this
slouken@935
    35
slouken@935
    36
struct SDL_PrivateAudioData {
slouken@935
    37
	AudioUnit outputAudioUnit;
slouken@935
    38
	void *buffer;
slouken@935
    39
	UInt32 bufferOffset;
slouken@935
    40
	UInt32 bufferSize;
slouken@935
    41
};
slouken@935
    42
slouken@935
    43
/* Old variable names */
slouken@935
    44
#define outputAudioUnit		(this->hidden->outputAudioUnit)
slouken@935
    45
#define buffer		(this->hidden->buffer)
slouken@935
    46
#define bufferOffset		(this->hidden->bufferOffset)
slouken@935
    47
#define bufferSize		(this->hidden->bufferSize)
slouken@935
    48
slouken@935
    49
#endif /* _SDL_coreaudio_h */