Package com.jogamp.opengl
Class FBObject.Attachment
java.lang.Object
com.jogamp.opengl.FBObject.Attachment
- Direct Known Subclasses:
FBObject.RenderAttachment,FBObject.TextureAttachment
- Enclosing class:
- FBObject
Common super class of all FBO attachments
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal intimmutable the internal formatfinal FBObject.Attachment.Typeimmutable type [#COLOR,#DEPTH,#STENCIL,#COLOR_TEXTURE,#DEPTH_TEXTURE,#STENCIL_TEXTURE] -
Method Summary
Modifier and TypeMethodDescriptionbooleanfinal voidformatToGLCapabilities(GLCapabilities caps, boolean rgba8Avail) Writes the internal format to the given GLCapabilities object.abstract voidReleases the attachment if initialized, i.e.final intimmutable internal format of attachmentfinal intheight of attachmentfinal intgetName()buffer name [1..max], maybe a texture or renderbuffer name, depending on type.static FBObject.Attachment.TypegetType(int attachmentPoint, int maxColorAttachments) final intgetWidth()width of attachmentinthashCode()abstract booleaninitialize(GL gl) Initializes the attachment and set it's parameter, if uninitialized, i.e.toString()
-
Field Details
-
type
immutable type [#COLOR,#DEPTH,#STENCIL,#COLOR_TEXTURE,#DEPTH_TEXTURE,#STENCIL_TEXTURE] -
format
public final int formatimmutable the internal format
-
-
Method Details
-
formatToGLCapabilities
Writes the internal format to the given GLCapabilities object.- Parameters:
caps- the destination for format bitsrgba8Avail- whether rgba8 is available
-
getFormat
public final int getFormat()immutable internal format of attachment -
getWidth
public final int getWidth()width of attachment -
getHeight
public final int getHeight()height of attachment -
getName
public final int getName()buffer name [1..max], maybe a texture or renderbuffer name, depending on type. -
initialize
Initializes the attachment and set it's parameter, if uninitialized, i.e. name iszero.final boolean init = 0 == name; if( init ) { do init .. } return init;- Returns:
trueif newly initialized, otherwisefalse.- Throws:
GLException- if buffer generation or setup fails. The just created buffer name will be deleted in this case.
-
free
Releases the attachment if initialized, i.e. name is notzero.if(0 != name) { do free .. name = 0; }- Throws:
GLException- if buffer release fails.
-
equals
-
hashCode
public int hashCode() -
toString
-
getType
-