分页: 1 / 2

[问题]mplayer能播放中文地址的流媒体吗?

发表于 : 2008-06-15 19:48
tnger
mplayer播放mms, rtsp都没问题,当前提是英文地址,如果是中文地址该如何?

发表于 : 2008-06-15 20:00
xiooli
试试不就行了吗?

发表于 : 2008-06-15 20:26
tnger
xiooli 写了:试试不就行了吗?
肯定是试过了不行。不然问这样的问题不是浪费大家时间吗?

发表于 : 2008-06-15 20:30
xiooli
tnger 写了:
xiooli 写了:试试不就行了吗?
肯定是试过了不行。不然问这样的问题不是浪费大家时间吗?
可能是编码的问题

代码: 全选

echo "mms:XXX" |iconv -f utf-8 -t gb2312
然后把出来的地址再试试?

发表于 : 2008-06-15 21:12
tnger
echo "rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |iconv -f utf-8 -t gb2312
rtsp://210.29.99.11:555/����/���Ŵ�ʦ������/����.RM

发表于 : 2008-06-15 21:29
xiooli
tnger 写了:echo "rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |iconv -f utf-8 -t gb2312
rtsp://210.29.99.11:555/����/���Ŵ�ʦ������/����.RM
:em27 用real试试?

发表于 : 2008-06-15 21:57
tnger
xiooli 写了:
tnger 写了:echo "rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |iconv -f utf-8 -t gb2312
rtsp://210.29.99.11:555/����/���Ŵ�ʦ������/����.RM
:em27 用real试试?
real播放的时候显示是可以播放的,但几乎所有的视频都没有声音,很多连图像都没有,很少有能够正常播放的

发表于 : 2008-06-17 21:07
tnger
大家帮忙顶上去啊!
看有没有高手解决这个问题!

发表于 : 2008-06-17 22:59
vvvli
转换一下:
echo "210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |xargs wget
出来信息:
--2008-06-17 22:56:06-- http://210.29.99.11:555/%E5%A5%A5%E8%BF ... 6%93%8D.RM

这就是转换后的url,加上rstp:// 试试。
不行的话 echo "210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |iconv -f utf8 -t gbk|xargs wget

发表于 : 2008-06-17 23:00
HuntXu
ls的漂亮~

发表于 : 2008-06-18 8:06
tnger
vvvli 写了:转换一下:
echo "210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |xargs wget
出来信息:
--2008-06-17 22:56:06-- http://210.29.99.11:555/%E5%A5%A5%E8%BF ... 6%93%8D.RM

这就是转换后的url,加上rstp:// 试试。
不行的话 echo "210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |iconv -f utf8 -t gbk|xargs wget
echo "210.29.99.11:555/奥运/跟着大师看奥运/体操.RM" |xargs wget
--08:03:41-- http://210.29.99.11:555/%E5%A5%A5%E8%BF ... 6%93%8D.RM
=> `��%93�%93%8D.RM'
正在连接 210.29.99.11:555... 已连接。
已发出 HTTP 请求,正在等待回应... 404 Not Found
08:03:41 错误 404:Not Found。

发表于 : 2008-06-18 8:33
vvvli
我倒,转换出来url再用 mplayer 开阿。

发表于 : 2008-06-18 9:40
fuhuizn
转换成urlencode之前要先转换成gbk吧,弄个python脚本吧

发表于 : 2008-06-18 9:49
yaoms
不需要转码吧。地址没问题,mplayer就能播;看看这些信息:
$ mplayer rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM
MPlayer 1.0rc2-4.2.3 (C) 2000-2007 MPlayer Team
CPU: Intel(R) Celeron(R) M processor 1.60GHz (Family: 6, Model: 13, Stepping: 8)
CPUflags: MMX: 1 MMX2: 1 3DNow: 0 3DNow2: 0 SSE: 1 SSE2: 1
Compiled with runtime CPU detection.
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.

Playing rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM.
Resolving 210.29.99.11 for AF_INET6...
Couldn't resolve name for AF_INET6: 210.29.99.11
Connecting to server 210.29.99.11[210.29.99.11]: 555...
connection timeout
STREAM_LIVE555, URL: rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM
This stream is non-cacheable
Stream not seekable!
file format detected.
$ ping 210.29.99.11
PING 210.29.99.11 (210.29.99.11) 56(84) bytes of data.

--- 210.29.99.11 ping statistics ---
39 packets transmitted, 0 received, 100% packet loss, time 38029ms

试试这个

发表于 : 2008-06-18 10:02
fuhuizn
urlenc.py:

代码: 全选

#!/usr/bin/python
import urllib
import sys

url = sys.argv[1]
try:
    url = url.decode('utf-8').encode('gbk')
except:
    pass
print urllib.quote(url,':/')
使用:

代码: 全选

mplayer `./urlenc.py rtsp://210.29.99.11:555/奥运/跟着大师看奥运/体操.RM`