Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / fpc-pascal / 2008-06

Embedding a Video Player into a Linux/FP/GTK2 Application ?

8 messages · 6 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

T. Guilleminot

Hi !

I'd like to be able to embed a video player (preferably MPlayer) into a Freepascal/GTK2 application (on Linux) in order to display some video or webcam flows.

I found some stuff on the web but I've no idea how to exploit this. Generally they are written in C and there is no FPC bindings :
- http://gtkplayerembed.sourceforge.net/
- http://web.iesrodeira.com/index.php/GtkMediaPlayer

There is also something pointed by Lazarus website (http://dppd.ubbcluj.ro/tanaselia/download/MPlayerGUI.zip) but unfortunately this is a dead link :(

Does anyone have hint, example, idea (...) ?

Thanks !
Tom

Henry Vermaak
to T. Guilleminot

2008/6/20 T. Guilleminot :

Show quoted text 5 lines
Hi ! I'd like to be able to embed a video player (preferably MPlayer) into a Freepascal/GTK2 application (on Linux) in order to display some video or webcam flows.

mplayer has a -wid option that takes a window id in which to embed itself. i haven't tried this, though. there's also the "slave mode" (-slave), that might be helpful to you.

henry

Graeme Geldenhuys
to Henry Vermaak

2008/6/20 Henry Vermaak :

mplayer has a -wid option that takes a window id in which to embed itself. i haven't tried this, though.

Wow!!! That is such a cool idea. I just tried it with a simple fpGUI one form application. Used xwininfo to find it's window id and launched mplayer. It worked. :) That is a neat trick.

Regards,
- Graeme -

_______________________________________________
fpGUI - a cross-platform Free Pascal GUI toolkit
http://opensoft.homeip.net/fpgui/

Henry Vermaak
to Graeme Geldenhuys

2008/6/21 Graeme Geldenhuys :

Show quoted text 8 lines
2008/6/20 Henry Vermaak : > mplayer has a -wid option that takes a window id in which to embed > itself. i haven't tried this, though. Wow!!! That is such a cool idea. I just tried it with a simple fpGUI one form application. Used xwininfo to find it's window id and launched mplayer. It worked. :) That is a neat trick.

heh, that's cool. i've been studying the mplayer man pages religiously while i was messing around with linux on the ps3. there's very little mplayer can't do (if you know how to).

henry

Andrew Haines
to Henry Vermaak
Henry Vermaak wrote 18 lines
2008/6/21 Graeme Geldenhuys : > 2008/6/20 Henry Vermaak : >> mplayer has a -wid option that takes a window id in which to embed >> itself. i haven't tried this, though. > Wow!!! That is such a cool idea. I just tried it with a simple fpGUI > one form application. Used xwininfo to find it's window id and > launched mplayer. It worked. :) That is a neat trick. > heh, that's cool. i've been studying the mplayer man pages religiously while i was messing around with linux on the ps3. there's very little mplayer can't do (if you know how to). henry _______________________________________________ fpc-pascal maillist - http://lists.freepascal.org/mailman/listinfo/fpc-pascal

I managed to make a tiny app with fpgui that uses xinelib to play media files.

It's barely usable but might be interesting to look at.

Andrew

Michael Van Canneyt
to Andrew Haines
Andrew Haines wrote 24 lines
Henry Vermaak wrote: > 2008/6/21 Graeme Geldenhuys : >> 2008/6/20 Henry Vermaak : >>> mplayer has a -wid option that takes a window id in which to embed >>> itself. i haven't tried this, though. >> Wow!!! That is such a cool idea. I just tried it with a simple fpGUI >> one form application. Used xwininfo to find it's window id and >> launched mplayer. It worked. :) That is a neat trick. >> > > heh, that's cool. i've been studying the mplayer man pages > religiously while i was messing around with linux on the ps3. there's > very little mplayer can't do (if you know how to). > > henry > _______________________________________________ > fpc-pascal maillist - > http://lists.freepascal.org/mailman/listinfo/fpc-pascal > I managed to make a tiny app with fpgui that uses xinelib to play media files. It's barely usable but might be interesting to look at.

Would it be OK to include the xine unit in fpc ?

Michael.

Joost van der Sluis
to Michael Van Canneyt

Op maandag 23-06-2008 om 09:42 uur [tijdzone +0200], schreef Michael Van Canneyt:

Show quoted text 29 lines
On Sun, 22 Jun 2008, Andrew Haines wrote: > Henry Vermaak wrote: > > 2008/6/21 Graeme Geldenhuys : > >> 2008/6/20 Henry Vermaak : > >>> mplayer has a -wid option that takes a window id in which to embed > >>> itself. i haven't tried this, though. > >> Wow!!! That is such a cool idea. I just tried it with a simple fpGUI > >> one form application. Used xwininfo to find it's window id and > >> launched mplayer. It worked. :) That is a neat trick. > >> > > > > heh, that's cool. i've been studying the mplayer man pages > > religiously while i was messing around with linux on the ps3. there's > > very little mplayer can't do (if you know how to). > > > > henry > > _______________________________________________ > > fpc-pascal maillist - > > http://lists.freepascal.org/mailman/listinfo/fpc-pascal > > > > I managed to make a tiny app with fpgui that uses xinelib to play media > files. > > It's barely usable but might be interesting to look at. Would it be OK to include the xine unit in fpc ?

Then the license should be changed to modified LGPL, instead of plain GPL?

Joost.