#include "ofApp.h" #include "glew.h" /* what do we want to store/control per letter? */ //-------------------------------------------------------------- void ofApp::setup(){ fonts.open("fonts/"); fonts.allowExt("svg"); fonts.listDir(); ofLogNotice()<<"found "< shapes = banner.getOutlines(0.08f*text_scale); //+(0.02f*sin(ofGetElapsedTimef()*.1f))); int num = 0; if (laser_power) num=laser.draw(shapes); //banner.draw(); ofPushMatrix(); ofTranslate(ofGetWidth()/2,ofGetHeight()/2); //ofScale(0.05,-0.05,0.05); for (auto& s: shapes) s.draw(); ofPopMatrix(); if (num>0){ ofSetWindowTitle(ofToString(ofGetFrameRate(), 2)+" fps laser points: "+ofToString(num)); } else { ofSetWindowTitle(ofToString(ofGetFrameRate(), 2)+" fps laser power off "); } } //-------------------------------------------------------------- void ofApp::exit() { } //-------------------------------------------------------------- void ofApp::keyPressed(ofKeyEventArgs &args){ } //-------------------------------------------------------------- void ofApp::keyReleased(int key){ if (key>=' '&&key<='~'){ banner.addGlyph(key); } else if (key==OF_KEY_BACKSPACE||key==OF_KEY_DEL) { //DEL banner.removeGlyph(); } ofLog()<