O'Reilly logo

Ionic Cookbook by Hoc Phan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Capturing video and allowing playback

It's possible to capture video using Ionic. There is a different plugin called Cordova Media Capture, which allows more flexible access to audio and video capability. ngCordova also ported this plugin to create the $cordovaCapture service (http://ngcordova.com/docs/plugins/capture/).

This is very convenient because you just need to call any of those three functions:

  • $cordovaCapture.captureAudio
  • $cordovaCapture.captureImage
  • $cordovaCapture.captureVideo

You could use this plugin for taking a photo as well, but it doesn't have a rich set of features like the Cordova Camera plugin does. The Media Capture plugin only provides access to the video camera to play back or update the resulting video file to a backend server. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required