Jump to content


Photo
- - - - -

Problem with using MPC-HC as external player


  • Please log in to reply
11 replies to this topic

#1 saj OFFLINE  

saj

    Advanced Member

  • Members
  • 74 posts
  • Local time: 09:25 AM

Posted 12 June 2017 - 10:16 AM

I use Emby for WMC heavily, and I use MPC-HC to play all my media. If I play a movie and watch it to the end or end it prematurely, everything works fine. However, If while playing the movie, I do anything unusual with MPC-HC setttings, like right click and change the subtitle option, then when the movie ends or I stop it, the Emby screen is displayed, but Emby is locked up. Indeed it is so thoroughly locked up that I cannot end it or even close Windows Media Center. I have to alt-tab to the desktop and use a Windows Taskkill command to end WMC, I have played with a lot of settings to no avail. Do you have any idea how to fix this?

 

Thanks



#2 ebr ONLINE  

ebr

    Chief Bottle Washer

  • Administrators
  • 47409 posts
  • Local time: 08:25 AM

Posted 12 June 2017 - 10:05 PM

Nothing comes immediately to mind unfortunately.  Perhaps one of our community members who also uses that setup...?



#3 One2Go OFFLINE  

One2Go

    Advanced Member

  • Members
  • 521 posts
  • Local time: 08:25 AM

Posted 13 June 2017 - 03:05 AM

When I interact with MPC I use keyboard commands rather then mousing on the screen and so far that has worked without a hitch. But I also have experienced where WMC is locked up and I also do the same use Task manager and kill WMC. The key combination of Ctrl+Shift+ESC brings up the Task manager. It does not have the WAF approval but it works.



#4 jachin99 OFFLINE  

jachin99

    Advanced Member

  • Members
  • 650 posts
  • Local time: 08:25 AM

Posted 13 June 2017 - 10:40 AM

I also have had nothing but problems closing mpc-hc when it is launched through emby.  What version of MPC are you on?  Maybe try a different version?  I didn't know about the keyboard trick so thats good to know



#5 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 139743 posts
  • Local time: 08:25 AM

Posted 13 June 2017 - 10:44 AM

I also have had nothing but problems closing mpc-hc when it is launched through emby.  What version of MPC are you on?  Maybe try a different version?  I didn't know about the keyboard trick so thats good to know

 

Can you please describe what that means? thanks.



#6 One2Go OFFLINE  

One2Go

    Advanced Member

  • Members
  • 521 posts
  • Local time: 08:25 AM

Posted 13 June 2017 - 12:07 PM

Here is my setup that runs so far flawless with MPC as external player and using the Throgsoft themes.

 

MPC-HC website https://mpc-hc.org/

 

Version: v1.7.11 is released March 06, 2017

 

To be fair I am using a Logitech One remote control that has a few custom commands on it like Next Audio, Sub Titles ON/OFF plus Current Play Time of media and Render Statistics. These custom commands can be defined and Customized in MPC Options.

 

Read the following thread that may help you as you need to edit the Exit part of the Options / Keys entry.  https://emby.media/c...xternal-player/

 

In addition I do launch MPC and have it set to auto switch my projector to the frames per second of the media being played back.

 

Finally I have no difficulties with using as external players PDVD for DVDs and BDs and MPC with madVR for everything else.

 

Now display of media formats on the Emby display pages for the BD structure that is a different story but @Luke knows that :)


Edited by One2Go, 13 June 2017 - 12:11 PM.


#7 jachin99 OFFLINE  

jachin99

    Advanced Member

  • Members
  • 650 posts
  • Local time: 08:25 AM

Posted 13 June 2017 - 04:07 PM

Can you please describe what that means? thanks.

When I had MPC-HC installed as an external player WMC or Emby would crash when I tried to exit the player.  I don't use it right now because I have a few other things to troubleshoot, and only so much time to do so.  I might try it later in the future but using MPC is pretty low on my HTPC to-do list. 



#8 saj OFFLINE  

