How to do pixel-perfect rendering in löve?

General discussion about LÖVE, Lua, game development, puns, and unicorns.
PolySaken
Prole
Posts: 4
Joined: Mon Mar 16, 2020 6:20 am

Re: How to do pixel-perfect rendering in löve?

Post by PolySaken »

Xii wrote: Sun Aug 15, 2021 12:14 am Instead of pre-deciding on a fixed resolution with black bars around, I adapt to any screen size and orientation. Scaling only by integer multiples (for square pixels), but drawing the upscaled canvas such that the edgemost 1 pixel on all sides "bleeds" outside the screen. That is, the view fills the whole screen, always, but the edgemost pixels are cut off.
..snip..
Thanks, I can adapt this to my needs.
User avatar
GVovkiv
Party member
Posts: 668
Joined: Fri Jan 15, 2021 7:29 am

Re: How to do pixel-perfect rendering in löve?

Post by GVovkiv »

Gunroar:Cannon() wrote: Sat Aug 14, 2021 10:25 pm text
Hey! That's balanced. In brogue and others you can wield a heavy item but because it's too heavy for you your character keeps missing.
No, you miss the point
I'm talking about random chance to hit/miss or being hit/missed
It's really annoing
I don't like miss or being missed because some randomGenerator(1, over9000) says so
The quests do give pretty weak stuff :rofl: . But the sheep wand has saved me countless times. Helps to make an escape
Point is, that you have no control over it, for example, at shattered, you have to choose one wand of 2 from wandmaker, so you can decide what what will be helpful for you to play; same for sad ghost
(You mean 25 levels. But I guess you meant like levels (separating on boss fights) and not floors :) )
I suck at english, okay?
Hmm...I guess it's true. But I think the boss battles are nice and varied
If compare original game with shattered, then no, they just feels like stronger mobs, not like unique fights
Swarm of flies are the beeeeeessssst(best)! Go to a corridor and start killing them. Whatever potion they drop is sure to be a healing potion. And there's like a 60% chance they drop one.
Oh, yeah, my favorite:
farming of healing potion
(Pls no, that sucks)
Fortunately, shattered get rid of that farming long time ago
I guess all games get repetitive eventually. Some just get there faster than others
In comparsion:
photo_2021-08-15_11-26-15.jpg
photo_2021-08-15_11-26-15.jpg (56.01 KiB) Viewed 5965 times
I played alot in shattered (and as you can see, i die like ALOT, only 12 wins)
At it still fells new from game to game (because variety of weapons, items, wands, enemies and balance overall makes PD much better)

As i sayed, original game is okay, but why you want to play that, when you have forks, which is much better?
unfair, I guess
and yes, unfair
yet again, in comparsion with shattered, it really feels unfair
User avatar
Gunroar:Cannon()
Party member
Posts: 1085
Joined: Thu Dec 10, 2020 1:57 am

Re: How to do pixel-perfect rendering in löve?

Post by Gunroar:Cannon() »

Haha :rofl: . Like those two guys talking about favourite animals in a conference meeting...

GVovkiv wrote: Sun Aug 15, 2021 8:44 am I suck at english, okay?
No, no, no. It wasn't an english problem. More of a personal terminology problem. Nothing you said there was incorrect.
Swarm of flies are the beeeeeessssst(best)! Go to a corridor and start killing them. Whatever potion they drop is sure to be a healing potion. And there's like a 60% chance they drop one.
Oh, yeah, my favorite:
farming of healing potion
(Pls no, that sucks)
Fortunately, shattered get rid of that farming long time ago

Woah, you don't...I guess it feels like ...cheating
GVovkiv wrote: Sun Aug 15, 2021 8:44 am
As i sayed, original game is okay, but why you want to play that, when you have forks, which is much better?
It's like this shattered is really good. Anyway I'm not saying it's the best of them(I have remixed installed, not even the origional, and I've only finished YAPD), just saying it's a good stepping stone. Like how "Rogue" isn't really great but it's the rogue. Okay, I see your points and guess your right :P
Last edited by Gunroar:Cannon() on Sun Aug 15, 2021 12:49 pm, edited 2 times in total.
The risk I took was calculated,
but man, am I bad at math.

-How to be saved and born again :huh:
User avatar
GVovkiv
Party member
Posts: 668
Joined: Fri Jan 15, 2021 7:29 am

Re: How to do pixel-perfect rendering in löve?

Post by GVovkiv »

Gunroar:Cannon() wrote: Sun Aug 15, 2021 12:40 pm Haha :rofl: . Like those two guys talking about favourite animals in a conference meeting...
Yeah, why not
User avatar
pgimeno
Party member
Posts: 3544
Joined: Sun Oct 18, 2015 2:58 pm

Re: How to do pixel-perfect rendering in löve?

Post by pgimeno »

PolySaken wrote: Sun Aug 15, 2021 12:25 am
pgimeno wrote: Sat Aug 14, 2021 1:38 pm The idea behind Push is to render to a canvas of a smaller resolution, then render that canvas to the screen appropriately scaled.
I mean I want what is usually referred to as pixel perfect rendering, where the pixels of one texture will always align with the pixels of any other, even though those pixels may not actually be a 1x1 pixel size. Basically the opposite of how most 'pixel' games look, where sprites may be offset by less than a pixel.
In that case, what I said applies to what you want. Drawing to the low-resolution canvas ensures that the pixels will be aligned the way you want. In order to get the effect that you *don't* want, the sprites have to be drawn scaled directly to the screen, or to a higher resolution canvas.

You can then draw the canvas using what Xii described if you want, but in that case Push won't be of much help.
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 51 guests