[Release version 0.10.43] Add New attributes for Pan, Tilt, Display ROI Area 33/66333/9 accepted/tizen/common/20160505.140919 accepted/tizen/ivi/20160506.035831 accepted/tizen/mobile/20160506.035310 accepted/tizen/tv/20160506.035609 accepted/tizen/wearable/20160506.035718 submit/tizen/20160504.093918
authorHaesu Gwon <haesu.gwon@samsung.com>
Mon, 18 Apr 2016 11:00:39 +0000 (20:00 +0900)
committerHaesu Gwon <haesu.gwon@samsung.com>
Tue, 3 May 2016 03:04:19 +0000 (12:04 +0900)
Change-Id: I3cbbbb6b185addd0126487c1d666a7daeece1f0c
Signed-off-by: Haesu Gwon <haesu.gwon@samsung.com>
packaging/libmm-camcorder.spec
src/include/mm_camcorder.h
src/include/mm_camcorder_attribute.h
src/include/mm_camcorder_platform.h
src/mm_camcorder_attribute.c
src/mm_camcorder_configure.c
src/mm_camcorder_platform.c

index bbba8bc..8c19bc4 100644 (file)
@@ -2,7 +2,7 @@
 
 Name:       libmm-camcorder
 Summary:    Camera and recorder library
-Version:    0.10.42
+Version:    0.10.43
 Release:    0
 Group:      Multimedia/Libraries
 License:    Apache-2.0
