brainfoolong/omxwebgui-v2

Autoplay next video

nmyakuba opened this issue · 6 comments

Where is Autoplay next video?

Unfortunetely it does not exist in v2. The idea was to implement it in a better way but due the lack of time it's just not in.

Just spent an hour or so to find out, why autoplay of the next song/video in the playlist is not working for me. And I just wanted to create an issue for that, just to find out that there is already one open for that ;-)
But seriously, I'm also of the opinion that this would be a vast improvement of the player - last but not least this is exactly what the term "playlist" means to me: A list of songs that are played automatically, one after each other.
Maybe I have the time to implement that myself - will do a pull request if relevant (or send you a patch per mail, whatever your personal commit style is).

I'll wait

Great to see if you can create something. The general problem here is, this is web based and there is no permanent service in the background that checks periodically if the player has stopped.

It can be done in the old v1 way of having opened the webpage all day long and pull every x seconds to check if the player has stopped, but that was the way i don't wanted anymore. Maybe there is some better way.

It can be done in the old v1 way of having opened the webpage all day long and pull every x seconds to check if the player has stopped, but that was the way i don't wanted anymore. Maybe there is some better way.

I don't get your point here: You still do this kind of polling client-side in v2 - in order to update the status bar of the player. So I thought to integrate the playlist functionality within this polling callback which is already doing its work. Or do you rather mean that you once planned to replace the whole status bar update functionality with a more modern one (which would be web sockets probably)?

You are right, the polling is done for the status updates on the website. But you want the status updates when you are on the website, it make no sense somewhere else.

For the autoplay/playlist functionality it's different. I want it to work even when you not have opened the webpage. There must be something "server/raspberry side" that do the polling and loading the next video from the playlist, if the player has stopped.

That's the reason why i don't want it to work like in v1, i don't want to must have opened the webpage to make the autoplay feature work. There must be a neat way but with PHP it's not so convenient to have something running in the background all day long. With NodeJS this all is not a problem, but this library don't use NodeJS and should also not require it as a dependency. Should be pure PHP.

Or maybe i do someday a complete rewrite with NodeJS... Pure NodeJS without PHP.