{"id":14960596,"url":"https://github.com/mygamedevtools/fps-counter","last_synced_at":"2026-02-13T21:33:36.606Z","repository":{"id":59271812,"uuid":"536358862","full_name":"mygamedevtools/fps-counter","owner":"mygamedevtools","description":"A lightweight FPS Counter for Games and Apps made with Unity.","archived":false,"fork":false,"pushed_at":"2022-10-25T23:29:23.000Z","size":33,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-07T08:43:41.125Z","etag":null,"topics":["diagnostics","editor","package","stats","tools","unity","unity-editor","unity-package","unity-plugin","unity3d","unity3d-plugin","unityeditor","upm","upm-package"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mygamedevtools.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-09-14T00:44:50.000Z","updated_at":"2025-03-03T05:54:58.000Z","dependencies_parsed_at":"2023-01-20T14:33:10.917Z","dependency_job_id":null,"html_url":"https://github.com/mygamedevtools/fps-counter","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"purl":"pkg:github/mygamedevtools/fps-counter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygamedevtools%2Ffps-counter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygamedevtools%2Ffps-counter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygamedevtools%2Ffps-counter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygamedevtools%2Ffps-counter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mygamedevtools","download_url":"https://codeload.github.com/mygamedevtools/fps-counter/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mygamedevtools%2Ffps-counter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29418531,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-13T06:24:03.484Z","status":"ssl_error","status_checked_at":"2026-02-13T06:23:12.830Z","response_time":78,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["diagnostics","editor","package","stats","tools","unity","unity-editor","unity-package","unity-plugin","unity3d","unity3d-plugin","unityeditor","upm","upm-package"],"created_at":"2024-09-24T13:22:34.885Z","updated_at":"2026-02-13T21:33:36.562Z","avatar_url":"https://github.com/mygamedevtools.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"![License](https://img.shields.io/github/license/mygamedevtools/fps-counter)\n[![openupm](https://img.shields.io/npm/v/com.mygamedevtools.fps-counter?label=openupm\u0026registry_uri=https://package.openupm.com)](https://openupm.com/packages/com.mygamedevtools.fps-counter/)\n![Release](https://img.shields.io/github/v/release/mygamedevtools/fps-counter?sort=semver)\n![Last Commit](https://img.shields.io/github/last-commit/mygamedevtools/fps-counter)\n\nFPS Counter\n===\n\n_A package to measure the average, highest and lowest frames per second in any Unity Application._\n\nInstallation\n---\n\n### OpenUPM\n\nThis package is available on the [OpenUPM](https://openupm.com/packages/com.mygamedevtools.fps-counter) registry. Add the package via the [openupm-cli](https://github.com/openupm/openupm-cli):\n\n```\nopenupm add com.mygamedevtools.fps-counter\n```\n\n### [Installing from Git](https://docs.unity3d.com/Manual/upm-ui-giturl.html) _(requires [Git](https://git-scm.com/) installed and added to the PATH)_\n\n1. Open `Edit/Project Settings/Package Manager`.\n2. Click \u003ckbd\u003e+\u003c/kbd\u003e.\n3. Select `Add package from git URL...`.\n4. Paste `com.mygamedevtools.fps-counter` into name.\n5. Click `Add`.\n\nUsage\n---\n\nAdd the component `FPSCounter` to any `GameObject` by manually dragging the script or via `Add Component/Stats/FPS Counter`. \nThen, add a `FPSDisplay` component to the same `GameObject` the same way you just did with `FPSCounter`.\nNow, you'll need to assign **3** `TextMeshProUGUI` objects in the `FPSDisplay` inspector to serve as output for the **average**, **highest** and **lowest** FPS counts respectively.\n\nYou can also configure the other settings to fit your needs:\n- The `Color Gradient` can alter the label color based on the target FPS where the **leftmost** value is the **closest** FPS value to **0**, \nand the **rightmost** value is the **closest** FPS value to the `Target Framerate`.\n- The `Refresh Rate` controls how often the `FPSDisplay` updates its values.\n- The `Target Framerate` is a guide to the `Color Gradient` property. It will be the reference for the value of 1 in the color gradient.\n- The `Max Tracked Fps` controls what should be the maximum FPS to track.\n\nAdvanced Usage\n---\n\nThe core FPS counter feature lies in the `FPSBuffer`. \nIt needs a `bufferSize` to be provided on creation, and then it will fill this buffer with FPS values to calculate the average, highest and lowest framerates.\nYou need to call `UpdateBuffer` every Unity `Update` to accurately calculate the FPS.\nThe `FPSCounter` component simply creates a `FPSBuffer` object on `Awake` with the provided `Buffer Size` in the inspector, \nand runs `FPSBuffer.UpdateBuffer` on its `Update`. \nYou can use any other structure as an alternative to the `FPSCounter` or even integrate to your existing systems just by using a `FPSBuffer` object.\n\nThe `FPSDisplay` component reads from the `FPSCounter` component directly and outputs the average, highest and lowest fps.\nYou can also create another component to display the values either from the `FPSCounter` or from another system you created that uses a `FPSBuffer` object.\nThe `FPSDisplay` class was created with an array of strings with numbers up to **300**, to avoid string allocation in runtime.\n\n---\n\nDon't hesitate to create [issues](https://github.com/mygamedevtools/fps-counter/issues) for suggestions and bugs. Have fun!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmygamedevtools%2Ffps-counter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmygamedevtools%2Ffps-counter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmygamedevtools%2Ffps-counter/lists"}