index 15b6911..494d517 100644 (file)
@@ -1253,6 +1253,30 @@ extern "C" {
 #define MMCAM_ENCODED_PREVIEW_GOP_INTERVAL      "encoded-preview-gop-interval"
 
 /**
+ * The distance to move the camera horizontally and physically
+ */
+#define MMCAM_CAMERA_PAN_MECHA                  "camera-pan-mecha"
+
+/**
+ * The distance to move the camera horizontally
+ */
+#define MMCAM_CAMERA_PAN_ELEC                   "camera-pan-elec"
+
+/**
+ * The distance to move the camera vertically and physically
+ */
+#define MMCAM_CAMERA_TILT_MECHA                 "camera-tilt-mecha"
+
+/**
+ * The distance to move the camera vertically
+ */
+#define MMCAM_CAMERA_TILT_ELEC                  "camera-tilt-elec"
+
+/**
+ * The type of PTZ(Pan Tilt Zoom). Mechanical or Electonic PTZ.
+ */
+#define MMCAM_CAMERA_PTZ_TYPE                   "camera-ptz-type"
+/**
  * Stream type and index for sound route
  */
 #define MMCAM_SOUND_STREAM_TYPE                 "sound-stream-type"
index 51ee5a4..fc63974 100644 (file)
@@ -156,7 +156,7 @@ typedef enum
        MM_CAM_CAMERA_FLIP,
        MM_CAM_CAMERA_HDR_CAPTURE,
        MM_CAM_DISPLAY_MODE,
-       MM_CAM_AUDIO_DISABLE,                   /* 100 */
+       MM_CAM_AUDIO_DISABLE,                           /* 100 */
        MM_CAM_RECOMMEND_CAMERA_WIDTH,
        MM_CAM_RECOMMEND_CAMERA_HEIGHT,
        MM_CAM_CAPTURED_EXIF_RAW_DATA,
@@ -166,17 +166,22 @@ typedef enum
        MM_CAM_DISPLAY_FLIP,
        MM_CAM_CAMERA_VIDEO_STABILIZATION,
        MM_CAM_TAG_VIDEO_ORIENTATION,
-       MM_CAM_VIDEO_WIDTH,                     /* 110 */
+       MM_CAM_CAMERA_PAN_MECHA,                        /* 110 */
+       MM_CAM_CAMERA_PAN_ELEC,
+       MM_CAM_CAMERA_TILT_MECHA,
+       MM_CAM_CAMERA_TILT_ELEC,
+       MM_CAM_CAMERA_PTZ_TYPE,
+       MM_CAM_VIDEO_WIDTH,
        MM_CAM_VIDEO_HEIGHT,
        MM_CAM_SUPPORT_ZSL_CAPTURE,
        MM_CAM_SUPPORT_ZERO_COPY_FORMAT,
        MM_CAM_SUPPORT_MEDIA_PACKET_PREVIEW_CB,
-       MM_CAM_ENCODED_PREVIEW_BITRATE,
+       MM_CAM_ENCODED_PREVIEW_BITRATE,         /* 120 */
        MM_CAM_ENCODED_PREVIEW_GOP_INTERVAL,
        MM_CAM_RECORDER_TAG_ENABLE,
        MM_CAM_DISPLAY_SOCKET_PATH,
        MM_CAM_PID_FOR_SOUND_FOCUS,
-       MM_CAM_ROOT_DIRECTORY,          /* 120 */
+       MM_CAM_ROOT_DIRECTORY,
        MM_CAM_SOUND_STREAM_TYPE,
        MM_CAM_SOUND_STREAM_INDEX,
        MM_CAM_ATTRIBUTE_NUM
@@ -344,6 +349,9 @@ bool _mmcamcorder_commit_camera_width(MMHandleType handle, int attr_idx, const m
 bool _mmcamcorder_commit_camera_height(MMHandleType handle, int attr_idx, const mmf_value_t *value);
 bool _mmcamcorder_commit_video_size(MMHandleType handle, int attr_idx, const mmf_value_t *value);
 bool _mmcamcorder_commit_camera_zoom(MMHandleType handle, int attr_idx, const mmf_value_t *value);
+bool _mmcamcorder_commit_camera_ptz_type(MMHandleType handle, int attr_idx, const mmf_value_t *value);
+bool _mmcamcorder_commit_camera_pan(MMHandleType handle, int attr_idx, const mmf_value_t *value);
+bool _mmcamcorder_commit_camera_tilt(MMHandleType handle, int attr_idx, const mmf_value_t *value);
 bool _mmcamcorder_commit_camera_focus_mode(MMHandleType handle, int attr_idx, const mmf_value_t *value);
 bool _mmcamcorder_commit_camera_af_scan_range(MMHandleType handle, int attr_idx, const mmf_value_t *value);
 bool _mmcamcorder_commit_camera_af_touch_area(MMHandleType handle, int attr_idx, const mmf_value_t *value);
index fdb1f87..bfcb88b 100644 (file)
@@ -145,7 +145,7 @@ extern "C" {
 #define _MMCAMCORDER_SENSOR_ENUM_NONE  -255
 
 /* camera information related */
-#define CAMINFO_CONVERT_NUM            40
+#define CAMINFO_CONVERT_NUM            45
 
 
 /*=======================================================================================
index 59db9a8..7e7a382 100644 (file)
@@ -1359,6 +1359,61 @@ _mmcamcorder_alloc_attribute( MMHandleType handle, MMCamPreset *info )
                },
                //110
                {
+                       MM_CAM_CAMERA_PAN_MECHA,
+                       "camera-pan-mecha",
+                       MMF_VALUE_TYPE_INT,
+                       MM_ATTRS_FLAG_RW,
+                       {(void*)0},
+                       MM_ATTRS_VALID_TYPE_INT_RANGE,
+                       {.int_min = 0},
+                       {.int_max = -1},
+                       _mmcamcorder_commit_camera_pan,
+               },
+               {
+                       MM_CAM_CAMERA_PAN_ELEC,
+                       "camera-pan-elec",
+                       MMF_VALUE_TYPE_INT,
+                       MM_ATTRS_FLAG_RW,
+                       {(void*)0},
+                       MM_ATTRS_VALID_TYPE_INT_RANGE,
+                       {.int_min = 0},
+                       {.int_max = -1},
+                       _mmcamcorder_commit_camera_pan,
+               },
+               {
+                       MM_CAM_CAMERA_TILT_MECHA,
+                       "camera-tilt-mecha",
+                       MMF_VALUE_TYPE_INT,
+                       MM_ATTRS_FLAG_RW,
+                       {(void*)0},
+                       MM_ATTRS_VALID_TYPE_INT_RANGE,
+                       {.int_min = 0},
+                       {.int_max = -1},
+                       _mmcamcorder_commit_camera_tilt,
+               },
+               {
+                       MM_CAM_CAMERA_TILT_ELEC,
+                       "camera-tilt-elec",
+                       MMF_VALUE_TYPE_INT,
+                       MM_ATTRS_FLAG_RW,
+                       {(void*)0},
+                       MM_ATTRS_VALID_TYPE_INT_RANGE,
+                       {.int_min = 0},
+                       {.int_max = -1},
+                       _mmcamcorder_commit_camera_tilt,
+               },
+               {
+                       MM_CAM_CAMERA_PTZ_TYPE,
+                       "camera-ptz-type",
+                       MMF_VALUE_TYPE_INT,
+                       MM_ATTRS_FLAG_RW,
+                       {(void*)0},
+                       MM_ATTRS_VALID_TYPE_INT_ARRAY,
+                       {0},
+                       {0},
+                       _mmcamcorder_commit_camera_ptz_type,
+               },
+               {
                        MM_CAM_VIDEO_WIDTH,
                        "video-width",
                        MMF_VALUE_TYPE_INT,
@@ -1435,6 +1490,7 @@ _mmcamcorder_alloc_attribute( MMHandleType handle, MMCamPreset *info )
                        {.int_max = _MMCAMCORDER_MAX_INT},
                        _mmcamcorder_commit_encoded_preview_gop_interval,
                },
+               //120
                {
                        MM_CAM_RECORDER_TAG_ENABLE,
                        "recorder-tag-enable",
@@ -1468,7 +1524,6 @@ _mmcamcorder_alloc_attribute( MMHandleType handle, MMCamPreset *info )
                        {.int_max = _MMCAMCORDER_MAX_INT},
                        _mmcamcorder_commit_pid_for_sound_focus,
                },
-               //120
                {
                        MM_CAM_ROOT_DIRECTORY,
                        "root-directory",
@@ -2364,6 +2419,195 @@ bool _mmcamcorder_commit_camera_zoom (MMHandleType handle, int attr_idx, const m
 }
 
 
+bool _mmcamcorder_commit_camera_ptz_type(MMHandleType handle, int attr_idx, const mmf_value_t *value)
+{
+       _MMCamcorderSubContext *sc = NULL;
+       int current_state = MM_CAMCORDER_STATE_NONE;
+
+       GstCameraControl *CameraControl = NULL;
+       GstCameraControlChannel *CameraControlChannel = NULL;
+       const GList *controls = NULL;
+       const GList *item = NULL;
+
+       sc = MMF_CAMCORDER_SUBCONTEXT(handle);
+       mmf_return_val_if_fail(sc, TRUE);
+
+       _mmcam_dbg_log("ptz type : %d", value->value.i_val);
+
+       current_state = _mmcamcorder_get_state(handle);
+       if (current_state < MM_CAMCORDER_STATE_PREPARE ||
+           current_state == MM_CAMCORDER_STATE_CAPTURING) {
+               _mmcam_dbg_err("invalid state[%d]", current_state);
+               return FALSE;
+       }
+
+       if (sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst) {
+               if (!GST_IS_CAMERA_CONTROL(sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst)) {
+                       _mmcam_dbg_log("Can't cast Video source into camera control.");
+                       return FALSE;
+               }
+
+               CameraControl = GST_CAMERA_CONTROL(sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst);
+               if (CameraControl == NULL) {
+                       _mmcam_dbg_err("cast CAMERA_CONTROL failed");
+                       return FALSE;
+               }
+
+               controls = gst_camera_control_list_channels(CameraControl);
+               if (controls == NULL) {
+                       _mmcam_dbg_err("gst_camera_control_list_channels failed");
+                       return FALSE;
+               }
+
+               for (item = controls ; item && item->data ; item = item->next) {
+                       CameraControlChannel = item->data;
+                       _mmcam_dbg_log("CameraControlChannel->label %s", CameraControlChannel->label);
+                       if (!strcmp(CameraControlChannel->label, "ptz")) {
+                               if (gst_camera_control_set_value(CameraControl, CameraControlChannel, value->value.i_val)) {
+                                       _mmcam_dbg_warn("set ptz type %d done", value->value.i_val);
+                                       return TRUE;
+                               } else {
+                                       _mmcam_dbg_err("failed to set ptz type %d", value->value.i_val);
+                                       return FALSE;
+                               }
+                       }
+               }
+
+               if (item == NULL) {
+                       _mmcam_dbg_warn("failed to find tilt control channel");
+               }
+       }
+
+       return FALSE;
+}
+
+
+bool _mmcamcorder_commit_camera_pan(MMHandleType handle, int attr_idx, const mmf_value_t *value)
+{
+       _MMCamcorderSubContext *sc = NULL;
+       int current_state = MM_CAMCORDER_STATE_NONE;
+
+       GstCameraControl *CameraControl = NULL;
+       GstCameraControlChannel *CameraControlChannel = NULL;
+       const GList *controls = NULL;
+       const GList *item = NULL;
+
+       sc = MMF_CAMCORDER_SUBCONTEXT(handle);
+       mmf_return_val_if_fail(sc, TRUE);
+
+       _mmcam_dbg_log("pan : %d", value->value.i_val);
+
+       current_state = _mmcamcorder_get_state(handle);
+       if (current_state < MM_CAMCORDER_STATE_PREPARE ||
+           current_state == MM_CAMCORDER_STATE_CAPTURING) {
+               _mmcam_dbg_err("invalid state[%d]", current_state);
+               return FALSE;
+       }
+
+       if (sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst) {
+               if (!GST_IS_CAMERA_CONTROL(sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst)) {
+                       _mmcam_dbg_log("Can't cast Video source into camera control.");
+                       return FALSE;
+               }
+
+               CameraControl = GST_CAMERA_CONTROL(sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst);
+               if (CameraControl == NULL) {
+                       _mmcam_dbg_err("cast CAMERA_CONTROL failed");
+                       return FALSE;
+               }
+
+               controls = gst_camera_control_list_channels(CameraControl);
+               if (controls == NULL) {
+                       _mmcam_dbg_err("gst_camera_control_list_channels failed");
+                       return FALSE;
+               }
+
+               for (item = controls ; item && item->data ; item = item->next) {
+                       CameraControlChannel = item->data;
+                       _mmcam_dbg_log("CameraControlChannel->label %s", CameraControlChannel->label);
+                       if (!strcmp(CameraControlChannel->label, "pan")) {
+                               if (gst_camera_control_set_value(CameraControl, CameraControlChannel, value->value.i_val)) {
+                                       _mmcam_dbg_warn("set pan %d done", value->value.i_val);
+                                       return TRUE;
+                               } else {
+                                       _mmcam_dbg_err("failed to set pan %d", value->value.i_val);
+                                       return FALSE;
+                               }
+                       }
+               }
+
+               if (item == NULL) {
+                       _mmcam_dbg_warn("failed to find pan control channel");
+               }
+       }
+
+       return FALSE;
+}
+
+
+bool _mmcamcorder_commit_camera_tilt(MMHandleType handle, int attr_idx, const mmf_value_t *value)
+{
+       _MMCamcorderSubContext *sc = NULL;
+       int current_state = MM_CAMCORDER_STATE_NONE;
+
+       GstCameraControl *CameraControl = NULL;
+       GstCameraControlChannel *CameraControlChannel = NULL;
+       const GList *controls = NULL;
+       const GList *item = NULL;
+
+       sc = MMF_CAMCORDER_SUBCONTEXT(handle);
+       mmf_return_val_if_fail(sc, TRUE);
+
+       _mmcam_dbg_log("tilt : %d", value->value.i_val);
+
+       current_state = _mmcamcorder_get_state(handle);
+       if (current_state < MM_CAMCORDER_STATE_PREPARE ||
+           current_state == MM_CAMCORDER_STATE_CAPTURING) {
+               _mmcam_dbg_err("invalid state[%d]", current_state);
+               return FALSE;
+       }
+
+       if (sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst) {
+               if (!GST_IS_CAMERA_CONTROL(sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst)) {
+                       _mmcam_dbg_log("Can't cast Video source into camera control.");
+                       return FALSE;
+               }
+
+               CameraControl = GST_CAMERA_CONTROL(sc->element[_MMCAMCORDER_VIDEOSRC_SRC].gst);
+               if (CameraControl == NULL) {
+                       _mmcam_dbg_err("cast CAMERA_CONTROL failed");
+                       return FALSE;
+               }
+
+               controls = gst_camera_control_list_channels(CameraControl);
+               if (controls == NULL) {
+                       _mmcam_dbg_err("gst_camera_control_list_channels failed");
+                       return FALSE;
+               }
+
+               for (item = controls ; item && item->data ; item = item->next) {
+                       CameraControlChannel = item->data;
+                       _mmcam_dbg_log("CameraControlChannel->label %s", CameraControlChannel->label);
+                       if (!strcmp(CameraControlChannel->label, "tilt")) {
+                               if (gst_camera_control_set_value(CameraControl, CameraControlChannel, value->value.i_val)) {
+                                       _mmcam_dbg_warn("set tilt %d done", value->value.i_val);
+                                       return TRUE;
+                               } else {
+                                       _mmcam_dbg_err("failed to set tilt %d", value->value.i_val);
+                                       return FALSE;
+                               }
+                       }
+               }
+
+               if (item == NULL) {
+                       _mmcam_dbg_warn("failed to find tilt control channel");
+               }
+       }
+
+       return FALSE;
+}
+
+
 bool _mmcamcorder_commit_camera_focus_mode (MMHandleType handle, int attr_idx, const mmf_value_t *value)
 {
        MMHandleType attr = 0;
@@ -3481,7 +3725,7 @@ bool _mmcamcorder_commit_display_geometry_method (MMHandleType handle, int attr_
        if (!strcmp(videosink_name, "xvimagesink") || !strcmp(videosink_name, "waylandsink") ||
            !strcmp(videosink_name, "evaspixmapsink") || !strcmp(videosink_name, "evasimagesink")) {
                method = value->value.i_val;
-               MMCAMCORDER_G_OBJECT_SET( sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "display-geometry-method", method);
+               MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "display-geometry-method", method);
                return TRUE;
        } else {
                _mmcam_dbg_warn("videosink[%s] does not support geometry method.", videosink_name);
@@ -3494,6 +3738,7 @@ bool _mmcamcorder_commit_display_rect(MMHandleType handle, int attr_idx, const m
 {
        int current_state = MM_CAMCORDER_STATE_NONE;
        int method = 0;
+       int ret = MM_ERROR_NONE;
        const char *videosink_name = NULL;
 
        mmf_camcorder_t *hcamcorder = MMF_CAMCORDER(handle);
@@ -3584,14 +3829,23 @@ bool _mmcamcorder_commit_display_rect(MMHandleType handle, int attr_idx, const m
                }
 
                if (!(flags & MM_ATTRS_FLAG_MODIFIED)) {
-                       _mmcam_dbg_log("RECT(x,y,w,h) = (%d,%d,%d,%d)",
-                                      rect_x, rect_y, rect_width, rect_height);
-                       g_object_set(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst,
-                                    "dst-roi-x", rect_x,
-                                    "dst-roi-y", rect_y,
-                                    "dst-roi-w", rect_width,
-                                    "dst-roi-h", rect_height,
-                                    NULL);
+                       _mmcam_dbg_log("RECT(x,y,w,h) = (%d,%d,%d,%d)", rect_x, rect_y, rect_width, rect_height);
+
+                       if (!strcmp(videosink_name, "waylandsink")) {
+                           ret = gst_video_overlay_set_render_rectangle(GST_VIDEO_OVERLAY(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst),
+                                       rect_x, rect_y, rect_width, rect_height);
+                               if (!ret) {
+                                       _mmcam_dbg_err("FAILED : could not set render rectangle.");
+                                       return FALSE;
+                               }
+                       } else {
+                           g_object_set(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst,
+                                                       "dst-roi-x", rect_x,
+                                                       "dst-roi-y", rect_y,
+                                                       "dst-roi-w", rect_width,
+                                                       "dst-roi-h", rect_height,
+                                                       NULL);
+                       }
                }
 
                return TRUE;
index 172f09e..b573b17 100644 (file)
@@ -744,28 +744,28 @@ void _mmcamcorder_conf_init(MMHandleType handle, int type, camera_conf** configu
 
        /* [Camera] matching table */
        static conf_info_table conf_ctrl_camera_table[] = {
-               { "InputIndex",        CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "DeviceName",        CONFIGURE_VALUE_STRING,         {NULL} },
-               { "PreviewResolution", CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
-               { "CaptureResolution", CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
-               { "VideoResolution",   CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
-               { "FPS0",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS1",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS2",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS3",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS4",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS5",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS6",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS7",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS8",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "FPS9",              CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "PictureFormat",     CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
-               { "Overlay",           CONFIGURE_VALUE_INT_RANGE,      {NULL} },
+               { "InputIndex",           CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "DeviceName",           CONFIGURE_VALUE_STRING,         {NULL} },
+               { "PreviewResolution",    CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
+               { "CaptureResolution",    CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
+               { "VideoResolution",      CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
+               { "FPS0",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS1",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS2",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS3",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS4",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS5",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS6",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS7",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS8",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "FPS9",                 CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "PictureFormat",        CONFIGURE_VALUE_INT_ARRAY,      {NULL} },
+               { "Overlay",              CONFIGURE_VALUE_INT_RANGE,      {NULL} },
                { "RecommendDisplayRotation", CONFIGURE_VALUE_INT,     {.value_int = 3}    },
                { "RecommendPreviewFormatCapture", CONFIGURE_VALUE_INT, {.value_int = MM_PIXEL_FORMAT_YUYV} },
                { "RecommendPreviewFormatRecord",  CONFIGURE_VALUE_INT, {.value_int = MM_PIXEL_FORMAT_NV12} },
                { "RecommendPreviewResolution", CONFIGURE_VALUE_INT_PAIR_ARRAY, {NULL} },
-               { "FacingDirection", CONFIGURE_VALUE_INT, {.value_int = MM_CAMCORDER_CAMERA_FACING_DIRECTION_REAR} },
+               { "FacingDirection",      CONFIGURE_VALUE_INT, {.value_int = MM_CAMCORDER_CAMERA_FACING_DIRECTION_REAR} },
        };
 
        /* [Strobe] matching table */
@@ -808,6 +808,10 @@ void _mmcamcorder_conf_init(MMHandleType handle, int type, camera_conf** configu
                { "VideoStabilization",   CONFIGURE_VALUE_INT_ARRAY, {NULL} },
                { "FaceZoomMode",         CONFIGURE_VALUE_INT_ARRAY, {NULL} },
                { "FaceZoomLevel",        CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "PanMecha",             CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "PanElec",              CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "TiltMecha",            CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "TiltElec",             CONFIGURE_VALUE_INT_RANGE, {NULL} },
        };
 
        /* [Capture] matching table */
@@ -822,10 +826,10 @@ void _mmcamcorder_conf_init(MMHandleType handle, int type, camera_conf** configu
 
        /* [Detect] matching table */
        static conf_info_table conf_ctrl_detect_table[] = {
-               { "DetectMode",         CONFIGURE_VALUE_INT_ARRAY, {NULL} },
-               { "DetectNumber",       CONFIGURE_VALUE_INT_RANGE, {NULL} },
-               { "DetectSelect",       CONFIGURE_VALUE_INT_RANGE, {NULL} },
-               { "DetectSelectNumber", CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "DetectMode",           CONFIGURE_VALUE_INT_ARRAY, {NULL} },
+               { "DetectNumber",         CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "DetectSelect",         CONFIGURE_VALUE_INT_RANGE, {NULL} },
+               { "DetectSelectNumber",   CONFIGURE_VALUE_INT_RANGE, {NULL} },
        };
 
        if (hcamcorder == NULL) {
index 2896d0b..5817538 100644 (file)
@@ -301,6 +301,51 @@ static _MMCamcorderInfoConverting  g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
        },
        {
                CONFIGURE_TYPE_CTRL,
+               CONFIGURE_CATEGORY_CTRL_CAMERA,
+               MM_CAM_CAMERA_PAN_MECHA,
+               MM_CAMCORDER_ATTR_NONE,
+               "PanMecha",
+               MM_CAMCONVERT_TYPE_INT_RANGE,
+               NULL,
+       },
+       {
+               CONFIGURE_TYPE_CTRL,
+               CONFIGURE_CATEGORY_CTRL_CAMERA,
+               MM_CAM_CAMERA_PAN_ELEC,
+               MM_CAMCORDER_ATTR_NONE,
+               "PanElec",
+               MM_CAMCONVERT_TYPE_INT_RANGE,
+               NULL,
+       },
+       {
+               CONFIGURE_TYPE_CTRL,
+               CONFIGURE_CATEGORY_CTRL_CAMERA,
+               MM_CAM_CAMERA_TILT_MECHA,
+               MM_CAMCORDER_ATTR_NONE,
+               "TiltMecha",
+               MM_CAMCONVERT_TYPE_INT_RANGE,
+               NULL,
+       },
+       {
+               CONFIGURE_TYPE_CTRL,
+               CONFIGURE_CATEGORY_CTRL_CAMERA,
+               MM_CAM_CAMERA_TILT_ELEC,
+               MM_CAMCORDER_ATTR_NONE,
+               "TiltElec",
+               MM_CAMCONVERT_TYPE_INT_RANGE,
+               NULL,
+       },
+       {
+               CONFIGURE_TYPE_CTRL,
+               CONFIGURE_CATEGORY_CTRL_CAMERA,
+               MM_CAM_CAMERA_PTZ_TYPE,
+               MM_CAMCORDER_ATTR_NONE,
+               "PtzType",
+               MM_CAMCONVERT_TYPE_INT_ARRAY,
+               NULL,
+       },
+       {/* 10 */
+               CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_STROBE,
                MM_CAM_STROBE_CONTROL,
                MM_CAMCORDER_ATTR_NONE,
@@ -344,7 +389,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_RANGE,
                NULL,
        },
-       {/* 10 */
+       {
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_EFFECT,
                MM_CAM_FILTER_SATURATION,
@@ -389,7 +434,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_ARRAY,
                &_mmcamcorder_enum_conv_colortone,
        },
-       {
+       {/* 20 */
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_EFFECT,
                MM_CAM_CAMERA_WDR,
@@ -434,7 +479,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_RANGE,
                NULL,
        },
-       {/* 20 */
+       {
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_PHOTOGRAPH,
                MM_CAM_CAMERA_FOCUS_MODE,
@@ -479,7 +524,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_ARRAY,
                NULL,
        },
-       {
+       {/* 30 */
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_PHOTOGRAPH,
                MM_CAM_CAMERA_SHUTTER_SPEED,
@@ -524,7 +569,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_ARRAY,
                NULL,
        },
-       {/* 30 */
+       {
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_CAPTURE,
                MM_CAM_IMAGE_ENCODER_QUALITY,
@@ -569,7 +614,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_RANGE,
                NULL,
        },
-       {
+       {/* 40 */
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_DETECT,
                MM_CAM_DETECT_FOCUS_SELECT,
@@ -614,7 +659,7 @@ static _MMCamcorderInfoConverting   g_caminfo_convert[CAMINFO_CONVERT_NUM] = {
                MM_CAMCONVERT_TYPE_INT_ARRAY,
                &_mmcamcorder_enum_conv_video_stabilization,
        },
-       {/* 40 */
+       {
                CONFIGURE_TYPE_CTRL,
                CONFIGURE_CATEGORY_CTRL_CAMERA,
                MM_CAM_VIDEO_WIDTH,