Tranquil 93 Posted January 15, 2014 Share Posted January 15, 2014 (edited) Hello Forum. I'm thinking about to code small plugin in client side to switch the framerate. Until today, I did not found a solution on my WMC to solve the framerate switching question. (even Media Control does not work properly) So I started to code a small tool yesterday. My Idea is, to examine the Mediafile using MediaInfo.dll to get the frame rate of the movie which is currently starting or running. Match the framerate in the list and map it to the list of supported frame rates by panel. Should be not that hard. Now I try to find a way of how to implement this in MB3 as a client side plugin. Where to find documentation about that? The easiest way for me is to create a .dll which has some entry points which will be called from the client if something happens. Edited January 15, 2014 by Tranquil Link to comment Share on other sites More sharing options...
Redshirt 1487 Posted January 15, 2014 Share Posted January 15, 2014 Hi, There's not a lot of public information when it comes to creating mediabrowser classic plugins. If your going to create this plugin then it sounds like the events you'll need to hook are the PrePlayback and PlaybackFinished events. That's likely where you'd want to call your custom methods. It's not perfect but you can have a look at my trakt plugin for MBC to see the basics of an MBC plugin and how to attach listeners to those events I mentioned. https://github.com/RedshirtMB/Trakt-Classic 1 Link to comment Share on other sites More sharing options...
Tikuf 663 Posted January 15, 2014 Share Posted January 15, 2014 I would be querying the database for the frame rate and not using MediaInfo.dll. MediaInfo.dll will not return info on some of the files we support. 1 Link to comment Share on other sites More sharing options...
Redshirt 1487 Posted January 15, 2014 Share Posted January 15, 2014 That's a good point Tikuf. Tranquil, if you look at e.Item.CurrentMedia.MediaInfo.VideoFPS in the preplayback events you should find the framerate. 1 Link to comment Share on other sites More sharing options...
Tranquil 93 Posted January 15, 2014 Author Share Posted January 15, 2014 Thanks for spotting on this. I will take a look if I'm at home! Link to comment Share on other sites More sharing options...
ebr 14935 Posted January 15, 2014 Share Posted January 15, 2014 Yeah, you don't want to be directly examining the file or running something as slow as media info on the MBC end. We already have this information in the object as Red pointed out. You can use the old MB2 Visual Studio template to create a MBC plug-in. The one for a straight plug-in can be found here. Link to comment Share on other sites More sharing options...
Recommended Posts