I want to to render an application (e.g. a browser) in memory (not on screen) and stream the result of this rendering to a couple of remote desktops.
What options do I have? Is there a Java framework (maybe based on OpenGL) that I can use for this?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
OpenGL is a drawing API; totally unsuited for your demands; just telling you to clear things up.
The whole “do the thing off-screen” requires to hook into the lower parts of the graphics system. With Java this means serious tinkering with the JNI and probably also some native binary code. IMHO not worth the effort, as there is a much nicer solution:
Xorg has a X server that is backed by a VNC framebuffer (Xvnc). You can start a browser in such and if there’s no window manager and desktop environment running, the browser will be the only thing visible, no decorations, titlebar or the like. Then you connect using VNC to that server and will see the picture of the browser only. Technically VNC is just a video stream of JPEG images, and there are tools to create a regular video stream from VNC.
X provides you an additional possibility: The Composite extension. X Composite provides a mechanism to transfer a window into an offscreen rendering area. The contents rendered to the offscreen area must be composited to the screen by a so called compositor. It is possible, though quite inefficient, to copy those offscreen images into process memory and from there build a video stream.