Skip to content

html-custom-camera-support #2472

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

calcifer-3118
Copy link

@calcifer-3118 calcifer-3118 commented Jun 24, 2025

feat(Html): support rendering Html with a specified custom camera

Why

Currently, the <Html /> component always renders using the active camera from the R3F context (useThree().camera). In multi-camera setups, this causes HTML overlays to shift or misalign when the active camera changes.

This PR adds support for a camera prop, allowing developers to lock <Html /> rendering to a specific camera — improving control and reliability in HUDs, fixed screens, and persistent overlays.

What

  • Adds a camera prop to <Html />
  • Defaults to the current active R3F camera (useThree().camera) if not provided (non-breaking)
  • Enables stable Html rendering in multi-camera scenes
  • Fully backward compatible

Checklist

  • Ready to be merged
  • Documentation updated (example)

feat(Html): support rendering Html with a specified custom camera
Copy link

vercel bot commented Jun 24, 2025

@calcifer-3118 is attempting to deploy a commit to the Poimandres Team on Vercel.

A member of the Team first needs to authorize it.

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.

1 participant