€•G.Œsphinx.addnodes”Œdocument”“”)”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)”}”(hhh]”(hŒ pending_xref”“”)”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…””}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ1/translations/zh_CN/userspace-api/media/v4l/video”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)”}”(hhh]”hŒChinese (Traditional)”…””}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/zh_TW/userspace-api/media/v4l/video”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒItalian”…””}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/it_IT/userspace-api/media/v4l/video”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒJapanese”…””}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/ja_JP/userspace-api/media/v4l/video”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒKorean”…””}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/ko_KR/userspace-api/media/v4l/video”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)”}”(hhh]”hŒSpanish”…””}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ1/translations/sp_SP/userspace-api/media/v4l/video”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒcomment”“”)”}”(hŒ8SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later”h]”hŒ8SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later”…””}”hh£sbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1h¡hhhžhhŸŒK/var/lib/git/docbuild/linux/Documentation/userspace-api/media/v4l/video.rst”h KubhŒtarget”“”)”}”(hŒ .. _video:”h]”h}”(h]”h ]”h"]”h$]”h&]”Œrefid”Œvideo”uh1h´h KhhhžhhŸh³ubhŒsection”“”)”}”(hhh]”(hŒtitle”“”)”}”(hŒVideo Inputs and Outputs”h]”hŒVideo Inputs and Outputs”…””}”(hhÉhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÇhhÄhžhhŸh³h KubhŒ paragraph”“”)”}”(hXVideo inputs and outputs are physical connectors of a device. These can be for example: RF connectors (antenna/cable), CVBS a.k.a. Composite Video, S-Video and RGB connectors. Camera sensors are also considered to be a video input. Video and VBI capture devices have inputs. Video and VBI output devices have outputs, at least one each. Radio devices have no video inputs or outputs.”h]”hXVideo inputs and outputs are physical connectors of a device. These can be for example: RF connectors (antenna/cable), CVBS a.k.a. Composite Video, S-Video and RGB connectors. Camera sensors are also considered to be a video input. Video and VBI capture devices have inputs. Video and VBI output devices have outputs, at least one each. Radio devices have no video inputs or outputs.”…””}”(hhÙhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h K hhÄhžhubhØ)”}”(hXiTo learn about the number and attributes of the available inputs and outputs applications can enumerate them with the :ref:`VIDIOC_ENUMINPUT` and :ref:`VIDIOC_ENUMOUTPUT` ioctl, respectively. The struct :c:type:`v4l2_input` returned by the :ref:`VIDIOC_ENUMINPUT` ioctl also contains signal status information applicable when the current video input is queried.”h]”(hŒvTo learn about the number and attributes of the available inputs and outputs applications can enumerate them with the ”…””}”(hhçhžhhŸNh Nubh)”}”(hŒ:ref:`VIDIOC_ENUMINPUT`”h]”hŒinline”“”)”}”(hhñh]”hŒVIDIOC_ENUMINPUT”…””}”(hhõhžhhŸNh Nubah}”(h]”h ]”(Œxref”Œstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhhïubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”Œuserspace-api/media/v4l/video”Œ refdomain”jŒreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆŒ reftarget”Œvidioc_enuminput”uh1hhŸh³h KhhçubhŒ and ”…””}”(hhçhžhhŸNh Nubh)”}”(hŒ:ref:`VIDIOC_ENUMOUTPUT`”h]”hô)”}”(hjh]”hŒVIDIOC_ENUMOUTPUT”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”(hÿŒstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhjubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”j&Œreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆjŒvidioc_enumoutput”uh1hhŸh³h KhhçubhŒ! ioctl, respectively. The struct ”…””}”(hhçhžhhŸNh Nubh)”}”(hŒ:c:type:`v4l2_input`”h]”hŒliteral”“”)”}”(hj>h]”hŒ v4l2_input”…””}”(hjBhžhhŸNh Nubah}”(h]”h ]”(hÿŒc”Œc-type”eh"]”h$]”h&]”uh1j@hj<ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jLŒreftype”Œtype”Œ refexplicit”‰Œrefwarn”‰jŒ v4l2_input”uh1hhŸh³h KhhçubhŒ returned by the ”…””}”(hhçhžhhŸNh Nubh)”}”(hŒ:ref:`VIDIOC_ENUMINPUT`”h]”hô)”}”(hjdh]”hŒVIDIOC_ENUMINPUT”…””}”(hjfhžhhŸNh Nubah}”(h]”h ]”(hÿŒstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhjbubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jpŒreftype”Œref”Œ refexplicit”‰Œrefwarn”ˆjŒvidioc_enuminput”uh1hhŸh³h KhhçubhŒb ioctl also contains signal status information applicable when the current video input is queried.”…””}”(hhçhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h KhhÄhžhubhØ)”}”(hXÀThe :ref:`VIDIOC_G_INPUT ` and :ref:`VIDIOC_G_OUTPUT ` ioctls return the index of the current video input or output. To select a different input or output applications call the :ref:`VIDIOC_S_INPUT ` and :ref:`VIDIOC_S_OUTPUT ` ioctls. Drivers must implement all the input ioctls when the device has one or more inputs, all the output ioctls when the device has one or more outputs.”h]”(hŒThe ”…””}”(hjŒhžhhŸNh Nubh)”}”(hŒ&:ref:`VIDIOC_G_INPUT `”h]”hô)”}”(hj–h]”hŒVIDIOC_G_INPUT”…””}”(hj˜hžhhŸNh Nubah}”(h]”h ]”(hÿŒstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhj”ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”j¢Œreftype”Œref”Œ refexplicit”ˆŒrefwarn”ˆjŒvidioc_g_input”uh1hhŸh³h KhjŒubhŒ and ”…””}”(hjŒhžhhŸNh Nubh)”}”(hŒ(:ref:`VIDIOC_G_OUTPUT `”h]”hô)”}”(hjºh]”hŒVIDIOC_G_OUTPUT”…””}”(hj¼hžhhŸNh Nubah}”(h]”h ]”(hÿŒstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhj¸ubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jÆŒreftype”Œref”Œ refexplicit”ˆŒrefwarn”ˆjŒvidioc_g_output”uh1hhŸh³h KhjŒubhŒ{ ioctls return the index of the current video input or output. To select a different input or output applications call the ”…””}”(hjŒhžhhŸNh Nubh)”}”(hŒ&:ref:`VIDIOC_S_INPUT `”h]”hô)”}”(hjÞh]”hŒVIDIOC_S_INPUT”…””}”(hjàhžhhŸNh Nubah}”(h]”h ]”(hÿŒstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhjÜubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jêŒreftype”Œref”Œ refexplicit”ˆŒrefwarn”ˆjŒvidioc_g_input”uh1hhŸh³h KhjŒubhŒ and ”…””}”hjŒsbh)”}”(hŒ(:ref:`VIDIOC_S_OUTPUT `”h]”hô)”}”(hjh]”hŒVIDIOC_S_OUTPUT”…””}”(hjhžhhŸNh Nubah}”(h]”h ]”(hÿŒstd”Œstd-ref”eh"]”h$]”h&]”uh1hóhjubah}”(h]”h ]”h"]”h$]”h&]”Œrefdoc”j Œ refdomain”jŒreftype”Œref”Œ refexplicit”ˆŒrefwarn”ˆjŒvidioc_g_output”uh1hhŸh³h KhjŒubhŒ› ioctls. Drivers must implement all the input ioctls when the device has one or more inputs, all the output ioctls when the device has one or more outputs.”…””}”(hjŒhžhhŸNh Nubeh}”(h]”h ]”h"]”h$]”h&]”uh1h×hŸh³h KhhÄhžhubhÃ)”}”(hhh]”(hÈ)”}”(hŒ2Example: Information about the current video input”h]”hŒ2Example: Information about the current video input”…””}”(hj-hžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÇhj*hžhhŸh³h K!ubhŒ literal_block”“”)”}”(hX\struct v4l2_input input; int index; if (-1 == ioctl(fd, VIDIOC_G_INPUT, &index)) { perror("VIDIOC_G_INPUT"); exit(EXIT_FAILURE); } memset(&input, 0, sizeof(input)); input.index = index; if (-1 == ioctl(fd, VIDIOC_ENUMINPUT, &input)) { perror("VIDIOC_ENUMINPUT"); exit(EXIT_FAILURE); } printf("Current input: %s\\n", input.name);”h]”hX\struct v4l2_input input; int index; if (-1 == ioctl(fd, VIDIOC_G_INPUT, &index)) { perror("VIDIOC_G_INPUT"); exit(EXIT_FAILURE); } memset(&input, 0, sizeof(input)); input.index = index; if (-1 == ioctl(fd, VIDIOC_ENUMINPUT, &input)) { perror("VIDIOC_ENUMINPUT"); exit(EXIT_FAILURE); } printf("Current input: %s\\n", input.name);”…””}”hj=sbah}”(h]”h ]”h"]”h$]”h&]”h±h²Œforce”‰Œlanguage”jLŒhighlight_args”}”uh1j;hŸh³h K#hj*hžhubeh}”(h]”Œ1example-information-about-the-current-video-input”ah ]”h"]”Œ2example: information about the current video input”ah$]”h&]”uh1hÂhhÄhžhhŸh³h K!ubhÃ)”}”(hhh]”(hÈ)”}”(hŒ+Example: Switching to the first video input”h]”hŒ+Example: Switching to the first video input”…””}”(hjZhžhhŸNh Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hÇhjWhžhhŸh³h K9ubj<)”}”(hŒ~int index; index = 0; if (-1 == ioctl(fd, VIDIOC_S_INPUT, &index)) { perror("VIDIOC_S_INPUT"); exit(EXIT_FAILURE); }”h]”hŒ~int index; index = 0; if (-1 == ioctl(fd, VIDIOC_S_INPUT, &index)) { perror("VIDIOC_S_INPUT"); exit(EXIT_FAILURE); }”…””}”hjhsbah}”(h]”h ]”h"]”h$]”h&]”h±h²jK‰jLjLjM}”uh1j;hŸh³h K;hjWhžhubeh}”(h]”Œ*example-switching-to-the-first-video-input”ah ]”h"]”Œ+example: switching to the first video input”ah$]”h&]”uh1hÂhhÄhžhhŸh³h K9ubeh}”(h]”(Œvideo-inputs-and-outputs”hÁeh ]”h"]”(Œvideo inputs and outputs”Œvideo”eh$]”h&]”uh1hÂhhhžhhŸh³h KŒexpect_referenced_by_name”}”j…h¶sŒexpect_referenced_by_id”}”hÁh¶subeh}”(h]”h ]”h"]”h$]”h&]”Œsource”h³uh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)”}”(hÇNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”j¯Œerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”h³Œ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”hÁ]”h¶asŒnameids”}”(j…hÁj„jjTjQj|jyuŒ nametypes”}”(j…ˆj„‰jT‰j|‰uh}”(hÁhÄjhÄjQj*jyjWuŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”hŒsystem_message”“”)”}”(hhh]”hØ)”}”(hhh]”hŒ+Hyperlink target "video" is not referenced.”…””}”hjsbah}”(h]”h ]”h"]”h$]”h&]”uh1h×hjubah}”(h]”h ]”h"]”h$]”h&]”Œlevel”KŒtype”ŒINFO”Œsource”h³Œline”Kuh1jubaŒ transformer”NŒ include_log”]”Œ decoration”Nhžhub.