dcam_property_table.h
Upload User: shyika
Upload Date: 2017-11-25
Package Size: 1227k
Code Size: 29k
Category:

Video Capture

Development Platform:

Unix_Linux

  1. /*
  2.     unicap
  3.     Copyright (C) 2004  Arne Caspari
  4.     This program is free software; you can redistribute it and/or modify
  5.     it under the terms of the GNU General Public License as published by
  6.     the Free Software Foundation; either version 2 of the License, or
  7.     (at your option) any later version.
  8.     This program is distributed in the hope that it will be useful,
  9.     but WITHOUT ANY WARRANTY; without even the implied warranty of
  10.     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  11.     GNU General Public License for more details.
  12.     You should have received a copy of the GNU General Public License
  13.     along with this program; if not, write to the Free Software
  14.     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  15. */
  16. #ifndef __DCAM_PROPERTY_TABLE_H__
  17. #define __DCAM_PROPERTY_TABLE_H__
  18. #include "unicap_cpi_std_struct.h"
  19. #include "dcam.h"
  20. #include "dcam_property.h"
  21. #define N_(x) x
  22. #define PPTY_FLAGS 0
  23. #define PPTY_MASK  0xffffffffffffffffULL
  24. #define DCAM_CAT_VIDEO    N_("Video")
  25. #define DCAM_CAT_EXPOSURE N_("Exposure")
  26. #define DCAM_CAT_LENS     N_("Lens Control")
  27. #define DCAM_CAT_COLOR    N_("Color")
  28. #define DCAM_CAT_DEVICE   N_("Device")
  29. #define DCAM_UNIT_NONE ""
  30. #define DCAM_UNIT_US   "us"
  31. static char *strobe_mode_menu[] = 
  32. {
  33.    N_("constant low"), 
  34.    N_("constant high"), 
  35.    N_("fixed duration"), 
  36.    N_("exposure")
  37. };
  38. static char *strobe_polarity_menu[] = 
  39. {
  40.    N_("active low"), 
  41.    N_("active high")
  42. };
  43. #define STROBE_MODE_DEFAULT_ITEM "exposure"
  44. char *dcam_brightness_relations[] =
  45. {
  46.    "shutter", 
  47.    "gain", 
  48.    "gamma", 
  49.    "iris", 
  50. };
  51. char *dcam_auto_exposure_relations[]= 
  52. {
  53. };
  54. char *dcam_sharpness_relations[] = 
  55. {
  56. };
  57. char *dcam_white_balance_mode_relations[] = 
  58. {
  59.    "white_balance_u", 
  60.    "white_balance_v", 
  61. };
  62. char *dcam_white_balance_u_relations[] = 
  63. {
  64.    "white_balance_v", 
  65. };
  66. char *dcam_white_balance_v_relations[] = 
  67. {
  68.    "white_balance_u", 
  69. };
  70. char *dcam_hue_relations[] = 
  71. {
  72. };
  73. char *dcam_saturation_relations[] = 
  74. {
  75. };
  76. char *dcam_gamma_relations[] =
  77. {
  78. "brightness", 
  79. };
  80. char *dcam_shutter_relations[] = 
  81. {
  82. "gain", 
  83. "brightness", 
  84. "gamma",
  85. "iris", 
  86. };
  87. char *dcam_gain_relations[] = 
  88. {
  89. "shutter", 
  90. "brightness", 
  91. "gamma", 
  92. "iris", 
  93. };
  94. char *dcam_iris_relations[] = 
  95. {
  96. "shutter", 
  97. "gain", 
  98. "brightness", 
  99. "gamma", 
  100. };
  101. char *dcam_focus_relations[] = 
  102. {
  103. "zoom", 
  104. };
  105. char *dcam_temperature_relations[] = 
  106. {
  107. };
  108. char *dcam_trigger_mode_relations[] = 
  109. {
  110. };
  111. char *dcam_trigger_modes[]=
  112. {
  113.    N_("free running"), 
  114.    N_("mode 0"), 
  115. };
  116. char *dcam_zoom_relations[] = 
  117. {
  118. "focus", 
  119. };
  120. char *dcam_pan_relations[] = 
  121. {
  122. "tilt",
  123. };
  124. char *dcam_tilt_relations[] = 
  125. {
  126. "pan", 
  127. };
  128. char *dcam_optical_filter_relations[] = 
  129. {
  130. };
  131. char *dcam_capture_quality_relations[] =
  132. {
  133. };
  134. char *dcam_frame_rate_relations[] =
  135. {
  136. };
  137. char *dcam_register_relations[] = 
  138. {
  139. };
  140. char *dcam_timeout_relations[] = 
  141. {
  142. };
  143. struct _dcam_property _dcam_properties[]=
  144. {
  145. { id: DCAM_PPTY_BRIGHTNESS, 
  146.   unicap_property: { identifier: N_("brightness"), 
  147.  category: DCAM_CAT_EXPOSURE, 
  148.  unit: DCAM_UNIT_NONE, 
  149.  relations: dcam_brightness_relations, 
  150.  relations_count: sizeof( dcam_brightness_relations ) / sizeof( char * ), 
  151.  { value: 0.0 }, 
  152.  { range: { min: 0.0, 
  153. max: 1.0} },  
  154.  stepping: 0.01, 
  155.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  156.  flags: UNICAP_FLAGS_MANUAL, 
  157.  flags_mask: PPTY_MASK, 
  158.  property_data: NULL, 
  159.  property_data_size: 0 }, 
  160.   register_offset: 0x000, 
  161.   register_inq: 0, 
  162.   register_default: 0, 
  163.   register_value: 0, 
  164.   type: PPTY_TYPE_BRIGHTNESS, 
  165.   set_function: dcam_set_property,
  166.   get_function: dcam_get_property,
  167.   init_function: dcam_init_brightness_property, 
  168.   feature_hi_mask: 1<<31, 
  169.   feature_lo_mask: 0,
  170. },
  171. #if 0
  172. { id: DCAM_PPTY_ABS_FOCUS, 
  173.   unicap_property: { identifier: "abs focus", 
  174.      category: DCAM_CAT_LENS, 
  175.      unit: DCAM_UNIT_NONE, 
  176.      relations: 0, 
  177.      relations_count: 0, 
  178.      { value: 300.0 }, 
  179.      { range: { min: 70.0, 
  180. max: 620.0} },  
  181.      stepping: 1.0, 
  182.      type: UNICAP_PROPERTY_TYPE_RANGE, 
  183.      flags: UNICAP_FLAGS_MANUAL, 
  184.      flags_mask: UNICAP_FLAGS_MANUAL, 
  185.      property_data: NULL, 
  186.      property_data_size: 0 }, 
  187.   register_offset: 0xfff970, 
  188.   register_inq: 0, 
  189.   register_default: 0, 
  190.   register_value: 0, 
  191.   type: PPTY_TYPE_BRIGHTNESS, 
  192.   set_function: dcam_set_property,
  193.   get_function: dcam_get_property,
  194.   init_function: dcam_init_rw_register_property, 
  195.   feature_hi_mask: 1<<31, 
  196.   feature_lo_mask: 0,
  197. },
  198. { id: DCAM_PPTY_ABS_ZOOM, 
  199.   unicap_property: { identifier: "abs zoom", 
  200.      category: DCAM_CAT_LENS, 
  201.      unit: DCAM_UNIT_NONE, 
  202.      relations: 0, 
  203.      relations_count: 0, 
  204.      { value: 300.0 }, 
  205.      { range: { min: 25.0, 
  206. max: 350.0} },  
  207.      stepping: 1.0, 
  208.      type: UNICAP_PROPERTY_TYPE_RANGE, 
  209.      flags: UNICAP_FLAGS_MANUAL, 
  210.      flags_mask: UNICAP_FLAGS_MANUAL, 
  211.      property_data: NULL, 
  212.      property_data_size: 0 }, 
  213.   register_offset: 0xfff974, 
  214.   register_inq: 0, 
  215.   register_default: 0, 
  216.   register_value: 0, 
  217.   type: PPTY_TYPE_BRIGHTNESS, 
  218.   set_function: dcam_set_property,
  219.   get_function: dcam_get_property,
  220.   init_function: dcam_init_rw_register_property, 
  221.   feature_hi_mask: 1<<31, 
  222.   feature_lo_mask: 0,
  223. },
  224. #endif
  225. { id: DCAM_PPTY_STROBE_MODE, 
  226.   unicap_property: { identifier: N_("strobe_mode"), 
  227.      category: DCAM_CAT_DEVICE, 
  228.      unit: DCAM_UNIT_NONE, 
  229.      relations: 0, 
  230.      relations_count: 0, 
  231.      { menu_item: {STROBE_MODE_DEFAULT_ITEM} }, 
  232.      { menu: { menu_items: strobe_mode_menu,
  233.        menu_item_count: sizeof( strobe_mode_menu ) / sizeof( char* ) } }, 
  234.      stepping: 0.0, 
  235.      type: UNICAP_PROPERTY_TYPE_MENU, 
  236.      flags: UNICAP_FLAGS_MANUAL, 
  237.      flags_mask: UNICAP_FLAGS_MANUAL, 
  238.      property_data: NULL, 
  239.      property_data_size: 0 },
  240.   register_offset: 0x3c,
  241.   register_inq: 0, 
  242.   register_default: 0, 
  243.   register_value: 0, 
  244.   type: PPTY_TYPE_BRIGHTNESS, 
  245.   set_function: dcam_set_strobe_mode_property,
  246.   get_function: dcam_get_strobe_mode_property,
  247.   init_function: dcam_init_gpio_property, 
  248.   feature_hi_mask: 1<<31, 
  249.   feature_lo_mask: 0,
  250. },
  251. { id: DCAM_PPTY_STROBE_DURATION,
  252.   unicap_property: { identifier: N_("strobe_duration"), 
  253.      category: DCAM_CAT_DEVICE, 
  254.      unit: DCAM_UNIT_US, 
  255.      relations: 0, 
  256.      relations_count: 0, 
  257.      { value: 10.0 }, 
  258.      { range: { min: 10.0, 
  259. max: 40000.0 } },  
  260.      stepping: 10.0, 
  261.      type: UNICAP_PROPERTY_TYPE_RANGE, 
  262.      flags: UNICAP_FLAGS_MANUAL, 
  263.      flags_mask: PPTY_MASK, 
  264.      property_data: NULL, 
  265.      property_data_size: 0 },
  266.      
  267.   register_offset: 0x3c,
  268.   register_inq: 0, 
  269.   register_default: 0, 
  270.   register_value: 0, 
  271.   type: PPTY_TYPE_BRIGHTNESS, 
  272.   set_function: dcam_set_strobe_duration_property,
  273.   get_function: dcam_get_strobe_duration_property,
  274.   init_function: dcam_init_gpio_property, 
  275.   feature_hi_mask: 1<<31, 
  276.   feature_lo_mask: 0,
  277. },
  278. { id: DCAM_PPTY_STROBE_DELAY,
  279.   unicap_property: { identifier: N_("strobe_delay"), 
  280.      category: DCAM_CAT_DEVICE, 
  281.      unit: DCAM_UNIT_US, 
  282.      relations: 0, 
  283.      relations_count: 0, 
  284.      { value: 0.0 }, 
  285.      { range: { min: -20000.0, 
  286. max: 20000.0 } },  
  287.      stepping: 10.0, 
  288.      type: UNICAP_PROPERTY_TYPE_RANGE, 
  289.      flags: UNICAP_FLAGS_MANUAL, 
  290.      flags_mask: PPTY_MASK, 
  291.      property_data: NULL, 
  292.      property_data_size: 0 },
  293.      
  294.   register_offset: 0x3c,
  295.   register_inq: 0, 
  296.   register_default: 0, 
  297.   register_value: 0, 
  298.   type: PPTY_TYPE_BRIGHTNESS, 
  299.   set_function: dcam_set_strobe_delay_property,
  300.   get_function: dcam_get_strobe_delay_property,
  301.   init_function: dcam_init_gpio_property, 
  302.   feature_hi_mask: 1<<31, 
  303.   feature_lo_mask: 0,
  304. },
  305. { id: DCAM_PPTY_STROBE_POLARITY, 
  306.   unicap_property: { identifier: N_("strobe_polarity"), 
  307.      category: DCAM_CAT_DEVICE, 
  308.      unit: DCAM_UNIT_NONE, 
  309.      relations: 0, 
  310.      relations_count: 0, 
  311.      { menu_item: {STROBE_MODE_DEFAULT_ITEM} }, 
  312.      { menu: { menu_items: strobe_polarity_menu,
  313.        menu_item_count: sizeof( strobe_polarity_menu ) / sizeof( char* ) } }, 
  314.      stepping: 0.0, 
  315.      type: UNICAP_PROPERTY_TYPE_MENU, 
  316.      flags: UNICAP_FLAGS_MANUAL, 
  317.      flags_mask: UNICAP_FLAGS_MANUAL, 
  318.      property_data: NULL, 
  319.      property_data_size: 0 },
  320.   register_offset: 0x3c,
  321.   register_inq: 0, 
  322.   register_default: 0, 
  323.   register_value: 0, 
  324.   type: PPTY_TYPE_BRIGHTNESS, 
  325.   set_function: dcam_set_strobe_polarity_property,
  326.   get_function: dcam_get_strobe_polarity_property,
  327.   init_function: dcam_init_gpio_property, 
  328.   feature_hi_mask: 1<<31, 
  329.   feature_lo_mask: 0,
  330. },
  331. { id: DCAM_PPTY_AUTO_EXPOSURE, 
  332.   unicap_property: { identifier: N_("auto_exposure"), 
  333.  category: DCAM_CAT_EXPOSURE, 
  334.  unit: DCAM_UNIT_NONE, 
  335.  relations: dcam_auto_exposure_relations, 
  336.  relations_count: sizeof( dcam_auto_exposure_relations ) / sizeof( char * ),
  337.  { value: 0.0 }, 
  338.  { range: { min: 0.0, 
  339. max: 1.0 } },  
  340.  stepping: 0.01, 
  341.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  342.  flags: UNICAP_FLAGS_MANUAL, 
  343.  flags_mask: PPTY_MASK, 
  344.  property_data: NULL, 
  345.  property_data_size: 0 },
  346.   register_offset: 0x004, 
  347.   register_inq: 0, 
  348.   register_default: 0, 
  349.   register_value: 0, 
  350.   type: PPTY_TYPE_BRIGHTNESS,
  351.   set_function: dcam_set_property,
  352.   get_function: dcam_get_property,
  353.   init_function: dcam_init_brightness_property, 
  354.   feature_hi_mask: 1<<30, 
  355.   feature_lo_mask: 0,
  356. },
  357. { id: DCAM_PPTY_SHARPNESS, 
  358.   unicap_property: { identifier: N_("sharpness"), 
  359.  category: DCAM_CAT_VIDEO, 
  360.  unit: DCAM_UNIT_NONE, 
  361.  relations: dcam_sharpness_relations, 
  362.  relations_count: sizeof( dcam_sharpness_relations ) / sizeof( char * ),   
  363.  { value: 0.0 }, 
  364.  { range: { min: -1.0, 
  365. max: 1.0 } }, 
  366.  stepping: 0.01, 
  367.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  368.  flags: UNICAP_FLAGS_MANUAL, 
  369.  flags_mask: PPTY_MASK, 
  370.  property_data: NULL, 
  371.  property_data_size: 0 }, 
  372.   register_offset: 0x008, 
  373.   register_inq: 0, 
  374.   register_default: 0, 
  375.   register_value: 0, 
  376.   type: PPTY_TYPE_BRIGHTNESS,
  377.   set_function: dcam_set_property,
  378.   get_function: dcam_get_property,
  379.   init_function: dcam_init_brightness_property, 
  380.   feature_hi_mask: 1<<29, 
  381.   feature_lo_mask: 0,
  382. },
  383. { id: DCAM_PPTY_WHITE_BALANCE_MODE, 
  384.   unicap_property: { identifier: N_("white_balance_mode"), 
  385.      category: DCAM_CAT_COLOR, 
  386.      unit: DCAM_UNIT_NONE, 
  387.      relations: dcam_white_balance_mode_relations, 
  388.      relations_count: sizeof( dcam_white_balance_mode_relations ) / sizeof( char * ), 
  389.      { value: 0.0 }, 
  390.      { range: { min: 0.0, 
  391. max: 0.0 } },  
  392.      stepping: 0.0, 
  393.      type: UNICAP_PROPERTY_TYPE_FLAGS, 
  394.      flags: UNICAP_FLAGS_MANUAL, 
  395.      flags_mask: PPTY_MASK, 
  396.      property_data: NULL, 
  397.      property_data_size: 0 }, 
  398.   register_offset: 0x00c, 
  399.   register_inq: 0, 
  400.   register_default: 0, 
  401.   register_value: 0, 
  402.   type: PPTY_TYPE_WHITEBAL_U,
  403.   set_function: dcam_set_white_balance_mode_property,
  404.   get_function: dcam_get_white_balance_mode_property,
  405.   init_function: dcam_init_white_balance_mode_property,
  406.   feature_hi_mask: 1<<28, 
  407.   feature_lo_mask: 0,
  408. }, 
  409.  
  410. { id: DCAM_PPTY_WHITE_BALANCE_U, 
  411.   unicap_property: { identifier: N_("white_balance_u"), 
  412.  category: DCAM_CAT_COLOR, 
  413.  unit: DCAM_UNIT_NONE, 
  414.  relations: dcam_white_balance_u_relations, 
  415.  relations_count: sizeof( dcam_white_balance_u_relations ) / sizeof( char * ), 
  416.  { value: 0.5 }, 
  417.  { range: { min: 0.0, 
  418. max: 1.0 } },  
  419.  stepping: 0.01, 
  420.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  421.  flags: UNICAP_FLAGS_MANUAL, 
  422.  flags_mask: PPTY_MASK, 
  423.  property_data: NULL, 
  424.  property_data_size: 0 }, 
  425.   register_offset: 0x00c, 
  426.   register_inq: 0, 
  427.   register_default: 0, 
  428.   register_value: 0, 
  429.   type: PPTY_TYPE_WHITEBAL_U,
  430.   set_function: dcam_set_property,
  431.   get_function: dcam_get_property,
  432.   init_function: dcam_init_white_balance_property,
  433.   feature_hi_mask: 1<<28, 
  434.   feature_lo_mask: 0,
  435. }, 
  436. { id: DCAM_PPTY_WHITE_BALANCE_V, 
  437.   unicap_property: { identifier: N_("white_balance_v"), 
  438.  category: DCAM_CAT_COLOR, 
  439.  unit: DCAM_UNIT_NONE, 
  440.  relations: dcam_white_balance_v_relations, 
  441.  relations_count: sizeof( dcam_white_balance_v_relations ) / sizeof( char * ),
  442.  { value: 0.5 }, 
  443.  { range: { min: 0.0, 
  444. max: 1.0 } },  
  445.  stepping: 0.01, 
  446.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  447.  flags: UNICAP_FLAGS_MANUAL, 
  448.  flags_mask: PPTY_MASK, 
  449.  property_data: NULL, 
  450.  property_data_size: 0 }, 
  451.   register_offset: 0x00c, 
  452.   register_inq: 0, 
  453.   register_default: 0, 
  454.   register_value: 0, 
  455.   type: PPTY_TYPE_WHITEBAL_V,
  456.   set_function: dcam_set_property,
  457.   get_function: dcam_get_property,
  458.   init_function: dcam_init_white_balance_property, 
  459.   feature_hi_mask: 1<<28, 
  460.   feature_lo_mask: 0,
  461. }, 
  462. { id: DCAM_PPTY_HUE, 
  463.   unicap_property: { identifier: N_("hue"), 
  464.  category: DCAM_CAT_COLOR, 
  465.  unit: DCAM_UNIT_NONE, 
  466.  relations: dcam_hue_relations, 
  467.  relations_count: sizeof( dcam_hue_relations ) / sizeof( char * ),  
  468.  { value: 0.0 }, 
  469.  { range: { min: -1.0, 
  470. max: 1.0 } }, 
  471.  stepping: 0.01, 
  472.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  473.  flags: UNICAP_FLAGS_MANUAL, 
  474.  flags_mask: PPTY_MASK, 
  475.  property_data: NULL, 
  476.  property_data_size: 0 }, 
  477.   register_offset: 0x010, 
  478.   register_inq: 0, 
  479.   register_default: 0, 
  480.   register_value: 0, 
  481.   type: PPTY_TYPE_BRIGHTNESS,
  482.   set_function: dcam_set_property,
  483.   get_function: dcam_get_property,
  484.   init_function: dcam_init_brightness_property, 
  485.   feature_hi_mask: 1<<27, 
  486.   feature_lo_mask: 0,
  487. },
  488. { id: DCAM_PPTY_SATURATION, 
  489.   unicap_property: { identifier: N_("saturation"), 
  490.  category: DCAM_CAT_COLOR, 
  491.  unit: DCAM_UNIT_NONE, 
  492.  relations: dcam_saturation_relations, 
  493.  relations_count: sizeof( dcam_saturation_relations ) / sizeof( char * ),
  494.  { value: 0.5 }, 
  495.  { range: { min: 0.0, 
  496. max: 1.0 } },  
  497.  stepping: 0.01, 
  498.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  499.  flags: UNICAP_FLAGS_MANUAL, 
  500.  flags_mask: PPTY_MASK, 
  501.  property_data: NULL, 
  502.  property_data_size: 0 }, 
  503.   register_offset: 0x014, 
  504.   register_inq: 0, 
  505.   register_default: 0, 
  506.   register_value: 0, 
  507.   type: PPTY_TYPE_BRIGHTNESS,
  508.   set_function: dcam_set_property,
  509.   get_function: dcam_get_property,
  510.   init_function: dcam_init_brightness_property, 
  511.   feature_hi_mask: 1<<26, 
  512.   feature_lo_mask: 0,
  513. }, 
  514. { id: DCAM_PPTY_GAMMA, 
  515.   unicap_property: { identifier: N_("gamma"), 
  516.  category: DCAM_CAT_VIDEO, 
  517.  unit: DCAM_UNIT_NONE, 
  518.  relations: dcam_gamma_relations, 
  519.  relations_count: sizeof( dcam_gamma_relations ) / sizeof( char * ),  
  520.  { value: 0.0 }, 
  521.  { range: { min: 0.0, 
  522. max: 0.0 } },  
  523.  stepping: 0.0,  
  524.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  525.  flags: UNICAP_FLAGS_MANUAL, 
  526.  flags_mask: PPTY_MASK, 
  527.  property_data: NULL, 
  528.  property_data_size: 0 }, 
  529.   register_offset: 0x018, 
  530.   register_inq: 0, 
  531.   register_default: 0, 
  532.   register_value: 0, 
  533.   type: PPTY_TYPE_BRIGHTNESS,
  534.   set_function: dcam_set_property,
  535.   get_function: dcam_get_property,
  536.   init_function: dcam_init_brightness_property, 
  537.   feature_hi_mask: 1<<25, 
  538.   feature_lo_mask: 0,
  539. },
  540. { id: DCAM_PPTY_SHUTTER, 
  541.   unicap_property: { identifier: N_("shutter"), 
  542.  category: DCAM_CAT_EXPOSURE, 
  543.  unit: DCAM_UNIT_NONE, 
  544.  relations: dcam_shutter_relations, 
  545.  relations_count: sizeof( dcam_shutter_relations ) / sizeof( char * ),
  546.  { value: 0.0 }, 
  547.  { range: { min: 0.0, 
  548. max: 0.0 } },  
  549.  stepping: 0.0,  
  550.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  551.  flags: UNICAP_FLAGS_MANUAL, 
  552.  flags_mask: PPTY_MASK, 
  553.  property_data: NULL, 
  554.  property_data_size: 0 }, 
  555.   register_offset: 0x01c, 
  556.   absolute_offset: 0, 
  557.   register_inq: 0, 
  558.   register_default: 0, 
  559.   register_value: 0, 
  560.   type: PPTY_TYPE_BRIGHTNESS,
  561.   set_function: dcam_set_property,
  562.   get_function: dcam_get_property,
  563.   init_function: dcam_init_shutter_property, 
  564.   feature_hi_mask: 1<<24, 
  565.   feature_lo_mask: 0,   
  566. },
  567. { id: DCAM_PPTY_GAIN, 
  568.   unicap_property: { identifier: N_("gain"), 
  569.  category: DCAM_CAT_EXPOSURE, 
  570.  unit: DCAM_UNIT_NONE, 
  571.  relations: dcam_gain_relations, 
  572.  relations_count: sizeof( dcam_gain_relations ) / sizeof( char * ),  
  573.  { value: 0.0 }, 
  574.  { range: { min: 0.0, 
  575. max: 0.0 } },  
  576.  stepping: 0.0,  
  577.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  578.  flags: UNICAP_FLAGS_MANUAL, 
  579.  flags_mask: PPTY_MASK, 
  580.  property_data: NULL, 
  581.  property_data_size: 0 },
  582.   register_offset: 0x020, 
  583.   register_inq: 0, 
  584.   register_default: 0, 
  585.   register_value: 0, 
  586.   type: PPTY_TYPE_BRIGHTNESS,
  587.   set_function: dcam_set_property,
  588.   get_function: dcam_get_property,
  589.   init_function: dcam_init_brightness_property, 
  590.   feature_hi_mask: 1<<23, 
  591.   feature_lo_mask: 0,
  592. },
  593. { id: DCAM_PPTY_IRIS, 
  594.   unicap_property: { identifier: N_("iris"), 
  595.  category: DCAM_CAT_LENS, 
  596.  unit: DCAM_UNIT_NONE, 
  597.  relations: dcam_iris_relations, 
  598.  relations_count: sizeof( dcam_iris_relations ) / sizeof( char * ),  
  599.  { value: 0.0 }, 
  600.  { range: { min: 0.0, 
  601. max: 0.0 } },  
  602.  stepping: 0.0,  
  603.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  604.  flags: UNICAP_FLAGS_MANUAL, 
  605.  flags_mask: PPTY_MASK, 
  606.  property_data: NULL, 
  607.  property_data_size: 0 }, 
  608.   register_offset: 0x024, 
  609.   register_inq: 0, 
  610.   register_default: 0, 
  611.   register_value: 0, 
  612.   PPTY_TYPE_BRIGHTNESS,
  613.   set_function: dcam_set_property,
  614.   get_function: dcam_get_property,
  615.   init_function: dcam_init_brightness_property, 
  616.   feature_hi_mask: 1<<22, 
  617.   feature_lo_mask: 0,
  618. },
  619. { id: DCAM_PPTY_FOCUS,
  620.   unicap_property: { identifier: N_("focus"),
  621.  category: DCAM_CAT_LENS,
  622.  unit: DCAM_UNIT_NONE,
  623.  relations: dcam_focus_relations,
  624.  relations_count: sizeof( dcam_focus_relations ) / sizeof( char * ),
  625.  { value: 0.0 },
  626.  { range: { min: 0.0,
  627. max: 0.0 } },
  628.  stepping: 0.0,
  629.  type: UNICAP_PROPERTY_TYPE_RANGE,
  630.  flags: UNICAP_FLAGS_MANUAL,
  631.  flags_mask: PPTY_MASK,
  632.  property_data: NULL,
  633.  property_data_size: 0 },
  634.   register_offset: 0x028,
  635.   register_inq: 0,
  636.   register_default: 0,
  637.   register_value: 0,
  638.   type: PPTY_TYPE_BRIGHTNESS,
  639.   set_function: dcam_set_property,
  640.   get_function: dcam_get_property,
  641.   init_function: dcam_init_brightness_property,
  642.   feature_hi_mask: 1<<21,
  643.   feature_lo_mask: 0,
  644. },
  645. { id: DCAM_PPTY_TEMPERATURE, 
  646.   unicap_property: { identifier: N_("temperature"), 
  647.  category: DCAM_CAT_VIDEO, 
  648.  unit: DCAM_UNIT_NONE, 
  649.  relations: dcam_temperature_relations, 
  650.  relations_count: sizeof( dcam_temperature_relations ) / sizeof( char * ),
  651.  { value: 0.0 }, 
  652.  { range: { min: 0.0, 
  653. max: 0.0 } },  
  654.  stepping: 0.0,  
  655.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  656.  flags: UNICAP_FLAGS_MANUAL, 
  657.  flags_mask: PPTY_MASK, 
  658.  property_data: NULL, 
  659.  property_data_size: 0 }, 
  660.   register_offset: 0x02c, 
  661.   register_inq: 0, 
  662.   register_default: 0, 
  663.   register_value: 0, 
  664.   type: PPTY_TYPE_TEMPERATURE,
  665.   set_function: dcam_set_property,
  666.   get_function: dcam_get_property,
  667.   init_function: dcam_init_brightness_property, 
  668.   feature_hi_mask: 1<<20, 
  669.   feature_lo_mask: 0,
  670. },
  671. { id: DCAM_PPTY_SOFTWARE_TRIGGER, 
  672.   unicap_property: { identifier: N_("software trigger"), 
  673.  category: DCAM_CAT_DEVICE, 
  674.  relations: NULL, 
  675.  relations_count: 0, 
  676.  { value: 0.0 }, 
  677.  { range: { min: 0.0, 
  678. max: 0.0 } }, 
  679.  stepping: 1.0, 
  680.  type: UNICAP_PROPERTY_TYPE_FLAGS, 
  681.  flags: UNICAP_FLAGS_ONE_PUSH, 
  682.  flags_mask: UNICAP_FLAGS_ONE_PUSH, 
  683.  property_data: NULL, 
  684.  property_data_size: 0 }, 
  685.   register_offset: 0x54, 
  686.   register_inq: 0, 
  687.   register_default: 0, 
  688.   register_value: 0, 
  689.   type: PPTY_TYPE_REGISTER, 
  690.   set_function: dcam_set_software_trigger_property, 
  691.   get_function: dcam_get_software_trigger_property, 
  692.   init_function: dcam_init_software_trigger_property, 
  693.   feature_hi_mask: 0xffffffff, 
  694.   feature_lo_mask: 0xffffffff,
  695. },
  696. { id: DCAM_PPTY_TRIGGER_MODE, 
  697.   unicap_property: { identifier: N_("trigger_mode"), 
  698.  category: DCAM_CAT_VIDEO, 
  699.  unit: DCAM_UNIT_NONE, 
  700.  relations: dcam_trigger_mode_relations, 
  701.  relations_count: sizeof( dcam_trigger_mode_relations ) / sizeof( char * ),
  702.  { value: 0.0 }, 
  703.  { value_list: { values: NULL, 
  704.  value_count: 0 } },  
  705.  stepping: 0.0,  
  706.  type: UNICAP_PROPERTY_TYPE_MENU, 
  707.  flags: UNICAP_FLAGS_MANUAL, 
  708.  flags_mask: UNICAP_FLAGS_MANUAL, 
  709.  property_data: NULL, 
  710.  property_data_size: 0 }, 
  711.   register_offset: 0x030, 0, 0, 0, PPTY_TYPE_TRIGGER,
  712.   set_function: dcam_set_property,
  713.   get_function: dcam_get_property,
  714.   init_function: dcam_init_trigger_property,
  715.   feature_hi_mask: 1<<19, 
  716.   feature_lo_mask: 0,
  717. }, 
  718. { id: DCAM_PPTY_ZOOM,
  719.   unicap_property: { identifier: N_("zoom"),
  720.  category: DCAM_CAT_LENS,
  721.  unit: DCAM_UNIT_NONE,
  722.  relations: dcam_zoom_relations,
  723.  relations_count: sizeof( dcam_zoom_relations ) / sizeof( char * ),
  724.  { value: 0.0 },
  725.  { range: { min: 0.0,
  726. max: 0.0 } },
  727.  stepping: 0.0,
  728.  type: UNICAP_PROPERTY_TYPE_RANGE,
  729.  flags: UNICAP_FLAGS_MANUAL,
  730.  flags_mask: PPTY_MASK,
  731.  property_data: NULL,
  732.  property_data_size: 0 },
  733.   register_offset: 0x080,
  734.   register_inq: 0,
  735.   register_default: 0,
  736.   register_value: 0,
  737.   type: PPTY_TYPE_BRIGHTNESS,
  738.   set_function: dcam_set_property,
  739.   get_function: dcam_get_property,
  740.   init_function: dcam_init_brightness_property,
  741.   feature_hi_mask: 0,
  742.   feature_lo_mask: 1<<31,
  743. },
  744. { id: DCAM_PPTY_PAN, 
  745.   unicap_property: { identifier: /* TRANSLATORS: Lens pan */
  746.    N_("pan"), 
  747.  category: DCAM_CAT_LENS, 
  748.  unit: DCAM_UNIT_NONE, 
  749.  relations: dcam_pan_relations, 
  750.  relations_count: sizeof( dcam_pan_relations ) / sizeof( char * ),
  751.  { value: 0.0 }, 
  752.  { range: { min: 0.0, 
  753. max: 0.0 } },  
  754.  stepping: 0.0,  
  755.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  756.  flags: UNICAP_FLAGS_MANUAL, 
  757.  flags_mask: PPTY_MASK, 
  758.  property_data: NULL, 
  759.  property_data_size: 0 }, 
  760.   register_offset: 0x084, 
  761.   register_inq: 0, 
  762.   register_default: 0, 
  763.   register_value: 0, 
  764.   type: PPTY_TYPE_BRIGHTNESS,
  765.   set_function: dcam_set_property,
  766.   get_function: dcam_get_property,
  767.   init_function: dcam_init_brightness_property, 
  768.   feature_hi_mask: 0, 
  769.   feature_lo_mask: 1<<30,
  770. },
  771. { id: DCAM_PPTY_TILT, 
  772.   unicap_property: { identifier: /* TRANSLATORS: Lens tilt */
  773.      N_("tilt"), 
  774.      category: DCAM_CAT_LENS, 
  775.      unit: DCAM_UNIT_NONE, 
  776.      relations: dcam_tilt_relations, 
  777.      relations_count: sizeof( dcam_tilt_relations ) / sizeof( char * ),  
  778.      { value: 0.0 }, 
  779.      { range: { min: 0.0, 
  780. max: 0.0 } },  
  781.      stepping: 0.0,  
  782.      type: UNICAP_PROPERTY_TYPE_RANGE, 
  783.      flags: UNICAP_FLAGS_MANUAL, 
  784.      flags_mask: PPTY_MASK, 
  785.      property_data: NULL, 
  786.      property_data_size: 0 }, 
  787.   register_offset: 0x088, 
  788.   register_inq: 0, 
  789.   register_default: 0, 
  790.   register_value: 0, 
  791.   type: PPTY_TYPE_BRIGHTNESS,
  792.   set_function: dcam_set_property,
  793.   get_function: dcam_get_property,
  794.   init_function: dcam_init_brightness_property, 
  795.   feature_hi_mask: 0, 
  796.   feature_lo_mask: 1<<29,
  797. },
  798. { id: DCAM_PPTY_OPTICAL_FILTER, 
  799.   unicap_property: { identifier: N_("optical_filter"),  
  800.  category: DCAM_CAT_VIDEO, 
  801.  unit: DCAM_UNIT_NONE, 
  802.  relations: dcam_optical_filter_relations, 
  803.  relations_count: sizeof( dcam_optical_filter_relations ) / sizeof( char * ),
  804.  { value: 0.0 }, 
  805.  { range: { min: 0.0, 
  806. max: 0.0 } },  
  807.  stepping: 0.0,  
  808.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  809.  flags: UNICAP_FLAGS_MANUAL, 
  810.  flags_mask: PPTY_MASK, 
  811.  property_data: NULL, 
  812.  property_data_size: 0 }, 
  813.   register_offset: 0x08c, 
  814.   register_inq: 0, 
  815.   register_default: 0, 
  816.   register_value: 0, 
  817.   type: PPTY_TYPE_BRIGHTNESS,
  818.   set_function: dcam_set_property,
  819.   get_function: dcam_get_property,
  820.   init_function: dcam_init_brightness_property, 
  821.   feature_hi_mask: 0, 
  822.   feature_lo_mask: 1<<28,
  823. },
  824. { id: DCAM_PPTY_CAPTURE_QUALITY, 
  825.   unicap_property: { identifier: N_("capture_quality"), 
  826.  category: DCAM_CAT_VIDEO, 
  827.  unit: DCAM_UNIT_NONE, 
  828.  relations: dcam_capture_quality_relations, 
  829.  relations_count: sizeof( dcam_capture_quality_relations ) / sizeof( char * ),
  830.  { value: 0.0 }, 
  831.  { range: { min: 0.0, 
  832. max: 0.0 } },  
  833.  stepping: 0.0,  
  834.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  835.  flags: UNICAP_FLAGS_MANUAL, 
  836.  flags_mask: PPTY_MASK, 
  837.  property_data: NULL, 
  838.  property_data_size: 0 }, 
  839.   register_offset: 0x0c4, 
  840.   register_inq: 0, 
  841.   register_default: 0, 
  842.   register_value: 0, 
  843.   type: PPTY_TYPE_BRIGHTNESS,
  844.   set_function: dcam_set_property,
  845.   get_function: dcam_get_property,
  846.   init_function: dcam_init_brightness_property, 
  847.   feature_hi_mask: 0, 
  848.   feature_lo_mask: 1<<15,
  849. },
  850. { id: DCAM_PPTY_FRAME_RATE, 
  851.   unicap_property: { identifier: N_("frame rate"),
  852.  category: DCAM_CAT_VIDEO, 
  853.  unit: DCAM_UNIT_NONE, 
  854.  relations: dcam_frame_rate_relations, 
  855.  relations_count: sizeof( dcam_frame_rate_relations ) / sizeof( char * ), 
  856.  { value: 0.0 },
  857.  { range: { min: 0.0, 
  858. max: 0.0 } },
  859.  stepping: 0.0, 
  860.  type: UNICAP_PROPERTY_TYPE_VALUE_LIST, 
  861.  flags: UNICAP_FLAGS_MANUAL, 
  862.  flags_mask: UNICAP_FLAGS_MANUAL, 
  863.  property_data: NULL, 
  864.  property_data_size: 0 }, 
  865.   register_offset: 0, 
  866.   register_inq: 0, 
  867.   register_default: 0, 
  868.   register_value: 0, 
  869.   type: PPTY_TYPE_FRAMERATE, 
  870.   set_function: dcam_set_frame_rate_property, 
  871.   get_function: dcam_get_frame_rate_property, 
  872.   init_function: dcam_init_frame_rate_property, 
  873.   feature_hi_mask: 0xffffffff, 
  874.   feature_lo_mask: 0xffffffff,
  875. }, 
  876. { id: DCAM_PPTY_RW_REGISTER, 
  877.   unicap_property: { identifier: /* TRANSLATORS: Camera
  878.     hardware register */
  879.      N_("register"), 
  880.      category: DCAM_CAT_VIDEO, 
  881.      unit: DCAM_UNIT_NONE, 
  882.      relations: dcam_register_relations, 
  883.      relations_count: sizeof( dcam_register_relations ) / sizeof( char * ), 
  884.      { value: 0.0 }, 
  885.      { range: { min: 0.0, 
  886. max: 0.0 } }, 
  887.      stepping: 0.0, 
  888.      type: UNICAP_PROPERTY_TYPE_DATA, 
  889.      flags: UNICAP_FLAGS_MANUAL, 
  890.      flags_mask: UNICAP_FLAGS_MANUAL, 
  891.      property_data: NULL, 
  892.      property_data_size: 0 }, 
  893.   register_offset: 0, 
  894.   register_inq: 0, 
  895.   register_default: 0, 
  896.   register_value: 0, 
  897.   type: PPTY_TYPE_REGISTER, 
  898.   set_function: dcam_set_property, 
  899.   get_function: dcam_get_property, 
  900.   init_function: dcam_init_rw_register_property, 
  901.   feature_hi_mask: 0xffffffff, 
  902.   feature_lo_mask: 0xffffffff,
  903. },   
  904. { id: DCAM_PPTY_TIMEOUT, 
  905.   unicap_property: { identifier: N_("timeout"), 
  906.  category: DCAM_CAT_DEVICE, 
  907.  relations: dcam_timeout_relations, 
  908.  relations_count: sizeof( dcam_timeout_relations ) / sizeof( char * ), 
  909.  { value: 1.0 }, 
  910.  { range: { min: 0.0, 
  911. max: 600.0 } }, 
  912.  stepping: 1.0, 
  913.  type: UNICAP_PROPERTY_TYPE_RANGE, 
  914.  flags: UNICAP_FLAGS_MANUAL, 
  915.  flags_mask: UNICAP_FLAGS_MANUAL, 
  916.  property_data: NULL, 
  917.  property_data_size: 0 }, 
  918.   register_offset: 0, 
  919.   register_inq: 0, 
  920.   register_default: 0, 
  921.   register_value: 0, 
  922.   type: PPTY_TYPE_REGISTER, 
  923.   set_function: dcam_set_timeout_property, 
  924.   get_function: dcam_get_timeout_property, 
  925.   init_function: dcam_init_timeout_property, 
  926.   feature_hi_mask: 0xffffffff, 
  927.   feature_lo_mask: 0xffffffff,
  928. },   
  929. { id: DCAM_PPTY_GPIO, 
  930.   unicap_property: { identifier: N_("gpio"), 
  931.  category: DCAM_CAT_DEVICE, 
  932.  relations: dcam_timeout_relations, 
  933.  relations_count: sizeof( dcam_timeout_relations ) / sizeof( char * ), 
  934.  { value: 0.0 }, 
  935.  { range: { min: 0.0, 
  936. max: 0.0 } }, 
  937.  stepping: 1.0, 
  938.  type: UNICAP_PROPERTY_TYPE_DATA, 
  939.  flags: UNICAP_FLAGS_MANUAL, 
  940.  flags_mask: UNICAP_FLAGS_MANUAL, 
  941.  property_data: NULL, 
  942.  property_data_size: 0 }, 
  943.   register_offset: 0x38, 
  944.   register_inq: 0, 
  945.   register_default: 0, 
  946.   register_value: 0, 
  947.   type: PPTY_TYPE_REGISTER, 
  948.   set_function: dcam_set_gpio_property, 
  949.   get_function: dcam_get_gpio_property, 
  950.   init_function: dcam_init_gpio_property, 
  951.   feature_hi_mask: 0xffffffff, 
  952.   feature_lo_mask: 0xffffffff,
  953. },
  954. {
  955. id: DCAM_PPTY_END
  956. }
  957. };
  958. #endif//__DCAM_PROPERTY_TABLE_H__