Little help.

Status: "Works for me." But at this time only with YouTube.
Other should be possible.

Use at your own risk [risc ;-)]!

Any known bugs...
Install/update youtubedl and youtubesearch needs a secand try often.
UTF8 conversation in the File and Tag names
If Python fails in the search routine, YTPlay needs a restart.
...

Have insert a small start check. I try to find out if any or all needed components are present but I can not find out if all are the right version and setup correct.

After start you get a iconbar icon. Drag a valid youtube-URL on it and wait...
Should play after any second. If not you get an errormessage, I hope.

MPLayer support (only V1.04), I add.
Click Adjust (right mouse button) to the iconbar icon and you can select the player and the videoformat.
You also can update youtube-suff if needed.
If you select 720p, you need a fast machine ...
If 720p is not available on youtube, YTPlay falls back to 360p.

Add a YTSearch engine. Select click will open the search window.
Search: The search string  List/Page: Search offset. Ytsearch display max. 20 results so an 1 = 001 - 020; 2 = 021 - 040
Note: Change the offset will not change the result numbers in this version. You get 1-20 for the line.
Select click the line to play. The selected result will not to be highlighted in this version. Only the infoline will be changed.
Adjust + [Shift] create an mp3 from stream. FFMPEG is needed.
Adjust click the line to download the video. The selected result will not to be highlighted in this version. Only the infoline will be changed.

You need a lot of other stuff before you can use YTPlay complete.

Python, youtube-dl, ytSearch, mplayer, ffmpeg, ffplay, unixhome, sharedlibs has to be installed in the latest version and must be seen by the filer before all is working.

Installing:
Copy YTPlay to a place of your choice on your Filecore partition / your RISC OS device.

The following tools must be installed to use the basic feature... 

Python3 and additionals via PackMan

Install or update all the Python3 stuff and 

LibFFI6
LibBZ2-1.0
LibSSL
ZLib1g
SharedUnixLibrary 1.16
ARMEABISupport 1.00
SOManager 3.01
 
Than install youtube-dl and youtube-search-python:

python3 -m pip install youtube-dl

python3 -m pip install youtube-search-python 

Since YTPlay V3.01 you can use the Install/Update button in the configure Window (click Adjust (right mouse button) to the iconbar Icon).
Any times on any machines it needs a second try if the last line in TaskWindow not begins with "Successful..." ;-)

A player is needed...

FFPlay
http://riscos.openpandora.org/Diverses/Videohokupokus/ffplayetc.zip

MPlayer:
https://www.riscosports.co.uk/eabi

FFMPEG to create an mp3 file
https://www.riscosports.co.uk/eabi

All the parts must be seen by the filer before you start YTPlay.


Look at

https://www.riscository.com/2020/watching-youtube-videos-on-risc-os/

https://www.riscosopen.org/forum/forums/5/topics/15476?page=1

for more information.



Many thanks to Chris Gransden for the various ports!!!!
Also many thanks to Chris Martin (ffplay) and Chris Johns (Python 3) and all the other I forget.


Player Controls -FFPlay
~~~~~~~~~~~~~~~~~~~~~~~

The key controls below require the player to have the input focus. If the player
has lost the input focus, a click with SELECT or MENU will regain it.

q, ESC              quit
f                   toggle full screen
p, SPC              pause
m                   toggle mute
9, 0                decrease and increase volume respectively
/, *                decrease and increase volume respectively
a                   cycle audio channel in the current program
v                   cycle video channel
t                   cycle subtitle channel in the current program
c                   cycle program
w                   cycle video filters or show modes
s                   activate frame-step mode
left/right          seek backward/forward 10 seconds
down/up             seek backward/forward 1 minute
page down/page up   seek backward/forward 10 minutes
right mouse click   seek to percentage in file corresponding to fraction of width
left double-click   toggle full screen



MPlayer Keyboard Shortcuts
~~~~~~~~~~~~~~~~~~~~~~~~~~

<- and ->           Seek backward/forward 10 seconds.
up and down         Seek forward/backward 1 minute.
pgup and pgdown     Seek forward/backward 10 minutes.
[ and ]             Decrease/increase current playback speed by 10%.
{ and }             Halve/double current playback speed.
backspace           Reset playback speed to normal.
< and >             Go backward/forward in the playlist.
ENTER               Go forward in the playlist, even over the end.
HOME and END        next/previous playtree entry in the parent list
INS and DEL(ASX playlist only)  next/previous alternative source.
p / SPACE           Pause (pressing again unpauses).
.                   Step forward. Pressing once will pause movie, every consecutive press will play one frame and then go into pause mode again (any other key unpauses).
q / ESC             Stop playing and quit.
+ and -             Adjust audio delay by +/- 0.1 seconds.
/ and *             Decrease/increase volume.
9 and 0             Decrease/increase volume.
( and )             Adjust audio balance in favor of left/right channel.
m                   Mute sound. (MPEG-TS and libavformat only) Cycle through the available video tracks.
#                   (DVD, MPEG, Matroska, AVI and libavformat only)	Cycle through the available audio tracks.
TAB (MPEG-TS only)  Cycle through the available programs.
f                   Toggle fullscreen (also see -fs).
T                   Toggle stay-on-top (also see -ontop).
w and e             Decrease/increase pan-and-scan range.
o                   Toggle OSD states: none / seek / seek + timer / seek + timer + total time.
d                   Toggle frame dropping states: none / skip display / skip decoding (see -framedrop and -hardframedrop).
v                   Toggle subtitle visibility.
j                   Cycle through the available subtitles.
y and g             Step forward/backward in the subtitle list.
F                   Toggle displaying forced subtitles .
a                   Toggle subtitle alignment: top / middle / bottom.
x and z             Adjust subtitle delay by +/- 0.1 seconds.
r and t             Move subtitles up/down.
i (-edlout mode only)    Set start or end of an EDL skip and write it out to the given file.
s (-vf screenshot only)  Take a screenshot.
S (-vf screenshot only)  Start/stop taking screenshots.
I                   Show filename on the OSD.
! and @             Seek to the beginning of the previous/next chapter.



Feel free to contact me and give a feedback.

http://riscos.openpandora.org/Kontakt.php