Meteor2D  dev internal
Meteor is a lightweight 2D game engine.
Loading...
Searching...
No Matches
meteor::MAudioClip Class Reference

AudioClip is the instance of a audio clip file, this class holds. This class holds basic information of the clip, and has methods to create playable instances. More...

#include <audioclip.h>

Inheritance diagram for meteor::MAudioClip:

Public Member Functions

 MAudioClip (irrklang::ISoundEngine *engine, std::string clipPath)
 Constructor.
 
MAudioPlayablecreatePlayableInstance ()
 Creates a playable instance of this clip, which can be used to play audio.
 
std::string toString () override
 Get this object as a string.
 

Detailed Description

AudioClip is the instance of a audio clip file, this class holds. This class holds basic information of the clip, and has methods to create playable instances.

Constructor & Destructor Documentation

◆ MAudioClip()

meteor::MAudioClip::MAudioClip ( irrklang::ISoundEngine * engine,
std::string clipPath )

Constructor.

Parameters
enginecore audio engine instance.
clipPathpath to the clip in disk.

Member Function Documentation

◆ createPlayableInstance()

MAudioPlayable * meteor::MAudioClip::createPlayableInstance ( )

Creates a playable instance of this clip, which can be used to play audio.

Returns
AudioPlayable instance.

◆ toString()

std::string meteor::MAudioClip::toString ( )
overridevirtual

Get this object as a string.

Returns
A string representing this object

Reimplemented from meteor::MEntity.