载入中...
搜索中...
未找到
eve::sound::Sound类 参考

Sound module: decodes compressed audio and produces SoundData buffers. Script: sound <- eve.Sound(); 更多...

#include <Sound.h>

类 eve::sound::Sound 继承关系图:
eve::Module

Public 成员函数

 Module_REG (Sound)
 
 Sound ()
 
 ~Sound () override
 
DecodernewDecoder (Data *data, int bufferSize=16384)
 Creates a streaming decoder over raw encoded data.
 
SoundDatanewSoundData (Data *data)
 Fully decodes data into a SoundData buffer.
 
SoundDatanewSoundDataFromDecoder (Decoder *decoder)
 Fully decodes a Decoder into a SoundData buffer.
 
SoundDatanewSoundDataFromFile (std::string path)
 Decodes a sound file from a VFS path through the unified resource cache. Repeated loads of one path share a single decoded buffer; a file change refreshes it in place (see ResourceManager).
 
SoundDatanewSoundDataEmpty (int samples, int rate, int bitDepth, int channels)
 Creates an empty PCM buffer (e.g. for synthesis).
 
- Public 成员函数 继承自 eve::Module
virtual ~Module ()
 
virtual std::string getName () const =0
 

详细描述

Sound module: decodes compressed audio and produces SoundData buffers. Script: sound <- eve.Sound();

在文件 Sound.h16 行定义.

构造及析构函数说明

◆ Sound()

eve::sound::Sound::Sound ( )

在文件 Sound.cpp107 行定义.

◆ ~Sound()

eve::sound::Sound::~Sound ( )
overridedefault

成员函数说明

◆ Module_REG()

eve::sound::Sound::Module_REG ( Sound  )

◆ newDecoder()

Decoder * eve::sound::Sound::newDecoder ( Data data,
int  bufferSize = 16384 
)

Creates a streaming decoder over raw encoded data.

在文件 Sound.cpp136 行定义.

引用了 data, impl , 以及 ptr.

被这些函数引用 newSoundData().

◆ newSoundData()

SoundData * eve::sound::Sound::newSoundData ( Data data)

Fully decodes data into a SoundData buffer.

在文件 Sound.cpp198 行定义.

引用了 data, newDecoder() , 以及 newSoundDataFromDecoder().

◆ newSoundDataEmpty()

SoundData * eve::sound::Sound::newSoundDataEmpty ( int  samples,
int  rate,
int  bitDepth,
int  channels 
)

Creates an empty PCM buffer (e.g. for synthesis).

在文件 Sound.cpp220 行定义.

◆ newSoundDataFromDecoder()

SoundData * eve::sound::Sound::newSoundDataFromDecoder ( Decoder decoder)

◆ newSoundDataFromFile()

SoundData * eve::sound::Sound::newSoundDataFromFile ( std::string  path)

Decodes a sound file from a VFS path through the unified resource cache. Repeated loads of one path share a single decoded buffer; a file change refreshes it in place (see ResourceManager).

参数
pathThe VFS path of the audio file.
返回
The cached SoundData.
异常
eve::Exceptionwhen the file cannot be read or decoded.

在文件 Sound.cpp210 行定义.

引用了 eve::ResourceManager::get() , 以及 eve::ResourceManager::getInstance().


该类的文档由以下文件生成: