Questions tagged [fbo]

Framebuffer object (FBO) is an OpenGL object type that allows rendering to textures or other user-allocated image buffers. Versions of OpenGL older than 3.0 can access an extension version of this functionality.

421 questions
3
votes
1 answer

Deferred shader textures from FBO display as black

I am trying to use deferred shading to implement SSAO and I have problems to access my textures in the deferred fragment shader. The code is in C++/Qt5 and makes use of Coin3D to generate the rest of the UI (but this shouldn't really matter…
Alexandre Kaspar
  • 564
  • 6
  • 21
3
votes
1 answer

Drawing to different size FBO

I'm having an issue while using FBO. My window size is 1200x300. When I create a FBO that's 1200x300, everything is fine. However, when I create FBO with 2400x600 size (effectively, two times bigger on both axes) and try to render the exact same…
Dragan Okanovic
  • 7,509
  • 3
  • 32
  • 48
3
votes
0 answers

Render multiple qml-scenes to 3d-scene

We want to render multiple independent but similar qml-scenes and use them as textures in an additional 3d-scene, that is shown on-screen. What would be the best way to achieve this? Should we go for multiple qml-scene-graphs or use a single one and…
3
votes
1 answer

Draw the contents of the render buffer Object

Do not quite understand the operation render buffer object. For example if I want to show what is in the render buffer, I must necessarily do the render to texture? GLuint fbo,color_rbo,depth_rbo; glGenFramebuffers(1,&fbo); …
Javier Ramírez
  • 1,001
  • 2
  • 12
  • 23
3
votes
1 answer

OpenGL Driver Monitor says textures are rapidly increasing. How to find the leak?

When I run my app, OpenGL Driver Monitor says the Textures count is rapidly increasing — within 30 seconds the Textures count increases by about 45,000. But I haven't been able to find the leak. I've instrumented every glGen*() call to print out…
smokris
  • 11,740
  • 2
  • 39
  • 59
3
votes
2 answers

Render to window framebuffer and FBO to save full scale texture image

I would like to save the output of my image processing OpenGL shader program to an image file and also display the result on the screen. I know how to save the window framebuffer using glReadPixels(). However, the resolution of the screen is smaller…
informer2000
  • 399
  • 6
  • 20
3
votes
1 answer

unable to read depth values from depth texture attached to FBO

I am unable to read correct depth values from depth texture using glreadpixels function. FBO status is complete. other render targets also look fine after blitting to another FBO. code snippet: // Create the FBO glGenFramebuffers(1,…
user942502
  • 111
  • 1
  • 7
3
votes
0 answers

OpenGL: how to unbind a render buffer

Using Frame Buffer objects, I have created render buffers for color and depth and attached them to the FBO. //set up color buffer for rendering glGenRenderbuffers(1, &my_fbo_params.color_rb[i]); glBindRenderbuffer(GL_RENDERBUFFER,…
Suri
  • 41
  • 4
3
votes
1 answer

Renderbuffers larger than window size - OpenGL

I'm trying to draw to a renderbuffer (512x512) that's larger than the screen size (i.e., 320x480). After doing a glReadPixels, the image looks correct, except once the dimensions of the image exceed that of the screen size- in this example, past 320…
user1054922
  • 2,101
  • 2
  • 23
  • 37
3
votes
2 answers

glGenFramebuffers() access violation when using GLFW + GLEW

I am getting this error: "Access violation executing location 0x00000000." when I use GLFW + GLEW on Windows. I am using Windows 7. I also have my own implementation (from scratch) that that creates a window, initializes OpenGL context,…
Wagner Patriota
  • 5,494
  • 26
  • 49
3
votes
1 answer

LibGDX FrameBuffer blending

Some quick background here, I just started using the LibGDX framework for my first attempts at Android game development. I am trying to build a texture using their FrameBuffer class by placing in sprites, and I want to use this texture as a sort of…
Chime
  • 51
  • 1
  • 4
3
votes
0 answers

Geometry shaders and depth FBOs

Are there any special rules regarding rendering to an FBO when there's a geometry shader involved? Context: I'm trying to implement shadow mapping in a scene which includes different types of objects being rendered in different ways: Meshes,…
bradshire
  • 341
  • 1
  • 3
  • 6
3
votes
2 answers

Getting incomplete FBO when setting GL_RGBA16F texture format

I am using Java wrapper for OpenGL (LWJGL)I am getting GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT status if I set FBO texture attachment format to be GL_RGBA16F.In fact Anything but GL_RGBA causes this error. Here is my FBO texture…
Michael IV
  • 11,016
  • 12
  • 92
  • 223
3
votes
1 answer

Android OpenGL ES 2.0 : Can a GL_FLOAT texture be assigned to a FBO as a COLOR attachment?

I want to get the value using GL_FLOAT texture by glReadPixels. My Android device support OES_texture_float. but, it became an error to attach GL_FLOAT texture. In OpenGL ES 2.0 in Android, to attach GL_FLOAT texture to FBO is impossible? Or depend…
ckit_bara
  • 31
  • 2
2
votes
2 answers

GLSL: unable to read texture from a FBO and render to another FBO with fragment shader

I'm trying to "read" the texture attached to a first FBO (fboA), modifying it (with fragment shader) and render to a second FBO (fboB). I'm not able to figure it out, all I got is a black or white texture. Here is the…
Andrea3000
  • 1,018
  • 1
  • 11
  • 26