I’ve updated my copy of ofVideoGrabber to include a function called “getDeviceCount()” which, as the name suggests, returns the number of available input devices. This is very handy for switching cameras easily when in “config” mode for camera apps.
It’s a very simple addition that doesn’t really affect the class too much. How could I contribute this for future release?
This sounds great – I needed exactly the same thing the other day. (It would also be nice to have a way to get an array of strings with the device names… I implemented a workaround to get this but it’s pretty ugly.)
Presumably you could fork the openFrameworks project on GitHub (http://github.com/openframeworks/openFrameworks), apply your change, and then send a pull request to get your addition merged with the master repo.