Commit 592d1349 authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab

[media] Docbook/media: improve data_offset/bytesused documentation

This patch explicitly documents the relationship between bytesused and data_offset.
Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <m.chehab@samsung.com>
parent e87b540b
...@@ -870,7 +870,8 @@ should set this to 0.</entry> ...@@ -870,7 +870,8 @@ should set this to 0.</entry>
If the application sets this to 0 for an output stream, then If the application sets this to 0 for an output stream, then
<structfield>bytesused</structfield> will be set to the size of the <structfield>bytesused</structfield> will be set to the size of the
plane (see the <structfield>length</structfield> field of this struct) plane (see the <structfield>length</structfield> field of this struct)
by the driver.</entry> by the driver. Note that the actual image data starts at
<structfield>data_offset</structfield> which may not be 0.</entry>
</row> </row>
<row> <row>
<entry>__u32</entry> <entry>__u32</entry>
...@@ -919,6 +920,10 @@ should set this to 0.</entry> ...@@ -919,6 +920,10 @@ should set this to 0.</entry>
<entry>Offset in bytes to video data in the plane. <entry>Offset in bytes to video data in the plane.
Drivers must set this field when <structfield>type</structfield> Drivers must set this field when <structfield>type</structfield>
refers to an input stream, applications when it refers to an output stream. refers to an input stream, applications when it refers to an output stream.
Note that data_offset is included in <structfield>bytesused</structfield>.
So the size of the image in the plane is
<structfield>bytesused</structfield>-<structfield>data_offset</structfield> at
offset <structfield>data_offset</structfield> from the start of the plane.
</entry> </entry>
</row> </row>
<row> <row>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment