Media Player Classic

Questions and comments specific to a particular plugin should go here.
User avatar
Pako
Plugin Developer
Posts: 2290
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: Media Player Classic

Post by Pako » Sun Jan 19, 2014 8:42 am

Unfortunately I do not see, how your question is meant.
The feature "event triggering" was integrated in MPC-HC plugin several years ago. For example:
MPC-HC_Events.png
What do you want exactly?

Pako

weirdinin
Posts: 3
Joined: Tue Nov 19, 2013 9:37 pm

Re: Media Player Classic

Post by weirdinin » Sun Jan 19, 2014 1:00 pm

Ah super! Didnt know that eventghost already has that property since i cannot test eventghost right atm. So my question is answered. Thank you.

weirdinin
Posts: 3
Joined: Tue Nov 19, 2013 9:37 pm

Re: Media Player Classic

Post by weirdinin » Thu Feb 06, 2014 8:16 am

Hi. Have an issue with mpc-hc plugin that I haven't been able to solve by myself. For some reason every time when I launch mpc-hc.exe and start a movie, mpc plugin fires first pause command and then immediately play command. Because the lights are controlled by play and pause, the lights flash on and off just before the movie starts. That's driving me crazy. Any ideas why there's pause and play before movie starts.
Here's screenshot and xml-file of the configuration. If neede more screenshots or information, tell me.
http://speedy.sh/dvfU4/startti52-kaukos.xml
Image

EDIT. I got it working now. I disabled the light controlling during that pause and play thing in the beginning of a movie and then enabled it again after five seconds. Eventghost's the best thanks to huge customization capacity.

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Mon Feb 17, 2014 2:32 am

Is there a newer plugin the upgrade broke my plugin. I went and restored a backup as the new version of EventGhost is not playing nice with the plugin version I have.

BTW I had to go back to r1572 version for now. I am going to try incremental updates starting at r1582 to see where the plugin breaks.

Problem started right at r1582 with this error message.

Code: Select all

      Error starting plugin: Media Player Classic
      Traceback (most recent call last) (1582):
        File "C:\Program Files\EventGhost\eg\Classes\PluginInstanceInfo.py", line 177, in Start
          self.instance.__start__(*self.args)
        File "C:\Program Files\EventGhost\plugins\MediaPlayerClassic\__init__.py", line 2346, in __start__
          if not exists(mpcPath):
        File "genericpath.pyc", line 18, in exists
      TypeError: coercing to Unicode: need string or buffer, NoneType found
Last edited by molitar on Fri Feb 21, 2014 6:47 pm, edited 1 time in total.

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Thu Feb 20, 2014 10:20 pm

This plugin in broken with the newest EventGhost I had to go back to the old one. It will only work for a short while than commands stop responding. If I choose the executable in the plugin than it works but it opens up tons of blank non playing mpc-home.exe files but no commands work.

For now I will backup my current folder than restore from the old backup I have so I can once again use my media player correctly again.

Can you please figure out why this plugin is not working correctly with latest version of EventGhost?

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Tue Dec 16, 2014 11:52 am

With a volume up script lately I been getting a new errror. If I reboot the computer it will start working fine again. I have pasted the error below and the code that I am using. Thanks for looking at it. It maybe some sort of memory leak I reboot and the problem will go away for a while.

ERROR
Media Player Classic: Volume Up
Python Script
Traceback (most recent call last):
Python script "0", line 5, in <module>
hwnd = Find_MPC_Volume_Ctrl()
File "C:\Program Files (x86)\EventGhost\eg\Classes\WindowMatcher.py", line 188, in FindMatch
hwnds = self.Find()
File "C:\Program Files (x86)\EventGhost\eg\Classes\WindowMatcher.py", line 180, in Find
childClassMatch(GetClassName(childHwnd)) and
OverflowError: long int too large to convert to int
SCRIPT

Code: Select all

    <?xml version="1.0" encoding="UTF-8" ?>
    <EventGhost Version="1572">
        <Action Name="Python Script">
            EventGhost.PythonScript(u'from eg.WinApi.Dynamic import SendMessage\nTBM_GETPOS = 1024\nFind_MPC_Volume_Ctrl=eg.WindowMatcher(u\'mpc-hc.exe\', None, u\'MediaPlayerClassicW\', None, u\'msctls_trackbar32\', 1, True, 0.0, 0)\n\nhwnd = Find_MPC_Volume_Ctrl()\n\nif len(hwnd) > 0:\n    if eg.globals.WindowsState != "Fullscreen":\n        mon = 2\n        top = 1000\n    else:\n        mon = 1\n        top = 900\n    volume = SendMessage(hwnd[0], TBM_GETPOS, 0, 0)\n    osd = "Volume: %i%%"\n    if volume == 1 : volume = 0\n    eg.plugins.EventGhost.ShowOSD(osd % volume, u\'0;-64;0;0;0;700;0;0;0;238;3;2;1;66;Arial\', (255, 255, 255), (0, 0, 0), 5, (0, top), mon, 3.0, True)\nelse:\n    print "Window not found"')
        </Action>
    </EventGhost>

jonib
Plugin Developer
Posts: 1280
Joined: Thu Mar 26, 2009 9:33 pm
Location: Sweden

Re: Media Player Classic

Post by jonib » Wed Dec 17, 2014 11:52 am

molitar wrote:
Media Player Classic: Volume Up
Python Script
Traceback (most recent call last):
Python script "0", line 5, in <module>
hwnd = Find_MPC_Volume_Ctrl()
File "C:\Program Files (x86)\EventGhost\eg\Classes\WindowMatcher.py", line 188, in FindMatch
hwnds = self.Find()
File "C:\Program Files (x86)\EventGhost\eg\Classes\WindowMatcher.py", line 180, in Find
childClassMatch(GetClassName(childHwnd)) and
OverflowError: long int too large to convert to int
I posted a similar error a while a go here, I assumed it got fixed somehow as I have not had the problem for a long time.

jonib
XBMC2 plugin to control XBMC. If you want to flatter me Image

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Wed Dec 17, 2014 11:56 pm

Ok I tried to upgrade to the latest version of EventGhost and sure enough it broke my plugin..

Plugin: Media Player Classic
Error starting plugin: Media Player Classic
Application not found!

So I tried to downgrade down to 4.1 1600 build.. still failed.. finally I just restored from backup my 4.1 build 1572 which works again.

This time I tried to upgrade EventGhost but downgrade the plugin from my backup and it is not complaining. Seems the version that comes with latest version does not work right. But seems some features maybe not working with it.. I'm going to reboot my system and test to verify the compatibility.

User avatar
Pako
Plugin Developer
Posts: 2290
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: Media Player Classic

Post by Pako » Thu Dec 18, 2014 7:41 am

molitar wrote:Plugin: Media Player Classic
Error starting plugin: Media Player Classic
Application not found!
Maybe I'm wrong, but this bug you never reported.
However, I myself met with a similar bug some time ago and I corrected it.
Maybe it will solve your problem.
You can always download the latest version from the repository.
Link is in the initial post in this topic.
Even today I made one small bug fix.

Pako

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Thu Dec 18, 2014 11:58 am

Thanks Pako I will grab that new version from the repository link.

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Fri Dec 19, 2014 1:01 am

Hi Pako,

I tried the repository link and I still am getting the same exact error message. Is there some log or something you want me to grab to find the error?

User avatar
Pako
Plugin Developer
Posts: 2290
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: Media Player Classic

Post by Pako » Fri Dec 19, 2014 5:09 am

molitar wrote:I tried the repository link and I still am getting the same exact error message
I'm not sure, which "the same error message" you are getting.
The old (why you can not use the latest version EventGhost) or the new (OverflowError: long int too large to convert to int) ?
molitar wrote:Is there some log or something you want me to grab to find the error?
I do not know about anything except normal log or log that is written to the file when you start EventGhost with the -debug option.

Pako

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Fri Dec 19, 2014 5:42 am

Ok I found the problem. The older version did not require me to point it to an mpc executable. The new one does which causes me problems as there is a few situations when I have more than one window open. Seems even though I am using find window the commands to MPC-HC would not work unless the filename and path is identified in that plugin now.

I found a way to fool the application so it would work without opening up a new Media Player Window all the time. I duplicated the mpc-hc.exe and renamed it to mpc-hc and pointed to that renamed file instead. It is now working great. Now I can once again have more than one player open and it will focus on the one that is active at the time. The -debug option helped me to locate what the issue was so thanks for that suggestion.

molitar
Experienced User
Posts: 165
Joined: Fri Sep 11, 2009 6:44 am

Re: Media Player Classic

Post by molitar » Fri Dec 26, 2014 6:21 am

I went back to the old version.. I really do not like your new plugin. It won't let me operate more than one MPC player at a time. The older one I did not have to point to a stupid exe file so it would not auto launch new MPC windows all the time. I could have 2 windows open on two different windows and just click to make one active and it would control that one properly. I really wish you would remove the need to point to an executable file in the plugin so I could use it like before.. I end up totally rolling back to my old version from a backup and back to a fully working EventGhost for my needs.

User avatar
Pako
Plugin Developer
Posts: 2290
Joined: Sat Nov 11, 2006 1:31 pm
Location: Czech Republic
Contact:

Re: Media Player Classic

Post by Pako » Fri Dec 26, 2014 8:23 am

I understand that you do not like the "new" plugin. But I do not intend to change it back.
  • Only a few users need to watch two (or more) video simultaneously.
  • I do not understand why you need EventGhost when you control MPC-HC by clicking?
  • Reference to one specific window it has its own reason. Some of the newer plugin features (that you probably do not use) can not function without it. For example, events triggering (yes and since it is EventGhost, it is an important function).
    Some other users need it: Can eventghost create an mpc event with this plugin?
So yes, for you is the solution to stay with the old version.
Pako

Post Reply