opt: optimize frame skip judge

This commit is contained in:
DreamMaoMao
2025-11-06 11:28:21 +08:00
parent 539fd233da
commit 12ab7d63ec

View File

@@ -4120,9 +4120,9 @@ void rendermon(struct wl_listener *listener, void *data) {
// 绘制客户端 // 绘制客户端
wl_list_for_each(c, &clients, link) { wl_list_for_each(c, &clients, link) {
need_more_frames = client_draw_frame(c) || need_more_frames; need_more_frames = client_draw_frame(c) || need_more_frames;
if (!animations && !allow_tearing && c->configure_serial && if (!animations && !(allow_tearing && frame_allow_tearing) &&
!c->isfloating && client_is_rendered_on_mon(c, m) && c->configure_serial && !c->isfloating &&
!client_is_stopped(c)) { client_is_rendered_on_mon(c, m) && !client_is_stopped(c)) {
goto skip; goto skip;
} }
} }