Lightweight metadata record for a discovered plugin. More...
#include <PluginInfo.h>
Public Attributes | |
| std::string | name |
Display name, from Plugin::getName(). | |
| std::string | path |
| Absolute path to the plugin shared library. | |
| std::optional< sf::Texture > | thumbnail |
| std::string | version |
Version string, from Plugin::getVersion(). | |
Lightweight metadata record for a discovered plugin.
PluginInfo is populated by PluginManager::scanPlugins() when it probes a directory for plugin shared libraries. Each record holds everything the host application needs to display a plugin in a carousel or menu — name, version, thumbnail image, and the path needed to load it — without keeping the plugin's dylib open or the Plugin object alive.
The thumbnail texture is copied from the GPU to a CPU-side sf::Texture before the probe plugin is unloaded. This means the texture pixel data in PluginInfo remains valid after the dylib is closed, and can be safely used to render a preview image without re-loading the plugin.
thumbnail is std::nullopt when the plugin's manifest does not declare Images::THUMBNAIL, or when the texture fails to load.
Definition at line 51 of file PluginInfo.h.
| std::string ml::PluginInfo::name |
Display name, from Plugin::getName().
Definition at line 54 of file PluginInfo.h.
| std::string ml::PluginInfo::path |
Absolute path to the plugin shared library.
Definition at line 53 of file PluginInfo.h.
| std::optional<sf::Texture> ml::PluginInfo::thumbnail |
CPU-side copy of the plugin thumbnail, or std::nullopt if unavailable.
Definition at line 56 of file PluginInfo.h.
| std::string ml::PluginInfo::version |
Version string, from Plugin::getVersion().
Definition at line 55 of file PluginInfo.h.