mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Renamed ParticleSystem:count, Channel:count, and all getNum* functions to get*Count (issue #602)
This commit is contained in:
@@ -76,7 +76,7 @@ public:
|
||||
* Gets the current number of simultaneous playing sources.
|
||||
* @return The current number of simultaneous playing sources.
|
||||
**/
|
||||
virtual int getNumSources() const = 0;
|
||||
virtual int getSourceCount() const = 0;
|
||||
|
||||
/**
|
||||
* Gets the maximum supported number of simultaneous playing sources.
|
||||
|
||||
@@ -50,7 +50,7 @@ love::audio::Source *Audio::newSource(love::sound::SoundData *)
|
||||
return new Source();
|
||||
}
|
||||
|
||||
int Audio::getNumSources() const
|
||||
int Audio::getSourceCount() const
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -46,7 +46,7 @@ public:
|
||||
// Implements Audio.
|
||||
love::audio::Source *newSource(love::sound::Decoder *decoder);
|
||||
love::audio::Source *newSource(love::sound::SoundData *soundData);
|
||||
int getNumSources() const;
|
||||
int getSourceCount() const;
|
||||
int getMaxSources() const;
|
||||
void play(love::audio::Source *source);
|
||||
void play();
|
||||
|
||||
@@ -143,9 +143,9 @@ love::audio::Source *Audio::newSource(love::sound::SoundData *soundData)
|
||||
return new Source(pool, soundData);
|
||||
}
|
||||
|
||||
int Audio::getNumSources() const
|
||||
int Audio::getSourceCount() const
|
||||
{
|
||||
return pool->getNumSources();
|
||||
return pool->getSourceCount();
|
||||
}
|
||||
|
||||
int Audio::getMaxSources() const
|
||||
|
||||
@@ -65,7 +65,7 @@ public:
|
||||
// Implements Audio.
|
||||
love::audio::Source *newSource(love::sound::Decoder *decoder);
|
||||
love::audio::Source *newSource(love::sound::SoundData *soundData);
|
||||
int getNumSources() const;
|
||||
int getSourceCount() const;
|
||||
int getMaxSources() const;
|
||||
void play(love::audio::Source *source);
|
||||
void play();
|
||||
|
||||
@@ -106,7 +106,7 @@ void Pool::update()
|
||||
}
|
||||
}
|
||||
|
||||
int Pool::getNumSources() const
|
||||
int Pool::getSourceCount() const
|
||||
{
|
||||
return playing.size();
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ public:
|
||||
|
||||
void update();
|
||||
|
||||
int getNumSources() const;
|
||||
int getSourceCount() const;
|
||||
int getMaxSources() const;
|
||||
|
||||
bool play(Source *source, ALuint &out);
|
||||
|
||||
@@ -35,9 +35,9 @@ namespace audio
|
||||
|
||||
static Audio *instance = 0;
|
||||
|
||||
int w_getNumSources(lua_State *L)
|
||||
int w_getSourceCount(lua_State *L)
|
||||
{
|
||||
lua_pushinteger(L, instance->getNumSources());
|
||||
lua_pushinteger(L, instance->getSourceCount());
|
||||
return 1;
|
||||
}
|
||||
|
||||
@@ -262,7 +262,7 @@ int w_getDistanceModel(lua_State *L)
|
||||
// List of functions to wrap.
|
||||
static const luaL_Reg functions[] =
|
||||
{
|
||||
{ "getNumSources", w_getNumSources },
|
||||
{ "getSourceCount", w_getSourceCount },
|
||||
{ "newSource1", w_newSource1 },
|
||||
{ "play", w_play },
|
||||
{ "stop", w_stop },
|
||||
|
||||
@@ -32,7 +32,7 @@ namespace love
|
||||
namespace audio
|
||||
{
|
||||
|
||||
int w_getNumSources(lua_State *L);
|
||||
int w_getSourceCount(lua_State *L);
|
||||
int w_newSource1(lua_State *L);
|
||||
int w_play(lua_State *L);
|
||||
int w_stop(lua_State *L);
|
||||
|
||||
Reference in New Issue
Block a user