Skip to content

Introducing Framecounter for measuring FPS#799

Merged
jfboeve merged 13 commits into
mainfrom
feat/framecounter
Jul 15, 2026
Merged

Introducing Framecounter for measuring FPS#799
jfboeve merged 13 commits into
mainfrom
feat/framecounter

Conversation

@jfboeve

@jfboeve jfboeve commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

@jfboeve jfboeve marked this pull request as draft June 4, 2026 09:25

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new FPS “frame counter” utility and extends the fpsUpdate event payload to include bucketed frame-time counts, configurable via a new fpsBoundaries runtime setting.

Changes:

  • Introduces src/core/lib/fps.ts to track FPS and bucket frame delta times.
  • Wires Stage FPS tracking to the new frame counter and adds runtime update hooks for interval/boundaries.
  • Extends shared FpsUpdatePayload to include frameCount and plumbs fpsBoundaries through renderer settings.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 8 comments.

File Description
src/main-api/Renderer.ts Adds fpsBoundaries setting and propagates runtime updates to Stage.
src/core/Stage.ts Replaces legacy FPS aggregation with the new frame-counter-based approach and adds update methods.
src/core/lib/fps.ts New FPS/frame bucketing utility used by Stage.
src/common/CommonTypes.ts Extends FpsUpdatePayload with frameCount typing.

Comment thread src/core/Stage.ts
Comment thread src/core/Stage.ts Outdated
Comment thread src/core/Stage.ts
Comment thread src/core/lib/fps.ts
Comment thread src/core/lib/fps.ts
Comment thread src/core/lib/fps.ts
Comment thread src/core/lib/fps.ts Outdated
Comment thread src/common/CommonTypes.ts
@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ jfboeve
❌ Copilot
You have signed the CLA already but the status is still pending? Let us recheck it.

@jfboeve jfboeve requested a review from Copilot July 1, 2026 13:20
@jfboeve jfboeve marked this pull request as ready for review July 1, 2026 13:21

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 7 comments.

Comment thread src/core/Stage.ts
Comment thread src/core/Stage.ts
Comment thread src/core/Stage.ts
Comment thread src/core/lib/fps.ts
Comment thread src/core/lib/fps.ts
Comment thread src/main-api/Renderer.ts Outdated
Comment thread src/core/Stage.ts
jfboeve and others added 5 commits July 1, 2026 15:38
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@jfboeve jfboeve requested a review from wouterlucas July 8, 2026 07:31

@michielvandergeest michielvandergeest left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jfboeve jfboeve merged commit 0c2b88a into main Jul 15, 2026
1 of 2 checks passed
@jfboeve jfboeve deleted the feat/framecounter branch July 15, 2026 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants