Plugin to perform custom action on startup and shutdown? (1 Viewer)

Vertigo1

Portal Member
November 5, 2008
8
0
For reasons I won't go into much, I need to run a "custom action" when MP starts and finishes. This is basically modifying the DirectDraw forced refresh rate in the registry to 24Hz on startup and 50Hz on shutdown.

Is there an existing plugin that would accomplish this or, if not, how easy would it be to write one? Don't really want to re-invent the wheel if there's already something out there that will do the job.

Additional info for those interested:
Basically using MCE2005 for TV viewing and time-shifting as I'm more than happy with it. This operates at 50Hz refresh to give me perfectly smooth playback with PAL material here in the UK.
What I want to do is be able to "shell out" to MP via a custom link in More Programs in MCE and then use MP for viewing non-TV AVI and MKV files. These are virtually all 23.976fps files. By switching the above registry value before running MP, the interface runs at a nice 50Hz but, when I start a video file, the full-screen viewer reads the above registry value and switches the output to 24Hz. I then use ReClock to make the small adjustment from 23.976fps to 24fps and I get perfectly smooth playback.
Works a treat if I just change the registry setting manually then run MP but I'm having trouble getting this to work automatically when running MP from within MCE. I'm therefore wondering if I can get MP itself to somehow change this registry value when it starts and closes.

Thanks for any advice anyone can offer :)
 

Epstone

Portal Pro
March 10, 2007
102
16
36
Riedstadt
Home Country
Germany Germany
uhm.. dunno if thats a workaround that can help you? :)

There is a small tool called reschange.exe which you can call through a bat file and defined values like:

reschange.exe -w1920 -h1080 23,XX Hz -force something like that
Mediaportal.exe

It would change the resolution at first to your needs and then starts mediaportal.
12noon
ah its now called Display changer, but it should still have those command line features?!
 

Vertigo1

Portal Member
November 5, 2008
8
0
Thanks for that. Think I've managed to whip up a little plugin which changes the registry setting I need when it starts and back again when it closes. Will try it out on my main HTPC when I get home and see how it works.

Had to do it as a "window" plugin as I couldn't figure out how to do a process one and make it work but there's no actual interface to it so it seems to do what I need.
 

Users who are viewing this thread

Top Bottom