code:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later -->
<svg
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:cc="http://creativecommons.org/ns#"
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:svg="http://www.w3.org/2000/svg"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   version="1.2"
   width="96.282211mm"
   height="28.282219mm"
   viewBox="0 0 9628.2211 2828.2219"
   preserveAspectRatio="xMidYMid"
   xml:space="preserve"
   id="svg2"
   inkscape:version="0.91 r13725"
   sodipodi:docname="nv12mt.svg"
   style="fill-rule:evenodd;stroke-width:28.22200012;stroke-linejoin:round"><metadata
     id="metadata383"><rdf:RDF><cc:Work
	 rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
	   rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><sodipodi:namedview
     pagecolor="#ffffff"
     bordercolor="#666666"
     borderopacity="1"
     objecttolerance="10"
     gridtolerance="10"
     guidetolerance="10"
     inkscape:pageopacity="0"
     inkscape:pageshadow="2"
     inkscape:window-width="1920"
     inkscape:window-height="997"
     id="namedview381"
     showgrid="false"
     fit-margin-top="0"
     fit-margin-left="0"
     fit-margin-right="0"
     fit-margin-bottom="0"
     inkscape:zoom="4.0919524"
     inkscape:cx="170.57872"
     inkscape:cy="50.106293"
     inkscape:window-x="1920"
     inkscape:window-y="30"
     inkscape:window-maximized="1"
     inkscape:current-layer="svg2" /><defs
     class="ClipPathGroup"
     id="defs4"><clipPath
       id="presentation_clip_path"
       clipPathUnits="userSpaceOnUse"><rect
	 x="0"
	 y="0"
	 width="28000"
	 height="21000"
	 id="rect7" /></clipPath></defs><defs
     id="defs9" /><defs
     id="defs80" /><defs
     id="defs103" /><defs
     class="TextShapeIndex"
     id="defs114" /><defs
     class="EmbeddedBulletChars"
     id="defs118" /><defs
     class="TextEmbeddedBitmaps"
     id="defs147" /><g
     class="SlideGroup"
     id="g177"
     transform="translate(-3285.889,-3185.889)"><g
       id="g179"><g
	 id="id1"
	 class="Slide"
	 clip-path="url(#presentation_clip_path)"><g
	   class="Page"
	   id="g182"><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g184"><g
	       id="id6"><rect
		 class="BoundingBox"
		 x="3299"
		 y="3199"
		 width="2403"
		 height="1403"
		 id="rect187"
		 style="fill:none;stroke:none" /><path
		 d="m 4500,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path189"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text191"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan193"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="4325"
		     y="4121"
		     id="tspan195"><tspan
		       id="tspan197"
		       style="fill:#000000;stroke:none">0</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g199"><g
	       id="id7"><rect
		 class="BoundingBox"
		 x="5699"
		 y="3199"
		 width="2403"
		 height="1403"
		 id="rect202"
		 style="fill:none;stroke:none" /><path
		 d="m 6900,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path204"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /></g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g206"><g
	       id="id8"><rect
		 class="BoundingBox"
		 x="8099"
		 y="3199"
		 width="2403"
		 height="1403"
		 id="rect209"
		 style="fill:none;stroke:none" /><path
		 d="m 9300,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path211"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text213"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan215"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="9125"
		     y="4121"
		     id="tspan217"><tspan
		       id="tspan219"
		       style="fill:#000000;stroke:none">6</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g221"><g
	       id="id9"><rect
		 class="BoundingBox"
		 x="5699"
		 y="3199"
		 width="2403"
		 height="1403"
		 id="rect224"
		 style="fill:none;stroke:none" /><path
		 d="m 6900,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path226"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text228"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan230"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="6725"
		     y="4121"
		     id="tspan232"><tspan
		       id="tspan234"
		       style="fill:#000000;stroke:none">1</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g236"><g
	       id="id10"><rect
		 class="BoundingBox"
		 x="10499"
		 y="3199"
		 width="2403"
		 height="1403"
		 id="rect239"
		 style="fill:none;stroke:none" /><path
		 d="m 11700,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path241"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text243"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan245"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="11525"
		     y="4121"
		     id="tspan247"><tspan
		       id="tspan249"
		       style="fill:#000000;stroke:none">7</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g251"><g
	       id="id11"><rect
		 class="BoundingBox"
		 x="3299"
		 y="4599"
		 width="2403"
		 height="1403"
		 id="rect254"
		 style="fill:none;stroke:none" /><path
		 d="m 4500,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path256"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text258"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan260"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="4325"
		     y="5521"
		     id="tspan262"><tspan
		       id="tspan264"
		       style="fill:#000000;stroke:none">2</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g266"><g
	       id="id12"><rect
		 class="BoundingBox"
		 x="5699"
		 y="4599"
		 width="2403"
		 height="1403"
		 id="rect269"
		 style="fill:none;stroke:none" /><path
		 d="m 6900,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path271"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /></g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g273"><g
	       id="id13"><rect
		 class="BoundingBox"
		 x="8099"
		 y="4599"
		 width="2403"
		 height="1403"
		 id="rect276"
		 style="fill:none;stroke:none" /><path
		 d="m 9300,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path278"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text280"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan282"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="9125"
		     y="5521"
		     id="tspan284"><tspan
		       id="tspan286"
		       style="fill:#000000;stroke:none">4</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g288"><g
	       id="id14"><rect
		 class="BoundingBox"
		 x="5699"
		 y="4599"
		 width="2403"
		 height="1403"
		 id="rect291"
		 style="fill:none;stroke:none" /><path
		 d="m 6900,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path293"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text295"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan297"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="6725"
		     y="5521"
		     id="tspan299"><tspan
		       id="tspan301"
		       style="fill:#000000;stroke:none">3</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.CustomShape"
	     id="g303"><g
	       id="id15"><rect
		 class="BoundingBox"
		 x="10499"
		 y="4599"
		 width="2403"
		 height="1403"
		 id="rect306"
		 style="fill:none;stroke:none" /><path
		 d="m 11700,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
		 id="path308"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#3465a4" /><text
		 class="TextShape"
		 id="text310"><tspan
		   class="TextParagraph"
		   font-size="635px"
		   font-weight="400"
		   id="tspan312"
		   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
		     class="TextPosition"
		     x="11525"
		     y="5521"
		     id="tspan314"><tspan
		       id="tspan316"
		       style="fill:#000000;stroke:none">5</tspan></tspan></tspan></text>
</g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g318"><g
	       id="id16"><rect
		 class="BoundingBox"
		 x="5199"
		 y="3850"
		 width="1402"
		 height="301"
		 id="rect321"
		 style="fill:none;stroke:none" /><path
		 d="m 5200,4000 970,0"
		 id="path323"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 6600,4000 -450,-150 0,300 450,-150 z"
		 id="path325"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g327"><g
	       id="id17"><rect
		 class="BoundingBox"
		 x="5000"
		 y="4299"
		 width="1202"
		 height="802"
		 id="rect330"
		 style="fill:none;stroke:none" /><path
		 d="m 6200,4300 -842,561"
		 id="path332"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 5000,5100 458,-125 -167,-249 -291,374 z"
		 id="path334"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g336"><g
	       id="id18"><rect
		 class="BoundingBox"
		 x="5399"
		 y="5250"
		 width="1202"
		 height="301"
		 id="rect339"
		 style="fill:none;stroke:none" /><path
		 d="m 5400,5400 770,0"
		 id="path341"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 6600,5400 -450,-150 0,300 450,-150 z"
		 id="path343"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g345"><g
	       id="id19"><rect
		 class="BoundingBox"
		 x="7599"
		 y="5250"
		 width="1202"
		 height="301"
		 id="rect348"
		 style="fill:none;stroke:none" /><path
		 d="m 7600,5400 770,0"
		 id="path350"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 8800,5400 -450,-150 0,300 450,-150 z"
		 id="path352"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g354"><g
	       id="id20"><rect
		 class="BoundingBox"
		 x="9799"
		 y="5250"
		 width="1402"
		 height="301"
		 id="rect357"
		 style="fill:none;stroke:none" /><path
		 d="m 9800,5400 970,0"
		 id="path359"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 11200,5400 -450,-150 0,300 450,-150 z"
		 id="path361"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g363"><g
	       id="id21"><rect
		 class="BoundingBox"
		 x="9900"
		 y="4200"
		 width="1202"
		 height="802"
		 id="rect366"
		 style="fill:none;stroke:none" /><path
		 d="m 11100,5000 -842,-561"
		 id="path368"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 9900,4200 291,374 167,-249 -458,-125 z"
		 id="path370"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g><g
	     class="com.sun.star.drawing.LineShape"
	     id="g372"><g
	       id="id22"><rect
		 class="BoundingBox"
		 x="9999"
		 y="3850"
		 width="1402"
		 height="301"
		 id="rect375"
		 style="fill:none;stroke:none" /><path
		 d="m 10000,4000 970,0"
		 id="path377"
		 inkscape:connector-curvature="0"
		 style="fill:none;stroke:#ff3333" /><path
		 d="m 11400,4000 -450,-150 0,300 450,-150 z"
		 id="path379"
		 inkscape:connector-curvature="0"
		 style="fill:#ff3333;stroke:none" /></g></g></g></g></g></g></svg>


code:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later -->
<svg
   xmlns:dc="http://purl.org/dc/elements/1.1/"
   xmlns:cc="http://creativecommons.org/ns#"
   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
   xmlns:svg="http://www.w3.org/2000/svg"
   xmlns="http://www.w3.org/2000/svg"
   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
   version="1.2"
   width="144.28223mm"
   height="70.282227mm"
   viewBox="0 0 14428.222 7028.2226"
   preserveAspectRatio="xMidYMid"
   xml:space="preserve"
   id="svg2"
   inkscape:version="0.91 r13725"
   sodipodi:docname="nv12mt_example.svg"
   style="fill-rule:evenodd;stroke-width:28.22200012;stroke-linejoin:round"><metadata
     id="metadata953"><rdf:RDF><cc:Work
	 rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type
	   rdf:resource="http://purl.org/dc/dcmitype/StillImage" /><dc:title></dc:title></cc:Work></rdf:RDF></metadata><sodipodi:namedview
     pagecolor="#ffffff"
     bordercolor="#666666"
     borderopacity="1"
     objecttolerance="10"
     gridtolerance="10"
     guidetolerance="10"
     inkscape:pageopacity="0"
     inkscape:pageshadow="2"
     inkscape:window-width="1920"
     inkscape:window-height="997"
     id="namedview951"
     showgrid="false"
     fit-margin-top="0"
     fit-margin-left="0"
     fit-margin-right="0"
     fit-margin-bottom="0"
     inkscape:zoom="2.7306359"
     inkscape:cx="255.61812"
     inkscape:cy="124.51576"
     inkscape:window-x="1920"
     inkscape:window-y="30"
     inkscape:window-maximized="1"
     inkscape:current-layer="svg2" /><defs
     class="ClipPathGroup"
     id="defs4" /><defs
     id="defs9" /><defs
     id="defs84" /><defs
     id="defs107" /><defs
     class="TextShapeIndex"
     id="defs118" /><defs
     class="EmbeddedBulletChars"
     id="defs122" /><defs
     class="TextEmbeddedBitmaps"
     id="defs151" /><g
     class="com.sun.star.drawing.CustomShape"
     id="g188"
     transform="translate(-3285.889,-3185.889)"><g
       id="id6"><rect
	 class="BoundingBox"
	 x="3299"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect191"
	 style="fill:none;stroke:none" /><path
	 d="m 4500,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path193"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text195"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan197"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="4325"
	     y="4121"
	     id="tspan199"><tspan
	       id="tspan201"
	       style="fill:#000000;stroke:none">0</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g203"
     transform="translate(-3285.889,-3185.889)"><g
       id="id7"><rect
	 class="BoundingBox"
	 x="5699"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect206"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path208"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g210"
     transform="translate(-3285.889,-3185.889)"><g
       id="id8"><rect
	 class="BoundingBox"
	 x="8099"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect213"
	 style="fill:none;stroke:none" /><path
	 d="m 9300,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path215"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text217"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan219"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="9125"
	     y="4121"
	     id="tspan221"><tspan
	       id="tspan223"
	       style="fill:#000000;stroke:none">6</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g225"
     transform="translate(-3285.889,-3185.889)"><g
       id="id9"><rect
	 class="BoundingBox"
	 x="5699"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect228"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path230"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text232"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan234"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="6725"
	     y="4121"
	     id="tspan236"><tspan
	       id="tspan238"
	       style="fill:#000000;stroke:none">1</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g240"
     transform="translate(-3285.889,-3185.889)"><g
       id="id10"><rect
	 class="BoundingBox"
	 x="10499"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect243"
	 style="fill:none;stroke:none" /><path
	 d="m 11700,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path245"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text247"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan249"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="11525"
	     y="4121"
	     id="tspan251"><tspan
	       id="tspan253"
	       style="fill:#000000;stroke:none">7</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g255"
     transform="translate(-3285.889,-3185.889)"><g
       id="id11"><rect
	 class="BoundingBox"
	 x="12899"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect258"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path260"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g262"
     transform="translate(-3285.889,-3185.889)"><g
       id="id12"><rect
	 class="BoundingBox"
	 x="15299"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect265"
	 style="fill:none;stroke:none" /><path
	 d="m 16500,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path267"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text269"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan271"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="16325"
	     y="4121"
	     id="tspan273"><tspan
	       id="tspan275"
	       style="fill:#000000;stroke:none">9</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g277"
     transform="translate(-3285.889,-3185.889)"><g
       id="id13"><rect
	 class="BoundingBox"
	 x="12899"
	 y="3199"
	 width="2403"
	 height="1403"
	 id="rect280"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,4600 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path282"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text284"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan286"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="13925"
	     y="4121"
	     id="tspan288"><tspan
	       id="tspan290"
	       style="fill:#000000;stroke:none">8</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g292"
     transform="translate(-3285.889,-3185.889)"><g
       id="id14"><rect
	 class="BoundingBox"
	 x="3299"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect295"
	 style="fill:none;stroke:none" /><path
	 d="m 4500,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path297"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text299"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan301"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="4325"
	     y="5521"
	     id="tspan303"><tspan
	       id="tspan305"
	       style="fill:#000000;stroke:none">2</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g307"
     transform="translate(-3285.889,-3185.889)"><g
       id="id15"><rect
	 class="BoundingBox"
	 x="5699"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect310"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path312"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g314"
     transform="translate(-3285.889,-3185.889)"><g
       id="id16"><rect
	 class="BoundingBox"
	 x="8099"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect317"
	 style="fill:none;stroke:none" /><path
	 d="m 9300,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path319"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text321"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan323"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="9125"
	     y="5521"
	     id="tspan325"><tspan
	       id="tspan327"
	       style="fill:#000000;stroke:none">4</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g329"
     transform="translate(-3285.889,-3185.889)"><g
       id="id17"><rect
	 class="BoundingBox"
	 x="5699"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect332"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path334"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text336"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan338"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="6725"
	     y="5521"
	     id="tspan340"><tspan
	       id="tspan342"
	       style="fill:#000000;stroke:none">3</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g344"
     transform="translate(-3285.889,-3185.889)"><g
       id="id18"><rect
	 class="BoundingBox"
	 x="10499"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect347"
	 style="fill:none;stroke:none" /><path
	 d="m 11700,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path349"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text351"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan353"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="11525"
	     y="5521"
	     id="tspan355"><tspan
	       id="tspan357"
	       style="fill:#000000;stroke:none">5</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g359"
     transform="translate(-3285.889,-3185.889)"><g
       id="id19"><rect
	 class="BoundingBox"
	 x="12899"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect362"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path364"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g366"
     transform="translate(-3285.889,-3185.889)"><g
       id="id20"><rect
	 class="BoundingBox"
	 x="15299"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect369"
	 style="fill:none;stroke:none" /><path
	 d="m 16500,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path371"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text373"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan375"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="16149"
	     y="5521"
	     id="tspan377"><tspan
	       id="tspan379"
	       style="fill:#000000;stroke:none">11</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g381"
     transform="translate(-3285.889,-3185.889)"><g
       id="id21"><rect
	 class="BoundingBox"
	 x="12899"
	 y="4599"
	 width="2403"
	 height="1403"
	 id="rect384"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,6000 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path386"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text388"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan390"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="13749"
	     y="5521"
	     id="tspan392"><tspan
	       id="tspan394"
	       style="fill:#000000;stroke:none">10</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g396"
     transform="translate(-3285.889,-3185.889)"><g
       id="id22"><rect
	 class="BoundingBox"
	 x="3299"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect399"
	 style="fill:none;stroke:none" /><path
	 d="m 4500,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path401"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text403"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan405"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="4149"
	     y="6921"
	     id="tspan407"><tspan
	       id="tspan409"
	       style="fill:#000000;stroke:none">12</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g411"
     transform="translate(-3285.889,-3185.889)"><g
       id="id23"><rect
	 class="BoundingBox"
	 x="5699"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect414"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path416"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g418"
     transform="translate(-3285.889,-3185.889)"><g
       id="id24"><rect
	 class="BoundingBox"
	 x="8099"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect421"
	 style="fill:none;stroke:none" /><path
	 d="m 9300,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path423"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text425"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan427"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="8949"
	     y="6921"
	     id="tspan429"><tspan
	       id="tspan431"
	       style="fill:#000000;stroke:none">18</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g433"
     transform="translate(-3285.889,-3185.889)"><g
       id="id25"><rect
	 class="BoundingBox"
	 x="5699"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect436"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path438"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text440"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan442"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="6549"
	     y="6921"
	     id="tspan444"><tspan
	       id="tspan446"
	       style="fill:#000000;stroke:none">13</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g448"
     transform="translate(-3285.889,-3185.889)"><g
       id="id26"><rect
	 class="BoundingBox"
	 x="10499"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect451"
	 style="fill:none;stroke:none" /><path
	 d="m 11700,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path453"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text455"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan457"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="11349"
	     y="6921"
	     id="tspan459"><tspan
	       id="tspan461"
	       style="fill:#000000;stroke:none">19</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g463"
     transform="translate(-3285.889,-3185.889)"><g
       id="id27"><rect
	 class="BoundingBox"
	 x="12899"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect466"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path468"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g470"
     transform="translate(-3285.889,-3185.889)"><g
       id="id28"><rect
	 class="BoundingBox"
	 x="15299"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect473"
	 style="fill:none;stroke:none" /><path
	 d="m 16500,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path475"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text477"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan479"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="16149"
	     y="6921"
	     id="tspan481"><tspan
	       id="tspan483"
	       style="fill:#000000;stroke:none">21</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g485"
     transform="translate(-3285.889,-3185.889)"><g
       id="id29"><rect
	 class="BoundingBox"
	 x="12899"
	 y="5999"
	 width="2403"
	 height="1403"
	 id="rect488"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,7400 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path490"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text492"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan494"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="13749"
	     y="6921"
	     id="tspan496"><tspan
	       id="tspan498"
	       style="fill:#000000;stroke:none">20</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g500"
     transform="translate(-3285.889,-3185.889)"><g
       id="id30"><rect
	 class="BoundingBox"
	 x="3299"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect503"
	 style="fill:none;stroke:none" /><path
	 d="m 4500,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path505"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text507"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan509"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="4149"
	     y="8321"
	     id="tspan511"><tspan
	       id="tspan513"
	       style="fill:#000000;stroke:none">14</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g515"
     transform="translate(-3285.889,-3185.889)"><g
       id="id31"><rect
	 class="BoundingBox"
	 x="5699"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect518"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path520"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g522"
     transform="translate(-3285.889,-3185.889)"><g
       id="id32"><rect
	 class="BoundingBox"
	 x="8099"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect525"
	 style="fill:none;stroke:none" /><path
	 d="m 9300,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path527"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text529"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan531"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="8949"
	     y="8321"
	     id="tspan533"><tspan
	       id="tspan535"
	       style="fill:#000000;stroke:none">16</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g537"
     transform="translate(-3285.889,-3185.889)"><g
       id="id33"><rect
	 class="BoundingBox"
	 x="5699"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect540"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path542"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text544"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan546"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="6549"
	     y="8321"
	     id="tspan548"><tspan
	       id="tspan550"
	       style="fill:#000000;stroke:none">15</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g552"
     transform="translate(-3285.889,-3185.889)"><g
       id="id34"><rect
	 class="BoundingBox"
	 x="10499"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect555"
	 style="fill:none;stroke:none" /><path
	 d="m 11700,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path557"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text559"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan561"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="11349"
	     y="8321"
	     id="tspan563"><tspan
	       id="tspan565"
	       style="fill:#000000;stroke:none">17</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g567"
     transform="translate(-3285.889,-3185.889)"><g
       id="id35"><rect
	 class="BoundingBox"
	 x="12899"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect570"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path572"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g574"
     transform="translate(-3285.889,-3185.889)"><g
       id="id36"><rect
	 class="BoundingBox"
	 x="15299"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect577"
	 style="fill:none;stroke:none" /><path
	 d="m 16500,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path579"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text581"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan583"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="16149"
	     y="8321"
	     id="tspan585"><tspan
	       id="tspan587"
	       style="fill:#000000;stroke:none">23</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g589"
     transform="translate(-3285.889,-3185.889)"><g
       id="id37"><rect
	 class="BoundingBox"
	 x="12899"
	 y="7399"
	 width="2403"
	 height="1403"
	 id="rect592"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,8800 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path594"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text596"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan598"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="13749"
	     y="8321"
	     id="tspan600"><tspan
	       id="tspan602"
	       style="fill:#000000;stroke:none">22</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g604"
     transform="translate(-3285.889,-3185.889)"><g
       id="id38"><rect
	 class="BoundingBox"
	 x="3299"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect607"
	 style="fill:none;stroke:none" /><path
	 d="m 4500,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path609"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text611"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan613"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="4149"
	     y="9721"
	     id="tspan615"><tspan
	       id="tspan617"
	       style="fill:#000000;stroke:none">24</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g619"
     transform="translate(-3285.889,-3185.889)"><g
       id="id39"><rect
	 class="BoundingBox"
	 x="5699"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect622"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path624"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g626"
     transform="translate(-3285.889,-3185.889)"><g
       id="id40"><rect
	 class="BoundingBox"
	 x="8099"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect629"
	 style="fill:none;stroke:none" /><path
	 d="m 9300,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path631"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text633"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan635"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="8949"
	     y="9721"
	     id="tspan637"><tspan
	       id="tspan639"
	       style="fill:#000000;stroke:none">26</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g641"
     transform="translate(-3285.889,-3185.889)"><g
       id="id41"><rect
	 class="BoundingBox"
	 x="5699"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect644"
	 style="fill:none;stroke:none" /><path
	 d="m 6900,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path646"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text648"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan650"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="6549"
	     y="9721"
	     id="tspan652"><tspan
	       id="tspan654"
	       style="fill:#000000;stroke:none">25</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g656"
     transform="translate(-3285.889,-3185.889)"><g
       id="id42"><rect
	 class="BoundingBox"
	 x="10499"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect659"
	 style="fill:none;stroke:none" /><path
	 d="m 11700,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path661"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text663"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan665"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="11349"
	     y="9721"
	     id="tspan667"><tspan
	       id="tspan669"
	       style="fill:#000000;stroke:none">27</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g671"
     transform="translate(-3285.889,-3185.889)"><g
       id="id43"><rect
	 class="BoundingBox"
	 x="12899"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect674"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path676"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /></g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g678"
     transform="translate(-3285.889,-3185.889)"><g
       id="id44"><rect
	 class="BoundingBox"
	 x="15299"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect681"
	 style="fill:none;stroke:none" /><path
	 d="m 16500,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path683"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text685"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan687"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="16149"
	     y="9721"
	     id="tspan689"><tspan
	       id="tspan691"
	       style="fill:#000000;stroke:none">29</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.CustomShape"
     id="g693"
     transform="translate(-3285.889,-3185.889)"><g
       id="id45"><rect
	 class="BoundingBox"
	 x="12899"
	 y="8799"
	 width="2403"
	 height="1403"
	 id="rect696"
	 style="fill:none;stroke:none" /><path
	 d="m 14100,10200 -1200,0 0,-1400 2400,0 0,1400 -1200,0 z"
	 id="path698"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#3465a4" /><text
	 class="TextShape"
	 id="text700"><tspan
	   class="TextParagraph"
	   font-size="635px"
	   font-weight="400"
	   id="tspan702"
	   style="font-weight:400;font-size:635px;font-family:sans-serif"><tspan
	     class="TextPosition"
	     x="13749"
	     y="9721"
	     id="tspan704"><tspan
	       id="tspan706"
	       style="fill:#000000;stroke:none">28</tspan></tspan></tspan></text>
</g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g708"
     transform="translate(-3285.889,-3185.889)"><g
       id="id46"><rect
	 class="BoundingBox"
	 x="5199"
	 y="3850"
	 width="1402"
	 height="301"
	 id="rect711"
	 style="fill:none;stroke:none" /><path
	 d="m 5200,4000 970,0"
	 id="path713"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 6600,4000 -450,-150 0,300 450,-150 z"
	 id="path715"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g717"
     transform="translate(-3285.889,-3185.889)"><g
       id="id47"><rect
	 class="BoundingBox"
	 x="5000"
	 y="4299"
	 width="1202"
	 height="802"
	 id="rect720"
	 style="fill:none;stroke:none" /><path
	 d="m 6200,4300 -842,561"
	 id="path722"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 5000,5100 458,-125 -167,-249 -291,374 z"
	 id="path724"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g726"
     transform="translate(-3285.889,-3185.889)"><g
       id="id48"><rect
	 class="BoundingBox"
	 x="5399"
	 y="5250"
	 width="1202"
	 height="301"
	 id="rect729"
	 style="fill:none;stroke:none" /><path
	 d="m 5400,5400 770,0"
	 id="path731"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 6600,5400 -450,-150 0,300 450,-150 z"
	 id="path733"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g735"
     transform="translate(-3285.889,-3185.889)"><g
       id="id49"><rect
	 class="BoundingBox"
	 x="7599"
	 y="5250"
	 width="1202"
	 height="301"
	 id="rect738"
	 style="fill:none;stroke:none" /><path
	 d="m 7600,5400 770,0"
	 id="path740"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 8800,5400 -450,-150 0,300 450,-150 z"
	 id="path742"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g744"
     transform="translate(-3285.889,-3185.889)"><g
       id="id50"><rect
	 class="BoundingBox"
	 x="9799"
	 y="5250"
	 width="1402"
	 height="301"
	 id="rect747"
	 style="fill:none;stroke:none" /><path
	 d="m 9800,5400 970,0"
	 id="path749"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 11200,5400 -450,-150 0,300 450,-150 z"
	 id="path751"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g753"
     transform="translate(-3285.889,-3185.889)"><g
       id="id51"><rect
	 class="BoundingBox"
	 x="9900"
	 y="4200"
	 width="1202"
	 height="802"
	 id="rect756"
	 style="fill:none;stroke:none" /><path
	 d="m 11100,5000 -842,-561"
	 id="path758"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 9900,4200 291,374 167,-249 -458,-125 z"
	 id="path760"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g762"
     transform="translate(-3285.889,-3185.889)"><g
       id="id52"><rect
	 class="BoundingBox"
	 x="9999"
	 y="3850"
	 width="1402"
	 height="301"
	 id="rect765"
	 style="fill:none;stroke:none" /><path
	 d="m 10000,4000 970,0"
	 id="path767"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 11400,4000 -450,-150 0,300 450,-150 z"
	 id="path769"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g771"
     transform="translate(-3285.889,-3185.889)"><g
       id="id53"><rect
	 class="BoundingBox"
	 x="12399"
	 y="3850"
	 width="1202"
	 height="301"
	 id="rect774"
	 style="fill:none;stroke:none" /><path
	 d="m 12400,4000 770,0"
	 id="path776"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 13600,4000 -450,-150 0,300 450,-150 z"
	 id="path778"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g780"
     transform="translate(-3285.889,-3185.889)"><g
       id="id54"><rect
	 class="BoundingBox"
	 x="14799"
	 y="3850"
	 width="1202"
	 height="301"
	 id="rect783"
	 style="fill:none;stroke:none" /><path
	 d="m 14800,4000 770,0"
	 id="path785"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 16000,4000 -450,-150 0,300 450,-150 z"
	 id="path787"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g789"
     transform="translate(-3285.889,-3185.889)"><g
       id="id55"><rect
	 class="BoundingBox"
	 x="14400"
	 y="4399"
	 width="1402"
	 height="602"
	 id="rect792"
	 style="fill:none;stroke:none" /><path
	 d="m 15800,4400 -1005,431"
	 id="path794"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 14400,5000 473,-39 -118,-276 -355,315 z"
	 id="path796"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g798"
     transform="translate(-3285.889,-3185.889)"><g
       id="id56"><rect
	 class="BoundingBox"
	 x="14599"
	 y="5250"
	 width="1402"
	 height="301"
	 id="rect801"
	 style="fill:none;stroke:none" /><path
	 d="m 14600,5400 970,0"
	 id="path803"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 16000,5400 -450,-150 0,300 450,-150 z"
	 id="path805"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g807"
     transform="translate(-3285.889,-3185.889)"><g
       id="id57"><rect
	 class="BoundingBox"
	 x="5199"
	 y="6550"
	 width="1402"
	 height="301"
	 id="rect810"
	 style="fill:none;stroke:none" /><path
	 d="m 5200,6700 970,0"
	 id="path812"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 6600,6700 -450,-150 0,300 450,-150 z"
	 id="path814"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g816"
     transform="translate(-3285.889,-3129.4446)"><g
       id="id58"><rect
	 class="BoundingBox"
	 x="5000"
	 y="6999"
	 width="1202"
	 height="802"
	 id="rect819"
	 style="fill:none;stroke:none" /><path
	 d="m 6200,7000 -842,561"
	 id="path821"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 5000,7800 458,-125 -167,-249 -291,374 z"
	 id="path823"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g825"
     transform="translate(-3285.889,-3185.889)"><g
       id="id59"><rect
	 class="BoundingBox"
	 x="5399"
	 y="7950"
	 width="1202"
	 height="301"
	 id="rect828"
	 style="fill:none;stroke:none" /><path
	 d="m 5400,8100 770,0"
	 id="path830"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 6600,8100 -450,-150 0,300 450,-150 z"
	 id="path832"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g834"
     transform="translate(-3285.889,-3185.889)"><g
       id="id60"><rect
	 class="BoundingBox"
	 x="7599"
	 y="7950"
	 width="1202"
	 height="301"
	 id="rect837"
	 style="fill:none;stroke:none" /><path
	 d="m 7600,8100 770,0"
	 id="path839"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 8800,8100 -450,-150 0,300 450,-150 z"
	 id="path841"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g843"
     transform="translate(-3285.889,-3185.889)"><g
       id="id61"><rect
	 class="BoundingBox"
	 x="9799"
	 y="7950"
	 width="1402"
	 height="301"
	 id="rect846"
	 style="fill:none;stroke:none" /><path
	 d="m 9800,8100 970,0"
	 id="path848"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 11200,8100 -450,-150 0,300 450,-150 z"
	 id="path850"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g852"
     transform="translate(-3285.889,-3129.4446)"><g
       id="id62"><rect
	 class="BoundingBox"
	 x="9900"
	 y="6900"
	 width="1202"
	 height="802"
	 id="rect855"
	 style="fill:none;stroke:none" /><path
	 d="m 11100,7700 -842,-561"
	 id="path857"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 9900,6900 291,374 167,-249 -458,-125 z"
	 id="path859"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g861"
     transform="translate(-3285.889,-3185.889)"><g
       id="id63"><rect
	 class="BoundingBox"
	 x="9999"
	 y="6550"
	 width="1402"
	 height="301"
	 id="rect864"
	 style="fill:none;stroke:none" /><path
	 d="m 10000,6700 970,0"
	 id="path866"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 11400,6700 -450,-150 0,300 450,-150 z"
	 id="path868"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g870"
     transform="translate(-3285.889,-3185.889)"><g
       id="id64"><rect
	 class="BoundingBox"
	 x="12399"
	 y="6550"
	 width="1202"
	 height="301"
	 id="rect873"
	 style="fill:none;stroke:none" /><path
	 d="m 12400,6700 770,0"
	 id="path875"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 13600,6700 -450,-150 0,300 450,-150 z"
	 id="path877"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g879"
     transform="translate(-3285.889,-3185.889)"><g
       id="id65"><rect
	 class="BoundingBox"
	 x="14799"
	 y="6550"
	 width="1202"
	 height="301"
	 id="rect882"
	 style="fill:none;stroke:none" /><path
	 d="m 14800,6700 770,0"
	 id="path884"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 16000,6700 -450,-150 0,300 450,-150 z"
	 id="path886"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g888"
     transform="translate(-3285.889,-3129.4446)"><g
       id="id66"><rect
	 class="BoundingBox"
	 x="14400"
	 y="7099"
	 width="1402"
	 height="602"
	 id="rect891"
	 style="fill:none;stroke:none" /><path
	 d="m 15800,7100 -1005,431"
	 id="path893"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 14400,7700 473,-39 -118,-276 -355,315 z"
	 id="path895"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g897"
     transform="translate(-3285.889,-3185.889)"><g
       id="id67"><rect
	 class="BoundingBox"
	 x="14599"
	 y="7950"
	 width="1402"
	 height="301"
	 id="rect900"
	 style="fill:none;stroke:none" /><path
	 d="m 14600,8100 970,0"
	 id="path902"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 16000,8100 -450,-150 0,300 450,-150 z"
	 id="path904"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g906"
     transform="translate(-3285.889,-3185.889)"><g
       id="id68"><rect
	 class="BoundingBox"
	 x="5399"
	 y="9450"
	 width="1202"
	 height="301"
	 id="rect909"
	 style="fill:none;stroke:none" /><path
	 d="m 5400,9600 770,0"
	 id="path911"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 6600,9600 -450,-150 0,300 450,-150 z"
	 id="path913"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g915"
     transform="translate(-3285.889,-3185.889)"><g
       id="id69"><rect
	 class="BoundingBox"
	 x="7599"
	 y="9450"
	 width="1202"
	 height="301"
	 id="rect918"
	 style="fill:none;stroke:none" /><path
	 d="m 7600,9600 770,0"
	 id="path920"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 8800,9600 -450,-150 0,300 450,-150 z"
	 id="path922"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g924"
     transform="translate(-3285.889,-3185.889)"><g
       id="id70"><rect
	 class="BoundingBox"
	 x="9999"
	 y="9450"
	 width="1202"
	 height="301"
	 id="rect927"
	 style="fill:none;stroke:none" /><path
	 d="m 10000,9600 770,0"
	 id="path929"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 11200,9600 -450,-150 0,300 450,-150 z"
	 id="path931"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g933"
     transform="translate(-3285.889,-3185.889)"><g
       id="id71"><rect
	 class="BoundingBox"
	 x="12399"
	 y="9450"
	 width="1202"
	 height="301"
	 id="rect936"
	 style="fill:none;stroke:none" /><path
	 d="m 12400,9600 770,0"
	 id="path938"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 13600,9600 -450,-150 0,300 450,-150 z"
	 id="path940"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g><g
     class="com.sun.star.drawing.LineShape"
     id="g942"
     transform="translate(-3285.889,-3185.889)"><g
       id="id72"><rect
	 class="BoundingBox"
	 x="14799"
	 y="9450"
	 width="1202"
	 height="301"
	 id="rect945"
	 style="fill:none;stroke:none" /><path
	 d="m 14800,9600 770,0"
	 id="path947"
	 inkscape:connector-curvature="0"
	 style="fill:none;stroke:#ff3333" /><path
	 d="m 16000,9600 -450,-150 0,300 450,-150 z"
	 id="path949"
	 inkscape:connector-curvature="0"
	 style="fill:#ff3333;stroke:none" /></g></g></svg>

