Package com.jogamp.opencl
Class CLImage<B extends Buffer>
- java.lang.Object
-
- com.jogamp.opencl.CLObject
-
- com.jogamp.opencl.CLMemory<B>
-
- com.jogamp.opencl.CLImage<B>
-
- All Implemented Interfaces:
AutoCloseable
,CLResource
,AutoCloseable
public abstract class CLImage<B extends Buffer> extends CLMemory<B>
- Author:
- Michael Bien, et al.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
CLImage.CLImageInfoAccessor
-
Nested classes/interfaces inherited from class com.jogamp.opencl.CLMemory
CLMemory.GLObjectType, CLMemory.Map, CLMemory.Mem
-
-
Field Summary
Fields Modifier and Type Field Description protected CLImageFormat
format
int
height
int
width
-
Fields inherited from class com.jogamp.opencl.CLMemory
clCapacity, elementSize, FLAGS, size
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
CLImage(CLContext context, B directBuffer, CLImageFormat format, int width, int height, long id, int flags)
protected
CLImage(CLContext context, B directBuffer, CLImageFormat format, CLImage.CLImageInfoAccessor accessor, int width, int height, long id, int flags)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
close()
Deprecated.This method is not intended to be called from client code.protected static CLImageFormat
createUninitializedImageFormat()
int
getElementSize()
Returns the size of each element of the image memory object given by image.CLImageFormat
getFormat()
Returns the image format descriptor specified when image was created.int
getHeight()
Returns the height of this image in pixels.int
getRowPitch()
Returns the size in bytes of a row of elements of the image object given by image.int
getWidth()
Returns width of this image in pixels.boolean
isReleased()
Returns true ifCLResource.release()
has been called.-
Methods inherited from class com.jogamp.opencl.CLMemory
cloneWith, equals, getBuffer, getCL, getCLCapacity, getCLSize, getConfig, getMapCount, getNIOCapacity, getNIOSize, getSizeImpl, hashCode, initCLCapacity, isHostPointerFlag, isReadOnly, isReadWrite, isWriteOnly, registerDestructorCallback, release, toString, use
-
Methods inherited from class com.jogamp.opencl.CLObject
getContext, getID, getPlatform
-
-
-
-
Field Detail
-
format
protected CLImageFormat format
-
width
public final int width
-
height
public final int height
-
-
Constructor Detail
-
CLImage
protected CLImage(CLContext context, B directBuffer, CLImageFormat format, int width, int height, long id, int flags)
-
CLImage
protected CLImage(CLContext context, B directBuffer, CLImageFormat format, CLImage.CLImageInfoAccessor accessor, int width, int height, long id, int flags)
-
-
Method Detail
-
createUninitializedImageFormat
protected static CLImageFormat createUninitializedImageFormat()
-
getFormat
public CLImageFormat getFormat()
Returns the image format descriptor specified when image was created.
-
getElementSize
public int getElementSize()
Returns the size of each element of the image memory object given by image. An element is made up of n channels. The value of n is given inCLImageFormat
descriptor.- Overrides:
getElementSize
in classCLMemory<B extends Buffer>
-
getRowPitch
public int getRowPitch()
Returns the size in bytes of a row of elements of the image object given by image.
-
getWidth
public int getWidth()
Returns width of this image in pixels.
-
getHeight
public int getHeight()
Returns the height of this image in pixels.
-
close
@Deprecated public final void close()
Deprecated.This method is not intended to be called from client code.Implementation detail, satisfyingAutoCloseable
. Might be remove as soon we have extension methods, but shall validate with Java 1.5 specs.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceAutoCloseable
- See Also:
AutoCloseable
-
isReleased
public boolean isReleased()
Description copied from interface:CLResource
Returns true ifCLResource.release()
has been called.- Specified by:
isReleased
in interfaceCLResource
-
-