diff options
author | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-10-06 18:35:33 +0300 |
---|---|---|
committer | Jaakko Keränen <jaakko.keranen@iki.fi> | 2021-10-06 18:35:33 +0300 |
commit | 35650b13e506f0df1a03b66747b9e1514640a2cc (patch) | |
tree | 06e39fa4113495a567d2e604ec1d523964aa38db | |
parent | ea8e703458f801075151b30d001d78ce3ba71ae2 (diff) |
Media: Print error message from stb_image
-rw-r--r-- | src/media.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/media.c b/src/media.c index 636cd91f..26f0af4b 100644 --- a/src/media.c +++ b/src/media.c | |||
@@ -144,6 +144,9 @@ void makeTexture_GmImage(iGmImage *d) { | |||
144 | else { | 144 | else { |
145 | imgData = stbi_load_from_memory( | 145 | imgData = stbi_load_from_memory( |
146 | constData_Block(data), size_Block(data), &d->size.x, &d->size.y, NULL, 4); | 146 | constData_Block(data), size_Block(data), &d->size.x, &d->size.y, NULL, 4); |
147 | if (!imgData) { | ||
148 | fprintf(stderr, "[media] image load failed: %s\n", stbi_failure_reason()); | ||
149 | } | ||
147 | } | 150 | } |
148 | if (!imgData) { | 151 | if (!imgData) { |
149 | d->size = zero_I2(); | 152 | d->size = zero_I2(); |