Skip to content
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

Design Proposal: Add Roll #850

Closed
NathanMOlson opened this issue Oct 10, 2024 · 1 comment
Closed

Design Proposal: Add Roll #850

NathanMOlson opened this issue Oct 10, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@NathanMOlson
Copy link
Contributor

NathanMOlson commented Oct 10, 2024

Design Proposal: Add Roll

Motivation

I would like to be able to roll the camera (rotate it about the camera boresight).
maplibre/maplibre-gl-js#4717
maplibre/maplibre-gl-js#4780

Proposed Change

I would like to add a field roll to the root style spec object. roll sets the camera roll angle in degrees, and joins its friends pitch and bearing.

API Modifications

Root style spec gets a new roll field. jumpTo(), easeTo(), and flyTo() get roll added to their options. Camera gets a setRoll() method.

Migration Plan and Compatibility

This is a pure extension. To achieve existing functionality, just leave roll undefined (default 0).

Rejected Alternatives

I considered adding roll to the API but not to the style spec. Rejected because:

  1. roll is needed in style spec for render tests.
  2. Similar fields pitch and bearing already exist in style spec
@NathanMOlson NathanMOlson changed the title Add Roll Design Proposal: Add Roll Oct 10, 2024
@HarelM HarelM added the enhancement New feature or request label Oct 15, 2024
@HarelM
Copy link
Collaborator

HarelM commented Oct 15, 2024

I think this can be a good addition.
Feel free to push this forward.
Don't forget the diff part of the implementation here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants