• Skip to main content
  • Select language
  • Skip to search
MDN Web Docs
  • Technologies
    • HTML
    • CSS
    • JavaScript
    • Graphics
    • HTTP
    • APIs / DOM
    • WebExtensions
    • MathML
  • References & Guides
    • Learn web development
    • Tutorials
    • References
    • Developer Guides
    • Accessibility
    • Game development
    • ...more docs
B2G OS
  1. MDN
  2. Archive of obsolete content
  3. B2G OS
  4. B2G OS APIs
  5. Navigator (Firefox OS extensions)
  6. Navigator.mozCameras

Navigator.mozCameras

In This Article
  1. Summary
  2. Syntax
  3. Value
  4. Specification
  5. Permissions
  6. See also

Non-standard
This feature is not on a current W3C standards track, but it is supported on the Firefox OS platform. Although implementations may change in the future and it is not supported widely across browsers, it is suitable for use in code dedicated to Firefox OS apps.

This API is available on Firefox OS for privileged or certified applications only.

Summary

Returns a CameraManager object you can use to access the cameras available on the user's device.

Syntax

var cameraManager = window.navigator.mozCameras;

Value

navigator.mozCameras is a CameraManager object you can use to access the cameras available on the device.

Specification

Not part of any specification as yet; this will probably be replaced by WebRTC when it gains more widespread support on mobile devices.

Permissions

Up until Firefox OS 1.4, The Camera API was a certified API, so not accessible to third party apps. From Firefox OS 2.0 onwards, the permission level has been downgraded to privileged, so it is now available for developers to use in their apps.

"permissions": {
  "camera": {
    "description": "Required for accessing cameras on the device."
  }
}

See also

  • WebRTC API

Document Tags and Contributors

Tags: 
  • API
  • DOM
  • Firefox OS
  • Gecko DOM Reference
  • Graphics
  • Non Standard
  • Property
  • WebAPI
 Contributors to this page: chrisdavidmills, teoli, Cfinke, SunboX, MHasan, kscarfone, iamanupmenon, Sheppy, Jeremie
 Last updated by: chrisdavidmills, Feb 27, 2017, 2:09:18 AM
See also
  1. Archive
  2. Related pages for Firefox OS
    1. MozAlarmsManager
    2. MozMobileNetworkInfo
    3. MozWifiP2pGroupOwner