catball

Meowdy Pawdner

  • she /they

pictures of my rats: @rats
yiddish folktale bot (currently offline): @Yiddish-Folktales

Seattle area
trans 🏳️‍⚧️ somewhere between (30 - 35)


Personal website
catball.dev/
Mastodon (not sure if I'll use this)
digipres.club/@cat
Pillowfort (not sure if I'll use this)
www.pillowfort.social/catball
Monthly Newsletter (email me to join)
newsletter AT computer DOT garden
Monthly Nudesletter (18+ only, email me to join)
nudesletter AT computer DOT garden
Rat Pics (placeholder, will update)
rats.computer.garden/
Website League main profile
transgender.city/@cat
Website League nudes profile
transgender.city/@hotcat
Website League rat pics
transgender.city/@rats

posts from @catball tagged #parallax

also:

bobacupcake
@bobacupcake
Anonymous User asked:

Hi! I'm trying to learn shaders and I'm rlly curious how you got the appearance of cracks running through your stones? I'm not sure how to make it look like something is "inside" like that ><

hi!!! i'm assuuuuming you're talking about the effect in this one?
spinning 3d model of the summoner job stone from final fantasy 14

i'm using something called parallax mapping!! i know most people know what parallax is and how it works in the realworld but im just gonna demonstrate it real quick just so i dont have to keep going "ok now imagine how parallax works"

so imagine you have two windows. in the middle of the window on the left, there is an Orb. it is directly in the middle of the window. the window on the right also has an Orb, but this one is pushed backwards outside the window quite a bit. now if you look at the two windows, and turn them, you get this:
diagram of above

for the first window, the Orb stays basically in the center of the window. but in the second window, if you turn the window right, the Orb "looks like" it's moving left

parallax mapping is essentially taking this assumption, that if you change the angle you are looking at an object, the further away an object is, the more it will move in the opposite direction. i will spare you on the matrix math involved but you can get the exact relation you need by getting the Tangent Space View Direction. you dont need to understand the math behind this to use it

so, lets go back to the window example, how would you make the same effect, but with just this 2d texture of the Orb?
a grey orb

what if, whenever the object it was attached to turned right, you just moved the texture to the left, by X amount, where X is how far into the window the orb is. you would essentially be cheating god and "faking" the parallax. it would look like it's moving like it's far out of the window, but really, it's still a 2d texture. it would look like this:
the same diagram

i was too lazy to make the shader and record another gif but i dont need to because functionally it would look almost identical because when you turn it right the Orb moves left

again, you can just Know the right direction to push the texture in based on the current angle by getting the Tangent Space View Direction. ok another example. what if you had a black and white noise texture, like this

a cloudy-looking noise texture

now what would happen if, instead of moving the whole texture X amount. you moved each pixel a proportional amount based on how bright it is. a 100% black pixel would not get moved at all, and a 100% white pixel would get moved the furthest along the Tangent Space View Direction. a pixel thats right down the middle would move half that distance etc etc. well it would look something like this!!!

a cube that looks like it has a 3d cloud inside of it

thaaat's the basics behind it!!! it's also used for effects like faking room interiors through windows with just a 2d texture in biig cityskapes and the like

a 2d picture of a room, plus the same room but with parallax

you can see how the cube example looks kind of like an ice cube with the distortion, that's Not intentional and how parallax mapping artifacts. i do not care about it, because i make crystals. but some people do care about it, so you can use parallax occlusion mapping, which is like parallax mapping but a step up

here's some more reads on it if you are interested!!!
https://simonschreibt.de/gat/windows-ac-row-ininite/
https://www.patreon.com/posts/playing-with-29753575
https://catlikecoding.com/unity/tutorials/rendering/part-20/
https://halisavakis.com/my-take-on-shaders-parallax-effect-part-i/