Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - tsaylor

Pages: [1]
1
For my arcade cabinet, the theme "At-The-Arcade Multi-Cab" was nearly perfect! But then I ruined everything by getting into pinball games -- a problem because I turned my monitor vertical, but also because I needed to display pinball tables as well. With that, I undertook a months long project of learning how to write Attract-Mode layouts and shaders, and modified At-The-Arcade Multi-Cab to become: At-The-Arcade Flex! A flexible version of the original, supporting (in theory) every resolution and aspect ratio, and also adding support for the display of pinball cabinets.

First, a note of thanks! This layout is definitely standing on the shoulders of giants as they say, and it would not exist without the excellent work of:
Features added with this layout:
  • Render at "any" resolution or aspect ratio (tested at the most common aspect ratios 16:9, 16:10, 4:3, 1:1, 3:4, 10:16, 10:9)
  • Hotkey to cycle through various resolutions (useful for testing or simulating other screen sizes)
  • Change most everything to rely on formulas and a table of positioning rules, instead of hard-coded numbers/percentages
  • Add support for displaying pinball cabinet/snapshot/marquee images (in addition to the existing MAME arcade cabinet support)
  • Allow cabinet to be horizontally "squeezed" up to a point, to make things fit better
  • Beyond that point, resize the cabinet smaller (resulting in a mix of some squeezing and some shrinking, for portrait resolutions)
  • Synthesize a cabinet "top" for resolutions where the cabinet is not full-height (necessary because the cabinet images do not include a top)
  • "Wheel" logic is formula-based, using shaders for the wheel background
  • Color choice for wheel background
  • Rework bezel rendering to show entire side bezels (with some compression)
  • Don't show scanlines for vector-based titles, or over bezels
  • For portrait screens, extend game information to two lines
  • Box art location depends on screen aspect (portrait vs landscape)

Demo:
https://www.youtube.com/watch?v=8IdFfWR30RI

Download the theme (updated to v1.1 Dec-29-2021):
https://mega.nz/file/fkgHyAYZ#-6I4-cUdBert9jcnAStAwIbWHq1SM_oaSB3SMtFsp_I
For install instructions, please see the ReadMe.txt file in the download zip (thanks again to Yaron2019)

Download the updated cabs:
https://mega.nz/file/rA833QiL#dqhQFfdh608n1pAdJdNnngajGSFI1NktuBkc37bJzMw

If needed, download other art from Damonxxx's original post:
http://forum.attractmode.org/index.php?topic=3778.0

Download fanart (optional):
https://mega.nz/file/gQlkBKia#Hz87o3SeV2I8GmR52aFCF-etVmJO-kjPWEt1VzBbVk0

Download bezels (optional):
https://github.com/thebezelproject/bezelproject-MAME

Change log (changes now maintained at https://github.com/toddsay/AtTheArcadeFlex):
1.0 Initial release
1.1 Fix potential crashes, auto-rotate horizontal snap videos for non-FX3 pinball tables

Examples shown below for:
  • Landscape/widescreen MAME
  • Portrait MAME
  • Landscape/widescreen Pinball
  • Portrait Pinball

2
Scripting / Trying to understand position within a shader
« on: April 02, 2021, 10:39:45 AM »
I'm experimenting with writing my first shader, but I'm having a hard time using gl_FragCoord to determine the position within the image. Does anyone here have experience with this? I can set gl_FragColor and see results, but what I can't seem to do is pass values into the shader (say a position and a size), and then use those values relative to the current coordinate in gl_FragCoord. Basically I'm trying to color a specified set of pixels within the image, where those locations are provided by an AM layout. Is there a secret I'm missing? I can get the desired results in an online tool such as thebookofshaders.com, but using the same code (I think) in a shader called by AM does not give the same results. I suspect the difference lies in how the coordinates are used, but I don't know of any direct way to "debug" the shader and show those internal values at run time.

I can put together a test example if needed, but I was hoping someone here knows something about conversion between a "standard" GLSL fragment shader and an AM compatible shader. In case it matters, the object I'm assigning the shader to is a surface.

Pages: [1]