Skip to content

winit: Add support for timer based frame throttling #8826

Closed
@tronical

Description

@tronical

Bug Description

Issues like #8823 suggest that despite platform specific frame throttling methods (which we also need , #5050, or #4025 and already have with wayland), we need first and foremost a time based fallback to avoid that animations triggering continuous repaint starve the event loop.

In the absence of windowing-system native solutions, a request to redraw needs to be throttled to the refresh rate of the monitor reported by winit.

Reproducible Code (if applicable)

See #8823 or just run the gallery and watch CPU usage.

Environment Details

1.12 with winit backend

Product Impact

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions