Skip to content

Instantly share code, notes, and snippets.

@robotconscience
Created January 27, 2013 19:39
Show Gist options
  • Save robotconscience/4650006 to your computer and use it in GitHub Desktop.
Save robotconscience/4650006 to your computer and use it in GitHub Desktop.
Openframeworks version of Processing's loadStrings
static vector<string> loadStrings( string file ){
static vector<string> ret;
ret.clear();
ofBuffer temp = ofFile( file ).readToBuffer();
while ( !temp.isLastLine() ){
ret.push_back( temp.getNextLine() );
cout<<ret.back()<<endl;
}
return ret;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment