maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   Youtube browser - mYTube - released (https://talk.maemo.org/showthread.php?t=17739)

briand 2008-09-09 03:42

Re: Youtube browser - mYTube - released
 
hmm. makes me wonder where I went wrong. :(

I downloaded the script above, put it in /usr/bin, replacing the one I had there, ran chmod +x on it, and added the -x to the prefs in mytube. ...wouldn't download or play any video until I took the -x out of the myytube preferences... :(

brontide 2008-09-09 03:48

Re: Youtube browser - mYTube - released
 
Quote:

Originally Posted by briand (Post 222216)
hmm. makes me wonder where I went wrong. :(

I downloaded the script above, put it in /usr/bin, replacing the one I had there, ran chmod +x on it, and added the -x to the prefs in mytube. ...wouldn't download or play any video until I took the -x out of the myytube preferences... :(

Try running mytube from a terminal and see if you get any error messages.

brontide 2008-09-09 03:50

Re: Youtube browser - mYTube - released
 
Oh and for my next trick.. auto crop and scale of widescreen clips. It's a hack, but once it's ready it should be a simple drop in.

qole 2008-09-09 04:21

Re: Youtube browser - mYTube - released
 
There you go again, brontide. Taking a perfectly good, working application...

...and making it better. Thanks.

brontide 2008-09-09 14:35

Re: Youtube browser - mYTube - released
 
Ok, here is the deal with the hack...

auto crop and scale imposes a long ( 8 seconds if downloaded, longer for streaming ) the first time a video gets played. It's the best I can do without rewriting this app to handle the post processing.

There is no delays after it gets played the first time.

Bundyo 2008-09-09 15:00

Re: Youtube browser - mYTube - released
 
What imposes this delay?

brontide 2008-09-09 15:17

Re: Youtube browser - mYTube - released
 
Quote:

Originally Posted by Bundyo (Post 222349)
What imposes this delay?

mplayer's cropdetect has to scan the video and spits out a stream of possible cropping suggestions. So I take and run mplayer on 1000 frames ( -benchmark -nosound so it goes full speed ) and then pick the proper crop for the video.

It's a one time penalty because I cache the results in a sqlite3 db for later retrieval.

I can probably get the time down for saved videos, but for streamed videos I'm not sure. I could also apply a new algorithm to try and deal with the edge cases with fewer frames. But for now that's the price of glorious full and widescreen mytube.

brontide 2008-09-09 15:26

Re: Youtube browser - mYTube - released
 
Thinking about the problem... yes i have another algorithm that I can apply. It's pretty easy in fact to get the time down and still have fewer edge cases. The new alogrithm will only detect no crop or proper letterboxing ( roughly equal top and bottom ). I will have to rewrite the code, but I think it should detect properly with much fewer frames ( and fewer frames = less latency on first play ).

brontide 2008-09-09 17:48

Re: Youtube browser - mYTube - released
 
100 frames... yep, that's less than a second delay for saved, and probably 3 seconds streaming. There are still misses, but this actually hits better than the last one with 1/10th the frames.

qole 2008-09-09 19:41

Re: Youtube browser - mYTube - released
 
Of course, this leads me to think about using your cropdetect / aspect ratio algorithm in other situations...

For instance, I would love to see you work your magic with josiahg777's mplayer-opt script...


All times are GMT. The time now is 17:05.

vBulletin® Version 3.8.8