LibGfx: Allow passing an ideal size to image decoders

The ideal size is the size the user will display the image. Raster
formats should ignore this parameter, but vector formats can use
it to generate a bitmap of the ideal size.
This commit is contained in:
MacDue 2023-07-02 22:20:06 +01:00 committed by Jelle Raaijmakers
commit e7cddda7e1
Notes: sideshowbarker 2024-07-17 04:09:56 +09:00
20 changed files with 22 additions and 22 deletions

View file

@ -264,7 +264,7 @@ size_t TGAImageDecoderPlugin::first_animated_frame_index()
return 0;
}
ErrorOr<ImageFrameDescriptor> TGAImageDecoderPlugin::frame(size_t index)
ErrorOr<ImageFrameDescriptor> TGAImageDecoderPlugin::frame(size_t index, Optional<IntSize>)
{
auto bits_per_pixel = m_context->header.bits_per_pixel;
auto color_map = m_context->header.color_map_type;