Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length

 
Advanced search

1075922 Posts in 44152 Topics- by 36120 Members - Latest Member: Royalhandstudios

December 29, 2014, 03:45:40 PM
TIGSource ForumsDeveloperTechnical (Moderators: Glaiel-Gamer, ThemsAllTook)Pixel Rotation
Pages: [1]
Print
Author Topic: Pixel Rotation  (Read 439 times)
thekill473
Level 0
***


View Profile Email
« on: March 22, 2013, 11:27:43 PM »

Are there any optimization for rotating a group of pixels by an arbitrary angle. I don't want to use standard image rotation algorithms because the number of pixels in the group has to stay consistent.

Thanks.
Logged
surt
Level 5
*****


Meat by-product.


View Profile Email
« Reply #1 on: March 23, 2013, 12:35:51 AM »

Huh?
If you are rotating a grid (in non quarter revolution increments) and returning the result to the grid you are always going to have overlaps, which result in a reduction of the number of pixels, and gaps, which when filled with interpolation result in a increase in the number of pixels.
Logged

Real life would be so much better with permadeath.
PJ Gallery - OGA Gallery - CC0 Scraps
Gimym JIMBERT
Level 10
*****


NOTGAMER ludophile


View Profile Email
« Reply #2 on: March 23, 2013, 09:36:29 AM »

What's the goal? good image or precise rotation? looks like @surt expose the problems quite well.

Else there is a algo, that upscale in some hqx filter (use in emulation), rotate, and downscale to have very good visual rotation.
Logged


ILLOGICAL, random guy on internet, do not trust (lelebĉcülo dum borobürükiss) ! GЮЯЦ TФ ДЯSTӨTZҚД!
sonic the heidegger (Überall Geschwindigkeit)
SF
Level 0
***


Game Builder Club and 3d Game Birds Gameapp Maker


View Profile WWW Email
« Reply #3 on: March 23, 2013, 10:30:20 AM »

Have you considered running the game at a modern resolution, but with scaled up low-res sprites? That would allow you to do fine rotations without much hassle, though you'd lose some visual authenticity if you were going for a retro look.
Logged

It's a bad day to be travelling, but it's a great day to drink it!
powly
Level 3
***



View Profile WWW
« Reply #4 on: March 23, 2013, 10:50:38 AM »

What's the situation - why do you need a consistent pixel count? You could probably just rotate every pixel, see where they land and adjust them to adjacent pixels if you get overlaps. If your groups are sparse enough or some oddities here and there don't matter, it could work very well.
Logged
thekill473
Level 0
***


View Profile Email
« Reply #5 on: March 23, 2013, 06:12:12 PM »

I wanted to attempt to make a game with powder toy(http://powdertoy.co.uk/) like physics, maybe with a lower resolution. But the pixels could group together to form a bigger object like a clump of dirt. And to make it anywhere near realistic the object would have to be able to rotate and be able to split and merge with other objects of the same material.
Logged
nikki
Level 10
*****


View Profile Email
« Reply #6 on: March 24, 2013, 02:18:05 AM »

nice toy,

perhabs you keep a reference to every particle, then you occasionaly don't see a pixel because it's rotated and aliased away but at a slightly different angle it reappears.

and then see if that's good enough

Logged
Pages: [1]
Print
Jump to:  

Theme orange-lt created by panic