diff options
author | Simon Ser <contact@emersion.fr> | 2021-05-17 12:09:37 +0200 |
---|---|---|
committer | Simon Zeni <simon@bl4ckb0ne.ca> | 2021-05-19 11:13:42 -0400 |
commit | beae3018cbbbbb566e964de63cf04e405b7d8ba5 (patch) | |
tree | a20469026854552cb220c2c61304663c80e03ff6 /render | |
parent | f73c04b8019522e445a19a5b5760faacfa91c0f0 (diff) |
render: relax stride check in wlr_texture_from_pixels
Some formats have a byte-per-pixel lower than 1. Let's not encode
an arbitrary limitation into the wlr_renderer API.
Diffstat (limited to 'render')
-rw-r--r-- | render/wlr_texture.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/render/wlr_texture.c b/render/wlr_texture.c index e9bda215..b2acfcb4 100644 --- a/render/wlr_texture.c +++ b/render/wlr_texture.c @@ -25,7 +25,7 @@ struct wlr_texture *wlr_texture_from_pixels(struct wlr_renderer *renderer, const void *data) { assert(width > 0); assert(height > 0); - assert(stride >= width); + assert(stride > 0); assert(data); return renderer->impl->texture_from_pixels(renderer, fmt, stride, width, height, data); |