aboutsummaryrefslogtreecommitdiff
path: root/render/wlr_renderer.c
diff options
context:
space:
mode:
Diffstat (limited to 'render/wlr_renderer.c')
-rw-r--r--render/wlr_renderer.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/render/wlr_renderer.c b/render/wlr_renderer.c
index b8374be9..fc224467 100644
--- a/render/wlr_renderer.c
+++ b/render/wlr_renderer.c
@@ -76,8 +76,12 @@ void wlr_renderer_scissor(struct wlr_renderer *r, struct wlr_box *box) {
bool wlr_render_texture(struct wlr_renderer *r, struct wlr_texture *texture,
const float projection[static 9], int x, int y, float alpha) {
- struct wlr_box box = { .x = x, .y = y };
- wlr_texture_get_size(texture, &box.width, &box.height);
+ struct wlr_box box = {
+ .x = x,
+ .y = y,
+ .width = texture->width,
+ .height = texture->height,
+ };
float matrix[9];
wlr_matrix_project_box(matrix, &box, WL_OUTPUT_TRANSFORM_NORMAL, 0,