W3C home > Mailing lists > Public > public-device-apis@w3.org > December 2009

RE: <input type=photo> etc as Capture API

From: Tran, Dzung D <dzung.d.tran@intel.com>
Date: Thu, 3 Dec 2009 10:59:17 -0800
To: Arve Bersvendsen <arveb@opera.com>, Ilkka Oksanen <Ilkka.Oksanen@nokia.com>
CC: "public-device-apis@w3.org" <public-device-apis@w3.org>
Message-ID: <753F67ADE6F5094C9F1DBA00D1BAA8D312C8AC6B14@orsmsx501.amr.corp.intel.com>
Yes, right.

However this does not work for the complex case such as: I want a camcorder device and control the recording such as record, stop, pause...etc.

Dzung Tran
Intel Corporation

-----Original Message-----
From: public-device-apis-request@w3.org [mailto:public-device-apis-request@w3.org] On Behalf Of Arve Bersvendsen
Sent: Thursday, December 03, 2009 04:30 AM
To: Ilkka Oksanen
Cc: public-device-apis@w3.org
Subject: Re: <input type=photo> etc as Capture API

On Thu, 03 Dec 2009 12:57:41 +0100, Ilkka Oksanen  
<Ilkka.Oksanen@nokia.com> wrote:

> navigator.device.captureImage(function(data) {
>    // send the image to server side script
>    }, 1);
>  How much more complex would equivalent <input> based solution be?

You're leaving out some details here, encapsulated by:

    // send the image to server side script

In your case you have to:

1. Extract the encapsulated data
2. Create an HTML form
3. Submit the data

(Steps two and three could be done using a hypothetical, not yet  
generally-implemented version of XHR)

In the <input>/web forms based case, you have to

1. Submit the form

Arve Bersvendsen

Opera Software ASA, http://www.opera.com/

Received on Thursday, 3 December 2009 18:59:53 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 14:53:41 UTC