Todo
Revisit this when Java 7.0 is released, there will be new Buffer API with 64bit indices/sizes.
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv static int | Returns: the region size in bytesthe host offset offset, final PointerBuffer the rectangle region region, long the host row pitch row_pitch, long the host slice pitch slice_pitch)Calculates the number of bytes in the specified cl_mem buffer rectangle region. |
| pack-priv static int | Returns: the 2D image size in bytesthe cl_image_format struct format, final long the image width w, final long the image height h, long the image row pitch row_pitch)Calculates the number of bytes in the specified 2D image. |
| pack-priv static int | Returns: the 3D image size in bytesthe cl_image_format struct format, final long the image width w, final long the image height h, final long the image depth d, long the image row pitch row_pitch, long the image slice pitch slice_pitch)Calculates the number of bytes in the specified 3D image. |
| pack-priv static int | Returns: the region size in bytesthe image region region, long the row pitch row_pitch, long the slice pitch slice_pitch)Calculates the number of bytes in the specified cl_mem image region. |
| private static int | Returns: the number of channelsthe cl_channel_order channelOrder)Returns the number of channels in the specified cl_channel_order. |
| private static int | Returns: the number of bytesthe cl_channel_type channelType)Returns the number of bytes in the specified cl_channel_type. |
| private static int | Returns: the number of bytes per image elementa cl_image_format struct. format)Returns the number of bytes per element for the specified image format. |
| CLChecks | back to summary |
|---|---|
| private CLChecks() | |
| calculateBufferRectSize | back to summary |
|---|---|
| pack-priv static int calculateBufferRectSize(final PointerBuffer offset, final PointerBuffer region, long row_pitch, long slice_pitch) Calculates the number of bytes in the specified cl_mem buffer rectangle region.
| |
| calculateImage2DSize | back to summary |
|---|---|
| pack-priv static int calculateImage2DSize(final ByteBuffer format, final long w, final long h, long row_pitch) Calculates the number of bytes in the specified 2D image.
| |
| calculateImage3DSize | back to summary |
|---|---|
| pack-priv static int calculateImage3DSize(final ByteBuffer format, final long w, final long h, final long d, long row_pitch, long slice_pitch) Calculates the number of bytes in the specified 3D image.
| |
| calculateImageSize | back to summary |
|---|---|
| pack-priv static int calculateImageSize(final PointerBuffer region, long row_pitch, long slice_pitch) Calculates the number of bytes in the specified cl_mem image region. This implementation assumes 1 byte per element, because we cannot the image type.
| |
| getChannelCount | back to summary |
|---|---|
| private static int getChannelCount(final int channelOrder) Returns the number of channels in the specified cl_channel_order.
| |
| getChannelSize | back to summary |
|---|---|
| private static int getChannelSize(final int channelType) Returns the number of bytes in the specified cl_channel_type.
| |
| getElementSize | back to summary |
|---|---|
| private static int getElementSize(final ByteBuffer format) Returns the number of bytes per element for the specified image format.
| |