[Pending] Allow web image caching between sessions, plus general web image improvements [MP Client]

Blue Lightning

Portal Member
October 8, 2011

Patch for MP1 Client attached

New feature:
Skins can include cache="true" on texture elements eg <texture cache="yes">#TV.Example.Logo</texture> or <texture cache="yes">https://example.com/example.png</texture>
This will make the image save in a /Webcache folder and persist between Mediaportal sessions.
Images are deleted when they haven't been used for 72 hours. This means you can have the same image persist for weeks without internet if you're constantly using it (no need to web request it), but when you're not using it it'll be deleted.
The 72 hours should be attached to a GUI setting in future.

Any texture elements without cache="yes" will continue to use the current session-based saving. Therefore this change is backwards compatible with all skins.

Fixes to existing feature:
Web downloaded images now accept HTTPS. Was previously just HTTP.
Web images are temporarily saved by their URL instead of a number. This may improve performance as MP only needs to look at 1 file instead of looping over every existing file.
PNG images are now saved and processed as .png. This may improve performance as they were previously being treated as gif and using frame-finding code.

(my previous threads can be closed as outdated)


Top Bottom