* More header cleanup, continuing korli's work.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36206 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2010-04-13 09:48:02 +00:00
parent 2d4ce06468
commit f46308c92a
21 changed files with 623 additions and 769 deletions
+70 -85
View File
@@ -1,34 +1,17 @@
//------------------------------------------------------------------------------
// Copyright (c) 2001-2002, OpenBeOS
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// File Name: FileGameSound.h
// Author: Christopher ML Zumwalt May ([email protected])
// Description: BFileGameSound is a class that streams data out of a file.
//------------------------------------------------------------------------------
/*
* Copyright 2001-2002, Haiku Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*
* Author:
* Christopher ML Zumwalt May ([email protected])
*/
#ifndef _FILEGAMESOUND_H
#define _FILEGAMESOUND_H
#include <StreamingGameSound.h>
struct entry_ref;
struct _gs_media_tracker;
struct _gs_ramp;
@@ -36,41 +19,78 @@ struct _gs_ramp;
class BFileGameSound : public BStreamingGameSound {
public:
BFileGameSound(const entry_ref * file,
bool looping = true,
BGameSoundDevice * device = NULL);
BFileGameSound(const char * file,
bool looping = true,
BGameSoundDevice * device = NULL);
BFileGameSound(const entry_ref* file,
bool looping = true,
BGameSoundDevice* device = NULL);
BFileGameSound(const char* file,
bool looping = true,
BGameSoundDevice* device = NULL);
virtual ~BFileGameSound();
virtual ~BFileGameSound();
virtual BGameSound * Clone() const;
virtual BGameSound* Clone() const;
virtual status_t StartPlaying();
virtual status_t StopPlaying();
status_t Preload(); // if you have stopped and want to start quickly again
virtual status_t StartPlaying();
virtual status_t StopPlaying();
status_t Preload();
// if you have stopped and want to start quickly again
virtual void FillBuffer(void* buffer, size_t byteCount);
virtual status_t Perform(int32 selector, void* data);
virtual status_t SetPaused(bool isPaused, bigtime_t rampTime);
virtual void FillBuffer(void * inBuffer,
size_t inByteCount);
virtual status_t Perform(int32 selector, void * data);
virtual status_t SetPaused(bool isPaused,
bigtime_t rampTime);
enum {
B_NOT_PAUSED,
B_PAUSE_IN_PROGRESS,
B_PAUSED
};
int32 IsPaused();
int32 IsPaused();
private:
_gs_media_tracker * fAudioStream;
BFileGameSound();
BFileGameSound(const BFileGameSound& other);
BFileGameSound& operator=(const BFileGameSound& other);
// not implemented
status_t Init(const entry_ref* file);
bool Load();
bool Read(void* buffer, size_t bytes);
status_t _Reserved_BFileGameSound_0(int32 arg, ...);
// SetPaused(bool paused, bigtime_t ramp);
virtual status_t _Reserved_BFileGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_23(int32 arg, ...);
private:
_gs_media_tracker* fAudioStream;
bool fStopping;
bool fLooping;
char fReserved;
char * fBuffer;
char* fBuffer;
size_t fFrameSize;
size_t fBufferSize;
size_t fPlayPosition;
@@ -78,48 +98,13 @@ private:
thread_id fReadThread;
port_id fPort;
_gs_ramp * fPausing;
_gs_ramp* fPausing;
bool fPaused;
float fPauseGain;
status_t Init(const entry_ref* file);
bool Load();
bool Read(void * buffer, size_t bytes);
/* leave these declarations private unless you plan on actually implementing and using them. */
BFileGameSound();
BFileGameSound(const BFileGameSound&);
BFileGameSound& operator=(const BFileGameSound&);
/* fbc data and virtuals */
uint32 _reserved_BFileGameSound_[9];
status_t _Reserved_BFileGameSound_0(int32 arg, ...); /* SetPaused(bool paused, bigtime_t ramp); */
virtual status_t _Reserved_BFileGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BFileGameSound_23(int32 arg, ...);
uint32 _reserved[9];
};
#endif // _FILEGAMESOUND_H
+111 -142
View File
@@ -1,168 +1,137 @@
//------------------------------------------------------------------------------
// Copyright (c) 2001-2002, OpenBeOS
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// File Name: GameSound.h
// Author: Christopher ML Zumwalt May ([email protected])
// Description: Base class for play sounds using the game kit
//------------------------------------------------------------------------------
/*
* Copyright 2001-2002, Haiku Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*
* Author:
* Christopher ML Zumwalt May ([email protected])
*/
#ifndef _GAMESOUND_H
#define _GAMESOUND_H
// Standard Includes -----------------------------------------------------------
// System Includes -------------------------------------------------------------
#include <GameSoundDefs.h>
#include <new>
// Project Includes ------------------------------------------------------------
// Local Includes --------------------------------------------------------------
// Local Defines ---------------------------------------------------------------
// Globals ---------------------------------------------------------------------
class BGameSoundDevice;
// BGameSound class -------------------------------------------------------------
class BGameSound
{
class BGameSound {
public:
BGameSound(BGameSoundDevice * device = NULL);
virtual ~BGameSound();
BGameSound(BGameSoundDevice* device = NULL);
virtual ~BGameSound();
virtual BGameSound * Clone() const = 0;
status_t InitCheck() const;
// BGameSound attributes
BGameSoundDevice * Device() const;
gs_id ID() const;
const gs_audio_format & Format() const; // only valid after Init()
virtual BGameSound* Clone() const = 0;
status_t InitCheck() const;
// Playing sounds
virtual status_t StartPlaying();
virtual bool IsPlaying();
virtual status_t StopPlaying();
// BGameSound attributes
BGameSoundDevice* Device() const;
gs_id ID() const;
const gs_audio_format& Format() const;
// only valid after Init()
// Modifing the playback
status_t SetGain(float gain,
bigtime_t duration = 0); // ramp duration in seconds
status_t SetPan(float pan,
bigtime_t duration = 0); // ramp duration in seconds
float Gain();
float Pan();
// Playing sounds
virtual status_t StartPlaying();
virtual bool IsPlaying();
virtual status_t StopPlaying();
virtual status_t SetAttributes(gs_attribute * inAttributes,
size_t inAttributeCount);
virtual status_t GetAttributes(gs_attribute * outAttributes,
size_t inAttributeCount);
// Modifing the playback
status_t SetGain(float gain, bigtime_t duration = 0);
// ramp duration in seconds
status_t SetPan(float pan, bigtime_t duration = 0);
// ramp duration in seconds
void * operator new(size_t size);
void * operator new(size_t size,
const std::nothrow_t &) throw();
void operator delete(void * ptr);
#if !__MWERKS__
// there's a bug in MWCC under R4.1 and earlier
void operator delete(void * ptr,
const std::nothrow_t &) throw();
#endif
float Gain();
float Pan();
virtual status_t SetAttributes(gs_attribute* attributes,
size_t attributeCount);
virtual status_t GetAttributes(gs_attribute* attributes,
size_t attributeCount);
void* operator new(size_t size);
void* operator new(size_t size,
const std::nothrow_t&) throw();
void operator delete(void* ptr);
void operator delete(void* ptr,
const std::nothrow_t&) throw();
static status_t SetMemoryPoolSize(size_t poolSize);
static status_t LockMemoryPool(bool lockInCore);
static int32 SetMaxSoundCount(int32 maxCount);
virtual status_t Perform(int32 selector, void* data);
static status_t SetMemoryPoolSize(size_t in_poolSize);
static status_t LockMemoryPool(bool in_lockInCore);
static int32 SetMaxSoundCount(int32 in_maxCount);
virtual status_t Perform(int32 selector, void * data);
protected:
status_t SetInitError(status_t initError);
status_t Init(gs_id handle);
status_t SetInitError(status_t in_initError);
status_t Init(gs_id handle);
BGameSound(const BGameSound& other);
BGameSound& operator=(const BGameSound& other);
BGameSound(const BGameSound & other);
BGameSound & operator=(const BGameSound & other);
private:
BGameSoundDevice* fDevice;
status_t fInitError;
BGameSound();
// not implemented
virtual status_t _Reserved_BGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BGameSound_23(int32 arg, ...);
virtual status_t _Reserved_BGameSound_24(int32 arg, ...);
virtual status_t _Reserved_BGameSound_25(int32 arg, ...);
virtual status_t _Reserved_BGameSound_26(int32 arg, ...);
virtual status_t _Reserved_BGameSound_27(int32 arg, ...);
virtual status_t _Reserved_BGameSound_28(int32 arg, ...);
virtual status_t _Reserved_BGameSound_29(int32 arg, ...);
virtual status_t _Reserved_BGameSound_30(int32 arg, ...);
virtual status_t _Reserved_BGameSound_31(int32 arg, ...);
virtual status_t _Reserved_BGameSound_32(int32 arg, ...);
virtual status_t _Reserved_BGameSound_33(int32 arg, ...);
virtual status_t _Reserved_BGameSound_34(int32 arg, ...);
virtual status_t _Reserved_BGameSound_35(int32 arg, ...);
virtual status_t _Reserved_BGameSound_36(int32 arg, ...);
virtual status_t _Reserved_BGameSound_37(int32 arg, ...);
virtual status_t _Reserved_BGameSound_38(int32 arg, ...);
virtual status_t _Reserved_BGameSound_39(int32 arg, ...);
virtual status_t _Reserved_BGameSound_40(int32 arg, ...);
virtual status_t _Reserved_BGameSound_41(int32 arg, ...);
virtual status_t _Reserved_BGameSound_42(int32 arg, ...);
virtual status_t _Reserved_BGameSound_43(int32 arg, ...);
virtual status_t _Reserved_BGameSound_44(int32 arg, ...);
virtual status_t _Reserved_BGameSound_45(int32 arg, ...);
virtual status_t _Reserved_BGameSound_46(int32 arg, ...);
virtual status_t _Reserved_BGameSound_47(int32 arg, ...);
private:
BGameSoundDevice* fDevice;
status_t fInitError;
gs_audio_format fFormat;
gs_id fSound;
/* leave these declarations private unless you plan on actually implementing and using them. */
BGameSound();
/* fbc data and virtuals */
uint32 _reserved_BGameSound_[16];
virtual status_t _Reserved_BGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BGameSound_23(int32 arg, ...);
virtual status_t _Reserved_BGameSound_24(int32 arg, ...);
virtual status_t _Reserved_BGameSound_25(int32 arg, ...);
virtual status_t _Reserved_BGameSound_26(int32 arg, ...);
virtual status_t _Reserved_BGameSound_27(int32 arg, ...);
virtual status_t _Reserved_BGameSound_28(int32 arg, ...);
virtual status_t _Reserved_BGameSound_29(int32 arg, ...);
virtual status_t _Reserved_BGameSound_30(int32 arg, ...);
virtual status_t _Reserved_BGameSound_31(int32 arg, ...);
virtual status_t _Reserved_BGameSound_32(int32 arg, ...);
virtual status_t _Reserved_BGameSound_33(int32 arg, ...);
virtual status_t _Reserved_BGameSound_34(int32 arg, ...);
virtual status_t _Reserved_BGameSound_35(int32 arg, ...);
virtual status_t _Reserved_BGameSound_36(int32 arg, ...);
virtual status_t _Reserved_BGameSound_37(int32 arg, ...);
virtual status_t _Reserved_BGameSound_38(int32 arg, ...);
virtual status_t _Reserved_BGameSound_39(int32 arg, ...);
virtual status_t _Reserved_BGameSound_40(int32 arg, ...);
virtual status_t _Reserved_BGameSound_41(int32 arg, ...);
virtual status_t _Reserved_BGameSound_42(int32 arg, ...);
virtual status_t _Reserved_BGameSound_43(int32 arg, ...);
virtual status_t _Reserved_BGameSound_44(int32 arg, ...);
virtual status_t _Reserved_BGameSound_45(int32 arg, ...);
virtual status_t _Reserved_BGameSound_46(int32 arg, ...);
virtual status_t _Reserved_BGameSound_47(int32 arg, ...);
gs_audio_format fFormat;
gs_id fSound;
uint32 _reserved[16];
};
#endif // _GAME_SOUND_H
#endif // _GAME_SOUND_H
+46 -62
View File
@@ -1,48 +1,30 @@
//------------------------------------------------------------------------------
// Copyright (c) 2001-2002, OpenBeOS
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// File Name: GameSound.cpp
// Author: Christopher ML Zumwalt May ([email protected])
// Description: Declarations for game sounds
//------------------------------------------------------------------------------
#if !defined(_GAME_SOUND_DEFS_H)
/*
* Copyright 2001-2002, Haiku Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*
* Author:
* Christopher ML Zumwalt May ([email protected])
*/
#ifndef _GAME_SOUND_DEFS_H
#define _GAME_SOUND_DEFS_H
#include <SupportDefs.h>
typedef int32 gs_id;
#define B_GS_CUR_API_VERSION B_BEOS_VERSION
#define B_GS_MIN_API_VERSION 0x100
// invalid sound handle
// invalid sound handle
#define B_GS_INVALID_SOUND ((gs_id)-1)
// gs_id for the main mix buffer
// gs_id for the main mix buffer
#define B_GS_MAIN_SOUND ((gs_id)-2)
enum //fixme renumber to real error messages
{
enum {
B_GS_BAD_HANDLE = -99999,
B_GS_NO_SOUNDS,
B_GS_NO_HARDWARE,
@@ -51,45 +33,47 @@ enum //fixme renumber to real error messages
};
struct gs_audio_format
{ /* same as media_raw_audio_format */
enum format { /* for "format" */
B_GS_U8 = 0x11, /* 128 == mid, 1 == bottom, 255 == top */
B_GS_S16 = 0x2, /* 0 == mid, -32767 == bottom, +32767 == top */
B_GS_F = 0x24, /* 0 == mid, -1.0 == bottom, 1.0 == top */
B_GS_S32 = 0x4 /* 0 == mid, 0x80000001 == bottom, 0x7fffffff == top */
struct gs_audio_format {
// same as media_raw_audio_format
enum format { // for "format"
B_GS_U8 = 0x11, // 128 == mid, 1 == bottom, 255 == top
B_GS_S16 = 0x2, // 0 == mid, -32767 == bottom, +32767 == top
B_GS_F = 0x24, // 0 == mid, -1.0 == bottom, 1.0 == top
B_GS_S32 = 0x4 // 0 == mid, 0x80000001 == bottom,
// 0x7fffffff == top
};
float frame_rate;
uint32 channel_count; /* 1 or 2, mostly */
uint32 format; /* for compressed formats, go to media_encoded_audio_format */
uint32 byte_order; /* 2 for little endian, 1 for big endian */
size_t buffer_size; /* size of each buffer -- NOT GUARANTEED */
uint32 channel_count; // 1 or 2, mostly
uint32 format; // for compressed formats, go to
// media_encoded_audio_format
uint32 byte_order; // 2 for little endian, 1 for big endian
size_t buffer_size; // size of each buffer -- NOT GUARANTEED
};
//
enum gs_attributes
{
B_GS_NO_ATTRIBUTE = 0, // when there is no attribute
B_GS_MAIN_GAIN = 1, // 0 == 0 dB, -6.0 == -6 dB (gs_id ignored)
B_GS_CD_THROUGH_GAIN, // 0 == 0 dB, -12.0 == -12 dB (gs_id ignored)
// but which CD?
B_GS_GAIN = 128, // 0 == 0 dB, -1.0 == -1 dB, +10.0 == +10 dB
B_GS_PAN, // 0 == middle, -1.0 == left, +1.0 == right
B_GS_SAMPLING_RATE, // 44100.0 == 44.1 kHz
B_GS_LOOPING, // 0 == no
enum gs_attributes {
B_GS_NO_ATTRIBUTE = 0, // when there is no attribute
B_GS_MAIN_GAIN = 1, // 0 == 0 dB, -6.0 == -6 dB (gs_id ignored)
B_GS_CD_THROUGH_GAIN, // 0 == 0 dB, -12.0 == -12 dB (gs_id ignored)
// but which CD?
B_GS_GAIN = 128, // 0 == 0 dB, -1.0 == -1 dB, +10.0 == +10 dB
B_GS_PAN, // 0 == middle, -1.0 == left, +1.0 == right
B_GS_SAMPLING_RATE, // 44100.0 == 44.1 kHz
B_GS_LOOPING, // 0 == no
B_GS_FIRST_PRIVATE_ATTRIBUTE = 90000,
B_GS_FIRST_USER_ATTRIBUTE = 100000
};
struct gs_attribute
{
int32 attribute; // which attribute
bigtime_t duration; // how long of time to ramp over for the change
float value; // where the value stops changing
uint32 flags; // whatever flags are for the attribute
struct gs_attribute {
int32 attribute; // which attribute
bigtime_t duration; // how long of time to ramp over for the change
float value; // where the value stops changing
uint32 flags; // whatever flags are for the attribute
};
struct gs_attribute_info
{
struct gs_attribute_info {
int32 attribute;
float granularity;
float minimum;
@@ -97,4 +81,4 @@ struct gs_attribute_info
};
#endif // _GAME_SOUND_DEFS_H
#endif // _GAME_SOUND_DEFS_H
+77 -100
View File
@@ -1,128 +1,105 @@
//------------------------------------------------------------------------------
// Copyright (c) 2001-2002, OpenBeOS
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// File Name: FileGameSound.h
// Author: Christopher ML Zumwalt May ([email protected])
// Description: BFileGameSound is a class that streams data out of a file.
//------------------------------------------------------------------------------
/*
* Copyright 2001-2002, Haiku Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*
* Author:
* Christopher ML Zumwalt May ([email protected])
*/
#ifndef _PUSHGAMESOUND_H
#define _PUSHGAMESOUND_H
#include <StreamingGameSound.h>
class BPushGameSound : public BStreamingGameSound
{
class BPushGameSound : public BStreamingGameSound {
public:
BPushGameSound(size_t inBufferFrameCount,
const gs_audio_format * format,
size_t inBufferCount = 2,
BGameSoundDevice * device = NULL);
BPushGameSound(size_t inBufferFrameCount,
const gs_audio_format* format,
size_t inBufferCount = 2,
BGameSoundDevice* device = NULL);
virtual ~BPushGameSound();
virtual ~BPushGameSound();
enum lock_status {
lock_failed = -1, // not yet time to do more
lock_ok = 0, // do more
lock_ok_frames_dropped // you may have missed some buffers
};
enum lock_status {
lock_failed = -1, // not yet time to do more
lock_ok = 0, // do more
lock_ok_frames_dropped // you may have missed some buffers
};
virtual lock_status LockNextPage(void ** out_pagePtr,
size_t * out_pageSize);
virtual status_t UnlockPage(void * in_pagePtr);
virtual lock_status LockNextPage(void** _pagePtr,
size_t* _pageSize);
virtual status_t UnlockPage(void* pagePtr);
virtual lock_status LockForCyclic(void ** out_basePtr,
size_t * out_size);
virtual status_t UnlockCyclic();
virtual size_t CurrentPosition();
virtual lock_status LockForCyclic(void** _basePtr, size_t* _size);
virtual status_t UnlockCyclic();
virtual size_t CurrentPosition();
virtual BGameSound * Clone() const;
virtual BGameSound* Clone() const;
virtual status_t Perform(int32 selector, void * data);
virtual status_t Perform(int32 selector, void* data);
protected:
BPushGameSound(BGameSoundDevice * device);
BPushGameSound(BGameSoundDevice* device);
virtual status_t SetParameters(size_t inBufferFrameCount,
const gs_audio_format * format,
size_t inBufferCount);
virtual status_t SetParameters(size_t bufferFrameCount,
const gs_audio_format* format,
size_t bufferCount);
virtual status_t SetStreamHook(void (*hook)(void * inCookie, void * inBuffer, size_t inByteCount, BStreamingGameSound * me),
void * cookie);
virtual void FillBuffer(void * inBuffer,
size_t inByteCount);
virtual status_t SetStreamHook(void (*hook)(void* inCookie,
void* buffer, size_t byteCount,
BStreamingGameSound* me),
void* cookie);
virtual void FillBuffer(void* buffer, size_t byteCount);
private:
BPushGameSound();
BPushGameSound(const BPushGameSound& other);
BPushGameSound& operator=(const BPushGameSound& other);
// not implemented
/* leave these declarations private unless you plan on actually implementing and using them. */
BPushGameSound();
BPushGameSound(const BPushGameSound&);
BPushGameSound& operator=(const BPushGameSound&);
bool BytesReady(size_t* bytes);
bool BytesReady(size_t * bytes);
virtual status_t _Reserved_BPushGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_23(int32 arg, ...);
private:
sem_id fLock;
BList* fPageLocked;
sem_id fLock;
BList * fPageLocked;
size_t fLockPos;
size_t fPlayPos;
size_t fLockPos;
size_t fPlayPos;
char * fBuffer;
size_t fPageSize;
int32 fPageCount;
size_t fBufferSize;
/* fbc data and virtuals */
uint32 _reserved_BPushGameSound_[12];
virtual status_t _Reserved_BPushGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BPushGameSound_23(int32 arg, ...);
char* fBuffer;
size_t fPageSize;
int32 fPageCount;
size_t fBufferSize;
uint32 _reserved[12];
};
#endif // _PUSH_GAME_SOUND_H
+49 -51
View File
@@ -1,5 +1,5 @@
/*
* Copyright 2001-2008, Haiku Inc. All Rights Reserved.
* Copyright 2001-2010, Haiku Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*/
#ifndef _SIMPLEGAMESOUND_H
@@ -15,64 +15,62 @@ struct entry_ref;
class BSimpleGameSound : public BGameSound {
public:
BSimpleGameSound(const entry_ref * inFile,
BGameSoundDevice * device = NULL);
BSimpleGameSound(const char * inFile,
BGameSoundDevice * device = NULL);
BSimpleGameSound(const void * inData,
size_t inFrameCount,
const gs_audio_format * format,
BGameSoundDevice * device = NULL);
BSimpleGameSound(const BSimpleGameSound & other);
BSimpleGameSound(const entry_ref* file,
BGameSoundDevice* device = NULL);
BSimpleGameSound(const char* file,
BGameSoundDevice* device = NULL);
BSimpleGameSound(const void* data,
size_t frameCount,
const gs_audio_format* format,
BGameSoundDevice* device = NULL);
BSimpleGameSound(const BSimpleGameSound& other);
virtual ~BSimpleGameSound();
virtual ~BSimpleGameSound();
virtual BGameSound * Clone() const;
virtual BGameSound* Clone() const;
virtual status_t Perform(int32 selector, void * data);
virtual status_t Perform(int32 selector, void* data);
status_t SetIsLooping(bool looping);
bool IsLooping() const;
status_t SetIsLooping(bool looping);
bool IsLooping() const;
private:
status_t Init(const entry_ref * inFile);
status_t Init(const void* inData, int64 inFrameCount,
const gs_audio_format* format);
/* leave these declarations private unless you plan on actually implementing and using them. */
BSimpleGameSound();
BSimpleGameSound& operator=(const BSimpleGameSound&);
private:
BSimpleGameSound();
BSimpleGameSound& operator=(const BSimpleGameSound& other);
// not implemented
/* fbc data and virtuals */
status_t Init(const entry_ref* file);
status_t Init(const void* data, int64 frameCount,
const gs_audio_format* format);
uint32 _reserved_BSimpleGameSound_[12];
virtual status_t _Reserved_BSimpleGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_23(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BSimpleGameSound_23(int32 arg, ...);
private:
uint32 _reserved[12];
};
#endif // _SIMPLE_GAME_SOUND_H
#endif // _SIMPLE_GAME_SOUND_H
+66 -97
View File
@@ -1,122 +1,91 @@
//------------------------------------------------------------------------------
// Copyright (c) 2001-2002, OpenBeOS
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and associated documentation files (the "Software"),
// to deal in the Software without restriction, including without limitation
// the rights to use, copy, modify, merge, publish, distribute, sublicense,
// and/or sell copies of the Software, and to permit persons to whom the
// Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
// DEALINGS IN THE SOFTWARE.
//
// File Name: StreamingGameSound.h
// Author: Christopher ML Zumwalt May ([email protected])
// Description: BStreamingGameSound is a class for all kinds of streaming
// (data not known beforehand) game sounds.
//------------------------------------------------------------------------------
/*
* Copyright 2001-2002, Haiku Inc. All Rights Reserved.
* Distributed under the terms of the MIT License.
*
* Author:
* Christopher ML Zumwalt May ([email protected])
*/
#ifndef _STREAMINGGAMESOUND_H
#define _STREAMINGGAMESOUND_H
// Standard Includes -----------------------------------------------------------
// System Includes -------------------------------------------------------------
#include <SupportDefs.h>
#include <GameSound.h>
#include <Locker.h>
// Project Includes ------------------------------------------------------------
// Local Includes --------------------------------------------------------------
// Local Defines ---------------------------------------------------------------
// Globals ---------------------------------------------------------------------
class BStreamingGameSound : public BGameSound
{
class BStreamingGameSound : public BGameSound {
public:
BStreamingGameSound(size_t inBufferFrameCount,
const gs_audio_format * format,
size_t inBufferCount = 2,
BGameSoundDevice * device = NULL);
BStreamingGameSound(size_t bufferFrameCount,
const gs_audio_format* format,
size_t bufferCount = 2,
BGameSoundDevice* device = NULL);
virtual ~BStreamingGameSound();
virtual ~BStreamingGameSound();
virtual BGameSound * Clone() const;
virtual BGameSound* Clone() const;
virtual status_t SetStreamHook(void (*hook)(void * inCookie, void * inBuffer, size_t inByteCount, BStreamingGameSound * me),
void * cookie);
virtual void FillBuffer(void * inBuffer,
size_t inByteCount);
virtual status_t SetStreamHook(void (*hook)(void* cookie,
void* buffer, size_t byteCount,
BStreamingGameSound* me),
void* cookie);
virtual void FillBuffer(void* buffer, size_t byteCount);
virtual status_t SetAttributes(gs_attribute * inAttributes,
size_t inAttributeCount);
virtual status_t SetAttributes(gs_attribute* attributes,
size_t attributeCount);
virtual status_t Perform(int32 selector, void * data);
virtual status_t Perform(int32 selector, void* data);
protected:
BStreamingGameSound(BGameSoundDevice* device);
BStreamingGameSound(BGameSoundDevice * device);
virtual status_t SetParameters(size_t inBufferFrameCount,
const gs_audio_format * format,
size_t inBufferCount);
bool Lock();
void Unlock();
virtual status_t SetParameters(size_t bufferFrameCount,
const gs_audio_format* format,
size_t bufferCount);
bool Lock();
void Unlock();
private:
BStreamingGameSound();
BStreamingGameSound(
const BStreamingGameSound& other);
BStreamingGameSound& operator=(const BStreamingGameSound& other);
// not implemented
void (*fStreamHook)(void * cookie, void * buffer, size_t bytes, BStreamingGameSound * sound);
void * fStreamCookie;
BLocker fLock;
virtual status_t _Reserved_BStreamingGameSound_0(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_1(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_2(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_3(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_4(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_5(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_6(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_7(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_8(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_9(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_10(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_11(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_12(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_13(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_14(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_15(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_16(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_17(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_18(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_19(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_20(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_21(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_22(int32 arg,...);
virtual status_t _Reserved_BStreamingGameSound_23(int32 arg,...);
/* leave these declarations private unless you plan on actually implementing and using them. */
BStreamingGameSound();
BStreamingGameSound(const BStreamingGameSound&);
BStreamingGameSound& operator=(const BStreamingGameSound&);
/* fbc data and virtuals */
uint32 _reserved_BStreamingGameSound_[12];
virtual status_t _Reserved_BStreamingGameSound_0(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_1(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_2(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_3(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_4(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_5(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_6(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_7(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_8(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_9(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_10(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_11(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_12(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_13(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_14(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_15(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_16(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_17(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_18(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_19(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_20(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_21(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_22(int32 arg, ...);
virtual status_t _Reserved_BStreamingGameSound_23(int32 arg, ...);
private:
void (*fStreamHook)(void* cookie, void* buffer,
size_t bytes, BStreamingGameSound* sound);
void* fStreamCookie;
BLocker fLock;
uint32 _reserved[12];
};
#endif // _STREAMING_GAME_SOUND_H
#endif // _STREAMING_GAME_SOUND_H