webOS Nation Forums >  webOS apps and software >  webOS development > How is the hardware exposed to the UI?
How is the hardware exposed to the UI?

  Reply
 
LinkBack Thread Tools Display Modes
Old 06/19/2009, 02:49 PM   #1 (permalink)
Member
 
Join Date: Dec 2007
Posts: 40
Likes Received: 0
Thanks: 3
Thanked 0 Times in 0 Posts
Default How is the hardware exposed to the UI?

Looking through the code for the camera app, I noticed this:

/user/palm/frameworks/media/palmInitMedia.js
Quote:
var captureUri = "capture://audio_video?VideoWidth="
+ "480" //width -- HARD ******* CODED IN THE DRIVER
+ "&VideoHeight="
+ "320" //height -- HARD ******* CODED IN THE DRIVER
+ "&VideoFPS=30";
this._adaptor.obj.cmdOpenRecorder(captureUri, 201/*cntxt*/);
Aside from the colorful comments, what I find interesting is that it appears they are referencing the camera hardware with a URI.

Can anyone with the pre-release copy of the SDK comment on this? Is all of the hardware addressable through URI calls similar to this?

Thanks!
whatsit2002 is offline   Reply With Quote
Old 06/19/2009, 03:04 PM   #2 (permalink)
Member
 
Join Date: Jun 2009
Location: Brooklyn, NY
Posts: 66
Likes Received: 0
Thanks: 12
Thanked 9 Times in 5 Posts
Default

I don't have the SDk but from what I've been seeing I think there will be APIs specifically for hardware access. Correct me if I'm wrong.

http://www.weboshelp.net/getting-sta...-mojo-services
OneSix is offline   Reply With Quote
Reply

 

Tags
address, camera, hardware, uri

Thread Tools
Display Modes



 


Content Relevant URLs by vBSEO 3.6.0