AuthorTopic: The chalenge to upscale pixel art  (Read 27686 times)

Offline Ai

  • 0100
  • ***
  • Posts: 1057
  • Karma: +2/-0
  • finti
    • http://pixeljoint.com/pixels/profile.asp?id=1996
    • finticemo
    • View Profile

Re: The chalenge to upscale pixel art

Reply #30 on: September 20, 2013, 10:37:00 am
I personally appreciate it as a prefilter for feeding into vectorization. Particularly for B/W / lineart. Being able to scale nicely up to any size and have something sharp to start painting on/under, is excellent. (I like to use GrafX2's contour fill to thumbnail designs in B/W, so I can get a lot of use out of strong vectorization. Inkscape with no prefiltering is mediocre at respecting ~pixel-sized details)

Here are some comparisons of vectorization results:

At 3x original-pixel-art scale:
The first item in the 'gallery' is the result of putting the dragon straight into Inkscape's Trace Bitmap function; The second is the result of putting the result of Hyllian's 3xbrLV4 filter into Trace Bitmap. It notably improves 'sharp' elements and anything that has a narrow line of pixels, preventing it from becoming unduly rounded.

http://imgur.com/yQvurII,F0weOQM#0


At 6x original-pixel-art scale:

http://i.imgur.com/b72bWZO.png (without 3xbrLV4 prefiltering)
http://i.imgur.com/vTL6mIq.png (with 3xbrLV4 prefiltering)

« Last Edit: September 20, 2013, 10:40:09 am by Ai »
If you insist on being pessimistic about your own abilities, consider also being pessimistic about the accuracy of that pessimistic judgement.

Offline Seiseki

  • 0011
  • **
  • Posts: 915
  • Karma: +1/-0
  • Starmancer
    • OminuxGames
    • http://pixeljoint.com/p/35207.htm
    • StarmancerGame
    • View Profile
    • Starmancer Patreon

Re: The chalenge to upscale pixel art

Reply #31 on: September 20, 2013, 10:59:57 am
Upscaling pixelart will always be a touchy subject here.
The Focus on scaling pixel art and making it less jaggy devalues pixel art, because the low resolution is being seen as undesirable.
Especially when it's even being applied to old classic games, which look "too chunky" in hd.
Where is the love for real pixels? If it's not being appreciated like it used to, then we're clinging to something people write algorithms to get rid of..
Why are we then making pixel art in the first place instead of going straight for vector art..
If everyone was using pixel art upscalers, modern and retro pixel art would be dead.

Yes, I'm being overly dramatic, but the thought is kinda worrying me.
That's why I can agree on the ptoings conservative stance on this..

Pixel art is created with the intention of being pixel art, not vector art.
If you upscale it you're saying "I'd rather want this in vector art.." and that it's not good enough as just pixel art.

@Hyllian, I hope you don't view this philosophical input as a personal attack or an attack on your work which is still very impressive.

Offline Ai

  • 0100
  • ***
  • Posts: 1057
  • Karma: +2/-0
  • finti
    • http://pixeljoint.com/pixels/profile.asp?id=1996
    • finticemo
    • View Profile

Re: The chalenge to upscale pixel art

Reply #32 on: September 20, 2013, 12:21:10 pm
There's no need to worry that upscalers will replace PA -- filtered-upscaled pixel art is worse artistically than pixel art, even if you are not judging by pixel-art's particular standards. The element of distortion and exaggeration in pixel art holds up much worse at larger scales (that is, it is often much better to simply reduce the distortion and exaggeration in order to do a more interesting rendering of details, when you have the pixels to do so.),  and there is a general scale problem (when you attain a higher resolution, your eye expects finer details (rather than merely refinement of existing details), which naturally are beyond the ability of the upscaler to produce, since they aren't present in the source material.

I think the only type of graphics upgrade that would not have these downsides would not depend on a real upscaling algo -- rather, it would use a database mapping original graphical blocks (8x8 or 16x16, according to the system) to manually redrawn versions for whatever scale was selected.
(this is fairly hairy video-bandwidth-wise, but we are getting towards having systems powerful enough that that kind of thing could be done in-emulator)

However, there is really such a thing as too chunky -- when each individual pixel gets too big, the overall image stops reading well, and really does look like a mere collection of blocks. On my 20" desktop screen, it's at about 5x for me when the illusion of a coherent image breaks down.
So I do understand the desire to recover something that's more visually coherent from that, even at the cost of some of the finer artistic detail. For sufficiently low-res art on large displays this is a genuine problem.
If you insist on being pessimistic about your own abilities, consider also being pessimistic about the accuracy of that pessimistic judgement.

Offline Mathias

  • 0100
  • ***
  • Posts: 1797
  • Karma: +2/-0
  • Goodbye.
    • http://pixeljoint.com/p/9542.htm
    • View Profile

Re: The chalenge to upscale pixel art

Reply #33 on: September 20, 2013, 02:41:46 pm
I'm gonna have to echo ptoing.

Yes, that 3X dragon looks cool. Know why? Because it's a cool design. At 1X it works great. Just as the artist intended. Pixel tech intact.
At 3X, it's still interesting to look at, but no longer works as well. The whole thing looks filtered. The way the pixels have been treated is very mechanical in appearance. There are numerous places I see in need of attention. Obviously, because a computer made choices in an attempt to interpolate 1 pixel into 9, essentially.

All that said, I do agree the dragon would look better to most people on a T-shirt as the 3X smoothy algo version rather than nearest neighbor, IF the wearer wasn't an appreciator of PA.

To each his own.

Offline ErekT

  • 0010
  • *
  • Posts: 330
  • Karma: +0/-0
  • fistful of pixels
    • View Profile

Re: The chalenge to upscale pixel art

Reply #34 on: September 20, 2013, 03:49:11 pm
I kinda appreciate the painterly look you get from these filters. But yeh, one of pixel art's main strengths is in minute control of detail. I think this is why I've always preferred it to 3D where the computer does half the rendering job for you.

As scaling filters go though, it's better than any of the others I've seen :)
« Last Edit: September 20, 2013, 03:55:00 pm by ErekT »

Offline rikfuzz

  • 0010
  • *
  • Posts: 427
  • Karma: +1/-0
    • View Profile
    • twitter @hot_pengu

Re: The chalenge to upscale pixel art

Reply #35 on: September 20, 2013, 04:44:16 pm
Scaling pixel art is difficult - I've often had to do jobs for multiple resolutions, and usually end up cleaning stuff up from nearest neighbour scales or trying out Rotsprite which has a halfway decent scaling algorithm. The alternative is redrawing everything 2 or 3 times so this kind of tool can actually be pretty useful, at least for a starting point.  Granted I usually scale down if I can help it, but occasionally I've had to scale up.  Normally something like 125% or something rather than 300%, but any advancements in this area are appreciated.   :) 

