You would need to implement a Mendix widget that uses a different Cordova camera plugin. Here's a plugin that looks promising:
https://www.npmjs.com/package/cordova-plugin-camera-preview
If you use that plugin, it looks like you can activate the camera and show it directly on/behind your HTML, and then render buttons to take pictures and switch cameras (front and back). I even see a function in there to enable and disable flash.
Warning: this is a significant undertaking. Probably a week or more from an experienced widget developer.