Quantcast
Channel: phones - jwz
Viewing all articles
Browse latest Browse all 294

XScreenSaver 5.39

$
0
0



XScreenSaver 5.39 is out now, including iOS and Android.

Four new hacks this time! Three by me.

For RazzleDazzle, I spent a lot of time looking at historical dazzle paint-jobs to try and get a sense of whether there was some basic algorithm under the technique, and came to the conclusion of, "no". Most of it seems to be, "you know it when you see it", but I didn't discern any simple universal rules about the underlying mesh. But, taking a grid and doing a random-walk on each node in it, with some constraints that they try to avoid passing each other, seemed to get the basic sense of it. Even though the pattern is fundamentally rectangular, after a few iterations a lot of sharp triangles show up anyway.

The infinite scroll effect is achieved by running the grid on a torus that is twice the size of the screen, so by the time you see that piece a second time, those points have moved. For the ship stencils, I just traced some old photos by hand.

Fun fact about Peepers: eyeballs are a really funny shape! The iris is kind of a smooshed torus, and is concave-ish compared to the sphere, while the lens is highly convex. But, from many angles the iris actually looks convex because of the diffraction of the lens. So it's hard to get this right in OpenGL, which doesn't do ray tracing. I think a little transparency kind-of got the job done, though. Inspired by PaintYourDragon's Adafruit Snake Eyes Raspberry Pi Bonnet, obviously. And as seen in Cyclopian glory in DNA Pizza.

On X11, try it as "peepers -mode xeyes -count 2" or "-mode beholder"

Crumbler is ok, but I had hoped for more complex shapes. Possibly those would emerge at higher resolutions and number of subdivisions, but the convex hull library that I grabbed is not ideal; it does a O(n^2) malloc at startup, and is kind of slow on top of that. Oh well. If you know of a small, fast quickhull in C, lemme know. I didn't feel like writing my own.

I'm told that the maze thing will be nostalgic for certain people who led childhoods of tragic deprivation, desktop-wise. My thoughts and prayers are with you.

Elsewhere:

Things work a lot better on Mac Retina displays (since I have one now). Turns out a lot of the older screen savers made crazy assumptions like "a single pixel is a thing that you can actually see".

Loading images from RSS feeds works more better, and Android is able to load images from your photo roll.

And on X11, fonts will hopefully look OK on your shitty-assed Linux distro that doesn't ship exotic, avant garde fonts like Helvetica by default, which is apparently a lot of them. Basically as soon as it fails to load a font, it goes scorched-earth and tries like a thousand different things until something works. Fuck it.

Also, internally I converted all of the image assets from XPM to PNG, because what year is it? This means several things have better color and better alpha, but mostly it's just less weird and bloated. But it probably makes some things display incorrectly on 8-bit pseudocolor displays, about which I have decided to just not care.

Previously, previously, previously, previously, previously.


Viewing all articles
Browse latest Browse all 294

Trending Articles