io_dec,CustomSetup: rm unnecessary 'is_alpha' check

`WebPIoInitFromOptions()` doesn't distinguish between `MODE_YUV` and
`MODE_YUVA`, only RGB vs YUV. Removing this check also removes a
confusing mix up between `MODE_YUV` and `MODE_YUVA` in the conditional.

Change-Id: Id46b21785433aded733ad914941398b0bd5d6b8f
This commit is contained in:
James Zern
2025-11-11 16:18:13 -08:00
parent 2760d87827
commit 05934f93b9

View File

@@ -574,7 +574,9 @@ static int CustomSetup(VP8Io* io) {
p->emit = NULL;
p->emit_alpha = NULL;
p->emit_alpha_row = NULL;
if (!WebPIoInitFromOptions(p->options, io, is_alpha ? MODE_YUV : MODE_YUVA)) {
// Note: WebPIoInitFromOptions() does not distinguish between MODE_YUV and
// MODE_YUVA, only RGB vs YUV.
if (!WebPIoInitFromOptions(p->options, io, /*src_colorspace=*/MODE_YUV)) {
return 0;
}
if (is_alpha && WebPIsPremultipliedMode(colorspace)) {