问题
i want to open camara in div on template, where app not go to background and camara open and after capture, camara app go to background and cordova app will go to foreground... instead of that the camara is open in div which is placed on html template..
Thank you..
回答1:
Yes, through this Plugin for iOS and Android it is possible to show a camera view in a div container or everywhere else in your body.
Cordova Camera Preview
Features:
- Start a camera preview from HTML code.
- Drag the preview box.
- Set camera color effect (Android and iOS).
- Send the preview box to back of the HTML content.
- Set a custom position for the camera preview box.
- Set a custom size for the preview box.
- Maintain HTML interactivity.
Installation:
cordova plugin add https://github.com/mbppower/CordovaCameraPreview.git
And the rest (methods) etc. can be found in the documentation on GitHub.
来源:https://stackoverflow.com/questions/31315320/can-cordova-camera-open-in-side-cordova-application