Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

LWJGL Window with Transparent Background?

I would like to create a window such that there is no "black background" area, but instead you see through to any other windows that are open, etc.

That is, render the scene and only the scene, leaving no frame and no background area.

I've read about a method that involves rendering to a hidden OpenGL window and buffering it in memory, creating a transparent layered window, and copying from memory to the transparent window.

Obviously this is very cpu/memory intensive, so I was wondering if there was any better ways of doing it, within Java and LWJGL?

like image 300
nighthawk454 Avatar asked Nov 29 '25 16:11

nighthawk454


1 Answers

This is something that can only be accomplished with platform-specific code.

This thread provides an interesting discussion on the subject. This post shares C code that accomplish this effect on Windows, and this post on Linux.

like image 177
karlphillip Avatar answered Dec 02 '25 07:12

karlphillip