Now that we have camera.js, audio.js, and screen_capture_device.js it would be smart to genericize the code and logic they all share and move it to a single extendable class object. This would cut down on complexity, improve readability, and streamline bugfixes and future enhancement.
Behavior like constraint handling, recorder calls, and creating some common UI elements can likely be shared.
Each class can then implement custom behavior (audio.js recording to .wav file, camera.js and screen_capture_device rendering to canvas, etc)
Now that we have camera.js, audio.js, and screen_capture_device.js it would be smart to genericize the code and logic they all share and move it to a single extendable class object. This would cut down on complexity, improve readability, and streamline bugfixes and future enhancement.
Behavior like constraint handling, recorder calls, and creating some common UI elements can likely be shared.
Each class can then implement custom behavior (audio.js recording to .wav file, camera.js and screen_capture_device rendering to canvas, etc)