John,
What I need is simpler I think–
I need an GUI on my PC (linux) to control a video projector connected to another computer (beagleboard).
As things stand I run my application on the BB and drive the projector using SDL via X11. I only need
to blit static images to the projector (but wanted another window exported to X11 on my host PC for the GUI).
Under X the create window function (can’t remember exactly) takes a display argument so each window
could in theory go to a different X-server but under SDL I think I am tied to one display because SDL_init
and the underlying library assumes just one display.
My plan was to make a simple screen server for the projecter on the BB and run an application on the BB
to produce a GUI that I could export to my PC. I already have a simple server for this running over TCP.
As things stand the BB is too slow to do the processing I need to do (almost exactly 100 times slower than
my PC for the intensive bit of code) so I am changing plans for the time being and running the gui + processing
on the PC and accessing the display via my simple TCP server (and therefore each SDL app now only
needs to talk to one display).
My next problem is I need to coordinate the output to the projector to the screen refresh rate so I can
change the output exactly in time with the refresh but I am not sure how to make SDL do this (or how
to get SDL to let me know the vertical blanking interval has passed so I can render and requeue SDL_flip()).
This is where it will likely get a bit complex and I’ll have to stick part of the processing back on the BB
and invert the client-server model to make the GUI a server and the application on the BB driving the
projector the client…
It has all got a bit complex and I think (in the end) I’ll retreat to a test based UI over ssh…
Cheers,
SA> Date: Wed, 26 Aug 2009 07:37:13 -0500
From: john.magnotti at gmail.com
To: sdl at lists.libsdl.org
Subject: Re: [SDL] Multiple X session windows
On Tue, Aug 25, 2009 at 5:29 PM, not disclosed<@not_disclosed> wrote:
I want to use SDL to open multiple windows on multiple X servers - basically
I want to use SDL to control one
screen and at the same time have windows open on a remote X server.
Can you describe the setup a bit more? When you say remote, do you
mean separate machines separated by nondeterministic connection
(something like udp)? If so, I think client-server may be the best
fit, and may be simpler than you think–just setup one machine to
broadcast SDL_Events, and the other machine to sit and receive them.
I’ve done this with some success in order to build a video wall using
SDL+OpenGL and it was actually easier than I expected. Even if the
apps are on the same physical machine, the socket approach will
generalize.
Check out the event package here:
http://code.google.com/p/xor/source/browse/#svn/trunk/src/event
and the folders for mouse/keyboard/timer/etc if you want to see how I
implemented it.
Does anyone know if it is possible to do this via SDL?
I think SDL 1.3 supports multiple windows out of the box, I would
check the latest version from the repository.
John
SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
With Windows Live, you can organize, edit, and share your photos.
http://www.microsoft.com/middleeast/windows/windowslive/products/photo-gallery-edit.aspx