PersistentInsistence
Posts: 2
Joined: Fri Apr 30, 2021 4:12 pm

Screen Orientation Flags

Hi Guys,

Does MAME have flags to indicate which way round the output video is displayed?

This isn't too bad for landscape games, but with portrait games I need to have a value to tell me if it's L>R or R>L.

Failing that, is there a way for all portrait games to be displayed in one direction only, or would they all need to be individually set?

TIA
User avatar
Tafoid
Posts: 351
Joined: Thu Nov 06, 2014 12:50 pm
Location: USA
Contact: Website

Re: Screen Orientation Flags

PersistentInsistence wrote: Fri Apr 30, 2021 8:23 pm Hi Guys,

Does MAME have flags to indicate which way round the output video is displayed?

This isn't too bad for landscape games, but with portrait games I need to have a value to tell me if it's L>R or R>L.

Failing that, is there a way for all portrait games to be displayed in one direction only, or would they all need to be individually set?

TIA

You can determine the original orientation from extracting the information from the -listxml output. In particular, the <display tag= line.
In that line the important setting is rotate= degrees value which MAME has to rotate the image to show it on screen. Most horizontal screens will show 0 and some require 180 (flipped). Vertical screens show either "90" (rotated right) or "270" (rotated left).
You can use the .ini commands rol, ror, autorol, autoror to have the orientation changed.

You should be able to divine enough information from that to do what you want.
PersistentInsistence
Posts: 2
Joined: Fri Apr 30, 2021 4:12 pm

Re: Screen Orientation Flags

Thanks for the reply.

Does the orientation affect the UI as well; if I flip from l>r to r>l will the UI change its orientation as well?

Essentially I need to get MAME to send that data to some external hardware and perform an action depending on the video output orientation. I know it's doable but have no idea where to start software wise.
User avatar
Tafoid
Posts: 351
Joined: Thu Nov 06, 2014 12:50 pm
Location: USA
Contact: Website

Re: Screen Orientation Flags

PersistentInsistence wrote: Mon May 03, 2021 8:48 am Thanks for the reply.

Does the orientation affect the UI as well; if I flip from l>r to r>l will the UI change its orientation as well?

Essentially I need to get MAME to send that data to some external hardware and perform an action depending on the video output orientation. I know it's doable but have no idea where to start software wise.

No idea. Can't really help there. I can only inform you what you can get from the internal meta data and you'll have to take it from there.
Using -ROR or -ROL at command line, even when launching a game does present the internal UI also in the rotated position.

Example: mappy
Attachments
&quot;mame mappy -ror&quot; output
"mame mappy -ror" output
mame_mappy_ror.png (482.41 KiB) Viewed 17938 times

Return to “MAME Discussion”