Commit 00d0fae7 authored by Andrey Filippov's avatar Andrey Filippov

upgraded imagej and added explicit .convertToColorProcessor() before

casting float pixels to int[]
parent 7180569b
...@@ -51,7 +51,8 @@ ...@@ -51,7 +51,8 @@
<groupId>net.imagej</groupId> <groupId>net.imagej</groupId>
<artifactId>ij</artifactId> <artifactId>ij</artifactId>
<!-- <version>1.52e</version> --> <!-- <version>1.52e</version> -->
<version>1.53j</version> <!-- <version>1.53j</version> -->
<version>1.54f</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.jcuda</groupId> <groupId>org.jcuda</groupId>
......
...@@ -3630,7 +3630,7 @@ public class QuadCLT extends QuadCLTCPU { ...@@ -3630,7 +3630,7 @@ public class QuadCLT extends QuadCLTCPU {
float [][] texture_rgba = isMonochrome() ? (new float [][] {texture_img[0],texture_img[1]}) : (new float [][] {texture_img[0],texture_img[1],texture_img[2],texture_img[3]}); float [][] texture_rgba = isMonochrome() ? (new float [][] {texture_img[0],texture_img[1]}) : (new float [][] {texture_img[0],texture_img[1],texture_img[2],texture_img[3]});
boolean toRGB = !isLwir() || colorProcParameters.lwir_pseudocolor; boolean toRGB = !isLwir() || colorProcParameters.lwir_pseudocolor;
ImagePlus imp_texture_bgnd = linearStackToColor( ImagePlus imp_texture_bgnd = linearStackToColor( // floatProcessor
clt_parameters, clt_parameters,
colorProcParameters, colorProcParameters,
rgbParameters, rgbParameters,
......
...@@ -13170,7 +13170,7 @@ public class QuadCLTCPU { ...@@ -13170,7 +13170,7 @@ public class QuadCLTCPU {
// int v_margin = (int) Math.round((backdropPixels - height)/2); // int v_margin = (int) Math.round((backdropPixels - height)/2);
// int width2 = width + 2 * h_margin; // int width2 = width + 2 * h_margin;
// int height2 = height + 2 * v_margin; // int height2 = height + 2 * v_margin;
int [] src_pixels = (int []) imp.getProcessor().getPixels(); int [] src_pixels = (int []) imp.getProcessor().convertToColorProcessor().getPixels();
int [] pixels = new int [out_width * out_height]; int [] pixels = new int [out_width * out_height];
int black = noalpha ? 0 : 0xff000000; int black = noalpha ? 0 : 0xff000000;
int mask = noalpha ? 0xffffff : 0xffffffff; int mask = noalpha ? 0xffffff : 0xffffffff;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment