Page 2 of 2

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Thu Mar 13, 2014 7:21 pm
by Squareys
Oh, well, maybe we can push that through...

Packed Renderbuffer is definitely possible, since that's how I got that to work. Packed Texture2D Attachments might not be, though.

I'm still very confused: What are the advantages of Texture2D attachmens over Renderbuffers?

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Thu Mar 13, 2014 7:26 pm
by Nadro
You can't use renderbuffer as a standard texture2D, so you are not able to sampling it in GLSL for example. Anyway fbo with renderbuffer may offer better performance on some mobile GPUs.

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Thu Mar 13, 2014 7:37 pm
by hendu
Packed DS textures were made core in GL 3.0, before that they were a widely implemented GL 1.2 extension.

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Thu Mar 13, 2014 7:45 pm
by Squareys
Okay, thanks.


@hendu: How do you know all this version stuff. I tried googling stuff like that, but I found it rather hard to find. :)
I will try your patch tomorrow. If it still works, I will try to draw some attention to it on sourceforge.

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Thu Mar 13, 2014 7:48 pm
by hendu
I googled it, as if I could remember the GL spec :P

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Sat Mar 15, 2014 12:54 pm
by Squareys
@hendu: I updated your patch for the current revision and added it to your ticket on sourceforge. Let's hope this get's through, it actually works perfectly :)

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Wed Jul 11, 2018 2:51 pm
by denzelbro
I am using 1.7 and currently having problems related to this issue with stencil buffer. would be interested in getting some tips or guide for a workaround or any fix to make them both work.

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Wed Jul 11, 2018 5:52 pm
by devsh
IrrlichtBAW supports explicit choice of renderbuffer or texture as an FBO depth and/or stencil attachment. It also allows you to use depth only format, stencil only format and depth stencil packed format.

The only thing you cannot do is use packed depth stencil texture is when you sample from it in a shader, you can only fetch depth (not because it doesn't want you to, OpenGL prevents it without some obscure extension whose name I cannot remember right now).

Stencil buffer gets used in the routed K OIT implementation in example 16
https://github.com/buildaworldnet/Irrli ... parencyZoo

Re: [open/new] OpenGLDriver > TargetTexture/FBO & Stencil Bu

Posted: Thu Jul 12, 2018 2:14 am
by denzelbro
Thanks for the info there devsh, that seems really interesting but I really need to work on good ol' stock irrlicht right now and will just attempt to apply the recent posted patch if I have no other option.