diff --git a/MediaBrowser.Providers/Plugins/Tmdb/Configuration/PluginConfiguration.cs b/MediaBrowser.Providers/Plugins/Tmdb/Configuration/PluginConfiguration.cs
index 92f5306e54..03aaf380b5 100644
--- a/MediaBrowser.Providers/Plugins/Tmdb/Configuration/PluginConfiguration.cs
+++ b/MediaBrowser.Providers/Plugins/Tmdb/Configuration/PluginConfiguration.cs
@@ -42,6 +42,11 @@ namespace MediaBrowser.Providers.Plugins.Tmdb
///
public string? BackdropSize { get; set; }
+ ///
+ /// Gets or sets a value indicating the logo image size to fetch.
+ ///
+ public string? LogoSize { get; set; }
+
///
/// Gets or sets a value indicating the profile image size to fetch.
///
diff --git a/MediaBrowser.Providers/Plugins/Tmdb/Configuration/config.html b/MediaBrowser.Providers/Plugins/Tmdb/Configuration/config.html
index 72bd38ffa3..48ec0535c5 100644
--- a/MediaBrowser.Providers/Plugins/Tmdb/Configuration/config.html
+++ b/MediaBrowser.Providers/Plugins/Tmdb/Configuration/config.html
@@ -36,6 +36,9 @@
+
+
+
@@ -76,6 +79,10 @@
selBackdropSize.innerHTML = clientConfig.BackdropSizes.map(sizeOptionsGenerator);
selBackdropSize.value = pluginConfig.BackdropSize;
+ var selLogoSize = document.querySelector('#selectLogoSize');
+ selLogoSize.innerHTML = clientConfig.LogoSizes.map(sizeOptionsGenerator);
+ selLogoSize.value = pluginConfig.LogoSize;
+
var selProfileSize = document.querySelector('#selectProfileSize');
selProfileSize.innerHTML = clientConfig.ProfileSizes.map(sizeOptionsGenerator);
selProfileSize.value = pluginConfig.ProfileSize;
@@ -129,6 +136,7 @@
config.MaxCastMembers = document.querySelector('#maxCastMembers').value;
config.PosterSize = document.querySelector('#selectPosterSize').value;
config.BackdropSize = document.querySelector('#selectBackdropSize').value;
+ config.LogoSize = document.querySelector('#selectLogoSize').value;
config.ProfileSize = document.querySelector('#selectProfileSize').value;
config.StillSize = document.querySelector('#selectStillSize').value;
ApiClient.updatePluginConfiguration(PluginConfig.pluginId, config).then(Dashboard.processPluginConfigurationUpdateResult);
diff --git a/MediaBrowser.Providers/Plugins/Tmdb/Movies/TmdbMovieImageProvider.cs b/MediaBrowser.Providers/Plugins/Tmdb/Movies/TmdbMovieImageProvider.cs
index f71f7bd10d..16f0089f8f 100644
--- a/MediaBrowser.Providers/Plugins/Tmdb/Movies/TmdbMovieImageProvider.cs
+++ b/MediaBrowser.Providers/Plugins/Tmdb/Movies/TmdbMovieImageProvider.cs
@@ -44,7 +44,8 @@ namespace MediaBrowser.Providers.Plugins.Tmdb.Movies
return new List
{
ImageType.Primary,
- ImageType.Backdrop
+ ImageType.Backdrop,
+ ImageType.Logo
};
}
@@ -85,10 +86,12 @@ namespace MediaBrowser.Providers.Plugins.Tmdb.Movies
var posters = movie.Images.Posters;
var backdrops = movie.Images.Backdrops;
- var remoteImages = new List(posters.Count + backdrops.Count);
+ var logos = movie.Images.Logos;
+ var remoteImages = new List(posters.Count + backdrops.Count + logos.Count);
_tmdbClientManager.ConvertPostersToRemoteImageInfo(posters, language, remoteImages);
_tmdbClientManager.ConvertBackdropsToRemoteImageInfo(backdrops, language, remoteImages);
+ _tmdbClientManager.ConvertLogosToRemoteImageInfo(logos, language, remoteImages);
return remoteImages;
}
diff --git a/MediaBrowser.Providers/Plugins/Tmdb/TV/TmdbSeriesImageProvider.cs b/MediaBrowser.Providers/Plugins/Tmdb/TV/TmdbSeriesImageProvider.cs
index 5ef3736c4f..130d6ce448 100644
--- a/MediaBrowser.Providers/Plugins/Tmdb/TV/TmdbSeriesImageProvider.cs
+++ b/MediaBrowser.Providers/Plugins/Tmdb/TV/TmdbSeriesImageProvider.cs
@@ -42,7 +42,8 @@ namespace MediaBrowser.Providers.Plugins.Tmdb.TV
return new List
{
ImageType.Primary,
- ImageType.Backdrop
+ ImageType.Backdrop,
+ ImageType.Logo
};
}
@@ -69,10 +70,12 @@ namespace MediaBrowser.Providers.Plugins.Tmdb.TV
var posters = series.Images.Posters;
var backdrops = series.Images.Backdrops;
- var remoteImages = new List(posters.Count + backdrops.Count);
+ var logos = series.Images.Logos;
+ var remoteImages = new List(posters.Count + backdrops.Count + logos.Count);
_tmdbClientManager.ConvertPostersToRemoteImageInfo(posters, language, remoteImages);
_tmdbClientManager.ConvertBackdropsToRemoteImageInfo(backdrops, language, remoteImages);
+ _tmdbClientManager.ConvertLogosToRemoteImageInfo(logos, language, remoteImages);
return remoteImages;
}
diff --git a/MediaBrowser.Providers/Plugins/Tmdb/TmdbClientManager.cs b/MediaBrowser.Providers/Plugins/Tmdb/TmdbClientManager.cs
index 28d6f4d0c1..d78652834d 100644
--- a/MediaBrowser.Providers/Plugins/Tmdb/TmdbClientManager.cs
+++ b/MediaBrowser.Providers/Plugins/Tmdb/TmdbClientManager.cs
@@ -543,6 +543,17 @@ namespace MediaBrowser.Providers.Plugins.Tmdb
ConvertToRemoteImageInfo(images, Plugin.Instance.Configuration.BackdropSize, ImageType.Backdrop, requestLanguage, results);
}
+ ///
+ /// Converts logo s into s.
+ ///
+ /// The input images.
+ /// The requested language.
+ /// The collection to add the remote images into.
+ public void ConvertLogosToRemoteImageInfo(List images, string requestLanguage, List results)
+ {
+ ConvertToRemoteImageInfo(images, Plugin.Instance.Configuration.LogoSize, ImageType.Logo, requestLanguage, results);
+ }
+
///
/// Converts profile s into s.
///
@@ -622,6 +633,11 @@ namespace MediaBrowser.Providers.Plugins.Tmdb
pluginConfig.BackdropSize = imageConfig.BackdropSizes[^1];
}
+ if (!imageConfig.LogoSizes.Contains(pluginConfig.LogoSize))
+ {
+ pluginConfig.LogoSize = imageConfig.LogoSizes[^1];
+ }
+
if (!imageConfig.ProfileSizes.Contains(pluginConfig.ProfileSize))
{
pluginConfig.ProfileSize = imageConfig.ProfileSizes[^1];