Interface AdvancedFboAttachment
- All Superinterfaces:
AutoCloseable,Cloneable,org.lwjgl.system.NativeResource
- All Known Implementing Classes:
AdvancedFboMutableTextureAttachment,AdvancedFboRenderAttachment,AdvancedFboTextureAttachment
An attachment added to an
AdvancedFboImpl.-
Method Summary
Modifier and TypeMethodDescriptionvoidattach(AdvancedFbo framebuffer, int attachment) Attaches this attachment to the provided target under the specified attachment point.voidBinds this attachment.booleanclone()voidcreate()Creates the attachment and initializes it with the default properties.intReturns the OpenGL attachment point.intint@Nullable StringgetName()voidUnbinds this attachment.Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Method Details
-
create
void create()Creates the attachment and initializes it with the default properties. -
attach
Attaches this attachment to the provided target under the specified attachment point.- Parameters:
framebuffer- The framebuffer to attach toattachment- The attachment point to add this attachment to
-
bindAttachment
void bindAttachment()Binds this attachment. -
unbindAttachment
void unbindAttachment()Unbinds this attachment. -
getAttachmentType
int getAttachmentType()Returns the OpenGL attachment point. One of:
All possible OpenGL attachment points COLOR_ATTACHMENT0COLOR_ATTACHMENT1COLOR_ATTACHMENT2COLOR_ATTACHMENT3COLOR_ATTACHMENT4COLOR_ATTACHMENT5COLOR_ATTACHMENT6COLOR_ATTACHMENT7COLOR_ATTACHMENT8COLOR_ATTACHMENT9COLOR_ATTACHMENT10COLOR_ATTACHMENT11COLOR_ATTACHMENT12COLOR_ATTACHMENT13COLOR_ATTACHMENT14COLOR_ATTACHMENT15COLOR_ATTACHMENT16COLOR_ATTACHMENT17COLOR_ATTACHMENT18COLOR_ATTACHMENT19COLOR_ATTACHMENT20COLOR_ATTACHMENT21COLOR_ATTACHMENT22COLOR_ATTACHMENT23COLOR_ATTACHMENT24COLOR_ATTACHMENT25COLOR_ATTACHMENT26COLOR_ATTACHMENT27COLOR_ATTACHMENT28COLOR_ATTACHMENT29COLOR_ATTACHMENT30COLOR_ATTACHMENT31DEPTH_ATTACHMENTSTENCIL_ATTACHMENTDEPTH_STENCIL_ATTACHMENT- Returns:
- OpenGL attachment point
-
getFormat
int getFormat()- Returns:
- The OpenGL format for this attachment
-
getLevels
int getLevels()- Returns:
- Texture targets return mipmaps and render targets return samples.
-
canSample
boolean canSample()- Returns:
- Whether this attachment can be read from
-
getName
- Returns:
- The custom name of this attachment or
nullto useDiffuseSampler#
-
clone
AdvancedFboAttachment clone()- Returns:
- A new identical attachment to this one
-