CLIJ2

Logo

GPU accelerated image processing for everyone

CLIJ2 home

zPositionProjection

Project a defined Z-slice of a 3D stack into a 2D image.

The slice is determined using a separate 2D image.

Category: Projections

Availability: Available in Fiji by activating the update sites clij and clij2. This function is part of clijx_-0.30.1.21.jar.

Usage in ImageJ macro

Ext.CLIJx_zPositionProjection(Image source_stack, Image z_position, Image destination);

Usage in object oriented programming languages

Java
// init CLIJ and GPU
import net.haesleinhuepf.clijx.CLIJx;
import net.haesleinhuepf.clij.clearcl.ClearCLBuffer;
CLIJx clijx = CLIJx.getInstance();

// get input parameters
ClearCLBuffer source_stack = clijx.push(source_stackImagePlus);
ClearCLBuffer z_position = clijx.push(z_positionImagePlus);
destination = clijx.create(source_stack);
// Execute operation on GPU
clijx.zPositionProjection(source_stack, z_position, destination);
// show result
destinationImagePlus = clijx.pull(destination);
destinationImagePlus.show();

// cleanup memory on GPU
clijx.release(source_stack);
clijx.release(z_position);
clijx.release(destination);
Matlab
% init CLIJ and GPU
clijx = init_clatlabx();

% get input parameters
source_stack = clijx.pushMat(source_stack_matrix);
z_position = clijx.pushMat(z_position_matrix);
destination = clijx.create(source_stack);
% Execute operation on GPU
clijx.zPositionProjection(source_stack, z_position, destination);
% show result
destination = clijx.pullMat(destination)

% cleanup memory on GPU
clijx.release(source_stack);
clijx.release(z_position);
clijx.release(destination);

Back to CLIJ2 reference Back to CLIJ2 documentation

Imprint