Directfb and gpm

I had this working a while back… and now I can’t.

Anybody care to give me advice on how to get a mouse when running a sdl
app from the framebuffer (directfb) ? I have gpm running… but no
mouse. Of course I really don’t understand gpm to well, but it loads
with no problems.

I am making a client/server program, and the clients will be using SDL to play
short movie clips (the clip is decided by the server and broadcast to the
clients) and subsequently changes to one client will affect the video play on
other clients (this is for an art project…).

The client needs to be able to take mouse input (SDL MouseButtonEvent) while the
movie is playing and do the following:
A) interrupt the movie clip and play a different movie upon mouse input
B) send the mouse input information to the server

I am new to SDL and threading but my suspicion is that the SDL movie playing is
already on its own thread (correct?). But then I am not sure if I need new
threads for taking in mouse input and perhaps another new thread for sending
the information to the server (when the movie is playing a connection to the
server is already/still established)…I guess there are probably several ways
to solve this, but ideally the simplest cleanest way would be best…

Does anyone have suggestions on how the program and threads should be arranged?

Thank you!

Best,
Shu

I had this working a while back… and now I can’t.

Anybody care to give me advice on how to get a mouse when running a sdl
app from the framebuffer (directfb) ? I have gpm running… but no
mouse. Of course I really don’t understand gpm to well, but it loads
with no problems.

When you say you have “no mouse” do you mean you are not getting any
mouse events? Or, do you mean that you do not see the mouse cursor? Or
both? Normally, you have to draw the cursor your self when you are using
a video device directly.

Also, when you say “gpm” are you really talking about “gdm”?

	Bob PendletonOn Thu, 2005-03-31 at 20:44 +0900, Steve B. wrote:

SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

shu wrote:

I am making a client/server program, and the clients will be using SDL to play
short movie clips (the clip is decided by the server and broadcast to the
clients) and subsequently changes to one client will affect the video play on
other clients (this is for an art project…).

The client needs to be able to take mouse input (SDL MouseButtonEvent) while the
movie is playing and do the following:
A) interrupt the movie clip and play a different movie upon mouse input
B) send the mouse input information to the server

I am new to SDL and threading but my suspicion is that the SDL movie playing is
already on its own thread (correct?).

SDL by itself doesn’t play movies. What are you using to play these movies ?

Stephane

Bob Pendleton wrote:>On Thu, 2005-03-31 at 20:44 +0900, Steve B. wrote:

I had this working a while back… and now I can’t.

Anybody care to give me advice on how to get a mouse when running a sdl
app from the framebuffer (directfb) ? I have gpm running… but no
mouse. Of course I really don’t understand gpm to well, but it loads
with no problems.

When you say you have “no mouse” do you mean you are not getting any
mouse events? Or, do you mean that you do not see the mouse cursor? Or
both? Normally, you have to draw the cursor your self when you are using
a video device directly.

Also, when you say “gpm” are you really talking about “gdm”?

gpm is the console mouse daemon.

Stephane

Steve B. wrote:

I had this working a while back… and now I can’t.

Anybody care to give me advice on how to get a mouse when running a sdl
app from the framebuffer (directfb) ? I have gpm running…

Last time I tried directfb, it didn’t like like gpm. Did you try without
it ?

Stephane

Quoting Stephane Marchesin <stephane.marchesin at wanadoo.fr>:

shu wrote:

I am making a client/server program, and the clients will be using SDL to
play
short movie clips (the clip is decided by the server and broadcast to the
clients) and subsequently changes to one client will affect the video play
on
other clients (this is for an art project…).

The client needs to be able to take mouse input (SDL MouseButtonEvent) while
the
movie is playing and do the following:
A) interrupt the movie clip and play a different movie upon mouse input
B) send the mouse input information to the server

I am new to SDL and threading but my suspicion is that the SDL movie playing
is
already on its own thread (correct?).

SDL by itself doesn’t play movies. What are you using to play these movies ?

Stephane


SDL mailing list
SDL at libsdl.org
http://www.libsdl.org/mailman/listinfo/sdl

I’m using the SMPEG libraries.

Thanks,
//shu

When you say you have “no mouse” do you mean you are not getting any
mouse events? Or, do you mean that you do not see the mouse cursor? Or
both? Normally, you have to draw the cursor your self when you are using
a video device directly.
Don’t see the mouse cursor. That is an idea, I didn’t really check to
see if I was getting mouse events. I just remeber when I gave it a go a
couple of months back I did get a cursor display.

Also, when you say “gpm” are you really talking about “gdm”?
Your are right. I do mean gdm.

Last time I tried directfb, it didn’t like like gpm. Did you try
without it ?

Stephane
Yes I did. Still no mouse cursor (at least not displayed). And I was
right the first time (the SDL mailing list now has now XXX confused me!
=) )
gpm = console mouse daemon
gdm = gnome display manager