mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-26 18:02:14 +00:00
![]() Since the color space is set at the time of specifying the target buffer of the canvas, there is no way to know the color space when the picture is loaded. So, check the color space applied to SwCanvas at the time of reload() and change the color space. There is an issue of BGR color space support for each loader. The external_jpg loader resets the TJPF color space and calls read() to get a new buffer. In the case of external_png, we need to change the color value directly because it have to start over from begin_read_*. This solution can affect performance as much as it access again image buffer that have already been `read()` done. However, this only happens once. |
||
---|---|---|
.. | ||
meson.build | ||
tvgJpgd.cpp | ||
tvgJpgd.h | ||
tvgJpgLoader.cpp | ||
tvgJpgLoader.h |