mirror of
https://github.com/GTAmodding/re3.git
synced 2025-10-09 23:40:34 +00:00
oal upd
This commit is contained in:
parent
1180cc2947
commit
8aac6060d3
22 changed files with 2850 additions and 2125 deletions
51
src/audio/oal/channel.h
Normal file
51
src/audio/oal/channel.h
Normal file
|
@ -0,0 +1,51 @@
|
|||
#pragma once
|
||||
#include "common.h"
|
||||
|
||||
#ifdef AUDIO_OAL
|
||||
#include "oal/oal_utils.h"
|
||||
#include <AL/al.h>
|
||||
#include <AL/alext.h>
|
||||
#include <AL/efx.h>
|
||||
|
||||
|
||||
class CChannel
|
||||
{
|
||||
ALuint alChannel;
|
||||
ALuint alFilter;
|
||||
ALuint Buffer;
|
||||
float Pitch, Gain;
|
||||
float Mix;
|
||||
int32 Frequency;
|
||||
float Position[3];
|
||||
float Distances[2];
|
||||
int32 LoopCount;
|
||||
ALint LoopPoints[2];
|
||||
uint32 Sample;
|
||||
public:
|
||||
CChannel();
|
||||
void SetDefault();
|
||||
void Reset();
|
||||
void Init(bool Is2D = false);
|
||||
void Term();
|
||||
void Start();
|
||||
void Stop();
|
||||
bool HasSource();
|
||||
bool IsUsed();
|
||||
void SetPitch(float pitch);
|
||||
void SetGain(float gain);
|
||||
void SetVolume(int32 vol);
|
||||
void SetSampleID(uint32 nSfx);
|
||||
void SetFreq(int32 freq);
|
||||
void SetCurrentFreq(uint32 freq);
|
||||
void SetLoopCount(int32 loopCount); // fake
|
||||
void SetLoopPoints(ALint start, ALint end);
|
||||
void SetPosition(float x, float y, float z);
|
||||
void SetDistances(float max, float min);
|
||||
void SetPan(uint32 pan);
|
||||
void SetBuffer(ALuint buffer);
|
||||
void ClearBuffer();
|
||||
void SetReverbMix(ALuint slot, float mix);
|
||||
void UpdateReverb(ALuint slot);
|
||||
};
|
||||
|
||||
#endif
|
Loading…
Add table
Add a link
Reference in a new issue