Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MicroManager: use PositionName key/value for storing the ImageName (rebased onto metadata54) #3092

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 11 additions & 3 deletions components/formats-bsd/src/loci/formats/in/MicromanagerReader.java
Original file line number Diff line number Diff line change
Expand Up @@ -317,9 +317,13 @@ private void populateMetadata() throws FormatException, IOException {
}
}

if (positions.size() > 1) {
Location parent = new Location(p.metadataFile).getParentFile();
store.setImageName(parent.getName(), i);
if (p.name != null) {
store.setImageName(p.name, i);
} else {
if (positions.size() > 1) {
Location parent = new Location(p.metadataFile).getParentFile();
store.setImageName(parent.getName(), i);
}
}

if (getMetadataOptions().getMetadataLevel() != MetadataLevel.MINIMUM) {
Expand Down Expand Up @@ -850,6 +854,9 @@ else if (key.equals(p.cameraRef + "-CCDMode")) {
else if (key.startsWith("DAC-") && key.endsWith("-Volts")) {
p.voltage.add(new Double(value));
}
else if (key.equals("PositionName") && !value.equals("null")) {
p.name = value;
}
else if (key.equals("FileName")) {
p.fileNameMap.put(new Index(slice), value);
Location realFile = new Location(parent, value);
Expand Down Expand Up @@ -1097,6 +1104,7 @@ class Position {

public String metadataFile;
public String xmlFile;
public transient String name;

public String[] channels;

Expand Down