javascript programming webdev android

I fired up the newly released Android 3.0 SDK to run some tests and found they’ve implemented part of the long-awaited Device API (aka the Media Capture API). From your browser you can now upload pictures and videos from the camera as well as sounds from the microphone. The returned data should be available to manipulate via the File API (although I haven’t yet tested this).


I made a short video demo with some explanation:


Here’s the code so you can play around with it for yourself!

<form enctype="multipart/form-data" method="post">
  <h2>Regular file upload</h2>
  <input type="file"></input>
  <input type="file" accept="image/*;capture=camera"></input>
  <input type="file" accept="video/*;capture=camcorder"></input>
  <input type="file" accept="audio/*;capture=microphone"></input>
comments powered by Disqus