Closed AxelTerizaki closed 4 years ago
To comment further...
My use case was that my app is used to manipulate mpv on a computer, and a similar app runs on a server on the net to allow people outside of the wifi network to participate. The app on the net serves as a proxy to node-mpv by listening to the socket and sending it over to the local app that runs the real mpv (with node-mpv too)
Not sure if this makes sense for you, but it should allow people to hook node-mpv to an already running mpv process as long as mpv's IPC server is listening in. To do that, they have to use the already_running
option flag and set it to true.
Since I'm using a new option, I don't believe this impacts normal use.
As expected, the module crashes when trying to connect to a non-existing socket (suppose already_running
is set to true, but no mpv is running at the moment, it thinks mpv has crashed.
I'm not sure how the error handling on this could be improved to be honest, I'm not familiar enough with node-mpv's code to decide what would be best.
I need to look into the code more closely but I believe this is used as a flag to tell if the process is running and needs to bre restarted or not.
I know this is super super old, is this ready to be merged or still a wip?
I'm currently not using this code at all since the reason I added it was an issue in Karaoke Mugen that I postponed eternally, but according to my comment I had tested it and it worked.
Up to you if you merge it or not, it's not super important to me at the moment, but I think @sir-kain wanted that for his use case.
Implemented this myself, still thanks for the effort you put into this :) always appreciate your help
This refs #33