public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] How to use mplayer play file online?
@ 2008-02-29  3:43 Chuanwen Wu
  2008-02-29  6:54 ` Alan McKinnon
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Chuanwen Wu @ 2008-02-29  3:43 UTC (permalink / raw
  To: gentoo-user

Hi,
I want to use mplayer to play files on the ftp server. For example, I
have some files on: ftp://user:passwd@myftpserv/thefile. Now I want to
play it, but I won't need to download all the file first then play it.
Is there any advice?

Thanks in advanced!
-- 
wcw
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  3:43 [gentoo-user] How to use mplayer play file online? Chuanwen Wu
@ 2008-02-29  6:54 ` Alan McKinnon
  2008-02-29  7:43   ` Chuanwen Wu
  2008-02-29  9:36 ` Daniel Iliev
  2008-02-29 15:53 ` Ed Santiago
  2 siblings, 1 reply; 13+ messages in thread
From: Alan McKinnon @ 2008-02-29  6:54 UTC (permalink / raw
  To: gentoo-user

On Friday 29 February 2008, Chuanwen Wu wrote:
> Hi,
> I want to use mplayer to play files on the ftp server. For example, I
> have some files on: ftp://user:passwd@myftpserv/thefile. Now I want
> to play it, but I won't need to download all the file first then play
> it. Is there any advice?

You have to download it as it has to be in RAM before mplayer can use 
it.

And you have to download the whole thing as it's a container file, not a 
stream.



-- 
Alan McKinnon
alan dot mckinnon at gmail dot com

-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  6:54 ` Alan McKinnon
@ 2008-02-29  7:43   ` Chuanwen Wu
  2008-02-29  8:04     ` Alan McKinnon
  2008-02-29  8:39     ` Michael Niggli
  0 siblings, 2 replies; 13+ messages in thread
From: Chuanwen Wu @ 2008-02-29  7:43 UTC (permalink / raw
  To: gentoo-user

>  You have to download it as it has to be in RAM before mplayer can use
>  it.
>
>  And you have to download the whole thing as it's a container file, not a
>  stream.
So, you mean mplayer can NOT play stream?
As far as I know, mplayer can play file on a web(html) site.
In "man mplayer", I can see that :

       Stream from HTTP:
       mplayer http://mplayer.hq/example.avi

       Stream using RTSP:
       mplayer rtsp://server.example.com/streamName

So, I think there may be some ways to play mplayer from the ftp(or
other protocol).
Somebody work it out and suggested me to do it like this:

wget ftp://THE_FTPSERVER/1.RM -O - | mplayer -cache 8192 -

But I just failed every time I tried to do it in this way. Can you do
it successfully?
>
>
>
>  --
>  Alan McKinnon
>  alan dot mckinnon at gmail dot com
>
>  --
>  gentoo-user@lists.gentoo.org mailing list
>
>



-- 
wcw
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  7:43   ` Chuanwen Wu
@ 2008-02-29  8:04     ` Alan McKinnon
  2008-02-29  8:21       ` Chuanwen Wu
  2008-02-29  8:39     ` Michael Niggli
  1 sibling, 1 reply; 13+ messages in thread
From: Alan McKinnon @ 2008-02-29  8:04 UTC (permalink / raw
  To: gentoo-user

On Friday 29 February 2008, Chuanwen Wu wrote:
> >  You have to download it as it has to be in RAM before mplayer can
> > use it.
> >
> >  And you have to download the whole thing as it's a container file,
> > not a stream.
>
> So, you mean mplayer can NOT play stream?

mplayer can play streams. But the4 thing you are trying to play is not a 
stream, it is a file.

You cannot change the nature of the thing on the ftp server as it is 
whatever it is. To turn it into a stream, you will have to log into the 
ftp server and do whatever is necessary there to do that. mplayer is 
not able to make such changes for very obvious reasons.

Meanwhile, just download the file and play it. What's the problem with 
that? To view the whole thing from beginning to end all that data would 
still have to move from the server to your local machine anyway.

-- 
Alan McKinnon
alan dot mckinnon at gmail dot com

-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  8:04     ` Alan McKinnon
@ 2008-02-29  8:21       ` Chuanwen Wu
  2008-02-29  9:27         ` Alan McKinnon
  2008-02-29  9:58         ` Uwe Thiem
  0 siblings, 2 replies; 13+ messages in thread
From: Chuanwen Wu @ 2008-02-29  8:21 UTC (permalink / raw
  To: gentoo-user

>  Meanwhile, just download the file and play it. What's the problem with
>  that? To view the whole thing from beginning to end all that data would
>  still have to move from the server to your local machine anyway.

But I can save the time of downing the file and when I want to watch
any movie, I don't need to wait.

>
>  --
>
>
> Alan McKinnon
>  alan dot mckinnon at gmail dot com
>
>  --
>  gentoo-user@lists.gentoo.org mailing list
>
>



-- 
wcw
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  7:43   ` Chuanwen Wu
  2008-02-29  8:04     ` Alan McKinnon
@ 2008-02-29  8:39     ` Michael Niggli
  2008-02-29 15:33       ` Chuanwen Wu
  1 sibling, 1 reply; 13+ messages in thread
From: Michael Niggli @ 2008-02-29  8:39 UTC (permalink / raw
  To: gentoo-user

Chuanwen Wu wrote:
>>  You have to download it as it has to be in RAM before mplayer can use
>>  it.
>>
>>  And you have to download the whole thing as it's a container file, not a
>>  stream.
>>     
> So, you mean mplayer can NOT play stream?
> As far as I know, mplayer can play file on a web(html) site.
> In "man mplayer", I can see that :
>
>        Stream from HTTP:
>        mplayer http://mplayer.hq/example.avi
>
>        Stream using RTSP:
>        mplayer rtsp://server.example.com/streamName
>
> So, I think there may be some ways to play mplayer from the ftp(or
> other protocol).
> Somebody work it out and suggested me to do it like this:
>
> wget ftp://THE_FTPSERVER/1.RM -O - | mplayer -cache 8192 -
>
> But I just failed every time I tried to do it in this way. Can you do
> it successfully?
>   

Does the wget itself work, eg. does wget ftp://ftpserver/file.ext 
download your file? If not, you may need to add some quoting... For 
instance, the [ character should be quoted twice, once for the local 
shell and once for the remote server (at least that was the case on a 
quick test I did), so downloading a file called "[.ext" would become

wget 'ftp://ftpserver/\[.ext'

or

wget 'ftp://ftpserver/\[.ext' -O - | mplayer -cache 8192 -

Regards
Michael
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  8:21       ` Chuanwen Wu
@ 2008-02-29  9:27         ` Alan McKinnon
  2008-02-29  9:58         ` Uwe Thiem
  1 sibling, 0 replies; 13+ messages in thread
