openframeworks / openframeworks/openFrameworks

iOS Orientation - Physical vs Screen content orientation

Open
#6,965 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

iOS
Dominant language
C++
Stars
10.4k
Forks
2.6k
Avg merge
1d 21h
Merged PRs (30d)
9

Description

There is some issues related to iOS orientation, physical vs. screen
I've seen in different issues, some I've experienced and now begining to understand better.

There is the fact that if you want to keep the content in the upright position, when screen is rotated physically to the left, you want to rotate content to the right.

other confusions arise from the lack of separation between physical orientation and screen orientation.
so some functions are not very clear, like ofGetOrientation

And finally the fact the auto rotation is broken (I've opened this issue in 2018). I can fix this one with a PR

I think this can be fixed with one PR in ofAppiOSWindow.mm (line 232 - 235)
Maybe another in ofAppGLFWWindow if needed (returning { x, y } or { y, x } when rotated)

And maybe better documentation, example or even a function to get physical orientation.

Other related issues:

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading ofAppiOSWindow.mm around lines 232–235 and review the linked orientation issues, especially 6076, 5612, and 4508. Check whether ofAppGLFWWindow is also involved, as suggested by the issue. Done should address the reported iOS auto-rotation problem and clearly distinguish physical orientation from screen orientation, with documentation or an example if needed.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp, ios
Domain
mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.