public class ReorderedPixelData extends PixelData
read-only
buffers may be used and
potential callers of getData()
should be aware of this restriction.PixelData
Constructor and Description |
---|
ReorderedPixelData(java.lang.String pixelsType,
java.nio.ByteBuffer data,
int rowSize)
Default constructor.
|
Modifier and Type | Method and Description |
---|---|
java.nio.ByteBuffer |
getData()
Returns the backing buffer for the pixel data.
|
java.nio.ByteOrder |
getOrder()
Returns the byte order of the backing buffer.
|
double |
getPixelValueDirect(int offset)
Returns the pixel intensity value of the pixel at a given offset within
the backing buffer.
|
static int |
getReorderedPixelOffset(int size,
int offset,
int rowSize)
Returns the re-ordered pixel offset.
|
void |
setOrder(java.nio.ByteOrder order)
Set the byte order of the backing buffer.
|
bytesPerPixel, dispose, getBitDepth, getMaximum, getMinimum, getPixelValue, in, isFloat, isSigned, javaType, setPixelValue, setPixelValueDirect, size
public ReorderedPixelData(java.lang.String pixelsType, java.nio.ByteBuffer data, int rowSize)
pixelsType
- The OME pixels type.data
- The raw pixel data.rowSize
- The size of each pixels row in bytes.public static int getReorderedPixelOffset(int size, int offset, int rowSize)
size
- The number of rows in the array.offset
- The offset within the array of rows assuming a top left
origin.rowSize
- The size of each pixels row in bytes.public double getPixelValueDirect(int offset)
getPixelValueDirect
in class PixelData
offset
- The absolute offset within the backing buffer.public java.nio.ByteBuffer getData()
public java.nio.ByteOrder getOrder()
Version: 5.4.6-ice35-b87
Copyright © 2018 The University of Dundee & Open Microscopy Environment. All Rights Reserved.