repo_name: angery/linux


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
.. c:namespace:: V4L

.. _open:

***************************
Opening and Closing Devices
***************************

.. _v4l2_hardware_control:

Controlling a hardware peripheral via V4L2
==========================================

Hardware that is supported using the V4L2 uAPI often consists of multiple
devices or peripherals, each of which have their own driver.

The bridge driver exposes one or more V4L2 device nodes
(see :ref:`v4l2_device_naming`).

There are other drivers providing support for other components of
the hardware, which may also expose device nodes, called V4L2 sub-devices.

When such V4L2 sub-devices are exposed, they allow controlling those
other hardware components - usually connected via a serial bus (like
I²C, SMBus or SPI). Depending on the bridge driver, those sub-devices
can be controlled indirectly via the bridge driver or explicitly via
the :ref:`Media Controller <media_controller>` and via the
:ref:`V4L2 sub-devices <subdev>`.

The devices that require the use of the
:ref:`Media Controller <media_controller>` are called **MC-centric**
devices. The devices that are fully controlled via V4L2 device nodes
are called **video-node-centric**.

Userspace can check if a V4L2 hardware peripheral is MC-centric by
calling :ref:`VIDIOC_QUERYCAP` and checking the
:ref:`device_caps field <device-capabilities>`.

If the device returns ``V4L2_CAP_IO_MC`` flag at ``device_caps``,
then it is MC-centric, otherwise, it is video-node-centric.

It is required for MC-centric drivers to identify the V4L2
sub-devices and to configure the pipelines via the
:ref:`media controller API <media_controller>` before using the peripheral.
Also, the sub-devices' configuration shall be controlled via the
:ref:`sub-device API <subdev>`.

.. note::

   A video-node-centric may still provide media-controller and
   sub-device interfaces as well.

  However, in that case the media-controller and the sub-device
  interfaces are read-only and just provide information about the
  device. The actual configuration is done via the video nodes.

.. _v4l2_device_naming:

V4L2 Device Node Naming
=======================

V4L2 drivers are implemented as kernel modules, loaded manually by the
system administrator or automatically when a device is first discovered.
The driver modules plug into the ``videodev`` kernel module. It provides
helper functions and a common application interface specified in this
document.

Each driver thus loaded registers one or more device nodes with major
number 81. Minor numbers are allocated dynamically unless the kernel
is compiled with the kernel option CONFIG_VIDEO_FIXED_MINOR_RANGES.
In that case minor numbers are allocated in ranges depending on the
device node type.

The device nodes supported by the Video4Linux subsystem are:

