Skip to content
Update getting started with image streams authored by Vsevolod Vlaskine's avatar Vsevolod Vlaskine
...@@ -44,7 +44,7 @@ To use **csv-play** we need to know the binary format of the stream: ...@@ -44,7 +44,7 @@ To use **csv-play** we need to know the binary format of the stream:
t,3ui,s[921600] t,3ui,s[921600]
``` ```
I.e. the format of the images output by **cv-cat** is: I.e. the format of the images output by **cv-cat** is:
- **t**: 8-byte timestamp - **t**: 8-byte UTC timestamp
- **3ui**: 3 4-byte integers (we will look into them in a minute) - **3ui**: 3 4-byte integers (we will look into them in a minute)
- **s[921600]**: followed by 921600 bytes of image (depending on your camera output, the size may be different; in my case, those are 640x480 3-byte RGB images, hence 640x480x3=921600) - **s[921600]**: followed by 921600 bytes of image (depending on your camera output, the size may be different; in my case, those are 640x480 3-byte RGB images, hence 640x480x3=921600)
...@@ -61,7 +61,11 @@ The format: **\<header\>\<image\>** ...@@ -61,7 +61,11 @@ The format: **\<header\>\<image\>**
### \<header\> ### \<header\>
Try to output only image headers: Try to output only image headers:
``` ```
> cv-cat --camera --output header-only | csv-from-bin t,3ui | head > cv-cat --camera --output header-only | csv-from-bin t,3ui | head -n4
20201119T233519.334569,480,640,16
20201119T233519.385821,480,640,16
20201119T233519.432076,480,640,16
20201119T233519.484135,480,640,16
``` ```
20-byte header has [binary format](https://gitlab.com/orthographic/comma/-/wikis/csv/getting-started:-basic-data-manipulations,-ascii-and-binary-data) **t,3ui** consisting of 20-byte header has [binary format](https://gitlab.com/orthographic/comma/-/wikis/csv/getting-started:-basic-data-manipulations,-ascii-and-binary-data) **t,3ui** consisting of
- timestamp - timestamp
... ...
......