re3-mirror/src/audio/sampman_null.cpp

404 lines
6.4 KiB
C++
Raw Normal View History

2020-05-17 19:13:25 +01:00
#include "common.h"
#if !defined(AUDIO_OAL) && !defined(AUDIO_MSS)
#include "sampman.h"
#include "AudioManager.h"
cSampleManager SampleManager;
2021-05-22 11:08:26 +01:00
bool8 _bSampmanInitialised = FALSE;
2020-05-17 19:13:25 +01:00
uint32 BankStartOffset[MAX_SFX_BANKS];
2020-05-17 19:13:25 +01:00
uint32 nNumMP3s;
cSampleManager::cSampleManager(void)
{
;
}
cSampleManager::~cSampleManager(void)
{
}
2021-08-12 13:03:38 +01:00
#ifdef EXTERNAL_3D_SOUND
2020-05-17 19:13:25 +01:00
void cSampleManager::SetSpeakerConfig(int32 nConfig)
{
}
uint32 cSampleManager::GetMaximumSupportedChannels(void)
{
return MAXCHANNELS;
}
uint32 cSampleManager::GetNum3DProvidersAvailable()
{
return 1;
}
void cSampleManager::SetNum3DProvidersAvailable(uint32 num)
{
}
char *cSampleManager::Get3DProviderName(uint8 id)
{
static char name[64] = "NULL";
return name;
}
void cSampleManager::Set3DProviderName(uint8 id, char *name)
{
}
int8 cSampleManager::GetCurrent3DProviderIndex(void)
{
return 0;
}
int8 cSampleManager::SetCurrent3DProvider(uint8 nProvider)
{
return 0;
}
2021-08-12 13:03:38 +01:00
#endif
2020-05-17 19:13:25 +01:00
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::IsMP3RadioChannelAvailable(void)
{
return nNumMP3s != 0;
}
void cSampleManager::ReleaseDigitalHandle(void)
{
}
void cSampleManager::ReacquireDigitalHandle(void)
{
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::Initialise(void)
{
2021-05-22 11:08:26 +01:00
return TRUE;
2020-05-17 19:13:25 +01:00
}
void
cSampleManager::Terminate(void)
{
}
2021-05-22 11:08:26 +01:00
bool8 cSampleManager::CheckForAnAudioFileOnCD(void)
2020-05-17 19:13:25 +01:00
{
2021-05-22 11:08:26 +01:00
return TRUE;
2020-05-17 19:13:25 +01:00
}
char cSampleManager::GetCDAudioDriveLetter(void)
{
return '\0';
}
void
cSampleManager::UpdateEffectsVolume(void)
{
}
void
cSampleManager::SetEffectsMasterVolume(uint8 nVolume)
{
}
void
cSampleManager::SetMusicMasterVolume(uint8 nVolume)
{
}
void
2021-07-07 00:59:16 +01:00
cSampleManager::SetMP3BoostVolume(uint8 nVolume)
{
}
2020-05-17 19:13:25 +01:00
void
cSampleManager::SetEffectsFadeVolume(uint8 nVolume)
{
}
void
cSampleManager::SetMusicFadeVolume(uint8 nVolume)
{
}
void
2021-05-22 11:08:26 +01:00
cSampleManager::SetMonoMode(bool8 nMode)
2020-05-17 19:13:25 +01:00
{
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::LoadSampleBank(uint8 nBank)
{
ASSERT( nBank < MAX_SFX_BANKS );
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
void
cSampleManager::UnloadSampleBank(uint8 nBank)
{
ASSERT( nBank < MAX_SFX_BANKS );
2020-05-17 19:13:25 +01:00
}
2021-09-02 17:22:50 +01:00
int8
2020-05-17 19:13:25 +01:00
cSampleManager::IsSampleBankLoaded(uint8 nBank)
{
ASSERT( nBank < MAX_SFX_BANKS );
2020-05-17 19:13:25 +01:00
2021-09-02 17:22:50 +01:00
return LOADING_STATUS_NOT_LOADED;
}
2021-09-02 17:22:50 +01:00
uint8
cSampleManager::IsMissionAudioLoaded(uint8 nSlot, uint32 nSample)
{
ASSERT(nSlot < MISSION_AUDIO_COUNT);
2021-09-02 17:22:50 +01:00
return LOADING_STATUS_NOT_LOADED;
}
bool8
cSampleManager::LoadMissionAudio(uint8 nSlot, uint32 nSample)
{
ASSERT(nSlot < MISSION_AUDIO_COUNT);
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
2021-09-02 17:22:50 +01:00
uint8
2020-05-17 19:13:25 +01:00
cSampleManager::IsPedCommentLoaded(uint32 nComment)
{
ASSERT( nComment < TOTAL_AUDIO_SAMPLES );
2021-09-02 17:22:50 +01:00
return LOADING_STATUS_NOT_LOADED;
2020-05-17 19:13:25 +01:00
}
int32
cSampleManager::_GetPedCommentSlot(uint32 nComment)
{
return -1;
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::LoadPedComment(uint32 nComment)
{
ASSERT( nComment < TOTAL_AUDIO_SAMPLES );
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
int32
cSampleManager::GetBankContainingSound(uint32 offset)
{
return INVALID_SFX_BANK;
2020-05-17 19:13:25 +01:00
}
uint32
2020-05-17 19:13:25 +01:00
cSampleManager::GetSampleBaseFrequency(uint32 nSample)
{
ASSERT( nSample < TOTAL_AUDIO_SAMPLES );
return 0;
}
uint32
2020-05-17 19:13:25 +01:00
cSampleManager::GetSampleLoopStartOffset(uint32 nSample)
{
ASSERT( nSample < TOTAL_AUDIO_SAMPLES );
return 0;
}
int32
cSampleManager::GetSampleLoopEndOffset(uint32 nSample)
{
ASSERT( nSample < TOTAL_AUDIO_SAMPLES );
return 0;
}
uint32
cSampleManager::GetSampleLength(uint32 nSample)
{
ASSERT( nSample < TOTAL_AUDIO_SAMPLES );
return 0;
}
2021-05-22 11:08:26 +01:00
bool8 cSampleManager::UpdateReverb(void)
2020-05-17 19:13:25 +01:00
{
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
void
2021-05-22 11:08:26 +01:00
cSampleManager::SetChannelReverbFlag(uint32 nChannel, bool8 nReverbFlag)
2020-05-17 19:13:25 +01:00
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::InitialiseChannel(uint32 nChannel, uint32 nSfx, uint8 nBank)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
2021-08-12 13:03:38 +01:00
#ifdef EXTERNAL_3D_SOUND
2020-05-17 19:13:25 +01:00
void
cSampleManager::SetChannelEmittingVolume(uint32 nChannel, uint32 nVolume)
{
2021-07-07 00:59:16 +01:00
ASSERT( nChannel < MAXCHANNELS );
2020-05-17 19:13:25 +01:00
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::SetChannel3DPosition(uint32 nChannel, float fX, float fY, float fZ)
{
2021-07-07 00:59:16 +01:00
ASSERT( nChannel < MAXCHANNELS );
2020-05-17 19:13:25 +01:00
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::SetChannel3DDistances(uint32 nChannel, float fMax, float fMin)
{
2021-07-07 00:59:16 +01:00
ASSERT( nChannel < MAXCHANNELS );
2020-05-17 19:13:25 +01:00
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
2021-08-12 13:03:38 +01:00
#endif
2020-05-17 19:13:25 +01:00
void
cSampleManager::SetChannelVolume(uint32 nChannel, uint32 nVolume)
{
2021-07-07 00:59:16 +01:00
ASSERT( nChannel >= MAXCHANNELS );
2020-05-17 19:13:25 +01:00
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::SetChannelPan(uint32 nChannel, uint32 nPan)
{
2021-07-07 00:59:16 +01:00
ASSERT( nChannel >= MAXCHANNELS );
2020-05-17 19:13:25 +01:00
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::SetChannelFrequency(uint32 nChannel, uint32 nFreq)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::SetChannelLoopPoints(uint32 nChannel, uint32 nLoopStart, int32 nLoopEnd)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::SetChannelLoopCount(uint32 nChannel, uint32 nLoopCount)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::GetChannelUsedFlag(uint32 nChannel)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
void
cSampleManager::StartChannel(uint32 nChannel)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
cSampleManager::StopChannel(uint32 nChannel)
{
ASSERT( nChannel < MAXCHANNELS+MAX2DCHANNELS );
}
void
2020-05-31 18:59:01 +01:00
cSampleManager::PreloadStreamedFile(uint32 nFile, uint8 nStream)
2020-05-17 19:13:25 +01:00
{
ASSERT( nStream < MAX_STREAMS );
}
void
2021-05-22 11:08:26 +01:00
cSampleManager::PauseStream(bool8 nPauseFlag, uint8 nStream)
2020-05-17 19:13:25 +01:00
{
ASSERT( nStream < MAX_STREAMS );
}
void
cSampleManager::StartPreloadedStreamedFile(uint8 nStream)
{
ASSERT( nStream < MAX_STREAMS );
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-31 18:59:01 +01:00
cSampleManager::StartStreamedFile(uint32 nFile, uint32 nPos, uint8 nStream)
2020-05-17 19:13:25 +01:00
{
ASSERT( nStream < MAX_STREAMS );
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
void
cSampleManager::StopStreamedFile(uint8 nStream)
{
ASSERT( nStream < MAX_STREAMS );
}
int32
cSampleManager::GetStreamedFilePosition(uint8 nStream)
{
ASSERT( nStream < MAX_STREAMS );
return 0;
}
void
2021-05-22 11:08:26 +01:00
cSampleManager::SetStreamedVolumeAndPan(uint8 nVolume, uint8 nPan, bool8 nEffectFlag, uint8 nStream)
2020-05-17 19:13:25 +01:00
{
ASSERT( nStream < MAX_STREAMS );
}
int32
cSampleManager::GetStreamedFileLength(uint8 nStream)
{
ASSERT( nStream < TOTAL_STREAMED_SOUNDS );
return 1;
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::IsStreamPlaying(uint8 nStream)
{
ASSERT( nStream < MAX_STREAMS );
2021-05-22 11:08:26 +01:00
return FALSE;
2020-05-17 19:13:25 +01:00
}
2021-05-22 11:08:26 +01:00
bool8
2020-05-17 19:13:25 +01:00
cSampleManager::InitialiseSampleBanks(void)
{
2021-05-22 11:08:26 +01:00
return TRUE;
2020-05-17 19:13:25 +01:00
}
void
cSampleManager::SetStreamedFileLoopFlag(bool8 nLoopFlag, uint8 nChannel)
{
}
int8 cSampleManager::AutoDetect3DProviders()
{
return -1;
}
2020-05-17 19:13:25 +01:00
#endif