How to import data from custom format file(file has custom const header(custom struct))?

Как импортировать данные из файла пользовательского формата (файл имеет пользовательский заголовок const (пользовательская структура))?
Спасибо.

1 件のコメント

Stephen23
Stephen23 2020 年 5 月 12 日
@Yauheni Babok: please upload a sample file by clicking on the paperclip button.

サインインしてコメントする。

回答 (1 件)

Yauheni Babok
Yauheni Babok 2020 年 5 月 12 日
編集済み: Yauheni Babok 2020 年 5 月 12 日

0 投票

Thank you very much for answer!!! I decided my some question)))
Part of my code:
fid = fopen (f_name, 'rb');
file_id = fread (fid, 3, 'uchar')
% file_id_s = dec2hex(file_id)
FileVerMaj = fread (fid, 1, 'uint8')
FileVerMin = fread (fid, 1, 'uint8')
FileSize = fread (fid, 1, 'uint32')
ImgWidth = fread (fid, 1, 'uint16')
ImgHeight = fread (fid, 1, 'uint16')
and so on.

カテゴリ

質問済み:

2020 年 5 月 12 日

編集済み:

2020 年 5 月 12 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by