Skip to content

Allow setting the camera "field of view" #4005

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
hhoppe opened this issue Dec 30, 2022 · 1 comment
Open

Allow setting the camera "field of view" #4005

hhoppe opened this issue Dec 30, 2022 · 1 comment
Labels
feature something new P3 backlog

Comments

@hhoppe
Copy link

hhoppe commented Dec 30, 2022

It doesn't seem possible to set the 3D camera field of view (fov).

(Re: my post to Stackoverflow.)

Looking at the source code, I see that:

In https://github.com/plotly/plotly.js/blob/master/src/plots/gl3d/scene.js, it uses glPlot3d.createScene and sets the options in proto.prepareOptions.

In https://github.com/gl-vis/gl-plot3d/blob/master/scene.js#L179, the allowed options include the field-of-view parameter fovy (field-of-view in the vertical direction), which defaults to Math.PI/4 (45 degrees).

For 3D graphics, a 45-degree vertical field-of-view typically gives an exaggerated perspective. It corresponds to about a 28mm camera lens.

It would be nice for plotly.graph_objects.layout.scene.Camera to include a fovy parameter (in radians).

@AaronStiff AaronStiff added the feature something new label Feb 11, 2023
@hidara2000
Copy link

Is there any way to hack this for the moment? Cheers

@gvwilson gvwilson self-assigned this Jul 11, 2024
@gvwilson gvwilson removed their assignment Aug 2, 2024
@gvwilson gvwilson added the P3 backlog label Aug 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature something new P3 backlog
Projects
None yet
Development

No branches or pull requests

4 participants