← Back

ofxRingBufferTexture

github.com/paulreimer/ofxRingBufferTexture · @paulreimer
OF 0.7 Video/Camera

openFrameworks addon to render vector<float> data by uploading frames to FBO textures.

2 1 Last commit 13y ago Created 13y ago

Forks

Forks pushed to more recently than paulreimer/ofxRingBufferTexture itself, plus any admin-confirmed fork with commits of its own — worth checking if you're hitting issues with the original.

GNV30/ofxRingBufferTexture by @GNV30 · ★ 0 · pushed 3y ago

README

How to use in an openFrameworks app

testApp.h

``c++

include "ofxRingBufferTexture.h"



class testApp : public ofBaseApp { public:

void setup(); void draw(); void audioIn(float input, int bufferSize, int nChannels);

ofxRingBufferTexture spectrogram; };
`

testApp.cpp

`c++ //-------------------------------------------------------------- void testApp::audioIn(float
input, int bufferSize, int nChannels) { for (size_t i=0; i<bufferSize; ++i) audioChannel.inputBuffer[i] = input[i];

audioChannel.process(); spectrogram.addFrame(audioChannel.spectrum); }

//-------------------------------------------------------------- void testApp::draw() { spectrogram.uploadToTexture(); spectrogram.getTextureReference().draw(windowRect); }
``

Get this addon

HTTPS
SSH