Infinity Ward
struct SpeakerMapChannelEntry
{
int InputChannel;
int OutputChannel;
float CurrentVolume;
float TargetVolume;
};
struct SpeakerMapChannel
{
int entryCount; // how many entries are used
SpeakerMapChannelEntry entries[6];
};
struct SpeakerMap
{
bool isDefault;
const char *name;
SpeakerMapChannel channelMaps[2][2];
};
enum snd_alias_type_t : char
{
SAT_UNKNOWN = 0x0,
SAT_LOADED = 0x1,
SAT_STREAMED = 0x2,
SAT_PRIMED = 0x3,
SAT_COUNT = 0x4,
};
struct StreamedSound
{
int packfileNum;
union
{
const char *strings[2]; // if packfileNum == 0
struct
{
int soundOffset;
int soundSize;
};
};
};
union SoundData
{
LoadedSound *loadSnd; // SoundFile->type == SAT_LOADED
StreamedSound streamSnd; // SoundFile->type == SAT_STREAMED
};
struct SoundFile // 0x10
{
snd_alias_type_t type;
bool exists;
SoundData sound;
};
struct snd_alias_t
{
const char *aliasName;
const char *subtitle;
const char *secondaryAliasName;
const char *chainAliasName;
SoundFile *soundFile;
int sequence;
float volMin;
float volMax;
#ifdef MW3 || GHOSTS
int unknown1;
#endif
float pitchMin;
float pitchMax;
float distMin;
float distMax;
#ifndef COD4
float velocityMin;
#endif
int flags;
#ifdef MW3 || GHOSTS
int unknown2[2];
#endif
float slavePercentage;
float probability;
float lfePercentage;
float centerPercentage;
int startDelay;
SndCurve *volumeFalloffCurve;
#ifdef GHOSTS
LPFCurve *unknownLPFCurve;
ReverbSendCurve *unknownReverbSendCurve;
#endif
float envelopMin;
float envelopMax;
float envelopPercentage;
SpeakerMap *speakerMap;
#ifdef GHOSTS
int unknown3;
char (*unknown4)[0x18];
int unknown5;
DopplerPreset *unknownDopplerPreset;
#endif
};
struct snd_alias_list_t
{
const char *aliasName;
snd_alias_t *head;
int count;
};
World at War
struct PrimedSound
{
const char *unknownString;
const char *buffer;
int unknown;
};
struct StreamedSound
{
struct
{
int unknown;
const char *unknownStrings[2];
};
PrimedSound *primedSnd;
};
struct SoundFile
{
snd_alias_type_t type;
bool exists;
union
{
StreamedSound streamSnd;
LoadedSound *loadSnd;
} u;
};
struct snd_alias_t // 0xB8
{
const char *aliasName;
unsigned int aliasNameHash;
const char *subtitle;
const char *secondaryAliasName;
const char *chainAliasName;
SoundFile *soundFile;
int sequence;
float volMin;
float volMax;
float pitchMin;
float pitchMax;
float distMin;
float distMax;
float distReverbMax;
float slavePercentage;
float probability;
float lifePercentage;
float centerPercentage;
float envelopMin;
float envelopMax;
float realDelay;
int minPriority;
float maxPriority;
float minPriorityThreshold;
float maxPriorityThreshold;
float reverbSend;
float teamVolMod;
float teamPitchMod;
float occlusionLevel;
float occlusionWetDry;
float moveTime;
int startDelay;
int speakerMap;
int flags;
int volumeFallOffCurve;
int reverbFallOffCurve;
int volumeMinFallOffCurve;
int reverbMinFallOfCurve;
int limitCount;
int limitType;
int entityLimitCount;
int entityLimitType;
int randomizeType;
float cylInnerRadius;
float cylOuterRadius;
float cylOuterLevel;
};
struct snd_alias_list_t
{
const char *aliasName;
snd_alias_t *head;
int count;
};
Black Ops
struct SndRadverb
{
char name[0x20];
int nameHash;
float smoothing;
float earlyTime;
float lateTime;
float earlyGain;
float lateGain;
float returnGain;
float earlyLpf;
float lateLpf;
float inputLpf;
float dampLpf;
float wallReflect;
float dryGain;
float earlySize;
float lateSize;
float diffusion;
};
struct SndSnapshot
{
char name[0x20];
int nameHash;
char occlusion[0x20];
int occlusionHash;
int fadeIn;
int fadeOut;
int distance;
int fadeInCurve;
int fadeOutCurve;
float field_5C[64];
};
struct snd_alias_t
{
const char *aliasName;
int subtitle;
const char *secondaryAliasName;
const char *chainAliasName;
SoundFile *soundFile;
int flags;
int duck;
int contextType;
int contextValue;
short moveTime;
short startDelay;
short centerSend;
short reverbSend;
short volMin;
short volMax;
short teamVolMod;
short pitchMin;
short pitchMax;
short teamPitchMod;
short distMin;
short distMax;
short distReverbMax;
short envelopMin;
short envelopMax;
short envelopPercentage;
char minPriorityThreshold;
char maxPriorityThreshold;
char probability;
char occlusionLevel;
char occlusionWetDry;
char minPriority;
char maxPriority;
char pan;
char volumeFalloffCurve;
char reverbFalloffCurve;
char volumeMinFalloffCurve;
char reverbMinFalloffCurve;
char limitCount;
char entityLimitCount;
char snapshot;
};
struct SndBank
{
int name;
int aliasCount;
snd_alias_list_t *alias;
int *aliasIndex;
int unknown[2];
int numRadverbs;
SndRadverb *radverbs;
int numSnapshots;
SndSnapshot *snapshots;
};
Black Ops 2
struct SndStruct5 // 0x1C
{
const char *string1;
const char *string2;
int unknown1;
int count1;
char *unk1; // size = 0x14 * count1
int count2;
char *unk2; // count = count2
};
struct SndStruct4 // 0x922
{
const char *string1;
const char *string2;
char unknown[0x91A];
};
struct SndDuck // 0x4C
{
char name[0x20];
int nameHash;
float fadeIn;
float fadeOut;
float startDelay;
float distance;
float length;
int fadeInCurve;
int fadeOutCurve;
float *attenuation; // size = 0x80
float *lpf; // size = 0x80
int updateWhilePaused;
};
struct snd_alias_t
{
const char *aliasName;
int aliasNameHash;
const char *string2;
const char *string3;
int unknown1;
const char *string4;
int flags1;
int flags2;
int duck;
int contextType;
int contextValue;
int stopOnPlay;
int futzPatch;
short fluxTime;
short startDelay;
short reverbSend;
short centerSend;
short volMin;
short volMax;
short pitchMin;
short pitchMax;
short distMin;
short distMaxDry;
short distMaxWet;
short envelopMin;
short envelopMax;
short envelopPercent;
short fadeIn;
short fadeOut;
short dopplerScale;
char priorityThresholdMin;
char priorityThresholdMax;
char priority;
char occlusionLevel;
char priorityMin;
char priorityMax;
char pan;
char limitCount;
char entityLimitCount;
char snapshotGroup;
};
struct snd_alias_list_t // 0x14
{
const char *aliasName;
int aliasNameHash;
snd_alias_t *head; // count = count
int count;
char unknown2[4];
};
struct SndRadverb // 0x64
{
char name[0x20];
int nameHash;
float smoothing;
float earlyTime;
float lateTime;
float earlyGain
float lateGain;
float returnGain;
float earlyLpf;
float lateLpf;
float inputLpf;
float dampLpf;
float wallReflect;
float dryGain;
float earlySize;
float lateSize;
float diffusion;
float returnHighpass;
};
struct SndBank // 0x1294
{
const char *name;
int aliasCount;
snd_alias_list_t *alias;
int *aliasIndex;
int numRadverbs;
SndRadverb *radverbs;
int duckCount;
SndDuck *ducks;
SndStruct4 unk5; // 0x20
SndStruct4 unk6; // 0x942
SndStruct5 unk7; // 0x1264
int count4; // 0x1280
char *unk4; // size = 8 * count4
char unknown[0xC];
};