mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-22 21:05:58 +01:00
remove unused dimension from buffer calculations
This commit is contained in:
parent
e46ec57b43
commit
84c6dbd58d
2 changed files with 0 additions and 4 deletions
|
@ -61,7 +61,6 @@ struct wlr_texture {
|
||||||
bool valid;
|
bool valid;
|
||||||
uint32_t format;
|
uint32_t format;
|
||||||
int width, height;
|
int width, height;
|
||||||
int height_from_buffer, width_from_buffer;
|
|
||||||
struct wl_signal destroy_signal;
|
struct wl_signal destroy_signal;
|
||||||
struct wl_resource *resource;
|
struct wl_resource *resource;
|
||||||
};
|
};
|
||||||
|
|
|
@ -15,11 +15,8 @@ static void surface_attach(struct wl_client *client,
|
||||||
struct wl_resource *resource,
|
struct wl_resource *resource,
|
||||||
struct wl_resource *buffer, int32_t sx, int32_t sy) {
|
struct wl_resource *buffer, int32_t sx, int32_t sy) {
|
||||||
struct wlr_surface *surface = wl_resource_get_user_data(resource);
|
struct wlr_surface *surface = wl_resource_get_user_data(resource);
|
||||||
int scale = surface->current.scale;
|
|
||||||
surface->pending.invalid |= WLR_SURFACE_INVALID_BUFFER;
|
surface->pending.invalid |= WLR_SURFACE_INVALID_BUFFER;
|
||||||
surface->pending.buffer = buffer;
|
surface->pending.buffer = buffer;
|
||||||
surface->texture->height_from_buffer = surface->texture->height / scale;
|
|
||||||
surface->texture->width_from_buffer = surface->texture->width / scale;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void surface_damage(struct wl_client *client,
|
static void surface_damage(struct wl_client *client,
|
||||||
|
|
Loading…
Reference in a new issue