Jump to content

Plugin image change


Go to solution Solved by Poppabear,

Recommended Posts

Going forward with Emby Server 3.6. plugins will be responsible for embedding their own thumbnail image to be used in the installed plugins list, "My Plugins".

 

Previously we were using the plugin catalog to figure out the image, however this has two problems:

  • If you're not listing the plugin in the catalog, there was no way to have a thumbnail
  • In the event of an outage of our admin server, this would cause the "My plugins" list to be very slow

Embedding is simple with these three steps:

  • Add a thumb image to your project as an embedded resource
  • Have your plugin implement IHasThumbImage
  • Implement these two methods:

https://github.com/MediaBrowser/NextPVR/blob/master/MediaBrowser.Plugins.NextPvr/Plugin.cs#L63-L75

 

@@Sven

@@mutu310

@@chef

@@radeon

@@Inrego

@@softworkz

@@reggi

@@krustyreturns 

@@Frank Drebin

@@snazy2000

@@hamstercat

@@Aphid

@@BeppoMonkeyBoy

@@flexage

@@pünktchen 

@

@t.andre

  • Like 1
Link to post
Share on other sites

Two questions.

 

1) What is the recommended size of the thumbnail image?

2) What is the minimum required server version that supports IHasThumbImage?

Link to post
Share on other sites
  • 3 weeks later...
  • 2 months later...
Happy2Play

Not knowing how far out 3.6 release is but out of all the plugins I have Statistics and TimeLord plugins still need updating.

 

Anyone else seeing plugins that don't have images in 3.6.x.x?

Link to post
Share on other sites
  • 1 month later...
Happy2Play

All the plugins I have come across or use have been updated.

 

 

 

Oops the Statistics plugin still need image update.

Edited by Happy2Play
Link to post
Share on other sites
  • 8 months later...

IHasThumbImage is not resolving for me ? And I get no Thumbnail ...

 

Visual Studio 2019

using System;
using System.Collections.Generic;
using MediaBrowser.Common.Configuration;
using MediaBrowser.Common.Plugins;
using MediaBrowser.Model.Plugins;
using MediaBrowser.Model.Serialization;
using System.IO;
using MediaBrowser.Model.Drawing;

...

public Stream GetThumbImage()
{
   var type = GetType();
   return type.Assembly.GetManifestResourceStream(type.Namespace + ".Images.plugin.png");
}

public ImageFormat ThumbImageFormat => ImageFormat.Png;

 5d83a61085f94_devenv_5GdmXFBs6h.png

 

5d83a65f9070f_devenv_AgcrVE5AP9.png

 

Any Help ?

 

Thanks in advance

Link to post
Share on other sites

Other than making sure you're running the latest nuget package, sorry, no ideas. There's an example right in the first post that all of the other plugins have followed.

Link to post
Share on other sites

@@BillOatman Thanks,

 

I have the same exact things going on.

 

I was able to fix the "Resolving issue" so now VS2019 is resolving the interface, However i still am not getting my image on the Emby server dashboard.

Link to post
Share on other sites
  • Solution

I was able to fix it, My Post Build Event was wrong

 

Had: xcopy "$(TargetPath)" "%AppData%\Roaming\Emby-Server\system\plugins" /y

 

Changed it to: xcopy "$(TargetPath)" "%AppData%\Emby-Server\system\plugins" /y

 

Had to remove the Roaming directory from that path

 

Thanks guys

  • Like 1
Link to post
Share on other sites
  • 10 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...