You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi,
I try to open ivf file and get raw obu data from packet. In documentation you write that parameter offset should get offet in buffer. But how to understand those values?
Each call to obp_get_next_obu() will have a different buffer pointer, so the offset can be the same, as it points to the start of that OBU's data inside the buffer, after the OBU header. You can see that it changes here in the example file: https://github.com/dwbuiten/obuparse/blob/master/tools/obudump.c#L232.
In your example above, the first packet contains:
OBU of type 2, with size 0, offset of 2. (It's empty)
OBU of type 1, with size 11, offset of 2.
OBU of type 6, wiith size 4224, offset of 3.
2 + 0 + 2 + 11 + 3 + 4224 = 4242.
Example diagram of that packet:
-----------------------------------------------------------------------------------------------------------------------------------------
| Header 1 (2 bytes) | OBU Data 1 (0 bytes) | Header 2 (2 bytes) | OBU Data 2 (11 bytes) | Header 3 (3 bytes) | OBU Data 3 (4224 bytes) |
-----------------------------------------------------------------------------------------------------------------------------------------
Hi,
I try to open ivf file and get raw obu data from packet. In documentation you write that parameter offset should get offet in buffer. But how to understand those values?
{"packet_number": 0, "packet_size": 4242}
{"obu_type": 2, "offset": 2, "obu_size": 0, "temporal_id": 0, "spatial_id": 0}
{"obu_type": 1, "offset": 2, "obu_size": 11, "temporal_id": 0, "spatial_id": 0}
{"obu_type": 6, "offset": 3, "obu_size": 4224, "temporal_id": 0, "spatial_id": 0}
{"packet_number": 1, "packet_size": 75}
{"obu_type": 2, "offset": 2, "obu_size": 0, "temporal_id": 0, "spatial_id": 0}
{"obu_type": 6, "offset": 2, "obu_size": 31, "temporal_id": 0, "spatial_id": 0}
{"obu_type": 6, "offset": 2, "obu_size": 38, "temporal_id": 0, "spatial_id": 0}
Packet 0 = 4224 + 11 != 4242
Why two OBUs has same offset?
The text was updated successfully, but these errors were encountered: