From 201af99d9fd26bae939ad7f2395920476f78d7f1 Mon Sep 17 00:00:00 2001 From: Sean Barrett Date: Sat, 2 Apr 2016 03:49:46 -0700 Subject: [PATCH] return correct # of channels for PNG --- stb_image.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stb_image.h b/stb_image.h index af663cf..4f2f4b7 100644 --- a/stb_image.h +++ b/stb_image.h @@ -4606,7 +4606,7 @@ static unsigned char *stbi__do_png(stbi__png *p, int *x, int *y, int *n, int req } *x = p->s->img_x; *y = p->s->img_y; - if (n) *n = p->s->img_out_n; + if (n) *n = p->s->img_n; } STBI_FREE(p->out); p->out = NULL; STBI_FREE(p->expanded); p->expanded = NULL;