uxn

Varvara Ordinator, written in ANSI C(SDL2)
git clone https://git.eamoncaddigan.net/uxn.git
Log | Files | Refs | README | LICENSE

commit c84b5015e4c8b22173317cfc20e1b5ced202bd09
parent c70f16f7ac2611339b51ffdfe0aaf655d368899e
Author: neauoire <aliceffekt@gmail.com>
Date:   Sat, 28 Aug 2021 13:44:53 -0700

Repaired zoom

Diffstat:
Msrc/uxnemu.c | 9++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/src/uxnemu.c b/src/uxnemu.c @@ -112,7 +112,14 @@ redraw(Uxn *u) { if(devsystem->dat[0xe]) inspect(&ppu, u->wst.dat, u->wst.ptr, u->rst.ptr, u->ram.dat); - SDL_BlitSurface(idxSurface, NULL, winSurface, &gRect); + if(rgbaSurface == NULL) + SDL_BlitScaled(idxSurface, NULL, winSurface, &gRect); + else if(zoom == 1) + SDL_BlitSurface(idxSurface, NULL, winSurface, &gRect); + else { + SDL_BlitSurface(idxSurface, NULL, rgbaSurface, NULL); + SDL_BlitScaled(rgbaSurface, NULL, winSurface, &gRect); + } SDL_UpdateWindowSurface(gWindow); reqdraw = 0; }