-
-
Notifications
You must be signed in to change notification settings - Fork 897
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
implent xcursor manager #7178
implent xcursor manager #7178
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
additionally the filename should be XCursorManager and not SXCursorManager
want the class to named XCursorManager too? |
file: XCursorManager |
8de3d59
to
d72a3ce
Compare
@vaxerski hmm got any clues?
|
also you seen #7162? |
re: asan, buffer is still there while you freed the pixels |
think i figured it out with setting current cursor after the buffer been dropped instead of before. but cursor:no_hardware_cursors = true still causes some corruption that isnt seen with it set to false. seems to occur on main too tho #7173 also gotta get some hyprcursor theme installed and fiddle around so there isnt some other edgy pointers trying to jump into mordor. but thats for tomorrow |
lmk when it's ready for review then |
i have tried bisecting no_hardware_cursors = true , up until 016da23 after that i gave up. either the bug is inside aquamarine as of recent or it has always been there. the bug im seeing is im having two pointer shapes showing at all times. one is permanent and one is changing accordingly. otherwise im not hitting any edgy pointers in my limited testing. maybe related to the spam of "[WARN] [AQ] Output WAYLAND-1: pending state has a non-released buffer??" that increases in frequency when no_hardware_cursors = true is set. |
wayland log thing is whatever |
i just noticed, since i have hw cursors on main and software on nested session the actual cursor that is showing overlayed is the one from the main session heh |
almost like the hwcursor buffer/surface is being empty and rendered "invisible" with chance of corruption because of uninitialized data? and because im nesting it it gets the data from the main session. if any of that makes any sorts of sense lol |
can't repro, running this branch with asan no probs |
cursor.mp4 |
I dont get it, whats wrong? duplicated cursors because no hw |
if nested has no_hardware_cursors = true, the main cursor shows at all time ontop of the nested session. never hides in timeout. and is stuck from the last shape of the main session. so either main session isnt hiding it or the nested session is double rendering something |
ye thats an aq bug that doesnt really matter |
okay :) then i got no other objections. <3 |
implent XCursorManager and load themes based on librarypath and its dir, now we catch all supplied theme files. and also implent animated cursors. also refactor a bit of spaghetti regarding xcursors in CursorManager.
animated cursors are creating a new buffer for each image, ensure we drop the buffers so it continously doesnt build up in infinity.
use EvenloopManager for timers instead of adding it directly to m_sWLEventLoop and using its related wl_* functions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so the bootleg xcursor has been redone into its own manager now fully supporting animated cursors and also library loading files directly instead of only the xcursor standard names, some themes supply shapes outside the standard names for wayland etc so this makes it miss even less shapes.
also while adding animated xcursors i noticed buffers where never dropped in tickAnimatedCursor for hyprcursor, ensure they are dropped aswell. this bit i have not tested since i dont use hyprcursor.
the xcursor manager still lacks support for inherited themes using index.theme files and the "default" xcursor theme is not working either but isnt on main branch either. that can be figured out in the future.
thought id start here make a PR and work out issues/comments/ideas and then spend time on fixing up the last missing bits.
this could use some testing in swapping between hyprcursor/xcursor using hyprctl and env vars so i havent missed some edgecase
Fixes: #7162
Probably fixes: #6983
Waiting for info: #7173