I am dealing with large binary files and I am looking for an efficent way to index concurrent elements in an array after reading the raw binary data into an linear array.
For example:
Assume I have a linear array of 'uint8', which was read from a binary file. I know that a single "record" consists of 16 bytes and that the first three bytes of each record contains a time stamp.
What is the most efficient way to index the first three elements of the array, then increment by 13 and read the next three elements and so on until the end of the array?
For single byte elements in a recod I do the following, which is quite fast:
array = rawData(start:recordSz:end);
I would like to do something similar for multi byte elements.
Thanks!
Best Answer