← Back

ofxShadow

github.com/sketchbooks99/ofxShadow · @sketchbooks99
OF 0.11 Graphics Shaders

Casts hard and soft shadows onto scene geometry, requiring an OpenGL 3.2 context with begin and end depth passes.

1 0 Last commit 5y ago Created 6y ago

README

ofxShadow



This addon is easily to cast shadow on scene geometries. Implementation is mainly based on the following site. https://github.com/yasuhirohoshino/oF-ShadowExamples

Version

int main() {
    ofGLWindowSettings settings;
    settings.setGLVersion(3,2);
    settings.setSize(1024, 768);

    ofCreateWindow(settings);
    ofRunApp(new ofApp());
}


Features

Usage

ofxShadow shadow;
ofEasyCam cam;


void setup() {
    shadow.setup();
}

void draw() {
    shadow.beginDepth();
    <-- RENDER SCENE -->
    shadow.endDepth();

    shadow.begin(cam);
    <-- RENDER SCENE -->
    shadow.end(cam);
}


TODO:

Get this addon

HTTPS
SSH