mouthporn.net
#gamedev – @chronicsheepdeprivation on Tumblr
Avatar

I'm going Sleepcycling

@chronicsheepdeprivation / chronicsheepdeprivation.tumblr.com

Hatty ★ ( They/Them ) ★ Mustelid System
Avatar
Avatar
bobacupcake
Anonymous asked:

If you don’t mind me asking, how do you achieve that extra depth effect on things like the Pokémon cards or the Vampire Bite potion? Is it just masks or is it done in post, or something a bit fancier?

always happy 2 share!! i have 3 main methods of doing it

first is called raymarching, its what i use for a lot of my potions!! i think the best way i can explain it is its really similar to how 3d printing is done in that it renders layer by layer (e.g. with normal rendering you take a point and get the color at that point, raymarching gets that point, and then the point behind it, and the point behind that, and the point behind that etc etc and adds them all together or some )

this is what it looks like from the camera if you go step by step rather than all at once 

imageimage

and if you somehow magically view it from the side and not from the camera its basically doing something like this, but all at the same time

the color is solid in this one but with some tweaks you can make stuff like clouds or wispy potions!!

another method i use is parallax mapping, its basically taking a 2d texture but distorting it based on the “depth” at each point and how youre looking at it. both of the squares below use the same 2d texture but the one on the right is using parallax mapping based on the angle youre viewing it from to make it look 3d 

if you know how parallax works in platformers and stuff then you already know how this works its the same exact concept but with a bit more flexibility. its a lot faster in terms of performance than raymarching since its literally just a 2d texture thats just distorted to look like its 3d. this is what i use for stuff like this!!

and the last thing i use is stencil shaders, where i actually use a full 3d model/whatever else i want but only make it visible when viewed through another 3d model that acts like a window. here mario can only be seen when hes in the circle. this is what i use for my pokemon cards!! (along with a bit of parallax mapping for the part of the card surrounding the “window”)

happy to clear anything up if anyone has any questions!!

Avatar
You are using an unsupported browser and things might not work as intended. Please make sure you're using the latest version of Chrome, Firefox, Safari, or Edge.
mouthporn.net