Kodi Community Forum

Full Version: Veoh High Quality Streaming Proxy - Nearly Working - Help needed!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Update: Please also have a look at the last post - there you can find a link to a current, working version!

Hi,
because Stage6 has been shut down, I looked for other possibilities to get high quality streaming content. Turns out Veoh hosts high quality content, but only wants to give it to their VeohTV users. No, that's not what we want.
What Veoh does is it divides the original avi, mov, etc... source into a lot of small files. Not I wrote a proxy that acts like a webserver. It listens for the requests and translates them to the small files veoh offers. It is possible to stream veoh's high quality files with this. It works okay on my PC. When I try to run it on the beloved XBox, it just crashes after buffering because of memory issues. I tried a lot to cut down memory usage, yet still can't get it to work. Could anyone help me with this? It would be so cool to finally have hq streaming back on the box without using another pc that acts as a proxy.

You can download the script (not a plugin yet!) here: http://theendofthelongestline.de/veohproxy.zip

To try it, you have to execute default.py as a script. Then go to the movies section and play the playlist in the zip. It connects to the local webserver at
http://localhost:8081/v1650118XbD3cFmX . The file part of the URL is the veoh ID. You can easily get this from the url of veoh videos.
It is only a virtual file, internally the script puts together all the file parts. Please help me debugging! Thanks a lot!
Unbehagen
You may want to have a look at the ninja video helper. From ninja video.
I came across this when attempting a plugin for the site.

It`s made in java, decompile the files and look at the classes. They do exactly what you are doing now. Also nickspoon wrote a script that acts like veoh downloader sharp usingthe jsp files from veoh, and i was recreating the ninja video helper in python for the same purpose. May come in handy.

Looks like i`ll have to implement a lister class for my other problem then. No short answers, what`s the world coming to hehe.

Cheers Voinage.
word=re.sub('lister','listener',above text)
Thanks for your tips, Voinage, very helpful!
I managed to get it to work properly. It can even stream NinjaVideo.net videos now. It should work on the xbox as well. Does anyone want to try it?
Grab it here: http://theendofthelongestline.de/blog.html
You are a star !
Abandoning my version. Integrating this into ninjavideo plugin and testing to capacity on veoh links in other plugins.

Cheers, Sir
It really eats the memory doesn`t it. It`s difficult to run it in the background while using plugins everything becomes very sluggish.

Other than the memory issue , it works very well.

It happily streams the ninja video content but after one movie you have to reset the xbox.

The main thing is that it works.
I guess it would be possible to cut down on memory usage using regular expressions instead of xml parsing.. Any other ideas?
Righ now, I'm talking to the JooX.net guys about making that source code their official software for Veoh content btw Smile Just creating a windows version with installer and so on.

Update: Grab the first version of the installer here: http://theendofthelongestline.de/setup.exe

I guess it will be integrated into Joox pretty soon!
Re seems the way to go, a loss of 30mb when running is acceptable for a pc but on the trusty xbox it`s a nightmare. If it`s memory usage was minimalised and it had a dedicated server on , server off mechanism to be called from a plugin when a veoh link is ran it would happily be the companion of choice for plugin dev. I`ve been playing with it and trying to find the best way of adding it to the ninjavideo plugin.

btw if you ever get a moment within your busy sched could you possibly pm me and offer me some guidance regarding the base64 algo for surf the channel, i`ve looked at your plugin and have created a new one but i`m having trouble finding the right split and offset to get a working link. It`s driving me mad. I know it`s a big ask.

Thanks V

I understand th
Were are you storing these chunks of data? if in memory there is your issue. Write them to disk as soon as you get them and serve them from there.
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.
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...
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
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.
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.
Pages: 1 2