Continue reading file after inner loop completes?
조회 수: 1(최근 30일)
Now I'm reading the file in the matlab environment, but there was a problem, I can't force the file to be read after the loop is completed. The file consists of four parts, my code reads the first part without problems, all sizes are written in the first part (the number of bytes to read), there is no such thing in other parts (but I know them)
fileID = fopen(fileName);
while (~feof(fileID)) && (ftell(fileID)<filesize)
if (block==0)&&(bitand(bitmask,2))&&(bitand(bitmask,8)) % this loop reads the first 220 bytes of each block
Now the file reads the first 20 bytes, and then makes a matrix out of 200 bytes. The structure of each group of blocks looks like this: blok(220,400,600,1000). How to continue reading bytes knowing their size (matrices should be obtained (with sizes of 400xN, 600xN values)?
I will be glad for any help