mirror of
https://github.com/thorvg/thorvg.git
synced 2025-06-08 05:33:36 +00:00
loaders: explicit variable scope to improve portability
issue: https://github.com/godotengine/godot/pull/105093
This commit is contained in:
parent
06103ed355
commit
8c4f3e7eec
3 changed files with 3 additions and 3 deletions
|
@ -130,7 +130,7 @@ bool JpgLoader::read()
|
|||
|
||||
//determine the image format
|
||||
TJPF format;
|
||||
if (cs == ColorSpace::ARGB8888 || cs == ColorSpace::ARGB8888S) {
|
||||
if (ImageLoader::cs == ColorSpace::ARGB8888 || ImageLoader::cs == ColorSpace::ARGB8888S) {
|
||||
format = TJPF_BGRX;
|
||||
surface.cs = ColorSpace::ARGB8888;
|
||||
} else {
|
||||
|
|
|
@ -87,7 +87,7 @@ bool PngLoader::read()
|
|||
|
||||
if (w == 0 || h == 0) return false;
|
||||
|
||||
if (cs == ColorSpace::ARGB8888 || cs == ColorSpace::ARGB8888S) {
|
||||
if (ImageLoader::cs == ColorSpace::ARGB8888 || ImageLoader::cs == ColorSpace::ARGB8888S) {
|
||||
image->format = PNG_FORMAT_BGRA;
|
||||
surface.cs = ColorSpace::ARGB8888S;
|
||||
} else {
|
||||
|
|
|
@ -138,7 +138,7 @@ bool WebpLoader::read()
|
|||
|
||||
if (!data || w == 0 || h == 0) return false;
|
||||
|
||||
surface.cs = this->cs;
|
||||
surface.cs = ImageLoader::cs;
|
||||
|
||||
TaskScheduler::request(this);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue