UI: Correct Splash RGB Image Corner Rounding #119473

Merged
Harley Acheson merged 2 commits from Harley/blender:SplashCorners into blender-v4.1-release 2024-03-14 17:22:30 +01:00

View File

@ -158,6 +158,7 @@ static ImBuf *wm_block_splash_image(int width, int *r_height)
}
if (ibuf) {
ibuf->planes = 32; /* The image might not have an alpha channel. */
Harley marked this conversation as resolved Outdated

ibuf->channels only applies to the float buffer, it should not be used here.

I think you can just do ibuf->planes = 32; without any checks.

`ibuf->channels` only applies to the float buffer, it should not be used here. I think you can just do `ibuf->planes = 32;` without any checks.
height = (width * ibuf->y) / ibuf->x;
if (width != ibuf->x || height != ibuf->y) {
IMB_scaleImBuf(ibuf, width, height);