mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-12-30 22:54:35 +03:00
LibGfx: Plumb the TGALoader into ImageDecoder :^)
This patch plumbs the TGALoader into ImageDecoder so TGA images can be decoded by the system
This commit is contained in:
parent
21db070887
commit
5bce58cd3e
Notes:
sideshowbarker
2024-07-17 07:48:42 +09:00
Author: https://github.com/06needhamt Commit: https://github.com/SerenityOS/serenity/commit/5bce58cd3e Pull-request: https://github.com/SerenityOS/serenity/pull/16574 Reviewed-by: https://github.com/ADKaster Reviewed-by: https://github.com/Hendiadyoin1 Reviewed-by: https://github.com/gmta ✅ Reviewed-by: https://github.com/supercomputer7
@ -15,6 +15,7 @@
|
||||
#include <LibGfx/PNGLoader.h>
|
||||
#include <LibGfx/PPMLoader.h>
|
||||
#include <LibGfx/QOILoader.h>
|
||||
#include <LibGfx/TGALoader.h>
|
||||
|
||||
namespace Gfx {
|
||||
|
||||
@ -66,6 +67,10 @@ RefPtr<ImageDecoder> ImageDecoder::try_create(ReadonlyBytes bytes)
|
||||
if (plugin->sniff())
|
||||
return plugin;
|
||||
|
||||
plugin = make<TGAImageDecoderPlugin>(data, size);
|
||||
if (plugin->sniff())
|
||||
return plugin;
|
||||
|
||||
return {};
|
||||
}(data, size);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user