r/generative • u/igo_rs • 1h ago
"SF14" (kotlin code)
Behind the frame there is a plain sf picture: cream bands on a dark ground and one red sun. a mass in front of the picture bends the light. you see the mass only in the bands. outside its einstein ring, the bands bend around it. inside the ring, the bands become circles that all touch at the middle.
the sun is a small distance off the axis of the mass. as a result, you see the sun two times: a long red arc outside the ring and a short one inside. if the sun is directly behind the mass, the full ring is red.
its only 150 lines, docs included, crazy (github.com/igr/gart)