mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Rename love.audio.getEffectsList and Source:getEffectsList to getActiveEffects. They now return an empty table instead of nil when there are no active effects, as well.
--HG-- branch : minor
This commit is contained in:
@@ -543,7 +543,7 @@ bool Audio::getEffect(const char *name, std::map<Effect::Parameter, float> ¶
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Audio::getEffectsList(std::vector<std::string> &list)
|
||||
bool Audio::getActiveEffects(std::vector<std::string> &list) const
|
||||
{
|
||||
if (effectmap.empty())
|
||||
return false;
|
||||
|
||||
@@ -118,7 +118,7 @@ public:
|
||||
bool setEffect(const char *name, std::map<Effect::Parameter, float> ¶ms);
|
||||
bool unsetEffect(const char *name);
|
||||
bool getEffect(const char *name, std::map<Effect::Parameter, float> ¶ms);
|
||||
bool getEffectsList(std::vector<std::string> &list);
|
||||
bool getActiveEffects(std::vector<std::string> &list) const;
|
||||
int getMaxSceneEffects() const;
|
||||
int getMaxSourceEffects() const;
|
||||
bool isEFXsupported() const;
|
||||
|
||||
@@ -1488,7 +1488,7 @@ bool Source::getEffect(const char *name, std::map<Filter::Parameter, float> &par
|
||||
return true;
|
||||
}
|
||||
|
||||
bool Source::getEffectsList(std::vector<std::string> &list)
|
||||
bool Source::getActiveEffects(std::vector<std::string> &list) const
|
||||
{
|
||||
if (effectmap.empty())
|
||||
return false;
|
||||
|
||||
@@ -152,7 +152,7 @@ public:
|
||||
virtual bool setEffect(const char *effect, const std::map<Filter::Parameter, float> ¶ms);
|
||||
virtual bool unsetEffect(const char *effect);
|
||||
virtual bool getEffect(const char *effect, std::map<Filter::Parameter, float> ¶ms);
|
||||
virtual bool getEffectsList(std::vector<std::string> &list);
|
||||
virtual bool getActiveEffects(std::vector<std::string> &list) const;
|
||||
|
||||
virtual int getFreeBufferCount() const;
|
||||
virtual bool queue(void *data, size_t length, int dataSampleRate, int dataBitDepth, int dataChannels);
|
||||
|
||||
Reference in New Issue
Block a user