Page 1 of 1

IrrIMGUI binding for Irrlicht2 (IrrlichtBAW)

Posted: Mon Nov 07, 2016 10:46 pm
by bkeys
My project benefited a lot from ZhalGraf's IMGUI bindings for Irrlicht. But my project is in the process of being ported to Irrlicht2 and we needed to keep our IMGUI functionality so I spent the last few days porting the old IrrIMGUI to Irrlicht2 and I got most of the functionality working correctly. There are a few bugs but the functionality itself is ready to go. So hopefully this will help people port their games over to Irrlicht2.

Image
The wrapper is licensed under the iMatix Standard Function Library (SFL) license which means that you can use this wrapper however you like so long as your project is under a license similar to the Artistic License or the GNU GPL. However, exceptions are available; PM me to discuss it further if you are interested.

Known issues
  • Picture example does not work properly, font texture is loaded instead of image
  • The widgets are not being clipped from the bottom of the window and widgets can overlap (as pictured)
  • Double rendering example does not work, we have to figure out how IrrlichtBAW does this
  • Thread safe compiling does not work; you have to run make twice to get the examples built

Re: IrrIMGUI binding for Irrlich2 (IrrlichtBAW)

Posted: Tue Nov 08, 2016 12:12 am
by devsh
I wouldn't call it Irrlicht2, might cause some confusion when developers finally get around to releasing version 2.0

What do you mean by double render?

Also someone help him pass texture handles to GLSL shaders
You need to set the correct texture in the SMaterial::TextureLayer, and pass the texture slot id to the shader uniform sampler2D variable

Re: IrrIMGUI binding for Irrlich2 (IrrlichtBAW)

Posted: Tue Nov 08, 2016 2:08 am
by bkeys
devsh wrote: What do you mean by double render?
Image
This is an example that was done in the old IrrIMGUI, basically you take an Irrlicht scene and render it to a texture, surely you guys do this in BAW I believe Soren showed us where he did this in your inventory menus. DMUX uses double rendering inside of its Garage where the player customizes cars
Image
devsh wrote: Also someone help him pass texture handles to GLSL shaders
You need to set the correct texture in the SMaterial::TextureLayer, and pass the texture slot id to the shader uniform sampler2D variable
Thank you for the help thus far; the last few days or so I was porting the rendering code to the old wrapper so no interfaces get broken by people moving over. Hopefully someone will make a pull request or something.

Re: IrrIMGUI binding for Irrlicht2 (IrrlichtBAW)

Posted: Tue Nov 08, 2016 8:48 pm
by devsh
Render to Texture is basically same as irrlicht, but instead of making an core::array<> of textures you need to create a FrameBufferObject and attach at least 1 texture to it

You should also create a Depth texture with a depth format, I dont know if I exposed texture creation with non RGBA formats in IVideoDriver, you may have to new a COpenGLTexture/COpenGLTexture2D and register it with the driver.

Re: IrrIMGUI binding for Irrlicht2 (IrrlichtBAW)

Posted: Thu Nov 10, 2016 7:47 pm
by bkeys
devsh wrote:Render to Texture is basically same as irrlicht, but instead of making an core::array<> of textures you need to create a FrameBufferObject and attach at least 1 texture to it

You should also create a Depth texture with a depth format, I dont know if I exposed texture creation with non RGBA formats in IVideoDriver, you may have to new a COpenGLTexture/COpenGLTexture2D and register it with the driver.
Alright; I will certainly take note of this when I get the time to move back to IrrIMGUI (When I start the work of porting DMUX to IrrlichtBAW).