======================== ====================================================
Default device node name Usage
======================== ====================================================
``/dev/videoX``		 Video and metadata for capture/output devices
``/dev/vbiX``		 Vertical blank data (i.e. closed captions, teletext)
``/dev/radioX``		 Radio tuners and modulators
``/dev/swradioX``	 Software Defined Radio tuners and modulators
``/dev/v4l-touchX``	 Touch sensors
``/dev/v4l-subdevX``	 Video sub-devices (used by sensors and other
			 components of the hardware peripheral)\ [#]_
======================== ====================================================

Where ``X`` is a non-negative integer.

.. note::

   1. The actual device node name is system-dependent, as udev rules may apply.
   2. There is no guarantee that ``X`` will remain the same for the same
      device, as the number depends on the device driver's probe order.
      If you need an unique name, udev default rules produce
      ``/dev/v4l/by-id/`` and ``/dev/v4l/by-path/`` directories containing
      links that can be used uniquely to identify a V4L2 device node::

	$ tree /dev/v4l
	/dev/v4l
	├── by-id
	│   └── usb-OmniVision._USB_Camera-B4.04.27.1-video-index0 -> ../../video0
	└── by-path
	    └── pci-0000:00:14.0-usb-0:2:1.0-video-index0 -> ../../video0

.. [#] **V4L2 sub-device nodes** (e. g. ``/dev/v4l-subdevX``) use a different
       set of system calls, as covered at :ref:`subdev`.

Many drivers support "video_nr", "radio_nr" or "vbi_nr" module
options to select specific video/radio/vbi node numbers. This allows the
user to request that the device node is named e.g. /dev/video5 instead
of leaving it to chance. When the driver supports multiple devices of
the same type more than one device node number can be assigned,
separated by commas:

.. code-block:: none

   # modprobe mydriver video_nr=0,1 radio_nr=0,1

In ``/etc/modules.conf`` this may be written as:

::

    options mydriver video_nr=0,1 radio_nr=0,1

When no device node number is given as module option the driver supplies
a default.

Normally udev will create the device nodes in /dev automatically for
you. If udev is not installed, then you need to enable the
CONFIG_VIDEO_FIXED_MINOR_RANGES kernel option in order to be able to
correctly relate a minor number to a device node number. I.e., you need
to be certain that minor number 5 maps to device node name video5. With
this kernel option different device types have different minor number
ranges. These ranges are listed in :ref:`devices`.

The creation of character special files (with mknod) is a privileged
operation and devices cannot be opened by major and minor number. That
means applications cannot *reliably* scan for loaded or installed
drivers. The user must enter a device name, or the application can try
the conventional device names.

.. _related:

Related Devices
===============

Devices can support several functions. For example video capturing, VBI
capturing and radio support.

The V4L2 API creates different V4L2 device nodes for each of these functions.

The V4L2 API was designed with the idea that one device node could
support all functions. However, in practice this never worked: this
'feature' was never used by applications and many drivers did not
support it and if they did it was certainly never tested. In addition,
switching a device node between different functions only works when
using the streaming I/O API, not with the
:c:func:`read()`/\ :c:func:`write()` API.

Today each V4L2 device node supports just one function.

Besides video input or output the hardware may also support audio
sampling or playback. If so, these functions are implemented as ALSA PCM
devices with optional ALSA audio mixer devices.

One problem with all these devices is that the V4L2 API makes no
provisions to find these related V4L2 device nodes. Some really complex
hardware use the Media Controller (see :ref:`media_controller`) which can
be used for this purpose. But several drivers do not use it, and while some
code exists that uses sysfs to discover related V4L2 device nodes (see
libmedia_dev in the
`v4l-utils <http://git.linuxtv.org/cgit.cgi/v4l-utils.git/>`__ git
repository), there is no library yet that can provide a single API
towards both Media Controller-based devices and devices that do not use
the Media Controller. If you want to work on this please write to the
linux-media mailing list:
`https://linuxtv.org/lists.php <https://linuxtv.org/lists.php>`__.

Multiple Opens
==============

V4L2 devices can be opened more than once. [#f1]_ When this is supported
by the driver, users can for example start a "panel" application to
change controls like brightness or audio volume, while another
application captures video and audio. In other words, panel applications
are comparable to an ALSA audio mixer application. Just opening a V4L2
device should not change the state of the device. [#f2]_

Once an application has allocated the memory buffers needed for
streaming data (by calling the :ref:`VIDIOC_REQBUFS`
or :ref:`VIDIOC_CREATE_BUFS` ioctls, or
implicitly by calling the :c:func:`read()` or
:c:func:`write()` functions) that application (filehandle)
becomes the owner of the device. It is no longer allowed to make changes
that would affect the buffer sizes (e.g. by calling the
:ref:`VIDIOC_S_FMT <VIDIOC_G_FMT>` ioctl) and other applications are
no longer allowed to allocate buffers or start or stop streaming. The
EBUSY error code will be returned instead.

Merely opening a V4L2 device does not grant exclusive access. [#f3]_
Initiating data exchange however assigns the right to read or write the
requested type of data, and to change related properties, to this file
descriptor. Applications can request additional access privileges using
the priority mechanism described in :ref:`app-pri`.

Shared Data Streams
===================

V4L2 drivers should not support multiple applications reading or writing
the same data stream on a device by copying buffers, time multiplexing
or similar means. This is better handled by a proxy application in user
space.

Functions
=========

To open and close V4L2 devices applications use the
:c:func:`open()` and :c:func:`close()` function,
respectively. Devices are programmed using the
:ref:`ioctl() <func-ioctl>` function as explained in the following
sections.

.. [#f1]
   There are still some old and obscure drivers that have not been
   updated to allow for multiple opens. This implies that for such
   drivers :c:func:`open()` can return an ``EBUSY`` error code
   when the device is already in use.

.. [#f2]
   Unfortunately, opening a radio device often switches the state of the
   device to radio mode in many drivers. This behavior should be fixed
   eventually as it violates the V4L2 specification.

.. [#f3]
   Drivers could recognize the ``O_EXCL`` open flag. Presently this is
   not required, so applications cannot know if it really works.


code:
# SPDX-License-Identifier: GPL-2.0

digraph board {
	rankdir=TB
	colorscheme=x11
	scaler [label="{<scaler_0> 0} | Host\nScaler | {<scaler_1> 1} ", shape=Mrecord, style=filled, fillcolor=lightblue]
	frontend [label="{<frontend_0> 0} | Host\nFrontend | {<frontend_1> 1}", shape=Mrecord, style=filled, fillcolor=lightblue]
	sensor [label="Sensor | {<sensor_0> 0}", shape=Mrecord, style=filled, fillcolor=aquamarine]
	io [label="{<io_0> 0} | V4L I/O", shape=Mrecord, style=filled, fillcolor=aquamarine]

	sensor:sensor_0 -> frontend:frontend_0 [color=blue, label="HQ: 2592x1968\nHS: 1296x984"]
	frontend:frontend_1 -> scaler:scaler_0 [color=blue, label="HQ: 2592x1968\nHS: 1296x984"]
	scaler:scaler_1 -> io:io_0 [color=blue, label="HQ: 1280x720\nHS: 1280x720"]
}


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

.. _pixfmt-bayer:

*****************
Raw Bayer Formats
*****************

Description
===========

The raw Bayer formats are used by image sensors before much if any processing is
performed on the image. The formats contain green, red and blue components, with
alternating lines of red and green, and blue and green pixels in different
orders. See also `the Wikipedia article on Bayer filter
<https://en.wikipedia.org/wiki/Bayer_filter>`__.

.. toctree::
    :maxdepth: 1

    pixfmt-srggb8
    pixfmt-srggb10
    pixfmt-srggb10p
    pixfmt-srggb10alaw8
    pixfmt-srggb10dpcm8
    pixfmt-srggb10-ipu3
    pixfmt-srggb12
    pixfmt-srggb12p
    pixfmt-srggb14
    pixfmt-srggb14p
    pixfmt-srggb16


code:
.. -*- coding: utf-8; mode: rst -*-

.. _V4L2-PIX-FMT-CNF4:

******************************
V4L2_PIX_FMT_CNF4 ('CNF4')
******************************

Depth sensor confidence information as a 4 bits per pixel packed array

Description
===========

Proprietary format used by Intel RealSense Depth cameras containing depth
confidence information in range 0-15 with 0 indicating that the sensor was
unable to resolve any signal and 15 indicating maximum level of confidence for
the specific sensor (actual error margins might change from sensor to sensor).

Every two consecutive pixels are packed into a single byte.
Bits 0-3 of byte n refer to confidence value of depth pixel 2*n,
bits 4-7 to confidence value of depth pixel 2*n+1.

**Bit-packed representation.**

.. flat-table::
    :header-rows:  0
    :stub-columns: 0
    :widths: 64 64

    * - Y'\ :sub:`01[3:0]`\ (bits 7--4) Y'\ :sub:`00[3:0]`\ (bits 3--0)
      - Y'\ :sub:`03[3:0]`\ (bits 7--4) Y'\ :sub:`02[3:0]`\ (bits 3--0)


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

******************
Compressed Formats
******************

.. _compressed-formats:

.. raw:: latex

    \small

.. tabularcolumns:: |p{5.8cm}|p{1.2cm}|p{10.3cm}|

.. cssclass:: longtable

.. flat-table:: Compressed Image Formats
    :header-rows:  1
    :stub-columns: 0
    :widths:       3 1 4

    * - Identifier
      - Code
      - Details
    * .. _V4L2-PIX-FMT-JPEG:

      - ``V4L2_PIX_FMT_JPEG``
      - 'JPEG'
      - TBD. See also :ref:`VIDIOC_G_JPEGCOMP <VIDIOC_G_JPEGCOMP>`,
	:ref:`VIDIOC_S_JPEGCOMP <VIDIOC_G_JPEGCOMP>`.
    * .. _V4L2-PIX-FMT-MPEG:

      - ``V4L2_PIX_FMT_MPEG``
      - 'MPEG'
      - MPEG multiplexed stream. The actual format is determined by
	extended control ``V4L2_CID_MPEG_STREAM_TYPE``, see
	:ref:`mpeg-control-id`.
    * .. _V4L2-PIX-FMT-H264:

      - ``V4L2_PIX_FMT_H264``
      - 'H264'
      - H264 Access Unit.
	The decoder expects one Access Unit per buffer.
	The encoder generates one Access Unit per buffer.
	If :ref:`VIDIOC_ENUM_FMT` reports ``V4L2_FMT_FLAG_CONTINUOUS_BYTESTREAM``
	then the decoder has no requirements since it can parse all the
	information from the raw bytestream.
    * .. _V4L2-PIX-FMT-H264-NO-SC:

      - ``V4L2_PIX_FMT_H264_NO_SC``
      - 'AVC1'
      - H264 video elementary stream without start codes.
    * .. _V4L2-PIX-FMT-H264-MVC:

      - ``V4L2_PIX_FMT_H264_MVC``
      - 'M264'
      - H264 MVC video elementary stream.
    * .. _V4L2-PIX-FMT-H264-SLICE:

      - ``V4L2_PIX_FMT_H264_SLICE``
      - 'S264'
      - H264 parsed slice data, including slice headers, either with or
	without the start code, as extracted from the H264 bitstream.
	This format is adapted for stateless video decoders that implement an
	H264 pipeline with the :ref:`stateless_decoder`.
	This pixelformat has two modifiers that must be set at least once
	through the ``V4L2_CID_STATELESS_H264_DECODE_MODE``
        and ``V4L2_CID_STATELESS_H264_START_CODE`` controls.
	In addition, metadata associated with the frame to decode are
	required to be passed through the ``V4L2_CID_STATELESS_H264_SPS``,
	``V4L2_CID_STATELESS_H264_PPS``,
	``V4L2_CID_STATELESS_H264_SCALING_MATRIX``,
	``V4L2_CID_STATELESS_H264_SLICE_PARAMS`` and
	``V4L2_CID_STATELESS_H264_DECODE_PARAMS`` controls.  See the
	:ref:`associated Codec Control IDs <v4l2-codec-stateless-h264>`.
        Exactly one output and one capture buffer must be provided for use
	with this pixel format. The output buffer must contain the
	appropriate number of macroblocks to decode a full
	corresponding frame to the matching capture buffer.

	The syntax for this format is documented in :ref:`h264`, section
	7.3.2.8 "Slice layer without partitioning RBSP syntax" and the following
	sections.

    * .. _V4L2-PIX-FMT-H263:

      - ``V4L2_PIX_FMT_H263``
      - 'H263'
      - H263 video elementary stream.
    * .. _V4L2-PIX-FMT-MPEG1:

      - ``V4L2_PIX_FMT_MPEG1``
      - 'MPG1'
      - MPEG1 Picture. Each buffer starts with a Picture header, followed
	by other headers as needed and ending with the Picture data.
	If :ref:`VIDIOC_ENUM_FMT` reports ``V4L2_FMT_FLAG_CONTINUOUS_BYTESTREAM``
	then the decoder has no requirements since it can parse all the
	information from the raw bytestream.
    * .. _V4L2-PIX-FMT-MPEG2:

      - ``V4L2_PIX_FMT_MPEG2``
      - 'MPG2'
      - MPEG2 Picture. Each buffer starts with a Picture header, followed
	by other headers as needed and ending with the Picture data.
	If :ref:`VIDIOC_ENUM_FMT` reports ``V4L2_FMT_FLAG_CONTINUOUS_BYTESTREAM``
	then the decoder has no requirements since it can parse all the
	information from the raw bytestream.
    * .. _V4L2-PIX-FMT-MPEG2-SLICE:

      - ``V4L2_PIX_FMT_MPEG2_SLICE``
      - 'MG2S'
      - MPEG-2 parsed slice data, as extracted from the MPEG-2 bitstream.
	This format is adapted for stateless video decoders that implement a
	MPEG-2 pipeline with the :ref:`stateless_decoder`.
	Metadata associated with the frame to decode is required to be passed
	through the ``V4L2_CID_STATELESS_MPEG2_SEQUENCE`` and
        ``V4L2_CID_STATELESS_MPEG2_PICTURE`` controls.
        Quantisation matrices can optionally be specified through the
	``V4L2_CID_STATELESS_MPEG2_QUANTISATION`` control.
	See the :ref:`associated Codec Control IDs <v4l2-codec-stateless-mpeg2>`.
	Exactly one output and one capture buffer must be provided for use with
	this pixel format. The output buffer must contain the appropriate number
	of macroblocks to decode a full corresponding frame to the matching
	capture buffer.
    * .. _V4L2-PIX-FMT-MPEG4:

      - ``V4L2_PIX_FMT_MPEG4``
      - 'MPG4'
      - MPEG4 video elementary stream.
    * .. _V4L2-PIX-FMT-XVID:

      - ``V4L2_PIX_FMT_XVID``
      - 'XVID'
      - Xvid video elementary stream.
    * .. _V4L2-PIX-FMT-VC1-ANNEX-G:

      - ``V4L2_PIX_FMT_VC1_ANNEX_G``
      - 'VC1G'
      - VC1, SMPTE 421M Annex G compliant stream.
    * .. _V4L2-PIX-FMT-VC1-ANNEX-L:

      - ``V4L2_PIX_FMT_VC1_ANNEX_L``
      - 'VC1L'
      - VC1, SMPTE 421M Annex L compliant stream.
    * .. _V4L2-PIX-FMT-VP8:

      - ``V4L2_PIX_FMT_VP8``
      - 'VP80'
      - VP8 compressed video frame. The encoder generates one
	compressed frame per buffer, and the decoder requires one
	compressed frame per buffer.
    * .. _V4L2-PIX-FMT-VP8-FRAME:

      - ``V4L2_PIX_FMT_VP8_FRAME``
      - 'VP8F'
      - VP8 parsed frame, including the frame header, as extracted from the container.
	This format is adapted for stateless video decoders that implement an
	VP8 pipeline with the :ref:`stateless_decoder`.
	Metadata associated with the frame to decode is required to be passed
	through the ``V4L2_CID_STATELESS_VP8_FRAME`` control.
	See the :ref:`associated Codec Control IDs <v4l2-codec-stateless-vp8>`.
	Exactly one output and one capture buffer must be provided for use with
	this pixel format. The output buffer must contain the appropriate number
	of macroblocks to decode a full corresponding frame to the matching
	capture buffer.

    * .. _V4L2-PIX-FMT-VP9:

      - ``V4L2_PIX_FMT_VP9``
      - 'VP90'
      - VP9 compressed video frame. The encoder generates one
	compressed frame per buffer, and the decoder requires one
	compressed frame per buffer.
    * .. _V4L2-PIX-FMT-VP9-FRAME:

      - ``V4L2_PIX_FMT_VP9_FRAME``
      - 'VP9F'
      - VP9 parsed frame, including the frame header, as extracted from the container.
	This format is adapted for stateless video decoders that implement a
	VP9 pipeline with the :ref:`stateless_decoder`.
	Metadata associated with the frame to decode is required to be passed
	through the ``V4L2_CID_STATELESS_VP9_FRAME`` and
	the ``V4L2_CID_STATELESS_VP9_COMPRESSED_HDR`` controls.
	See the :ref:`associated Codec Control IDs <v4l2-codec-stateless-vp9>`.
	Exactly one output and one capture buffer must be provided for use with
	this pixel format. The output buffer must contain the appropriate number
	of macroblocks to decode a full corresponding frame to the matching
	capture buffer.
    * .. _V4L2-PIX-FMT-HEVC:

      - ``V4L2_PIX_FMT_HEVC``
      - 'HEVC'
      - HEVC/H.265 Access Unit.
	The decoder expects one Access Unit per buffer.
	The encoder generates one Access Unit per buffer.
	If :ref:`VIDIOC_ENUM_FMT` reports ``V4L2_FMT_FLAG_CONTINUOUS_BYTESTREAM``
	then the decoder has no	requirements since it can parse all the
	information from the raw bytestream.
    * .. _V4L2-PIX-FMT-HEVC-SLICE:

      - ``V4L2_PIX_FMT_HEVC_SLICE``
      - 'S265'
      - HEVC parsed slice data, as extracted from the HEVC bitstream.
	This format is adapted for stateless video decoders that implement a
	HEVC pipeline (using the :ref:`mem2mem` and :ref:`media-request-api`).
	This pixelformat has two modifiers that must be set at least once
	through the ``V4L2_CID_MPEG_VIDEO_HEVC_DECODE_MODE``
        and ``V4L2_CID_MPEG_VIDEO_HEVC_START_CODE`` controls.
	Metadata associated with the frame to decode is required to be passed
	through the following controls:
        ``V4L2_CID_MPEG_VIDEO_HEVC_SPS``,
        ``V4L2_CID_MPEG_VIDEO_HEVC_PPS``, and
        ``V4L2_CID_MPEG_VIDEO_HEVC_SLICE_PARAMS``.
	See the :ref:`associated Codec Control IDs <v4l2-codec-stateless-hevc>`.
	Buffers associated with this pixel format must contain the appropriate
	number of macroblocks to decode a full corresponding frame.
    * .. _V4L2-PIX-FMT-FWHT:

      - ``V4L2_PIX_FMT_FWHT``
      - 'FWHT'
      - Video elementary stream using a codec based on the Fast Walsh Hadamard
        Transform. This codec is implemented by the vicodec ('Virtual Codec')
	driver. See the codec-fwht.h header for more details.
	:ref:`VIDIOC_ENUM_FMT` reports ``V4L2_FMT_FLAG_CONTINUOUS_BYTESTREAM``
	since the decoder can parse all the information from the raw bytestream.
    * .. _V4L2-PIX-FMT-FWHT-STATELESS:

      - ``V4L2_PIX_FMT_FWHT_STATELESS``
      - 'SFWH'
      - Same format as V4L2_PIX_FMT_FWHT but requires stateless codec implementation.
        Metadata associated with the frame to decode is required to be passed
        through the ``V4L2_CID_STATELESS_FWHT_PARAMS`` control.
	See the :ref:`associated Codec Control ID <codec-stateless-fwht>`.

.. raw:: latex

    \normalsize


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

.. _pixfmt-indexed:

**************
Indexed Format
**************

In this format each pixel is represented by an 8 bit index into a 256
entry ARGB palette. It is intended for
:ref:`Video Output Overlays <osd>` only. There are no ioctls to access
the palette, this must be done with ioctls of the Linux framebuffer API.

.. flat-table:: Indexed Image Format
    :header-rows:  2
    :stub-columns: 0

    * - Identifier
      - Code
      -
      - :cspan:`7` Byte 0
    * -
      -
      - Bit
      - 7
      - 6
      - 5
      - 4
      - 3
      - 2
      - 1
      - 0
    * .. _V4L2-PIX-FMT-PAL8:

      - ``V4L2_PIX_FMT_PAL8``
      - 'PAL8'
      -
      - i\ :sub:`7`
      - i\ :sub:`6`
      - i\ :sub:`5`
      - i\ :sub:`4`
      - i\ :sub:`3`
      - i\ :sub:`2`
      - i\ :sub:`1`
      - i\ :sub:`0`


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

**********************
Standard Image Formats
**********************

In order to exchange images between drivers and applications, it is
necessary to have standard image data formats which both sides will
interpret the same way. V4L2 includes several such formats, and this
section is intended to be an unambiguous specification of the standard
image data formats in V4L2.

V4L2 drivers are not limited to these formats, however. Driver-specific
formats are possible. In that case the application may depend on a codec
to convert images to one of the standard formats when needed. But the
data can still be stored and retrieved in the proprietary format. For
example, a device may support a proprietary compressed format.
Applications can still capture and save the data in the compressed
format, saving much disk space, and later use a codec to convert the
images to the X Windows screen format when the video is to be displayed.

Even so, ultimately, some standard formats are needed, so the V4L2
specification would not be complete without well-defined standard
formats.

The V4L2 standard formats are mainly uncompressed formats. The pixels
are always arranged in memory from left to right, and from top to
bottom. The first byte of data in the image buffer is always for the
leftmost pixel of the topmost row. Following that is the pixel
immediately to its right, and so on until the end of the top row of
pixels. Following the rightmost pixel of the row there may be zero or
more bytes of padding to guarantee that each row of pixel data has a
certain alignment. Following the pad bytes, if any, is data for the
leftmost pixel of the second row from the top, and so on. The last row
has just as many pad bytes after it as the other rows.

In V4L2 each format has an identifier which looks like ``PIX_FMT_XXX``,
defined in the :ref:`videodev2.h <videodev>` header file. These
identifiers represent
:ref:`four character (FourCC) codes <v4l2-fourcc>` which are also
listed below, however they are not the same as those used in the Windows
world.

For some formats, data is stored in separate, discontiguous memory
buffers. Those formats are identified by a separate set of FourCC codes
and are referred to as "multi-planar formats". For example, a
:ref:`YUV422 <V4L2-PIX-FMT-YUV422M>` frame is normally stored in one
memory buffer, but it can also be placed in two or three separate
buffers, with Y component in one buffer and CbCr components in another
in the 2-planar version or with each component in its own buffer in the
3-planar case. Those sub-buffers are referred to as "*planes*".


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

.. _V4L2-PIX-FMT-INZI:

**************************
V4L2_PIX_FMT_INZI ('INZI')
**************************

Infrared 10-bit linked with Depth 16-bit images

Description
===========

Proprietary multi-planar format used by Intel SR300 Depth cameras, comprise of
Infrared image followed by Depth data. The pixel definition is 32-bpp,
with the Depth and Infrared Data split into separate continuous planes of
identical dimensions.

The first plane - Infrared data - is stored according to
:ref:`V4L2_PIX_FMT_Y10 <V4L2-PIX-FMT-Y10>` greyscale format.
Each pixel is 16-bit cell, with actual data stored in the 10 LSBs
with values in range 0 to 1023.
The six remaining MSBs are padded with zeros.

The second plane provides 16-bit per-pixel Depth data arranged in
:ref:`V4L2-PIX-FMT-Z16 <V4L2-PIX-FMT-Z16>` format.

**Frame Structure.**
Each cell is a 16-bit word with more significant data stored at higher
memory address (byte order is little-endian).

.. raw:: latex

    \small

.. tabularcolumns:: |p{2.5cm}|p{2.5cm}|p{2.5cm}|p{2.5cm}|p{2.5cm}|p{2.5cm}|

.. flat-table::
    :header-rows:  0
    :stub-columns: 1
    :widths:    1 1 1 1 1 1

    * - Ir\ :sub:`0,0`
      - Ir\ :sub:`0,1`
      - Ir\ :sub:`0,2`
      - ...
      - ...
      - ...
    * - :cspan:`5` ...
    * - :cspan:`5` Infrared Data
    * - :cspan:`5` ...
    * - ...
      - ...
      - ...
      - Ir\ :sub:`n-1,n-3`
      - Ir\ :sub:`n-1,n-2`
      - Ir\ :sub:`n-1,n-1`
    * - Depth\ :sub:`0,0`
      - Depth\ :sub:`0,1`
      - Depth\ :sub:`0,2`
      - ...
      - ...
      - ...
    * - :cspan:`5` ...
    * - :cspan:`5` Depth Data
    * - :cspan:`5` ...
    * - ...
      - ...
      - ...
      - Depth\ :sub:`n-1,n-3`
      - Depth\ :sub:`n-1,n-2`
      - Depth\ :sub:`n-1,n-1`

.. raw:: latex

    \normalsize


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

.. _V4L2-PIX-FMT-M420:

**************************
V4L2_PIX_FMT_M420 ('M420')
**************************

Format with ½ horizontal and vertical chroma resolution, also known as
YUV 4:2:0. Hybrid plane line-interleaved layout.

Description
===========

M420 is a YUV format with ½ horizontal and vertical chroma subsampling
(YUV 4:2:0). Pixels are organized as interleaved luma and chroma planes.
Two lines of luma data are followed by one line of chroma data.

The luma plane has one byte per pixel. The chroma plane contains
interleaved CbCr pixels subsampled by ½ in the horizontal and vertical
directions. Each CbCr pair belongs to four pixels. For example,
Cb\ :sub:`0`/Cr\ :sub:`0` belongs to Y'\ :sub:`00`, Y'\ :sub:`01`,
Y'\ :sub:`10`, Y'\ :sub:`11`.

All line lengths are identical: if the Y lines include pad bytes so do
the CbCr lines.

**Byte Order.**
Each cell is one byte.

.. flat-table::
    :header-rows:  0
    :stub-columns: 0

    * - start + 0:
      - Y'\ :sub:`00`
      - Y'\ :sub:`01`
      - Y'\ :sub:`02`
      - Y'\ :sub:`03`
    * - start + 4:
      - Y'\ :sub:`10`
      - Y'\ :sub:`11`
      - Y'\ :sub:`12`
      - Y'\ :sub:`13`
    * - start + 8:
      - Cb\ :sub:`00`
      - Cr\ :sub:`00`
      - Cb\ :sub:`01`
      - Cr\ :sub:`01`
    * - start + 16:
      - Y'\ :sub:`20`
      - Y'\ :sub:`21`
      - Y'\ :sub:`22`
      - Y'\ :sub:`23`
    * - start + 20:
      - Y'\ :sub:`30`
      - Y'\ :sub:`31`
      - Y'\ :sub:`32`
      - Y'\ :sub:`33`
    * - start + 24:
      - Cb\ :sub:`10`
      - Cr\ :sub:`10`
      - Cb\ :sub:`11`
      - Cr\ :sub:`11`

**Color Sample Location:**
Chroma samples are :ref:`interstitially sited<yuv-chroma-centered>`
horizontally and vertically.


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

.. _v4l2-meta-fmt-d4xx:

*******************************
V4L2_META_FMT_D4XX ('D4XX')
*******************************

Intel D4xx UVC Cameras Metadata

Description
===========

Intel D4xx (D435 and other) cameras include per-frame metadata in their UVC
payload headers, following the Microsoft(R) UVC extension proposal [1_]. That
means, that the private D4XX metadata, following the standard UVC header, is
organised in blocks. D4XX cameras implement several standard block types,
proposed by Microsoft, and several proprietary ones. Supported standard metadata
types are MetadataId_CaptureStats (ID 3), MetadataId_CameraExtrinsics (ID 4),
and MetadataId_CameraIntrinsics (ID 5). For their description see [1_]. This
document describes proprietary metadata types, used by D4xx cameras.

V4L2_META_FMT_D4XX buffers follow the metadata buffer layout of
V4L2_META_FMT_UVC with the only difference, that it also includes proprietary
payload header data. D4xx cameras use bulk transfers and only send one payload
per frame, therefore their headers cannot be larger than 255 bytes.

Below are proprietary Microsoft style metadata types, used by D4xx cameras,
where all fields are in little endian order:

.. tabularcolumns:: |p{5.0cm}|p{12.5cm}|

.. flat-table:: D4xx metadata
    :widths: 1 2
    :header-rows:  1
    :stub-columns: 0

    * - **Field**
      - **Description**
    * - :cspan:`1` *Depth Control*
    * - __u32 ID
      - 0x80000000
    * - __u32 Size
      - Size in bytes (currently 56)
    * - __u32 Version
      - Version of this structure. The documentation herein corresponds to
        version xxx. The version number will be incremented when new fields are
        added.
    * - __u32 Flags
      - A bitmask of flags: see [2_] below
    * - __u32 Gain
      - Gain value in internal units, same as the V4L2_CID_GAIN control, used to
	capture the frame
    * - __u32 Exposure
      - Exposure time (in microseconds) used to capture the frame
    * - __u32 Laser power
      - Power of the laser LED 0-360, used for depth measurement
    * - __u32 AE mode
      - 0: manual; 1: automatic exposure
    * - __u32 Exposure priority
      - Exposure priority value: 0 - constant frame rate
    * - __u32 AE ROI left
      - Left border of the AE Region of Interest (all ROI values are in pixels
	and lie between 0 and maximum width or height respectively)
    * - __u32 AE ROI right
      - Right border of the AE Region of Interest
    * - __u32 AE ROI top
      - Top border of the AE Region of Interest
    * - __u32 AE ROI bottom
      - Bottom border of the AE Region of Interest
    * - __u32 Preset
      - Preset selector value, default: 0, unless changed by the user
    * - __u32 Laser mode
      - 0: off, 1: on
    * - :cspan:`1` *Capture Timing*
    * - __u32 ID
      - 0x80000001
    * - __u32 Size
      - Size in bytes (currently 40)
    * - __u32 Version
      - Version of this structure. The documentation herein corresponds to
        version xxx. The version number will be incremented when new fields are
        added.
    * - __u32 Flags
      - A bitmask of flags: see [3_] below
    * - __u32 Frame counter
      - Monotonically increasing counter
    * - __u32 Optical time
      - Time in microseconds from the beginning of a frame till its middle
    * - __u32 Readout time
      - Time, used to read out a frame in microseconds
    * - __u32 Exposure time
      - Frame exposure time in microseconds
    * - __u32 Frame interval
      - In microseconds = 1000000 / framerate
    * - __u32 Pipe latency
      - Time in microseconds from start of frame to data in USB buffer
    * - :cspan:`1` *Configuration*
    * - __u32 ID
      - 0x80000002
    * - __u32 Size
      - Size in bytes (currently 40)
    * - __u32 Version
      - Version of this structure. The documentation herein corresponds to
        version xxx. The version number will be incremented when new fields are
        added.
    * - __u32 Flags
      - A bitmask of flags: see [4_] below
    * - __u8 Hardware type
      - Camera hardware version [5_]
    * - __u8 SKU ID
      - Camera hardware configuration [6_]
    * - __u32 Cookie
      - Internal synchronisation
    * - __u16 Format
      - Image format code [7_]
    * - __u16 Width
      - Width in pixels
    * - __u16 Height
      - Height in pixels
    * - __u16 Framerate
      - Requested frame rate per second
    * - __u16 Trigger
      - Byte 0: bit 0: depth and RGB are synchronised, bit 1: external trigger

.. _1:

[1] https://docs.microsoft.com/en-us/windows-hardware/drivers/stream/uvc-extensions-1-5

.. _2:

[2] Depth Control flags specify which fields are valid: ::

  0x00000001 Gain
  0x00000002 Exposure
  0x00000004 Laser power
  0x00000008 AE mode
  0x00000010 Exposure priority
  0x00000020 AE ROI
  0x00000040 Preset

.. _3:

[3] Capture Timing flags specify which fields are valid: ::

  0x00000001 Frame counter
  0x00000002 Optical time
  0x00000004 Readout time
  0x00000008 Exposure time
  0x00000010 Frame interval
  0x00000020 Pipe latency

.. _4:

[4] Configuration flags specify which fields are valid: ::

  0x00000001 Hardware type
  0x00000002 SKU ID
  0x00000004 Cookie
  0x00000008 Format
  0x00000010 Width
  0x00000020 Height
  0x00000040 Framerate
  0x00000080 Trigger
  0x00000100 Cal count

.. _5:

[5] Camera model: ::

  0 DS5
  1 IVCAM2

.. _6:

[6] 8-bit camera hardware configuration bitfield: ::

  [1:0] depthCamera
	00: no depth
	01: standard depth
	10: wide depth
	11: reserved
  [2]   depthIsActive - has a laser projector
  [3]   RGB presence
  [4]   Inertial Measurement Unit (IMU) presence
  [5]   projectorType
	0: HPTG
	1: Princeton
  [6]   0: a projector, 1: an LED
  [7]   reserved

.. _7:

[7] Image format codes per video streaming interface:

Depth: ::

  1 Z16
  2 Z

Left sensor: ::

  1 Y8
  2 UYVY
  3 R8L8
  4 Calibration
  5 W10

Fish Eye sensor: ::

  1 RAW8


code:
.. SPDX-License-Identifier: GPL-2.0 OR GFDL-1.1-no-invariants-or-later

.. _v4l2-meta-fmt-params:
.. _v4l2-meta-fmt-stat-3a:

******************************************************************
V4L2_META_FMT_IPU3_PARAMS ('ip3p'), V4L2_META_FMT_IPU3_3A ('ip3s')
******************************************************************

.. ipu3_uapi_stats_3a

3A statistics
=============

The IPU3 ImgU 3A statistics accelerators collect different statistics over
an input Bayer frame. Those statistics are obtained from the "ipu3-imgu [01] 3a
stat" metadata capture video nodes, using the :c:type:`v4l2_meta_format`
interface. They are formatted as described by the :c:type:`ipu3_uapi_stats_3a`
structure.

The statistics collected are AWB (Auto-white balance) RGBS (Red, Green, Blue and
Saturation measure) cells, AWB filter response, AF (Auto-focus) filter response,
and AE (Auto-exposure) histogram.

The struct :c:type:`ipu3_uapi_4a_config` saves all configurable parameters.

.. code-block:: c

	struct ipu3_uapi_stats_3a {
		struct ipu3_uapi_awb_raw_buffer awb_raw_buffer;
		struct ipu3_uapi_ae_raw_buffer_aligned ae_raw_buffer[IPU3_UAPI_MAX_STRIPES];
		struct ipu3_uapi_af_raw_buffer af_raw_buffer;
		struct ipu3_uapi_awb_fr_raw_buffer awb_fr_raw_buffer;
		struct ipu3_uapi_4a_config stats_4a_config;
		__u32 ae_join_buffers;
		__u8 padding[28];
		struct ipu3_uapi_stats_3a_bubble_info_per_stripe stats_3a_bubble_per_stripe;
		struct ipu3_uapi_ff_status stats_3a_status;
	};

.. ipu3_uapi_params

Pipeline parameters
===================

The pipeline parameters are passed to the "ipu3-imgu [01] parameters" metadata
output video nodes, using the :c:type:`v4l2_meta_format` interface. They are
formatted as described by the :c:type:`ipu3_uapi_params` structure.

Both 3A statistics and pipeline parameters described here are closely tied to
the underlying camera sub-system (CSS) APIs. They are usually consumed and
produced by dedicated user space libraries that comprise the important tuning
tools, thus freeing the developers from being bothered with the low level
hardware and algorithm details.

.. code-block:: c

	struct ipu3_uapi_params {
		/* Flags which of the settings below are to be applied */
		struct ipu3_uapi_flags use;

		/* Accelerator cluster parameters */
		struct ipu3_uapi_acc_param acc_param;

		/* ISP vector address space parameters */
		struct ipu3_uapi_isp_lin_vmem_params lin_vmem_params;
		struct ipu3_uapi_isp_tnr3_vmem_params tnr3_vmem_params;
		struct ipu3_uapi_isp_xnr3_vmem_params xnr3_vmem_params;

		/* ISP data memory (DMEM) parameters */
		struct ipu3_uapi_isp_tnr3_params tnr3_dmem_params;
		struct ipu3_uapi_isp_xnr3_params xnr3_dmem_params;

		/* Optical black level compensation */
		struct ipu3_uapi_obgrid_param obgrid_param;
	};

Intel IPU3 ImgU uAPI data types
===============================

.. kernel-doc:: drivers/staging/media/ipu3/include/uapi/intel-ipu3.h


code:
.. SPDX-License-Identifier: GPL-2.0

.. _v4l2-meta-fmt-rk-isp1-params:

.. _v4l2-meta-fmt-rk-isp1-stat-3a:

*****************************************************************************
V4L2_META_FMT_RK_ISP1_PARAMS ('rk1p'), V4L2_META_FMT_RK_ISP1_STAT_3A ('rk1s')
*****************************************************************************

Configuration parameters
========================

The configuration parameters are passed to the
:ref:`rkisp1_params <rkisp1_params>` metadata output video node, using
the :c:type:`v4l2_meta_format` interface. The buffer contains
a single instance of the C structure :c:type:`rkisp1_params_cfg` defined in
``rkisp1-config.h``. So the structure can be obtained from the buffer by:

.. code-block:: c

	struct rkisp1_params_cfg *params = (struct rkisp1_params_cfg*) buffer;

.. rkisp1_stat_buffer

3A and histogram statistics
===========================

The ISP1 device collects different statistics over an input Bayer frame.
Those statistics are obtained from the :ref:`rkisp1_stats <rkisp1_stats>`
metadata capture video node,
using the :c:type:`v4l2_meta_format` interface. The buffer contains a single
instance of the C structure :c:type:`rkisp1_stat_buffer` defined in
``rkisp1-config.h``. So the structure can be obtained from the buffer by:

.. code-block:: c

	struct rkisp1_stat_buffer *stats = (struct rkisp1_stat_buffer*) buffer;

The statistics collected are Exposure, AWB (Auto-white balance), Histogram and
AF (Auto-focus). See :c:type:`rkisp1_stat_buffer` for details of the statistics.

The 3A statistics and configuration parameters described here are usually
consumed and produced by dedicated user space libraries that comprise the
important tuning tools using software control loop.

rkisp1 uAPI data types
======================

.. kernel-doc:: include/uapi/linux/rkisp1-config.h


code:
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later

.. _v4l2-meta-fmt-uvc:

*******************************
V4L2_META_FMT_UVC ('UVCH')
*******************************

UVC Payload Header Data

Description
===========

This format describes standard UVC metadata, extracted from UVC packet headers
and provided by the UVC driver through metadata video nodes. That data includes
exact copies of the standard part of UVC Payload Header contents and auxiliary
timing information, required for precise interpretation of timestamps, contained
in those headers. See section "2.4.3.3 Video and Still Image Payload Headers" of
the "UVC 1.5 Class specification" for details.

Each UVC payload header can be between 2 and 12 bytes large. Buffers can
contain multiple headers, if multiple such headers have been transmitted by the
camera for the respective frame. However, the driver may drop headers when the
buffer is full, when they contain no useful information (e.g. those without the
SCR field or with that field identical to the previous header), or generally to
perform rate limiting when the device sends a large number of headers.

Each individual block contains the following fields:

.. flat-table:: UVC Metadata Block
    :widths: 1 4
    :header-rows:  1
    :stub-columns: 0

    * - Field
      - Description
    * - __u64 ts;
      - system timestamp in host byte order, measured by the driver upon
        reception of the payload
    * - __u16 sof;
      - USB Frame Number in host byte order, also obtained by the driver as
        close as possible to the above timestamp to enable correlation between
        them
    * - :cspan:`1` *The rest is an exact copy of the UVC payload header:*
    * - __u8 length;
      - length of the rest of the block, including this field
    * - __u8 flags;
      - Flags, indicating presence of other standard UVC fields
    * - __u8 buf[];
      - The rest of the header, possibly including UVC PTS and SCR fields