diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-01-08 23:38:06 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-08 23:38:06 +0100 |
commit | 32abe36cceacf7221fde09f84e0610c7d4741640 (patch) | |
tree | 6a48950aef7472d1baf57dc50403b20ef12fc1c3 /modules | |
parent | e03714f66c1047024de5adc5b8f42f3edc8abcb9 (diff) | |
parent | c9f5d88f3a152be03450af364075420e10dc1f18 (diff) |
Merge pull request #56617 from AnilBK/use_fill
Use fill() to fill an entire image instead of setting pixels individually.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/lightmapper_rd/lightmapper_rd.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/modules/lightmapper_rd/lightmapper_rd.cpp b/modules/lightmapper_rd/lightmapper_rd.cpp index 5d5b2ed6cb..11715040c2 100644 --- a/modules/lightmapper_rd/lightmapper_rd.cpp +++ b/modules/lightmapper_rd/lightmapper_rd.cpp @@ -775,11 +775,7 @@ LightmapperRD::BakeError LightmapperRD::bake(BakeQuality p_quality, bool p_use_d } else { panorama_tex.instantiate(); panorama_tex->create(8, 8, false, Image::FORMAT_RGBAF); - for (int i = 0; i < 8; i++) { - for (int j = 0; j < 8; j++) { - panorama_tex->set_pixel(i, j, Color(0, 0, 0, 1)); - } - } + panorama_tex->fill(Color(0, 0, 0, 1)); } RD::TextureFormat tfp; |