Would anyone tackle an arbitrary % scaling DOWN algorithm? Ideally something that weighs contrast higher than near-duplicates. 

Offline Ai

  • 0100
  • ***
  • Posts: 1057
  • Karma: +2/-0
  • finti
    • http://pixeljoint.com/pixels/profile.asp?id=1996
    • finticemo
    • View Profile

Re: The chalenge to upscale pixel art

Reply #36 on: September 20, 2013, 10:37:53 pm
^ I think you probably want an algorithm based on the principles found in Liquid Resize (http://liquidrescale.wikidot.com/)
If you insist on being pessimistic about your own abilities, consider also being pessimistic about the accuracy of that pessimistic judgement.

Offline surt

  • 0011
  • **
  • Posts: 570
  • Karma: +0/-0
  • Meat by-product
    • not_surt
    • http://pixeljoint.com/p/2254.htm
    • View Profile
    • Uninhabitant

Re: The chalenge to upscale pixel art

Reply #37 on: September 20, 2013, 11:13:41 pm
I've been meaning to try out a simple priority/mode-based down-scaler idea using a colour priority list (eg. transparency low priority so it doesn't dominate small protruding features, outlines high priority so they don't get broken up), taking the highest priority colour, next taking the mode of the set of contributing pixels, then failing that take the weighted mean of the contributing pixels and fit to the palette.

Offline rikfuzz

  • 0010
  • *
  • Posts: 427
  • Karma: +1/-0
    • View Profile
    • twitter @hot_pengu

Re: The chalenge to upscale pixel art

Reply #38 on: September 21, 2013, 01:45:33 am
^ I think you probably want an algorithm based on the principles found in Liquid Resize (http://liquidrescale.wikidot.com/)

That's like photoshop's content aware scaling - I think you need something much simpler for pixel art - probably give every pixel a score of the distance in R/G/B to all it's neighbours (and maybe next next neighbours), and just throw them away in reverse score order till you reach the desired size.  Doing that row by row might make straight lines go wibbly, so maybe there's a smarter way to perform the cull. 

A secondary ranking based on the pixel position, might help, but even the dumbest approach would probably still be a better starting point than nearest neighbour for most cases.  (In theory!) 

Offline Tourist

  • 0010
  • *
  • Posts: 376
  • Karma: +1/-0
    • View Profile

Re: The chalenge to upscale pixel art

Reply #39 on: September 21, 2013, 11:08:44 pm
Perhaps there needs to be an in-between step to identify the artist's intention. 

This color is used for lines, so scale it according to these rules.  This other color, which has the same RGB value, is just a material shade, so scale it using these rules.

These two colors are on a common ramp, so shape the boundary between them to preserve the larger path of the border, and maybe use a little AA.  These two colors are two different objects altogether that just happen to be adjacent or overlapping, so do .. something else.

You could probably do it with different palette entries, but only for small color counts.  Otherwise you need to store additional data with the pixels.  A custom TIFF file format, maybe.  Final output can have the extra data stripped and colors merged.