Skip to content

Project Structure and Code Abstraction

Christopher Baker edited this page May 15, 2014 · 2 revisions

Like Processing, projects created with ofSketch will each live in their own Projects folder. ofSketch will create custom helloworld.sketch files that it uses in the editor. Those *.sketch files are combined and compiled behind the scenes to dynamically create C++ src files traditionally located in src/.

Sketches will be written in header-style C++ right in the editor without the user realizing it:

void setup(){
	
}

void draw(){
}

// ...

vs ofApp.h

class ofApp: ofBaseApp{
    void setup(){}
    void draw(){}
// ...

ofApp.cpp

void ofApp::setup(){
// ...
}

void ofApp::draw(){
}

// ...
Clone this wiki locally