metaDataRetrieve interface
Posted: Wed Feb 17, 2010 5:20 pm
Hello,
I have some problems retrieving metadata from a flex-file:
1)
I saw, that there are methods to get information about the objectives (NA, magnification...). In their function signature ther is a 'objectiveIndex' parameter to access the objectives attributes. However I couldn't find any way to determine the index from an attribute of the image plane that I'm currently reading.
This is the method from the 'metaDataRetrieve' class I would like to use to:
getObjectiveLensNA(int instrumentIndex, int objectiveIndex)
But where do I get the link between image and Objective from????
2)
Some methods of 'metaDataRetrieve' also need a 'pixelsIndex' parmeter. What does that refer to?
Here is the an extract of a matlab-script to get an idea how I use the API:
reader = loci.formats.in.FlexReader();
metaDataScheme = loci.formats.ome.OMEXML200809Metadata();
imageReader = loci.formats.gui.BufferedImageReader(reader);
imageReader.setMetadataStore(metaDataScheme)
imageReader.setId(absoluteFlexFilePath);
metaData = imageReader.getMetadataStore();
% Read the image planes.
for s = 1:imageReader.getSeriesCount();
imageReader.setSeries(s - 1);
for i = 1:imageReader.getImageCount();
img = imageReader.openImage(i - 1);
pix = img.getData.getPixels(0, ...
0, ...
imageReader.getSizeX(), ...
imageReader.getSizeY(), ...
[]);
zct = imageReader.getZCTCoords(i - 1);
imageIndex = imageReader.getIndex(zct(1), zct(2), zct(3));
attribute = metaData.getPixelsCount(imageIndex)
%etc.
end
end
I have some problems retrieving metadata from a flex-file:
1)
I saw, that there are methods to get information about the objectives (NA, magnification...). In their function signature ther is a 'objectiveIndex' parameter to access the objectives attributes. However I couldn't find any way to determine the index from an attribute of the image plane that I'm currently reading.
This is the method from the 'metaDataRetrieve' class I would like to use to:
getObjectiveLensNA(int instrumentIndex, int objectiveIndex)
But where do I get the link between image and Objective from????
2)
Some methods of 'metaDataRetrieve' also need a 'pixelsIndex' parmeter. What does that refer to?
Here is the an extract of a matlab-script to get an idea how I use the API:
reader = loci.formats.in.FlexReader();
metaDataScheme = loci.formats.ome.OMEXML200809Metadata();
imageReader = loci.formats.gui.BufferedImageReader(reader);
imageReader.setMetadataStore(metaDataScheme)
imageReader.setId(absoluteFlexFilePath);
metaData = imageReader.getMetadataStore();
% Read the image planes.
for s = 1:imageReader.getSeriesCount();
imageReader.setSeries(s - 1);
for i = 1:imageReader.getImageCount();
img = imageReader.openImage(i - 1);
pix = img.getData.getPixels(0, ...
0, ...
imageReader.getSizeX(), ...
imageReader.getSizeY(), ...
[]);
zct = imageReader.getZCTCoords(i - 1);
imageIndex = imageReader.getIndex(zct(1), zct(2), zct(3));
attribute = metaData.getPixelsCount(imageIndex)
%etc.
end
end