Bug 1037 - FBObject/GLFBODrawable: Do not assume using a TextureAttachment for a Colorbuffer, also make DEPTH optional.
Summary: FBObject/GLFBODrawable: Do not assume using a TextureAttachment for a Colorbu...
Status: RESOLVED FIXED
Alias: None
Product: Jogl
Classification: JogAmp
Component: core (show other bugs)
Version: 2
Hardware: All all
: --- enhancement
Assignee: Sven Gothel
URL:
Depends on:
Blocks: 1016
  Show dependency treegraph
 
Reported: 2014-07-28 01:19 CEST by Sven Gothel
Modified: 2014-07-28 18:40 CEST (History)
2 users (show)

See Also:
Type: ---
SCM Refs:
e96882ae569c681e1b28da6701bf547f6dd9eda8 1d813dbb19ee20c7d0a3a4614c88e3733fd489dc
Workaround: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sven Gothel 2014-07-28 01:19:49 CEST
In certain cases a TextureAttachment for the FBO's color buffer
is not desired, either for performance reasons where texture functionality
is not required or to avoid texture restrictions like size, etc.
Comment 1 Sven Gothel 2014-07-28 15:20:35 CEST
GLFBODrawable shall use TextureAttachment for the FBO's color buffer
and a DEPTH buffer per default.

However, the user shall be allowed to use a plain ColorAttachment (renderbuffer)
and also no DEPTH buffer.
Comment 2 Sven Gothel 2014-07-28 15:32:51 CEST
commit e96882ae569c681e1b28da6701bf547f6dd9eda8:

- Colorbuffer interface exposes Attachment details
  like format, size, etc as well as it's implementation
  specifics, isTextureAttachment() and getTextureAttachment() 
  allowing a clean   cast and type query.

- Allow ColorAttachment to be used for non MSAA

- Make TextureAttachment optional for method 'use(GL, TextureAttachment)'

- Only validate size against MAX_TEXTURESIZE if using a TextureAttachment

- API Change:
- rename: getColorAttachmentCount() -> getColorbufferCount()
- add: getTextureAttachmentCount()
- change 'TextureAttachment getSamplingSink()' -> 'Colorbuffer getSamplingSink()'
Comment 3 Sven Gothel 2014-07-28 18:40:08 CEST
1d813dbb19ee20c7d0a3a4614c88e3733fd489dc:

FBObject: Add proper attachment size validation at init, reset and attachColorbuffer(..) / attachRenderbuffer(..)