[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

how to play .avi and view jpg?

arun

7/26/2007 11:40:00 AM

I'm trying to write some client software that can play .avi videos,
either in a window or full screen, as well as display photos. What is
the best way to do this in Ruby? A library that works across platforms
would be perfect, failing which, either Windows or Linux would do.

Thanks,
Arun

4 Answers

greg.kujawa

7/26/2007 12:13:00 PM

0

On Jul 26, 7:40 am, arun <arun.me...@gmail.com> wrote:
> I'm trying to write some client software that can play .avi videos,
> either in a window or full screen, as well as display photos. What is
> the best way to do this in Ruby? A library that works across platforms
> would be perfect, failing which, either Windows or Linux would do.
>
> Thanks,
> Arun

The simplest thing you could do if you are targeting Windows platforms
is look into the command line options for Windows Media Player and the
Microsoft Pain apps. I have done some scripting that opens up Windows
Media Player to play a selected media file and automatically close
when done. I don't have code handy right now, but googling Microsoft's
Knowledgebase should show you the proper command line options (http://
support.microsoft.com/KB/241422). Plus if you just pass the proper
graphic file to Microsoft Paint as a command line argument that should
achive something similar. Basically invoking Ruby's system() method
will facilitate this. Of course you could try all of the win32ole
stuff, but this would seemingly complicate matters beyond what's
needed. Just my $0.02 US...


Edwin van Leeuwen

7/26/2007 12:27:00 PM

0

Greg Kujawa wrote:
> The simplest thing you could do if you are targeting Windows platforms
> is look into the command line options for Windows Media Player and the
> Microsoft Pain apps. I have done some scripting that opens up Windows
> Media Player to play a selected media file and automatically close
> when done.
You could do something similar using mplayer, which would allow you to
target both windows and linux (and mplayer has lots and lots of command
line options available).

If you want to write your own mediaplayer then using the ruby/gstreamer
bindings is probably the easiest way, although that would be linux
specific.

Edwin

--
Posted via http://www.ruby-....

Tiffany Sonny

7/26/2007 2:00:00 PM

0

unsubscribe

-----Original Message-----
From: arun [mailto:arun.mehta@gmail.com]
Sent: Thursday, July 26, 2007 4:45 AM
To: ruby-talk ML
Subject: how to play .avi and view jpg?

I'm trying to write some client software that can play .avi videos,
either in a window or full screen, as well as display photos. What is
the best way to do this in Ruby? A library that works across platforms
would be perfect, failing which, either Windows or Linux would do.

Thanks,
Arun



John Joyce

7/27/2007 1:16:00 AM

0


On Jul 26, 2007, at 6:45 AM, arun wrote:

> I'm trying to write some client software that can play .avi videos,
> either in a window or full screen, as well as display photos. What is
> the best way to do this in Ruby? A library that works across platforms
> would be perfect, failing which, either Windows or Linux would do.
>
> Thanks,
> Arun
>
>
You want cross platform?
You should use VLC player for the .avi files, nothing is more cross
platform than that. It's a full blown app already with GUI hooks for
many platforms. Open source, so you can use it and abuse it.
Displaying photos? It can probably do that too.