Sign up here and you can log into the forum!

Youtube3

UMSP Plugin Depot, the place for sharing plugins & info about them. No requests, just plugins/code.

Re: Youtube3   

Postby mad_ady » Sun Oct 11, 2015 10:56 pm

Yeah, issue is known. Hope to solve it soon...
User avatar
mad_ady
Developer
 
Posts: 4564
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Youtube3   

Postby mad_ady » Mon Oct 12, 2015 11:47 pm

Image

Well, the fix was easier than I anticipated. I just had to read the appropriate PHP documentation to use ssl on the socket I needed to create. Most of the code remained unchanged. Thank you guys for showing an interest in the plugin, otherwise I wouldn't have looked into it yet.

I also tried out the VEVO playback feature and made a few tweaks. In theory it works, in practice it doesn't. Apart from youtube using sophisticated signatures in their URLs (which we can decode with youtube-dl), it seems the videos returned are in various formats - mp4 and webm. As you know, the WDTV doesn't play webm, so we're left with mp4. Unfortunately, the mp4s are encoded with a codec called "dash" that I'm having trouble playing even on my PC:

Code: Select all
adrianp@frost:/tmp$ mediainfo video-3.mp4
General
Complete name                            : video-3.mp4
Format                                   : dash
Codec ID                                 : dash
File size                                : 50.8 MiB
Duration                                 : 3mn 54s
Overall bit rate                         : 1 815 Kbps
Encoded date                             : UTC 2015-09-05 10:19:50
Tagged date                              : UTC 2015-09-05 10:19:50

Video
ID                                       : 1
Format                                   : AVC
Format/Info                              : Advanced Video Codec
Format profile                           : High@L4.0
Format settings, CABAC                   : Yes
Format settings, ReFrames                : 3 frames
Codec ID                                 : avc1
Codec ID/Info                            : Advanced Video Coding
Duration                                 : 3mn 54s
Bit rate                                 : 1 812 Kbps
Width                                    : 1 920 pixels
Height                                   : 1 080 pixels
Display aspect ratio                     : 16:9
Frame rate mode                          : Variable
Frame rate                               : 23.976 fps
Minimum frame rate                       : 23.974 fps
Maximum frame rate                       : 23.981 fps
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 8 bits
Scan type                                : Progressive
Bits/(Pixel*Frame)                       : 0.036
Stream size                              : 50.7 MiB (100%)
Encoded date                             : UTC 2015-09-05 10:19:50
Tagged date                              : UTC 2015-09-05 10:19:50


So, I doubt the WDTV will ever play this format.

The proxy supports it and will transfer the video content to the player, but I expect the player will refuse to play it.

Here's the video I tested: http://www.youtube.com/watch?v=jYa1eI1hpDE. Maybe not all videos are the same. Give it a try and let me know if you can play any VEVO content.

Code: Select all
adrianp@frost:/tmp$ youtube-dl -F http://www.youtube.com/watch?v=jYa1eI1hpDE
[youtube] jYa1eI1hpDE: Downloading webpage
[youtube] jYa1eI1hpDE: Extracting video information
[youtube] jYa1eI1hpDE: Downloading DASH manifest
[info] Available formats for jYa1eI1hpDE:
format code  extension  resolution note
249          webm       audio only DASH audio , opus @ 50k
250          webm       audio only DASH audio , opus @ 70k
251          webm       audio only DASH audio , opus @160k
140          m4a        audio only DASH audio  129k , m4a_dash container, aac  @128k (44100Hz), 3.73MiB
171          webm       audio only DASH audio  131k , audio@128k (44100Hz), 3.52MiB
141          m4a        audio only DASH audio  255k , m4a_dash container, aac  @256k (44100Hz), 7.40MiB
278          webm       256x144    DASH video  107k , webm container, VP9, 1fps, video only, 2.70MiB
160          mp4        256x144    DASH video  110k , 12fps, video only, 3.16MiB
242          webm       426x240    DASH video  233k , 1fps, video only, 5.41MiB
133          mp4        426x240    DASH video  248k , 24fps, video only, 7.09MiB
243          webm       640x360    DASH video  418k , 1fps, video only, 9.66MiB
134          mp4        640x360    DASH video  611k , 24fps, video only, 11.94MiB
244          webm       854x480    DASH video  853k , 1fps, video only, 18.55MiB
135          mp4        854x480    DASH video 1115k , 24fps, video only, 22.90MiB
17           3gp        176x144   
36           3gp        320x240   
5            flv        400x240   
43           webm       640x360   
18           mp4        640x360    (best)


Wait, on second look, I can force it to quality 18 - which is 360p and is returned in mp4. I hope most vevo videos will still have this (probably youtube still keeps it for compatibility). At least this way you can play something from VEVO...

Feedback welcome.
User avatar
mad_ady
Developer
 
Posts: 4564
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Youtube3   

Postby willsguise » Wed Oct 14, 2015 8:48 am

Hi Mad

Brilliant! :) I have just tested the plugin and it is working fine, except for the Vevo videos (which does not personally concern me) . I have been able to search, find and play an amusing clip in which the whole Periodic Table is sung to the Cancan from Offenbach's Orpheus in the Underworld. A lot of elements seem to have been added to the Table since I was at school. I was also able to play videos from my subscription channels and favourites. I have a 40 inch TV and the picture quality on that is very good. So hearty congratulations on a job very well done.
Best Wishes
William
willsguise
n00b
 
