dirkwhoffmann / vAmiga

vAmiga is a user-friendly Amiga 500, 1000, 2000 emulator for macOS

Home Page:https://dirkwhoffmann.github.io/vAmiga

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Feature request: "Zoom to 1:1 scale" menu item

gklka opened this issue · comments

It would be great to have a menu item, which resizes vAmiga's window to have a nice 1:1 pixel rendering.

I've added a new item Restore to the Window menu which restores the window size to the original window size of 800 x 600. However, this is no guarantee for a 1:1 pixel rendering. This is because the texture cutout is not fixed (it varies based on the zoom factor which can be chosen freely by the user). To achieve a 1:1 pixel rendering, I would need to know the exact amount of pixels that are drawn by the GPU. But even if this number could be determined reliably, we would have to decide if we want to have a 1:1 mapping on the x-axis or on the y-axis. To achieve both, the pixel aspect ratio had to be changed which I'd like to avoid.

Just thought about it in more detail. Having a 1:1 mapping on the y-axis is indeed a desirable feature as it would turn the "Embedded scanline" feature into a useful one (embedded scanlines means the scanlines are created by darkening some lines in the texture). Right now, embedded scanlines cause Moiré effect all over the place. I just hacked together some code to determine the exact number of drawn texture lines which seems to work in most cases (the difficulty is to avoid out-by-one errors caused by rounding effects). An Auto Resize feature which resizes the emulator window accordingly could be added to the Window menu.

Option will be available in next release