Skip to content

nariakiiwatani/ofxWatchFile

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Attention

I prefer using ofxWatcher now because it's more flexible and straightforward.
Please check it out!


ofxWatchFile

auto reload any file when it is modified inspired by ofxAutoReloadedShader

usage

See example. Shortly, see below.

There are 2 ways to receive the result,

  • event listeners
ofxWatchFile file;
file.addListener(this, &MyClass::onFileChanged);
// MyClass::onFileChanged is called when the target file is changed
  • derived class
class MyClass : public ofxWatchFile {
	bool reload(ofFile &file) override;
};
// MyClass::reload is called when the target file is changed

License

MIT License.

About

automatically reload a file if it is modified

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published