Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

Lamp::SoundList Class Reference

サウンドリスト More...

#include <SoundList.h>

List of all members.

Static Public Member Functions

bool load (SoundCache *soundCache, const String &filePath)
 ロード

bool load (SoundCache *soundCache, TextReader *textReader)
 ロード

bool loadSound (SoundCache *soundCache, const String &line)
 サウンドのロード


Detailed Description

サウンドリスト

テキストファイルからサウンドリストをサウンドキャッシュに読み込む。 具体的にはサウンドファイルが置いてあるディレクトリに以下に示すフォーマットの テキストファイルを配置する。その後、サウンドキャッシュのloadSoundList() を使用してサウンドリストをロードします。 このファイルはエクセル等のツールで編集すると楽でしょう。


// 行頭の「//」コメントに対応している。 各要素はタブで区切る。
//ファイル名 Stereo,3D Once,Loop Priority MaxMixingCount Min3DDistance Max3DDistance
muda Stereo Once -1 0
mudamuda 3D Loop 100 16 5.73 76.5

ファイル名
 相対ファイル名を指定します。拡張子はサウンドキャッシュで指定すると いいでしょう。

Stereo,3D
 ステレオサウンドか3Dサウンドかを指定します。3Dサウンドはモノラルである必要が あります。

Once,Loop
 一回の再生かループ再生かを指定します。

Priority
 優先度を32767〜-32768の範囲で指定します。どうしても鳴ってほしい音の優先度を 上げましょう。

MaxMixingCount
 最大同音同時発音数を指定します。0を指定するとサウンドキャッシュのデフォルト値を 使用します

Min3DDistance
3Dサウンドの最小距離を指定します。

Max3DDistance
3Dサウンドの最大距離を指定します。

Definition at line 75 of file SoundList.h.


Member Function Documentation

bool Lamp::SoundList::load SoundCache soundCache,
TextReader textReader
[static]
 

ロード

Parameters:
soundCache サウンドキャッシュ
textReader テキストリーダ
Returns:
成功すればtrue

Definition at line 46 of file SoundList.cpp.

References Lamp::Reader::isEnd(), loadSound(), and Lamp::TextReader::readLine().

bool Lamp::SoundList::load SoundCache soundCache,
const String filePath
[static]
 

ロード

Parameters:
soundCache サウンドキャッシュ
filePath ファイルパス
Returns:
成功すればtrue

Definition at line 36 of file SoundList.cpp.

References Lamp::FilePath::existFile().

bool Lamp::SoundList::loadSound SoundCache soundCache,
const String line
[static]
 

サウンドのロード

Parameters:
soundCache サウンドキャッシュ
line ロード文字列
Returns:
成功すればtrue

Definition at line 56 of file SoundList.cpp.

References ErrorOut, Lamp::StringTokenizer::getNextToken(), Lamp::StringTokenizer::hasMoreTokens(), Lamp::SoundCache::loadStaticSound(), Lamp::SoundCache::loadStaticSound3D(), and Lamp::String::startsWith().

Referenced by load().


The documentation for this class was generated from the following files:
Generated on Wed Mar 16 10:29:51 2005 for Lamp by doxygen 1.3.2