Skip to main content

SFPS - Smooth FPS.

Project description

Test PyPI Build Publish on PyPI

SFPS - Smooth FPS

SFPS is a small and very efficient Python library which helps calculate the real-time computing frame rate with a few lines of code.

You can install from PyPI:

pip install sfps

You can import and initialize SFPS in your Python code:

from sfps import SFPS
sfps = SFPS(nframes=8, interval=1)
  • nframes (int, default=5) : Number of the last frames, used for averaging.
  • interval (int, default=1) : Time interval in second.

And then you can call fps() or raw_fps() to calculate the real-time frame rate.

...
fps = sfps.fps(format_spec='.2f')
...

For usage details, please check SFPS. You can also check an example here.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sfps-0.0.0.tar.gz (3.7 kB view hashes)

Uploaded Source

Built Distribution

sfps-0.0.0-py3-none-any.whl (3.7 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page