Hi,
I just finished optimizing VeohProxy for XBMC. I was able to run it and play a Veoh Video having 19MB of free memory left! Try it here: http://theendofthelongestline.de/VeohProxyXBMC.rar
Use something like FoxyTunes to feed it with URLS.
Veoh High Quality Streaming Proxy - Nearly Working - Help needed!
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-13 04:37
Post: #11
|
| find quote |
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-16 23:15
Post: #12
So here is a new version. Now supporting Veoh, NinjaVideo and Streamplug files:
http://theendofthelongestline.de/proxytest.rar for Veoh: http://127.0.0.1/veohID for NinjaVideo: Just copy the video download link and make XBMC play it (using foxyTunes for example) for Streamplug: http://127.0.0.1/streamplug/ + base64-encoded url of the ogm-file. Here is an online encoder: http://www.php-einfach.de/base64_generator.php It has one problem though and I just can't figure it out: If I play the file with mplayer, there are two possibilities what happens: 1) MPlayer doesn't even bother trying to download the index chunk (which is near the end of the file). It somehow doesn't recognize that it could seek within the file using http-range-requests. 2) MPlayer tries to download the index chunk. Then it complains that it cannot allocate 200MB of memory and then continues to generate an index, for which it downloads the whole file which takes ages. This is not the case on MPlayer on linux if I run the script locally or on the XBox. DVDPlayer also seems to work fine. Elupus, the guys on IRC told me to talk to you about this problem. Maybe you can help? I included a test M3U file in the rar to make your testing easier. Why is ancient MPlayer still default on XBox? Shouldn't this be changed now that DVDPlayer is really really ready? Is there some drawback to it on the XBox? I'd really love to know if this is a bug in the proxy (maybe in the way range-requests are treated?) or in MPlayer itself which I can't imagine because it works on other servers. But it MAY be a problem with http seeks in this old version. Any help/testing would be REALLY appreciated! Sorry for the dirty code but I really tried everything to make it work... |
| find quote |
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-16 23:29
Post: #13
Here is a pastebin of my XBMC. I played the same movie (from the M3U) 4 times. Two times it didn't want to seek and displayed the movie. The last two times, it tried to generate an index, which I cancelled:
http://pastebin.ca/1020567 |
| find quote |
elupus
Team-XBMC Developer Posts: 3,764 Joined: Mar 2004 Reputation: 2 |
2008-05-17 12:50
Post: #14
i didn't look at the code, but during seeks mplayer will have two sockets agains the http server open at the same time. thus if you have some global state in your script, that might be getting messed up.
Always read the XBMC online-manual, FAQ and search the forum before posting. Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules. For troubleshooting and bug reporting please make sure you read this first. ![]() |
| find quote |
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-17 18:06
Post: #15
No, there's no global state. It's all done in the individual threads. One thing I can't figure out: Should MPlayer normally seek right to the idx1 chunk after reading the first few bytes of the file? I found out that with the proxy, it seems to seek 1700 bytes before the idx1 char identifier. Is this right? If it is not, it's probably a bug in the seek calculation.
|
| find quote |
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-21 16:07
Post: #16
VeohProxy is now on google code with a much improved version:
http://code.google.com/p/veohproxy/ The MPlayer problem is still pretty much unsolved. The only way I could get it to work was patching the default.xbe. I searched for "-forceidx" in a hex editor and changed that to "-noidx", followed by 0-Bytes. When writing a plugin, playing via DVDPlayer is not possible: The automatic detection of the player even forbids the user to choose DVDPlayer in the context menu. I fixed this by appending "?extension=.avi" to the stream URL. Maybe there is an extension that DVDPlayer is the default player for? When I want to launch the video with XBMC.Player.Play(), this is also not working, I think Python gets confused when two scripts are running at the same time. It becomes so slow that the player closes the stream. |
| find quote |
elupus
Team-XBMC Developer Posts: 3,764 Joined: Mar 2004 Reputation: 2 |
2008-05-21 19:17
Post: #17
You can force player from python. Check apple trailer script it does so.
mplayer aught to seek first to eof (must succeed and return 0 bytes read not error) then directly to the idx chunk i should think. Always read the XBMC online-manual, FAQ and search the forum before posting. Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules. For troubleshooting and bug reporting please make sure you read this first. ![]() |
| find quote |
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-21 19:29
Post: #18
elupus Wrote:You can force player from python. Check apple trailer script it does so. Unbehagen Wrote:When I want to launch the video with XBMC.Player.Play(), this is also not working, I think Python gets confused when two scripts are running at the same time. It becomes so slow that the player closes the stream.This also happens even if I force any of the players. Quote:mplayer aught to seek first to eof (must succeed and return 0 bytes read not error) then directly to the idx chunk i should think. I could not see the seek to EOF in the logs yet. That's odd. I will investigate further. Is there any file extension that I could append to the stream URL so DVDPlayer is automatically launched? As I said, launching it from a python script doesn't work - python becomes horribly slow for some reason and the stream won't start to play. So I need a way to launch the stream with DVDPlayer. |
| find quote |
Nuka1195
Skilled Python Coder Posts: 3,914 Joined: Dec 2004 Reputation: 17 |
2008-05-21 21:46
Post: #19
vob?
|
| find quote |
Unbehagen
Skilled Python Coder Posts: 342 Joined: Jul 2007 Reputation: 3 Location: Bremen, Germany |
2008-05-22 02:33
Post: #20
Nuka1195 Wrote:vob? Hmm, doesn't work. It still uses mplayer. Maybe it doesn't work this way. But then it's weird that when I added "?.somefiletype" to the URL I got to choose DVDPlayer in via context menu. This had influence. Any ideas on how to get DVDPlayer to play the files? |
| find quote |

![[Image: badge.gif]](http://www.ohloh.net/p/xbmc/badge.gif)
Search
Help