saj

    Advanced Member

  • Members
  • 74 posts
  • Local time: 09:25 AM

Posted 14 June 2017 - 09:47 AM

Thanks @ebr to all for the feedback. I have been able to solve the problem, but I had to write an AutoIt script to call MPC-HC rather than calling it directly from emby. It is clear that the mouse actions on the MPC-HC side affect emby for WMC somehow or affect how MPC-HC returns. The symptoms are that it returns to the emby screen from which I played the movie and usually displays a message saying it was unable to start emby. Sorry I don't have the exact message available at the moment. Then emby and WMC are locked and I cannot respond to the error message or do anything else except kill WMC and start over. With my script as an intermediary everything works perfectly.



#9 Luke OFFLINE  

Luke

    System Architect

  • Administrators
  • 139743 posts
  • Local time: 08:25 AM

Posted 14 June 2017 - 11:05 AM

It is possible that certain actions within MPC-HC may pause the MPC web api or may have the MPC web api act differently, and EMC is not accounting for this and that's when you see the lockup.



#10 One2Go OFFLINE  

One2Go

    Advanced Member

  • Members
  • 521 posts
  • Local time: 08:25 AM

Posted 14 June 2017 - 11:06 AM

That is one of the reasons I use keyboard commands from a small HTPC wireless keyboard.

Ctrl+I and up comes where you are time wise in the media played back.
Ctrl+R shows all the details of the media being played back, how many frames dropped and other playback information.
Ctrl+Enter MPC. Goes into full screen.

Check the key assignments in the options part of MPC

Edited by One2Go, 14 June 2017 - 11:08 AM.


#11 saj OFFLINE  

saj

    Advanced Member

  • Members
  • 74 posts
  • Local time: 09:25 AM

Posted 14 June 2017 - 11:21 AM

It is possible the web API is being paused, But I don't know how to tell that.I don't have to do anything very elaborate to cause the problem. Just moving the mouse, so MPC-HC displays its status information at the bottom of the screen along with the scroll bar seems to be enough. I do understand about using the keyboard, but I really prefer to have the mouse options, and the script makes everything work fine, so I 'll stick with that. Obviously it would be better if there were a way for emby to fix it. I am pretty familiar with all the MPC-HC options, and I have tried a lot of things that didn't help at all.



#12 saj OFFLINE  

saj

    Advanced Member

  • Members
  • 74 posts
  • Local time: 09:25 AM

Posted 14 June 2017 - 01:14 PM

I don't know if it will help at all, but I thought I would post the script in case it might offer the developers some insight into what might be happening. It follows:

 

___________________________________________________________________

 

If $CMDLINE[0] < 1 Then
    MsgBox(0," Missing Parameter","Missing Media File Name Parameter")
    Exit
EndIf
 
$MediaFileName = $CMDLINE[1]
 
RunWait(@ComSpec & " /c  pushd ..","",@SW_HIDE)
 
WinSetState("Windows Media Center","",@SW_DISABLE)
 
ShellExecuteWait("C:\Program Files\MPC-HC\mpc-hc64.exe", """"&$MediaFileName&"""", "C:\Program Files\MPC-HC", "open", @SW_Maximize)
 
ProcessWaitClose("mpc-hc64.exe")
 
RunWait(@ComSpec & " /c  popd","",@SW_HIDE)
 
WinActivate("Windows Media Center")
 
Send ("#!{ENTER}{ENTER}")
 
Exit (0)
 
______________________________________________________________
 
It's a weird little thing, and it seems to be the minimum of what I can make work consistently. It saves the current directory, actually disables Windows Media Center, calls MPC-HC, waits for MPC-HC to terminate, restores the directory, activates WMC, and then sends a WMC green button command followed by an extra enter, I found that the green button command would return me to the WMC menu pointing at my emby entry, and the extra enter command takes me back exactly where I should be in in emby (at the movie play screen).
 
It certainly wasn't an intuitive fix, but trial and error sometimes pays off.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users