TGA importer plugin.
Supports Truevision TGA (
*.vst) BGR, BGRA or grayscale images with 8 bits per channel.
This plugin depends on the Trade library and is built if
MAGNUM_WITH_TGAIMPORTER is enabled when building Magnum. To use as a dynamic plugin, load
"TgaImporter" via Corrade::
Additionally, if you're using Magnum as a CMake subproject, do the following:
set(MAGNUM_WITH_TGAIMPORTER ON CACHE BOOL "" FORCE) add_subdirectory(magnum EXCLUDE_FROM_ALL) # So the dynamically loaded plugin gets built implicitly add_dependencies(your-app Magnum::TgaImporter)
To use as a static plugin or use this as a dependency of another plugin with CMake, you need to request the
TgaImporter component of the
Magnum package and link to the
find_package(Magnum REQUIRED TgaImporter) # ... target_link_libraries(your-app PRIVATE Magnum::TgaImporter)
See Downloading and building, Usage with CMake, Loading and using plugins and File format support for more information.
Behavior and limitations
The images are imported with PixelFormat::
1 if the data require it.
RLE compression is supported, paletted images are not.
If a TGA 2 footer is recognized in the file, the optional extension and developer area blocks at the end of the file are ignored.
- class AbstractImporter
- Base for importer plugins.
Constructors, destructors, conversion operators
- TgaImporter() explicit
- Default constructor.
AbstractManager& manager, const Containers:: StringView& plugin) explicit
- Plugin manager constructor.