# Namespace hcap.camera

hcap.camera

- Defined in: hcap-1.24.6.5901.js

Namespace Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| hcap.camera

## Method Summary

## Namespace Detail

hcap.camera

## Method Detail

- <static> hcap.camera.getCameraControl(param)
  Gets the current value of the camera control type. Only supported for Logitech BCC950 model.

      hcap.camera.getCameraControl({
           "id" : "video0",
           "control_type" : "Brightness",
           "onSuccess" : function(s) {
               console.log("onSuccess : value = " + s.value);
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {String} param.id [Required] - camera id
    - {String} param.control_type [Required] - control type of the camera ("Pan (relative)"/"Tilt (relative)"/"Zoom"/"Absolute"/"Brightness"/"Contrast"/"Sharpness")
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function (param) {
                // {Number} param.value - the current value of the control_type parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.24.4
  See:
    hcap.camera.getCameraInformation()
    hcap.camera.setCameraControl()
- <static> hcap.camera.getCameraInformation(param)
  Get information about currently available camera devices. Only supported for Logitech BCC950 model.

      hcap.camera.getCameraInformation({
           "onSuccess" : function() {
               console.log("onSuccess : list length = " + s.list.length);
               for (var i = 0; i < s.list.length; i++) {
                   console.log(
                   "[" + i + "].id = " + s.list[i].id +
                   ", [" + i + "].name = " + s.list[i].name +
                   ", [" + i + "].controls = " + s.list[i].controls
                   );
               }
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function() {
                // {Array} param.list - camera information list supported by TV
                //         {String} param.list[].id - camera id currently available
                //         {String} param.list[].name - camera name currently available
                //         {String} param.list[].controls - control types currently available
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.24.4
  See:
    hcap.camera.getCameraControl()
    hcap.camera.setCameraControl()
- <static> hcap.camera.setCameraControl(param)
  Sets the value of the camera control type. Only supported for Logitech BCC950 model.

      hcap.camera.setCameraControl({
           "id" : "video0",
           "control_type" : "Pan (Relative)",
           "value" : -500,
           "onSuccess" : function(s) {
               console.log("onSuccess : value = " + s.value);
           },
           "onFailure" : function(f) {
               console.log("onFailure : errorMessage = " + f.errorMessage);
           }
      });

  Parameters:
  {Object} param
    - {String} param.id [Required] - camera id
    - {String} param.control_type [Required] - control type of the camera ("Pan (relative)"/"Tilt (relative)"/"Zoom"/"Absolute"/"Brightness"/"Contrast"/"Sharpness"/"Pan Reset"/"Tilt Reset")
    - {Number} param.value [Required] - value to set
    - {Function} param.onSuccess [Optional] - success callback function.

            param.onSuccess = function (param) {
                // No Parameter.
            }

    - {Function} param.onFailure [Optional] - failure callback function.

            param.onFailure = function (param) {
                // {String} param.errorMessage - in case of failure, this message provides the details.
            }

  Since:
    1.24.4
  See:
    hcap.camera.getCameraInformation()
    hcap.camera.getCameraControl()