Skip to main content

frametimer

An accurate clock/timer that can be used to help obtain constant framerates. It uses a hybrid approach of sleeping for most of the required duration, then spin-waiting for the rest.

Installation

pip install frametimer

(Or just grab the .py file, it's a simple module)

Usage

timer = frametimer.FrameTimer(60)

while run_main_loop:
	dt = timer.tick()

	update(dt)
	...

Metadata

Release files for frametimer 2.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for frametimer 2.0.0
File Size Uploaded Provenance Actions
frametimer-2.0.0.tar.gz 3.5 kB Without provenance Details for frametimer-2.0.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for frametimer 2.0.0
File Interpreter ABI Platform Actions
frametimer-2.0.0-py3-none-any.whl Python 3 none any Details for frametimer-2.0.0-py3-none-any.whl

Total release size: 7.3 kB

Release files / frametimer-2.0.0.tar.gz

Download URL frametimer-2.0.0.tar.gz
Size 3.5 kB
Tags Source
SHA-256 checksum
How to use checksums
5a9285923cd4c5f7bc7f8f55ba7987f737035326dc3082f57a46d439868927e6
BLAKE2b-256 checksum
How to use checksums
968baf9596b1751a6f211a438fd602f7766f39fd15cdd38c3b9e1d41eac51eb9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Release files / frametimer-2.0.0-py3-none-any.whl

Download URL frametimer-2.0.0-py3-none-any.whl
Size 3.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0341ba3e174bdcd996c7368272fffd329a0102aaa383078df9d2edb53cadf2a3
BLAKE2b-256 checksum
How to use checksums
424302fb8596a3b28eb8033da2cdf7afc5f627cf1227b59626227f3e8418af7f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.3

Security for frametimer 2.0.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page