read multiple images contained in a proprietary microscope file

2 ビュー (過去 30 日間)
arnold
arnold 2013 年 7 月 24 日
Hi!
I'd like to extract several images that are contained in an Olympus *.LEXT file. A HEX Editor quickly revealed, there are several files just thrown together in this one file. I figures I use imfinfo to gain some more information and it finds 5 images contained in the file, thus returns a struct with five entries.
My question now is:
How can I extract all those images? Using imread on the file only loads the first image file. Is there a readily available function that solves this, do I have to dissect the file manually somehow? My guess would be that via the exact image locations in the file are somehow given by StripOffsets and StripByteCounts but I don't know if that is actually the case nor do I have a clue how to extract the data then.
I'm kinda stuck here, I'd appreciate any advice.
  1 件のコメント
arnold
arnold 2013 年 7 月 24 日
Found a solution myself. imread provides everything I needed. This code extracts all the images like a charm:
info = imfinfo(file);
A = imread(file, 1, 'Info', info);
B = imread(file, 2, 'Info', info);
C = imread(file, 3, 'Info', info);
D = imread(file, 4, 'Info', info);
E = imread(file, 5, 'Info', info);
regards
Arnold

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

回答 (0 件)

カテゴリ

Help Center および File ExchangeImport, Export, and Conversion についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by