Skip to content

Commit

Permalink
ND2: preserve pixel type when a multi-position dataset is found
Browse files Browse the repository at this point in the history
  • Loading branch information
melissalinkert committed Feb 19, 2025
1 parent ea96bf4 commit 329cffd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions components/formats-gpl/src/loci/formats/in/ND2Handler.java
Original file line number Diff line number Diff line change
Expand Up @@ -791,6 +791,7 @@ else if (isDimensions(key) && !imageMetadataLVExists) {
int tSize = ms0.sizeT;
int c = ms0.sizeC;
String order = ms0.dimensionOrder;
int pixelType = ms0.pixelType;
core = new CoreMetadataList();
for (int i=0; i<numSeries; i++) {
CoreMetadata ms = new CoreMetadata();
Expand All @@ -801,6 +802,7 @@ else if (isDimensions(key) && !imageMetadataLVExists) {
ms.sizeC = c == 0 ? 1 : c;
ms.sizeT = tSize == 0 ? 1 : tSize;
ms.dimensionOrder = order;
ms.pixelType = pixelType;
}
ms0 = core.get(0, 0);
}
Expand Down

0 comments on commit 329cffd

Please sign in to comment.