From: Alan McKinnon @ 2008-02-29  9:27 UTC (permalink / raw
  To: gentoo-user

On Friday 29 February 2008, Chuanwen Wu wrote:
> >  Meanwhile, just download the file and play it. What's the problem
> > with that? To view the whole thing from beginning to end all that
> > data would still have to move from the server to your local machine
> > anyway.
>
> But I can save the time of downing the file and when I want to watch
> any movie, I don't need to wait.

Tough. You can't do what you want to do from the client.


-- 
Alan McKinnon
alan dot mckinnon at gmail dot com

-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  3:43 [gentoo-user] How to use mplayer play file online? Chuanwen Wu
  2008-02-29  6:54 ` Alan McKinnon
@ 2008-02-29  9:36 ` Daniel Iliev
  2008-03-04  9:43   ` Chuanwen Wu
  2008-02-29 15:53 ` Ed Santiago
  2 siblings, 1 reply; 13+ messages in thread
From: Daniel Iliev @ 2008-02-29  9:36 UTC (permalink / raw
  To: gentoo-user

On Fri, 29 Feb 2008 11:43:43 +0800
"Chuanwen Wu" <wcw8410@gmail.com> wrote:

> Hi,
> I want to use mplayer to play files on the ftp server. For example, I
> have some files on: ftp://user:passwd@myftpserv/thefile. Now I want to
> play it, but I won't need to download all the file first then play it.
> Is there any advice?
> 
> Thanks in advanced!


I'm not sure if mplayer supports authentication, but you could try to
"pipe" the output from another client. Something like:

curl --auth-options ftp:/exemple.com/patth/file | mplayer -

or

wget --auth-options ftp://exemple.com/patth/file -O - | mplayer -

-- 
Best regards,
Daniel
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  8:21       ` Chuanwen Wu
  2008-02-29  9:27         ` Alan McKinnon
@ 2008-02-29  9:58         ` Uwe Thiem
  2008-02-29 17:03           ` Florian Philipp
  1 sibling, 1 reply; 13+ messages in thread
From: Uwe Thiem @ 2008-02-29  9:58 UTC (permalink / raw
  To: gentoo-user

On Friday 29 February 2008, Chuanwen Wu wrote:
> >  Meanwhile, just download the file and play it. What's the
> > problem with that? To view the whole thing from beginning to end
> > all that data would still have to move from the server to your
> > local machine anyway.
>
> But I can save the time of downing the file and when I want to
> watch any movie, I don't need to wait.

You can start the download and start mplayer on the (incompletely) 
downloaded file.

Uwe

-- 
Informal Linux Group Namibia:
http://www.linux.org.na/
SysEx (Pty) Ltd.:
http://www.SysEx.com.na/
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  8:39     ` Michael Niggli
@ 2008-02-29 15:33       ` Chuanwen Wu
  0 siblings, 0 replies; 13+ messages in thread
From: Chuanwen Wu @ 2008-02-29 15:33 UTC (permalink / raw
  To: gentoo-user

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=UTF-8, Size: 2564 bytes --]

>  Does the wget itself work, eg. does wget ftp://ftpserver/file.ext
>  download your file?

Yes, I can see the file after downloading, but mplayer just don't  play it.
I attach the output below, when I do "wget ftp://THE_FTPSERVER/1.RM -O
- | mplayer -cache 8192 -" below. There are some Chinese characters. I
am sorry because I don't know how to get English output(although I
have tried to set the locale to POSIX), but I will give the translated
one:

 //************************************************************************************************//
$  wget ftp://FTPSERVER/upload/13.RM -O - | mplayer -cache 8192 -
MPlayer dev-SVN-rUNKNOWN-4.1.2 (C) 2000-2007 MPlayer Team
CPU: Intel(R) Core(TM)2 Duo CPU     T5470  @ 1.60GHz (Family: 6,
Model: 15, Stepping: 13)
CPUflags:  MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
编译用了针对 x86 CPU 的扩展指令集: MMX MMX2 SSE SSE2

正在播放 -。
从标准输入中读取...
缓存填充:  0.00% (0 字节)   --23:17:17--  ftp://FTPSERVER/upload/13.RM
           => `-'
缓存填充:  0.00% (0 字节)   connected. to 202.114.6.64:21...
    //filling buf:  0.00% (0 char)   connected. to 202.114.6.64:21...
缓存填充:  0.00% (0 字节)   Logged in! as common ...
缓存填充:  0.00% (0 字节)   done.    ==> PWD ...
缓存填充:  0.00% (0 字节)   done.WD /upload ...
缓存填充:  0.00% (0 字节)   done.    ==> RETR 13.RM ...
缓存填充:  0.00% (0 字节)    (unauthoritative)
缓存填充:  0.00% (0 字节)
缓存填充: 17.48% (1466368 字节)           ] 0             --.--K/s
检测到 REAL 文件格式。
    //detected the REAL file formate
Stream description: Audio Stream
Stream mimetype: audio/x-pn-realaudio
[real] 找到音频流,-aid 0
        //[real]found the audio stream, -aid 0
Stream description: Video Stream
Stream mimetype: video/x-pn-realvideo
[real] 找到视频流,-vid 1
        // [real]found the video stream, -vid 1
100%[====================================>] 79,381,843    10.60M/s    ETA 00:00

23:17:25 (10.59 MB/s) - `-' saved [79381843]

Something went wrong, no index chunk found on given address (79352095)
RM: 未找到视频流。
        //RM:can't find the video stream
RM: 未找到音频流...  -> 没声音。
//RM:can't find the audio stream... ->no sound.
找不到流媒体。
            //Can't find the media stream


正在退出... (文件结束)
         //Exiting...(file end)
//***********************************************************************************************************//

-- 
wcw
éí¢‹¬z¹b²Û z{h¢Šà™¨¥Šx%ŠË

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  3:43 [gentoo-user] How to use mplayer play file online? Chuanwen Wu
  2008-02-29  6:54 ` Alan McKinnon
  2008-02-29  9:36 ` Daniel Iliev
@ 2008-02-29 15:53 ` Ed Santiago
  2 siblings, 0 replies; 13+ messages in thread
From: Ed Santiago @ 2008-02-29 15:53 UTC (permalink / raw
  To: gentoo-user

>I want to use mplayer to play files on the ftp server. For example, I
>have some files on: ftp://user:passwd@myftpserv/thefile. Now I want to
>play it, but I won't need to download all the file first then play it.

GNUMP3d is available as a Gentoo package:

    http://www.gnump3d.org/

You run it on your server.  In its config file, you point
to a directory with mp3 or ogg files.  It will do the magic
work of converting files to streams, so you can choose and
play music from another box on your network.

Hope this helps,
Ed
-- 
Ed Santiago               Toolsmith               ed@edsantiago.com

-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  9:58         ` Uwe Thiem
@ 2008-02-29 17:03           ` Florian Philipp
  0 siblings, 0 replies; 13+ messages in thread
From: Florian Philipp @ 2008-02-29 17:03 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 774 bytes --]


On Fri, 2008-02-29 at 11:58 +0200, Uwe Thiem wrote:
> On Friday 29 February 2008, Chuanwen Wu wrote:
> > >  Meanwhile, just download the file and play it. What's the
> > > problem with that? To view the whole thing from beginning to end
> > > all that data would still have to move from the server to your
> > > local machine anyway.
> >
> > But I can save the time of downing the file and when I want to
> > watch any movie, I don't need to wait.
> 
> You can start the download and start mplayer on the (incompletely) 
> downloaded file.
> 
> Uwe
> 
> --

I do this all the time over NFS with Matroska-files that are still being
created by my server. If you can't navigate within the movie, add -idx
or --force-idx to create a new index on the fly. 

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: [gentoo-user] How to use mplayer play file online?
  2008-02-29  9:36 ` Daniel Iliev
@ 2008-03-04  9:43   ` Chuanwen Wu
  0 siblings, 0 replies; 13+ messages in thread
From: Chuanwen Wu @ 2008-03-04  9:43 UTC (permalink / raw
  To: gentoo-user

I have found a way. Just add USE=ftp when emerge mplayer.
Then, we can play movie in ftp use mplayer:

 mplayer ftp://FTP_SERVER/FILE

>  I'm not sure if mplayer supports authentication, but you could try to
>  "pipe" the output from another client. Something like:
>
>  curl --auth-options ftp:/exemple.com/patth/file | mplayer -
>
>  or
>
>  wget --auth-options ftp://exemple.com/patth/file -O - | mplayer -
But I still want to find a "pipe" way like what you show above.
I have a simple program, which can fetch a file in a remote
machine(this machine also run my protocol).
If mplayer can play in a pipe way, then I can player media like this:
MY_PROGRAM --fetch --MY_SERVER -O - | mplayer -
>
>  --
>  Best regards,
>  Daniel
>
>
> --
>  gentoo-user@lists.gentoo.org mailing list
>
>



-- 
wcw
-- 
gentoo-user@lists.gentoo.org mailing list



^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2008-03-04  9:43 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-29  3:43 [gentoo-user] How to use mplayer play file online? Chuanwen Wu
2008-02-29  6:54 ` Alan McKinnon
2008-02-29  7:43   ` Chuanwen Wu
2008-02-29  8:04     ` Alan McKinnon
2008-02-29  8:21       ` Chuanwen Wu
2008-02-29  9:27         ` Alan McKinnon
2008-02-29  9:58         ` Uwe Thiem
2008-02-29 17:03           ` Florian Philipp
2008-02-29  8:39     ` Michael Niggli
2008-02-29 15:33       ` Chuanwen Wu
2008-02-29  9:36 ` Daniel Iliev
2008-03-04  9:43   ` Chuanwen Wu
2008-02-29 15:53 ` Ed Santiago

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox