mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2026-02-10 04:27:51 -05:00
scene: use fractional positions
Signed-off-by: Loukas Agorgianitis <loukas@agorgianitis.com>
This commit is contained in:
parent
1f0fb95e3b
commit
8a54671d2c
4 changed files with 35 additions and 35 deletions
|
|
@ -50,7 +50,7 @@ typedef bool (*wlr_scene_buffer_point_accepts_input_func_t)(
|
|||
struct wlr_scene_buffer *buffer, double *sx, double *sy);
|
||||
|
||||
typedef void (*wlr_scene_buffer_iterator_func_t)(
|
||||
struct wlr_scene_buffer *buffer, int sx, int sy, void *user_data);
|
||||
struct wlr_scene_buffer *buffer, double sx, double sy, void *user_data);
|
||||
|
||||
enum wlr_scene_node_type {
|
||||
WLR_SCENE_NODE_TREE,
|
||||
|
|
@ -66,7 +66,7 @@ struct wlr_scene_node {
|
|||
struct wl_list link; // wlr_scene_tree.children
|
||||
|
||||
bool enabled;
|
||||
int x, y; // relative to parent
|
||||
double x, y; // relative to parent
|
||||
|
||||
struct {
|
||||
struct wl_signal destroy;
|
||||
|
|
@ -230,7 +230,7 @@ struct wlr_scene_output {
|
|||
|
||||
struct wlr_damage_ring damage_ring;
|
||||
|
||||
int x, y;
|
||||
double x, y;
|
||||
|
||||
struct {
|
||||
struct wl_signal destroy;
|
||||
|
|
@ -301,7 +301,7 @@ void wlr_scene_node_set_enabled(struct wlr_scene_node *node, bool enabled);
|
|||
/**
|
||||
* Set the position of the node relative to its parent.
|
||||
*/
|
||||
void wlr_scene_node_set_position(struct wlr_scene_node *node, int x, int y);
|
||||
void wlr_scene_node_set_position(struct wlr_scene_node *node, double x, double y);
|
||||
/**
|
||||
* Move the node right above the specified sibling.
|
||||
* Asserts that node and sibling are distinct and share the same parent.
|
||||
|
|
@ -332,7 +332,7 @@ void wlr_scene_node_reparent(struct wlr_scene_node *node,
|
|||
*
|
||||
* True is returned if the node and all of its ancestors are enabled.
|
||||
*/
|
||||
bool wlr_scene_node_coords(struct wlr_scene_node *node, int *lx, int *ly);
|
||||
bool wlr_scene_node_coords(struct wlr_scene_node *node, double *lx, double *ly);
|
||||
/**
|
||||
* Call `iterator` on each buffer in the scene-graph, with the buffer's
|
||||
* position in layout coordinates. The function is called from root to leaves
|
||||
|
|
@ -591,7 +591,7 @@ void wlr_scene_output_destroy(struct wlr_scene_output *scene_output);
|
|||
* Set the output's position in the scene-graph.
|
||||
*/
|
||||
void wlr_scene_output_set_position(struct wlr_scene_output *scene_output,
|
||||
int lx, int ly);
|
||||
double lx, double ly);
|
||||
|
||||
struct wlr_scene_output_state_options {
|
||||
struct wlr_scene_timer *timer;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue