vidioc-g-dv-timings.xml 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224
  1. <refentry id="vidioc-g-dv-timings">
  2. <refmeta>
  3. <refentrytitle>ioctl VIDIOC_G_DV_TIMINGS, VIDIOC_S_DV_TIMINGS</refentrytitle>
  4. &manvol;
  5. </refmeta>
  6. <refnamediv>
  7. <refname>VIDIOC_G_DV_TIMINGS</refname>
  8. <refname>VIDIOC_S_DV_TIMINGS</refname>
  9. <refpurpose>Get or set custom DV timings for input or output</refpurpose>
  10. </refnamediv>
  11. <refsynopsisdiv>
  12. <funcsynopsis>
  13. <funcprototype>
  14. <funcdef>int <function>ioctl</function></funcdef>
  15. <paramdef>int <parameter>fd</parameter></paramdef>
  16. <paramdef>int <parameter>request</parameter></paramdef>
  17. <paramdef>&v4l2-dv-timings;
  18. *<parameter>argp</parameter></paramdef>
  19. </funcprototype>
  20. </funcsynopsis>
  21. </refsynopsisdiv>
  22. <refsect1>
  23. <title>Arguments</title>
  24. <variablelist>
  25. <varlistentry>
  26. <term><parameter>fd</parameter></term>
  27. <listitem>
  28. <para>&fd;</para>
  29. </listitem>
  30. </varlistentry>
  31. <varlistentry>
  32. <term><parameter>request</parameter></term>
  33. <listitem>
  34. <para>VIDIOC_G_DV_TIMINGS, VIDIOC_S_DV_TIMINGS</para>
  35. </listitem>
  36. </varlistentry>
  37. <varlistentry>
  38. <term><parameter>argp</parameter></term>
  39. <listitem>
  40. <para></para>
  41. </listitem>
  42. </varlistentry>
  43. </variablelist>
  44. </refsect1>
  45. <refsect1>
  46. <title>Description</title>
  47. <para>To set custom DV timings for the input or output, applications use the
  48. <constant>VIDIOC_S_DV_TIMINGS</constant> ioctl and to get the current custom timings,
  49. applications use the <constant>VIDIOC_G_DV_TIMINGS</constant> ioctl. The detailed timing
  50. information is filled in using the structure &v4l2-dv-timings;. These ioctls take
  51. a pointer to the &v4l2-dv-timings; structure as argument. If the ioctl is not supported
  52. or the timing values are not correct, the driver returns &EINVAL;.</para>
  53. </refsect1>
  54. <refsect1>
  55. &return-value;
  56. <variablelist>
  57. <varlistentry>
  58. <term><errorcode>EINVAL</errorcode></term>
  59. <listitem>
  60. <para>This ioctl is not supported, or the
  61. <constant>VIDIOC_S_DV_TIMINGS</constant> parameter was unsuitable.</para>
  62. </listitem>
  63. </varlistentry>
  64. <varlistentry>
  65. <term><errorcode>EBUSY</errorcode></term>
  66. <listitem>
  67. <para>The device is busy and therefore can not change the timings.</para>
  68. </listitem>
  69. </varlistentry>
  70. </variablelist>
  71. <table pgwide="1" frame="none" id="v4l2-bt-timings">
  72. <title>struct <structname>v4l2_bt_timings</structname></title>
  73. <tgroup cols="3">
  74. &cs-str;
  75. <tbody valign="top">
  76. <row>
  77. <entry>__u32</entry>
  78. <entry><structfield>width</structfield></entry>
  79. <entry>Width of the active video in pixels</entry>
  80. </row>
  81. <row>
  82. <entry>__u32</entry>
  83. <entry><structfield>height</structfield></entry>
  84. <entry>Height of the active video in lines</entry>
  85. </row>
  86. <row>
  87. <entry>__u32</entry>
  88. <entry><structfield>interlaced</structfield></entry>
  89. <entry>Progressive (0) or interlaced (1)</entry>
  90. </row>
  91. <row>
  92. <entry>__u32</entry>
  93. <entry><structfield>polarities</structfield></entry>
  94. <entry>This is a bit mask that defines polarities of sync signals.
  95. bit 0 (V4L2_DV_VSYNC_POS_POL) is for vertical sync polarity and bit 1 (V4L2_DV_HSYNC_POS_POL) is for horizontal sync polarity. If the bit is set
  96. (1) it is positive polarity and if is cleared (0), it is negative polarity.</entry>
  97. </row>
  98. <row>
  99. <entry>__u64</entry>
  100. <entry><structfield>pixelclock</structfield></entry>
  101. <entry>Pixel clock in Hz. Ex. 74.25MHz->74250000</entry>
  102. </row>
  103. <row>
  104. <entry>__u32</entry>
  105. <entry><structfield>hfrontporch</structfield></entry>
  106. <entry>Horizontal front porch in pixels</entry>
  107. </row>
  108. <row>
  109. <entry>__u32</entry>
  110. <entry><structfield>hsync</structfield></entry>
  111. <entry>Horizontal sync length in pixels</entry>
  112. </row>
  113. <row>
  114. <entry>__u32</entry>
  115. <entry><structfield>hbackporch</structfield></entry>
  116. <entry>Horizontal back porch in pixels</entry>
  117. </row>
  118. <row>
  119. <entry>__u32</entry>
  120. <entry><structfield>vfrontporch</structfield></entry>
  121. <entry>Vertical front porch in lines</entry>
  122. </row>
  123. <row>
  124. <entry>__u32</entry>
  125. <entry><structfield>vsync</structfield></entry>
  126. <entry>Vertical sync length in lines</entry>
  127. </row>
  128. <row>
  129. <entry>__u32</entry>
  130. <entry><structfield>vbackporch</structfield></entry>
  131. <entry>Vertical back porch in lines</entry>
  132. </row>
  133. <row>
  134. <entry>__u32</entry>
  135. <entry><structfield>il_vfrontporch</structfield></entry>
  136. <entry>Vertical front porch in lines for bottom field of interlaced field formats</entry>
  137. </row>
  138. <row>
  139. <entry>__u32</entry>
  140. <entry><structfield>il_vsync</structfield></entry>
  141. <entry>Vertical sync length in lines for bottom field of interlaced field formats</entry>
  142. </row>
  143. <row>
  144. <entry>__u32</entry>
  145. <entry><structfield>il_vbackporch</structfield></entry>
  146. <entry>Vertical back porch in lines for bottom field of interlaced field formats</entry>
  147. </row>
  148. </tbody>
  149. </tgroup>
  150. </table>
  151. <table pgwide="1" frame="none" id="v4l2-dv-timings">
  152. <title>struct <structname>v4l2_dv_timings</structname></title>
  153. <tgroup cols="4">
  154. &cs-str;
  155. <tbody valign="top">
  156. <row>
  157. <entry>__u32</entry>
  158. <entry><structfield>type</structfield></entry>
  159. <entry></entry>
  160. <entry>Type of DV timings as listed in <xref linkend="dv-timing-types"/>.</entry>
  161. </row>
  162. <row>
  163. <entry>union</entry>
  164. <entry><structfield></structfield></entry>
  165. <entry></entry>
  166. </row>
  167. <row>
  168. <entry></entry>
  169. <entry>&v4l2-bt-timings;</entry>
  170. <entry><structfield>bt</structfield></entry>
  171. <entry>Timings defined by BT.656/1120 specifications</entry>
  172. </row>
  173. <row>
  174. <entry></entry>
  175. <entry>__u32</entry>
  176. <entry><structfield>reserved</structfield>[32]</entry>
  177. <entry></entry>
  178. </row>
  179. </tbody>
  180. </tgroup>
  181. </table>
  182. <table pgwide="1" frame="none" id="dv-timing-types">
  183. <title>DV Timing types</title>
  184. <tgroup cols="3">
  185. &cs-str;
  186. <tbody valign="top">
  187. <row>
  188. <entry>Timing type</entry>
  189. <entry>value</entry>
  190. <entry>Description</entry>
  191. </row>
  192. <row>
  193. <entry></entry>
  194. <entry></entry>
  195. <entry></entry>
  196. </row>
  197. <row>
  198. <entry>V4L2_DV_BT_656_1120</entry>
  199. <entry>0</entry>
  200. <entry>BT.656/1120 timings</entry>
  201. </row>
  202. </tbody>
  203. </tgroup>
  204. </table>
  205. </refsect1>
  206. </refentry>
  207. <!--
  208. Local Variables:
  209. mode: sgml
  210. sgml-parent-document: "v4l2.sgml"
  211. indent-tabs-mode: nil
  212. End:
  213. -->