Skip to content
Snippets Groups Projects
Commit 90514ea6 authored by Vojtech Moravec's avatar Vojtech Moravec
Browse files

Fix InputDataInfo configuration in parseSCIFIOFileArguments.

parent 6b866325
No related branches found
No related tags found
No related merge requests found
......@@ -204,10 +204,9 @@ public class CompressionOptionsCLIParser extends CompressionOptions implements C
private void parseSCIFIOFileArguments(final StringBuilder errorBuilder, final String[] inputFileArguments) {
getInputDataInfo().setDataLoaderType(InputData.DataLoaderType.SCIFIOLoader);
final Reader reader;
try {
reader = ScifioWrapper.getReader(getInputDataInfo().getFilePath());
reader = ScifioWrapper.getReader(inputFileArguments[0]);
} catch (final IOException | FormatException e) {
parseErrorOccurred = true;
errorBuilder.append("Failed to get SCIFIO reader for file.\n");
......@@ -215,7 +214,6 @@ public class CompressionOptionsCLIParser extends CompressionOptions implements C
return;
}
final int imageCount = reader.getImageCount();
if (imageCount != 1) {
parseErrorOccurred = true;
......@@ -255,6 +253,7 @@ public class CompressionOptionsCLIParser extends CompressionOptions implements C
setInputDataInfo(new FileInputData(inputFileArguments[0], new HyperStackDimensions((int) planeWidth,
(int) planeHeight,
(int) planeCount)));
getInputDataInfo().setDataLoaderType(InputData.DataLoaderType.SCIFIOLoader);
if (inputFileArguments.length > 1) {
parseInputFilePlaneOptions(errorBuilder, inputFileArguments, 1);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment