Re: Reposition MAME on an HD display?
07/11/17 12:41 PM
> > Sure, you can ask!
> > I play 4:3 games exclusively. And most of those are, technically, 3:4
> > (vertically-oriented) games.
> > 3:4 games on a 16:9 screen leaves a -huge- amount of blank space on the left and
> > right. Accurate bezel artwork wouldn't fill it properly, and I tend to find that
> > stuff a distraction anyway. So I feel like a vertically mounted 43" HD screen will
> > give me the size I want with the minimum amount of wasted (visible) display space.
> I think that's perfectly fair, and thank you for the explanation! I tend to agree,
> since when doing development I don't really have time to go tracking down all the
> various artwork and such. I just didn't want to miss a chance to plug the MAME
> Artwork subforum.
> You can probably use the artwork/bgfx/border_blur/default.lay file as reference, as
> it's a layout I came up with for this one shader. Some background:
> .lay files are essentially XML files which define the layout of MAME's output
> relative to the dimensions of the host screen, in units of your choosing.
> In the most basic sense, they consist of one or more "view" tags, which then contain
> one or more "screen" tags, which then have a "bounds" tag which defines the borders
> of that emulated screen's output.
> In the case of the specific .lay file that I mentioned, I use it to fill out the
> blank border space when showing a 4:3 game on an un-rotated 16:9 screen (the
> "Horizontal" view), or when showing a 3:4 game on an un-rotated 16:9 screen (the
> "Vertical" view), then at runtime, there's a shader which applies a
> desaturate/zoom/blur filter to the left and right strips on either side of the main
> screen. The idea is that combined with the shader, you get the sort of effect that
> you often see on YouTube or news broadcasts when they want to display a vertical
> video without having a bunch of blank space on either side of it.
> As you can see based on the differences between the Horizontal and Vertical bounds
> tags, the units really are arbitrary, they just need to ultimately divide down to
> match the aspect ratio of the output screen. That's obvious in the Horizontal view,
> and in the Vertical view, the overall bounds of 64:36 divides by 4 to give 16:9 as
> Supposing I wanted to simply left-justify the Vertical view on an un-rotated 16:9
> screen and not duplicate it on either side, I would simply have one "screen" tag, and
> its bounds would be 0, 0, 27, 36 for left, top, right, and bottom. Or, if you wanted
> to divide out the common factor (9), you would go with 0, 0, 3, 4, which shows more
> clearly that the source screen has an aspect ratio of 3:4 (i.e. a vertical game).
> Hopefully this should be enough information to help get you going in the right
> direction. Cheers!
Just to fill this out a bit, you'll need an explicit bounds tag for the view if you want to produce blank space, otherwise MAME will just centre the entire view on the screen. To get views left-justified on a 16:9 display you might do something like this:
<bounds left="0" top="0" right="16" bottom="9" />
<bounds left="0" top="0" right="12" bottom="9" />
<bounds left="0" top="0" right="65" bottom="36" />
<bounds left="0" top="0" right="27" bottom="36" />