<html>
<head>
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
I'm not used to mailing lists and reporting bugs, sorry if I do this
in a unintended way.<br>
<br>
In ImageConverter.java (from
<meta http-equiv="content-type" content="text/html;
charset=ISO-8859-1">
<a
href="https://raw.github.com/openmicroscopy/bioformats/develop/components/scifio-tools/src/loci/formats/tools/ImageConverter.java">https://raw.github.com/openmicroscopy/bioformats/develop/components/scifio-tools/src/loci/formats/tools/ImageConverter.java</a>,
obtained today, 2013 September 21st 14:54 UTC+1), lines 573-574
read:<br>
<br>
int tileWidth = x < nXTiles - 1 ? w : width % w;<br>
int tileHeight = y < nYTiles - 1 ? h : height % h;<br>
<br>
When processing the last tile in a row:<br>
<br>
If the width isn't divisable with tileWidth (like 5 isn't divisable
with 2, we have 1 left), this works fine. But if the width is
divisable with tileWidth (like 4 is divisable with 2), tileWidth is
assigned zero (because 4 % 2 is zero). In this case,
reader.openBytes(...) failes with some large file error.<br>
<br>
Sollution:<br>
<br>
int tileWidth = x < nXTiles - 1 ? w : width - (w*x);<br>
int tileHeight = y < nYTiles - 1 ? h : height - (h*y);<br>
<br>
With these lines (when processing the last tile in a row), tileWidth
is assigned the remaining width not yet processed.<br>
<br>
I'm sorry, I don't know how to apply this to github, but I hope this
mail is helpful.<br>
<br>
- Kristian Kjærgaard<br>
</body>
</html>