mirror of
https://github.com/love2d/love.git
synced 2026-08-16 08:11:02 +02:00
Implement audio filters
Use Source:setFilter(type, params...) to set a filter. Use Source:setFilter() to detach the current filter. Use Source:getFilter() to get the currently set filter (or nil). Squashed from pull request 27, and the clean-pr27 branch in love-experiments. --HG-- branch : minor
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
// LOVE
|
||||
#include "common/Object.h"
|
||||
#include "audio/Source.h"
|
||||
#include "audio/Filter.h"
|
||||
|
||||
namespace love
|
||||
{
|
||||
@@ -79,6 +80,10 @@ public:
|
||||
virtual int getFreeBufferCount() const;
|
||||
virtual bool queue(void *data, size_t length, int dataSampleRate, int dataBitDepth, int dataChannels);
|
||||
|
||||
virtual bool setFilter(love::audio::Filter::Type type, std::vector<float> ¶ms);
|
||||
virtual bool setFilter();
|
||||
virtual bool getFilter(love::audio::Filter::Type &type, std::vector<float> ¶ms);
|
||||
|
||||
private:
|
||||
|
||||
float pitch;
|
||||
|
||||
Reference in New Issue
Block a user