← Back

ofxAdjustH

github.com/ffunatsu/ofxAdjustH · @ffunatsu
OF 0.12 Utilities GUI

adjust.h for openFrameworks

3 0 Last commit 10mo ago Created 11mo ago

README

ofxAdjustH



adjust.h for openFrameworks (tested on oF 0.12.0)

You can interactively change values (hot reload) without recompiling files on realtime.

Please see https://www.youtube.com/watch?v=9eIXOygjPvw about adjust.h (introduction movie by colan biemer)

Features



Example



see example/src/ofApp.cpp for detail.

#include "ofxAdjustH.h"

float x, y, w, h;

//--------------------------------------------------------------
void ofApp::setup(){
    ofxAdjustH::setup();

    ADJUST_SET_FLOAT(x, 100); // modify this line, save file and press R on your running app!
	ADJUST_SET_FLOAT(y, 100); // modify this line, save file and press R on your running app!
    ADJUST_SET_FLOAT(w, 200); // modify this line, save file and press R on your running app!
	ADJUST_SET_FLOAT(h, 200); // modify this line, save file and press R on your running app!
}

//--------------------------------------------------------------
void ofApp::draw(){
    ofSetColor(255, 0, 0);
    ofDrawEllipse(x, y, w, h);
}

//--------------------------------------------------------------
void ofApp::keyPressed(int key){
    if(key == 'r'){
        ofxAdjustH::refresh();
        ofLog() << "refreshed";
    }
}


Notes



License





Get this addon

HTTPS
SSH