Posts: 14
Joined: Fri Oct 02, 2015 6:28 am

Re: Youtube3   

Postby scorpio.sar » Wed Oct 14, 2015 9:05 am

scorpio.sar wrote:Many thx for plugin but:

1. I cant add to fav list some Youtube channels such as: (not shown in plugin)

https://www.youtube.com/channel/UC5JHZ7no2Kcn1ejHuA8AmDQ
https://www.youtube.com/channel/UCsgnWX-HU2BIS7B-QMzPcfQ
https://www.youtube.com/channel/UCZkl4La84NS5IdPLeLltRmw

2. If you cant realize user authentication to view all new videos in one feed (such as on youtube site https://www.youtube.com/feed/subscriptions ) please realize one feed for all channels in comma-separated list by publish time in descending order. Its not very good to list all my channels to search new videos everytime.


What about these bugs ?
Device: WDLXTV_LIVE
FW Base: 1.05.04
Current version: 0.5.2.2
scorpio.sar
n00b
 
Posts: 11
Joined: Sat Sep 19, 2015 1:04 am

Re: Youtube3   

Postby jakeb » Wed Oct 14, 2015 1:18 pm

willsguise wrote: I have been able to search,


Search doesn't work for me, simply gives me that initial list of videos like when I start plugin except it doesn't show my \username \categories and \search on top.
Rest is working fine, good job, thank you!
jakeb
n00b
 
Posts: 5
Joined: Sat Oct 10, 2015 12:42 pm

Re: Youtube3   

Postby mad_ady » Wed Oct 14, 2015 10:18 pm

I'd appreciate the elements song you found. My favorite is https://www.youtube.com/watch?v=DYW50F42ss8 :)

To play VEVO clips you will also need the python.app.bin (see the first post).

The best video quality you can get is 720p, because youtube stopped providing 1080p as MP4 with sound (there are different streams for video/audio that you'd need to mux together). VEVO clips are limited to 360p because I can see most don't have MP4 with higher quality (higher quality either has different codecs or different - webm - formats).

For the new video subscriptions feature (the one that Youtube's v3 API doesn't implement), I plan on using an external project to do the legwork: https://github.com/ali1234/ytsubs/blob/master/ytsubs.py Again, you'll need python.app.bin for this to work. Will let you know when it should work. I haven't looked in the favorite channels not showing up.

I will also have to test search. Can you provide some search terms?
User avatar
mad_ady
Developer
 
Posts: 4564
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Youtube3   

Postby willsguise » Thu Oct 15, 2015 2:52 am

[quote="mad_ady"]I'd appreciate the elements song you found. My favorite is https://www.youtube.com/watch?v=DYW50F42ss8 :)

Here is the link to the elements song: https://www.youtube.com/watch?v=zUDDiWtFtEM

How would I download and install python. app.bin?

This may be relevant to jakeb too: To do my searches I clicked on the search thumbnail in the app and then used the search function on the remote. E.g. Having clicked on the search thumbnail, I pressed the search button on the remote, used the onscreen keyboard to type in "Nottingham Trams" and, after about twenty seconds loading, was presented with a long list of tram videos about ten of which were about Nottingham's new tram extension. I selected one and it played very well.

I look forward to further developments.

All the best.
willsguise
n00b
 
Posts: 14
Joined: Fri Oct 02, 2015 6:28 am

Re: Youtube3   

Postby mad_ady » Thu Oct 15, 2015 4:24 am

Heh, I'm nerdy enough to say I knew that one :) I'm an ASAPScience subscriber :)

I updated the first post with prerequisite information to include where to get the python.app.bin.

The search function should work with the remote only (or by clicking search).
User avatar
mad_ady
Developer
 
Posts: 4564
Joined: Fri Nov 05, 2010 9:08 am
Location: Bucharest, Romania

Re: Youtube3   

Postby jakeb » Thu Oct 15, 2015 4:40 am

willsguise wrote:This may be relevant to jakeb too: To do my searches I clicked on the search thumbnail in the app and then used the search function on the remote. E.g. Having clicked on the search thumbnail, I pressed the search button on the remote, used the onscreen keyboard to type


Thank you, that was the problem!

I've managed to search for ABBA (easiest to type on on-screen-keaboard) - but when I click on particular video screen is black for 2-3 seconds, no error message and set me back to the search result list.

Edit: just saw I can not play some of those "recommended" videos now from YT. Some play some don't. Puzzled.
jakeb
n00b
 
Posts: 5
Joined: Sat Oct 10, 2015 12:42 pm

Re: Youtube3   

Postby willsguise » Thu Oct 15, 2015 5:23 am

mad_ady wrote:Heh, I'm nerdy enough to say I knew that one :) I'm an ASAPScience subscriber :)

I updated the first post with prerequisite information to include where to get the python.app.bin.

The search function should work with the remote only (or by clicking search).


Thanks for pointing me in the direction of the link for python.app.bin. Unfortunately the website only offers it in a tarball which I cannot open on my Windows PC. I think I shall just have to manage without it . I do not think this will inconvenience me too much, as there are already more videos available to me than I should ever have time to watch.
willsguise
n00b
 
Posts: 14
Joined: Fri Oct 02, 2015 6:28 am

PreviousNext

Return to UMSP Plugins

Who is online

Users browsing this forum: No registered users and 1 guest