Pixel Art Shader - Feedback wanted

Ask about editing graphics, sounds, models, music, etc here!
Shaders (GLSL) and SNDINFO questions also go here!

Moderators: GZDoom Developers, Raze Developers

Forum rules
Before asking on how to use a ZDoom feature, read the ZDoom wiki first. If you still don't understand how to use a feature, then ask here.

Re: Pixel Art Shader - Feedback wanted

Postby Stopsignal » Thu Feb 04, 2021 1:04 pm

Lovely work!

If i were to throw my two cents (though most stuff was already said by caligari, who was absolutely on point) there is a huge problem you'll face, which is incredibly ironic in and of itself: You want to make this shader so animation and rotations are easier to do, but the more animations and rotations you do, the more the brain realizes this is, in fact, a 3D object.

The idea is that the brain isn't dumb. At all. In fact it is incredibly fast to detect depth in things.
For example, in the unholstering animation you posted, that alone breaks the ilusion: everything moves like it should have, everything gets smaller or bigger depending on the angle: i can see that it is 3D. Which kind of sucks! There goes the irony.
Showing perfect depth and placement in character rotations does this as well.

Usually there is a method to go around this. Severely limiting animation frames is one- for example, Guilty Gear (the ones that are 3D but look 2D) limits it's poses when attacking, and depending on the position of the camera, move certain parts of the characters (like mouth, eyes, that kinda stuff that are mostly drawn depending on the angle) to fool the brain. It mostly works!

What i have seen people do, with 3d to 2d weapons, is to limit frames like this. Usually 1 frame idle, maybe 1 when lowering, and to make it stiff when shooting, rather than having many frames. You are allowed to do many frames with the reload, but be careful, as too many angle changes can lead to the brain realizing.

Lately i saw this tweet from a dude making something akin to this for his guns, and i think it looked rather neat.
https://twitter.com/JasozzGames/status/ ... 7295331329
He has a different artstyle than Doom, though, of course!

As for the art itself, make it
-not have banding (this automatically kills the effect), use hand drawn details in some places to better fool the person looking
-avoid poses which look too 3D (way too subjective, but w/e, arms or legs way too open, things like that, as long as the legs don't go all over the place like the arachnotron you are good to go)
-make poses look flatter (by this, i mean the field of view, i guess, if one leg looks way smaller because it's further back, it won't look like fake 3D, it will look like a rendered frame from a model)
-be careful with shining and lighting (sometimes, you might have your renderer options all correct, but the absolutely correct lighting, which is the best way for our eyes to see depth in 2D images in real life, will be an obvious tell that it is a model, as drawings usually have imperfections that, while you might not be able to tell, your brain actually does tell. I have no idea how to properly fix this. Baked in lighting? That could be problematic if not fixed post rendering. hmmm)
-ugly messes. By this i mean that, sometimes, when downscaling, a model suddenly looks all ugly and weird. Lines become blobs, faces become whatever, parts of the body become flat, contrasts become blurry. This is bad. Pixel artists usually spend hours looking at the same set of images, and work pushing pixels one at a time, they see these things. After all, pixelart is a way to convey more detail with less. Therefore, there are tricks to do so- playing with the pixels in order to suggest a weapon and its small details, a face with its nose and eyes and mouth. It might only be a few pixels, but these small details are what are important, and downscaling can either make them dissapear or become messes.
I guess a perfect sprite shader would check on those small details and make them pop? No idea.

I see these kind of projects as an awesome jumping point, however, as you can give these frames to an artist and he can finish the work by cleaning them. Like Ion Fury, i guess!

This is all if you want to replicate doom's style, however.
After all, one thing i always say is that it doesn't matter how it looks, the thing that matters is that it looks *consistent*. If everything looks the same way, it's a style. If it all looks different, it's a mess, hahahaha
User avatar
Pixel Artist
Joined: 21 Apr 2015
Discord: Stopsignal#2168

Re: Pixel Art Shader - Feedback wanted

Postby Custodian » Sun Feb 07, 2021 11:33 pm

@Stop signal - I am not aiming to perfectly replicate Doom's art style. I do, however, want my sprites to have a polished and consistent look.

Here's another sprite for critique:

Something that immediately struck me is how weird and out of place my sprites look when they're higher resolution than Doom's sprites. That female character looks weirdly tall and skinny compared to her counterparts when I replaced the zombieman with her. I opened up the Zombieman sprites and was stunned to see that she's about twice as tall as they are. I want my character sprites to be roughly the same size as their Doom counterparts. After making some tweaks to my model, I was able to get something a little closer to the original style. I had to 'squish' my character model down to make it feel wider and bulkier like the doom sprites. I still wasn't getting enough resolution to clearly resolve the face like you can with the Doom sprites. I had to roughly double the head size to get a similar appearance.

This sprite is much closer in size to the zombieman, albeit just a few pixels taller. The definition of hairstyle is completely lost. Why... why are Doom's sprites so bulky? Can anyone point me to a resource about size and proportion in Doom? I'd like to try to match at least the sizing and proportions of the Doom sprites, even if they aren't necessarily accurate or realistic.
User avatar
Beyond Sunset
Joined: 29 Jan 2021
Location: Minneapolis MN, USA
Github ID: disasteroftheuniverse
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: ATI/AMD (Modern GZDoom)

Re: Pixel Art Shader - Feedback wanted

Postby Gez » Mon Feb 08, 2021 3:14 am

Yes, Doom sprites are very bulky. Part of the explanation is Doom's no-square aspect ratio (320x200 stretched to 4:3 physical size means that pixels are 20% taller than they're wide); but even when stretching the vertically a bit, they're still bulky. The human characters wear armor, which may be also an explanation; the Doom II flayed corpses certainly look less wide than the zombies. But another factor to take into account is the low resolution. Remember when I said you might have to cheat with proportions to keep things readable, notably give them a bigger head so the face still looks like a face? That's what the id artists did.

I think no matter how good the shader gets, a manual clean-up will still be needed at least for the heads.
Joined: 06 Jul 2007

Re: Pixel Art Shader - Feedback wanted

Postby Enjay » Mon Feb 08, 2021 3:51 am

The Doom sprites are squat and weirdly proportioned. Importing human-looking sprites from games such as Duke Nukem (+ other build games), Rise of the Triad and many more show a very similar problem because those sprites have more human-like proportions (and are often bigger too).

If you intend your sprites to be on screen at the same time as Doom sprites then, yes, I would agree that something needs to be done to address the style-mismatch. If, however, your sprites will only be seen with other sprites by you, then I would go with the style that you want. If you feel that they are too tall/big in some way, then you can scale them down to a suitable size in their actor code (DECORATE or ZScript) and keep the details.

Custodian wrote:Here's another sprite for critique:

I like that one. It looks a bit grainy pixel-wise, but from what has gone on above, I suspect you are happy with that. My only "problem" with it is the colour of the weapon. Its pink/purpleness makes it look a bit comical/plastic but, more problematically (IMO) it gets a bit lost against the colour of the person's clothes. Also, there is a quite a large area of the weapon that seems to have exactly the same coloured (or very similarly coloured) pixels and it therefore looks a bit flat and like it has been forced into a specific palette, thereby losing detail.
User avatar
Everyone is a moon, and has a dark side which he never shows to anybody. Twain
Joined: 15 Jul 2003
Location: Scotland

Re: Pixel Art Shader - Feedback wanted

Postby Custodian » Sun Feb 21, 2021 8:39 pm

How to create pixel-art style renders in Maya

I wanted to update this thread with a quick word on how I achieved this effect in case anyone was interested. Fortunately, I am not the first to attempt this, and such a tutorial already exists, which uses a remarkably similar process to mine.
I rendered my sprites with Autodesk Arnold, which is the stock renderer for most modern Autodesk 3D design and animation products. This renderer is also available for Cinema 4D. A similar effect should be possible in any modern render engines that come with 3D animation software.

Here's a quick description of how my process differed from the linked tutorial.

Spoiler: These images are animated, click to follow link to Imgur

  • I simply used the Arnold Toon Shader. I left the diffuse color at pure white, the diffuse weight at 1, disabled energy conservation and connected a ramp to the tonemap without any interpolation to give the tone map a banded/cell-shaded look.
  • To add some texture and avoid an overly-cartoony look, I used a bump map to add some texture to the material
  • For more complex materials, I used the Arnold Layered Shader with an RGB mask. To ensure no off-palette colors leaked in, I disabled antialiasing in my image software to get crisp edges between colors
  • I disabled antialiasing while rendering and applied a custom color LUT to force the colors to match my palette in the event that any errant pixels were blending and creating non-palette colors.

I'll add another post soonish about a wonderful dithering node I discovered. It can produce the classic Bayer 2x2/4x4/8x8 dithers consistently without much noise (yeah, i know dithers are noisy inherently)
User avatar
Beyond Sunset
Joined: 29 Jan 2021
Location: Minneapolis MN, USA
Github ID: disasteroftheuniverse
Operating System: Windows 10/8.1/8/201x 64-bit
Graphics Processor: ATI/AMD (Modern GZDoom)


Return to Assets (and other stuff)

Who is online

Users browsing this forum: No registered users and 0 guests