显示在HTML中的Andr​​oid摄像头视图,然后拍摄照片 [英] Showing camera view inside html in android and then snap a picture

查看:155
本文介绍了显示在HTML中的Andr​​oid摄像头视图,然后拍摄照片的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有显示出里面的html直播相机视图(如嵌入在一个div),我们捕捉使用JavaScript照片前的看法?我曾尝试PhoneGap的,但它完全启动一个新的相机应用程序,并完全远离我的html的web应用程序返回到它之前。我需要的东西嵌在我的应用程序

Is there a view of showing the live camera view inside html ( e.g. embedded in a div ) before we snap a picture using JavaScript? I have tried PhoneGap but it totally starts a new camera app and totally moves away from my html web app before returning to it. I need something embedded in my app

感谢

推荐答案

您可以安装 mbppower / CordovaCamera preVIEW 插件(针对Android,IOS)在科尔多瓦/ PhoneGap的应用程序,允许从HTML code相机的互动。一个非常惊人的插件,这是... 您可以访问功能,例如:

You can install mbppower/CordovaCameraPreview plugin (for android,ios) in your Cordova/phonegap application that allows camera interaction from HTML code. A really amazing plugin it is.. You can access Features such as:

开始从HTML code相机preVIEW。 拖动preVIEW框。 设置相机的色彩效果(Android和iOS),发送preVIEW盒背的HTML内容,设定摄像机preVIEW框自定义位置,设置自定义尺寸为preVIEW盒和维护HTML的互动性。

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 and Maintain HTML interactivity.

或者你也可以使用 donaldp24 / CanvasCamera 插件作为您的应用程序,如果它适合在Android和iOS的平台支持您requirements.Its。我观察到,为iOS其工作正常,但在Android中它不能正常工作。

Or you can also use donaldp24/CanvasCamera Plugin for your application if it fits to your requirements.Its supported in both android and iOS platforms. I have observed, for iOS its working fine but in android it isn't working.

现在您可以通过网上的PhoneGap安装CordovaCamera preVIEW插件了。因此,没有使用CLI可以直接通过这个加用它

Now you can install CordovaCameraPreview plugin through Online PhoneGap too. So without using CLI you can directly use it through this by adding

<差距:插件名称=com.mbppower.camera preVIEW版本=0.0.8来源=plugins.cordova.io/>

在config.xml文件,并创建ApplicationTemplate.apk /的.ipa。有关它的更多信息,你可以问我。很高兴能帮助你。

in your config.xml file and create ApplicationTemplate.apk/.ipa. For more information regarding this you can ask me. Happy to help.

这篇关于显示在HTML中的Andr​​oid摄像头视图,然后拍摄照片的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