void uninit()
Releases the miniaudio sound resource.
kAudio()
Constructs an empty audio clip; call initFromFile() (via kAudioManager) before use.
void setVolume(float volume)
Sets the playback volume.
void setPosition(const kVec3 &position)
Positions the sound in 3D world space for spatialized audio.
bool isLooping() const
Returns true if the looping flag is set.
void setSpatialization(bool enable)
Enables or disables 3D spatialization for this sound.
void pause()
Pauses playback without resetting the cursor.
bool initFromFile(void *maEngine, const kString &filePath)
Initialises the sound from a file using an existing miniaudio engine.
void play()
Starts or resumes playback from the current position.
bool isPlaying() const
Returns true if the sound is currently playing.
void stop()
Stops playback and resets the cursor to the beginning.
void resume()
Resumes a paused sound. Equivalent to play() if already stopped.
~kAudio()
Destructor; releases the underlying miniaudio sound resource.
void setLooping(bool loop)
Sets the looping flag.
bool isPaused() const
Returns true if the sound is paused.
void setPitch(float pitch)
Sets the playback pitch / speed multiplier.
void setVelocity(const kVec3 &velocity)
Sets the velocity of the audio emitter (used for Doppler shift).
Core type aliases, enumerations, structs, and utility functions used throughout the engine.
Symbol visibility / linkage macro for the Kemena3D library.
#define KEMENA3D_API
Definition kexport.h:35
Top-level Kemena3D engine namespace.
Definition kanimation.h:23
std::string kString
Standard string alias.
Definition kdatatype.h:42
glm::vec3 kVec3
3-component float vector.
Definition kdatatype.h:33