Project

General

Profile

Actions

Action Item #441

open

Add display rotatation/flip

Added by Hammel over 9 years ago. Updated over 1 year ago.

Status:
In Progress
Priority:
High
Assignee:
Category:
-
Target version:
Start date:
20 Jul 2020
Due date:
% Done:

0%

Estimated time:
(Total: 0.00 h)
Severity:
02 - High

Description

If the projector is upside down or displaying behind a screen the user may need to rotate and flip it.

This is a setting in config.txt. From eLinux.org:

display_rotate rotates the display clockwise on the screen (default=0) or flips the display.

display_rotate=0 Normal
display_rotate=1 90 degrees
display_rotate=2 180 degrees
display_rotate=3 270 degrees
display_rotate=0x10000 horizontal flip
display_rotate=0x20000 vertical flip

Note: the 90 and 270 degrees rotation options require additional memory on GPU, so won't work with the 16M GPU split. Probably the reason for:

So it looks like the first two bits are rotate and bit 16/17 are flip. It's unclear if you can do both rotate and flip at the same time.

This needs to be added to launcher as two keyboard sequences:
  1. Ctrl-r: rotate 180 degrees
  2. Ctrl-f: flip

Launcher needs to read the config file, parse this setting (it should always be hex) and then write out the updated value. Rotate toggles between 0 and 2 and flip toggles between 0 and 1. The default config.txt in the rpi tree (scripts/config.txt) needs to be modified to have the NORMAL setting enabled (re: not commented out). That's the line that Launcher will modify.

These changes require a reboot. Just using xrandr won't work because that doesn't affect omxplayer. omxplayer does have an --orientation option but this doesn't include flip, which would be needed to display from behind the screen.


Subtasks 1 (1 open0 closed)

PiBox - Feature #781: Add UI for system configurationNewHammel20 Jul 2020

Actions
Actions

Also available in: Atom PDF