1,055 books…

… are in my personal library, yay!

I had been meaning to digitally catalog my book collection for some time now. I have on several occasions found books at used bookstores that I wasn’t sure whether or not I owned yet (typically books in a series or books by prolific authors). So I finally used a free app called Libib to digitally catalog the books I own (not including eBooks at the moment; I only have perhaps a dozen of those). Next time I am wondering the shelves of a used bookstore, I can now search the app to be sure of what I have and what I don’t. Even while cataloging the books, I found a few books to weed out because I have multiple copies of them.

You can scroll through my library here: https://shannifin.libib.com/

(Unfortunately there does not yet seem to be a way to sort the public listing in any other way besides by title.)

I get a majority of books used, and have walked away with some big loads for cheap prices when stores are going out of business or getting rid of excess. I’m sure I still spend too much money on books considering my slow reading speed, but they’re addicting to collect, aren’t they?

I’ve only read around 10% of these books. Of course, some books are more for reference and not really meant to be read from front to back anyway. Still, with my current reading speed, I will likely die with the majority of these books left unread. Which is fine, because upon death I will have access to infinite knowledge… I hope.

Anyway, if you’re a book lover or collector and wish to digitize a record of your catalog, Libib is the best free app (for Android) I’ve come across so far. It also allows you to export a CSV file, which is handy.

Statistics do not determine probability

Well, that really depends on what probability you’re asking about. Perhaps it is more clear to say: The statistics of past events do not determine the probability of future events.

(At least not in and of themselves.)

An obvious example: Suppose you flip a coin three times. Your statistics, especially with the sample set being so low (and odd for that matter), naturally won’t reflect the intuitive 50/50 probability of flipping heads the fourth time.

What if you flip a coin 10 times and get heads each time? Does flipping 10 heads in a row imply anything at all about probability of flipping heads on your eleventh flip? (The answer is no.)

I bring this up because it’s annoyingly astounding how many times people will bring up statistics as evidence of societal privilege, oppression, or institutional racism / sexism.

For example, one may find that at a certain company, only 5% of the employees are black, and 95% are white. Does this mean a black person picked from the general population at random is far less likely than a white person to get a job there? Of course not. Firstly, that statistics of who’s already been hired doesn’t tell us anything about applicants who weren’t hired (are less black people applying in the first place?), and secondly, we’re ignoring quite a lot of other variables, such as interest in what the company does and necessary qualifications.

To make the fallacy a little more obvious: Suppose the company has 100 employees, 5 of which are black (thus 5%). Then a white person retires and they hire a black person in his place. Does this mean the probability of any random black person getting a job there just rose by 1%? That is, does hiring a black person increase the probability of any random black person being hired? Obviously not. (At least, I hope it’s obvious.)

And yet this fallacious way of interpreting statistics is brought up again and again in discussions of race and sex and privilege, as though the statistics of past events alone somehow determine the likelihood of your future. (“You have so many opportunities! Just look at the stats!”)

What’s even sadder is that this way of thinking seems persuade amiable people to believe that they have some kind of moral obligation to put themselves down based on their race or sex for the greater good, as in: “I shouldn’t apply for that job because I have white male privilege; that job should really go to a minority who doesn’t share my privilege!” or “I shouldn’t seek financial aid for my white children because they already have so many opportunities already just by virtue of being white!”

You don’t make the world better with that sort of thinking. You make it worse.

Font rendering: stb oversampling vs NV path rendering

I told you I wanted to try stb oversampling in my last post, and I did! Here is the result (stb 2×2 oversampling on top, nanovg in middle (which is based on stb anyway, but no oversampling), and NV path rendering on bottom, screen size then 5x zoom):

So stb oversampling definitely looks the best, although it is still pretty fuzzy. And moving it around by subpixels looks very decent; it doesn’t get very much of the “shimmer” effect. (Still a bit, but not much to be bothersome.)

Here’s stb oversampling (top) vs NV path rendering (bottom) with a bigger font size (screen size then 2x zoom):

Here, I think NV path rendering looks better; it’s definitely less fuzzy. (The trade-off is that it does suffer from more “shimmer” when translated by subpixels, but it doesn’t bother me too much.)

You can also see that NV path rendering is able to utilize proper kerning: the ‘e’ is slightly below the capital ‘T’, as it should be. Each letter isn’t being drawn on a textured quad, so overlapping is trivial. (Well, for the end library user, at least.)

So, I think that completes my foray into font rendering for now. I’m too lazy to make bitmap fonts at the moment; stb oversampling will work for smaller fonts for now. Time to continue on to other GUI elements. I will try to design the GUI system in such a way that it will be able to utilize any font rendering system should I wish to create bitmap font support in the future.

More font fun and other random stuff

Font rendering in OpenGL

Haven’t done so much programming in the past week, but I did try rendering fonts with NanoVG (in lwjgl). Unfortunately it’s really not much better than just using OpenGL’s NV path rendering extension. Small fonts look slightly better, but not really good enough for me to want to use them. See the example below, a zoom-in of an 8-pixel high rendering of the font “Verdana”, NanoVG rendering it on top, NV path rendering below. NanoVG is better, but it’s still way too fuzzy to look any good.

So I might just use bitmap fonts for small text; I can’t see any alternative. (Bitmap fonts basically means loading in each letter as a pre-rendered picture and plopping it on the screen. The disadvantage is that they don’t look very good when resized or positioned between pixels, but they’ll at least be guaranteed to render small fonts clearly and crisply.) I’ll continue to use NV path rendering for larger fonts or fonts that need to be animated more dynamically or rendered with 3D perspective. I do want to try using oversampling with stb for small fonts before I move on from font rendering and further develop a GUI system; the demo doesn’t look too bad.


Kanopy film streaming service

I just realized our local library offers free access to the film streaming service Kanopy, and they’ve actually got a decent selection. Not the latest blockbusters, but some good foreign and classic cinema. (They’ve even got The Red Pill, the controversial anti-radical-feminist documentary which Netflix refuses to stream. (Though they did just recently finally add the DVD to their catalog.)) Since it’s free (for library card holders of participating library systems), we’re limited to 10 streams per month, but the streaming quality is decent. It’s not full HD (at least not on my PC), but it’s better than DVD quality. Interestingly they also allow you to embed videos. Here’s “Kumiko the Treasure Hunter”, which I really enjoyed (which I guess you won’t be able to see without an account, haha):

Interesting indeed!


Some metal music

Finally, I recently discovered the band Elvenking. I couldn’t quite get in to some of their older work, but their last album, released last year, is quite catchy. Disregarding the bizarre sense of fashion metal band members tend to share, this song is some power metal awesomeness:

I also came across the latest album from the symphonic metal band Leaves’ Eyes, and found it to be quite catchy as well. Love the use of choirs, the female lead’s operatic voice, and the cheesy fantasy lyrics. (I’m not a big fan of the growl singing, it sounds so gross and ugly and demonic, why is it so popular? It sounds so awful, so unmusical. Bah!)

OK, that’s all for now.

Font programming fun

So I’ve started working on GUI elements for my little engine that could. My quick list of things I’d like to include in a GUI system:

  • ability to create a menu bar
  • ability to create windows / panels with drop shadows
  • ability to create scroll bars for window content
  • ability to create buttons and button animations (hover, click)
  • ability to create text boxes and text fields

I started working on text today, i.e., font rendering. The NV path rendering extension actually does a pretty good job with larger text:

It’s not so good with smaller text:

Look at that ugly subpixel rendering:

Bleh! So I’ll have to figure out something else for smaller fonts. I’ll probably look into the Java AWT package, or perhaps look into NanoVG, especially since it looks like lwjgl already has bindings for it. (Maybe it already has everything I want?)

MIDI animator version 2 wishlist…

As I blogged a couple months ago, one of my goals for 2018 is to program a very simple 3D engine. I’ve been wanting to program a simple adventure game for a few years now, but the 3D and 2D engines I’ve played around with just don’t have quite the features I want, so I’m attempting to create my own little game engine with the Lightweight Java Game Library (lwjgl).

Here’s what I’ve got so far: I can render a textured box and some resolution independent vector graphics including true-type fonts, which can intersect with the box!

OK, so nothing special yet.

Anyway, another thing I’d like to create with lwjgl is a new version of my MIDI animator, using vector graphics (instead of custom shaders) to represent the MIDI notes. (On a side note, I’m using the OpenGL “NV path rendering” extension for vector graphics support, which was created by Nvidia. Does that mean it’ll only work on their GPUs? I don’t know.) This should easily allow many more possible note shapes to be created.

Here’s my current wishlist for “MIDI animator 2.0” (I should also come up with a more interesting name):

  • Should be able to run standalone (that is, users shouldn’t have to download and compile the code to use it)
  • A graphical user interface (GUI) that makes it easy to:
    • load MIDI files
    • change note styles / shapes / colors / animations
    • a scroll bar to make it easier to scroll through the MIDI
    • save files
  • Ability to add title / text animations (instead of having to do this in post)
  • Ability to change / animate background
  • Ability to load in an MP3 to sync with the visualization
  • Ability to add an MP3 visualization, such as one of those pulsing frequency bars or something
  • Ability to export a movie file automatically (if I can figure out how; I’ll save this for last)

Anything else I should include or look into?

So, yeah, this is probably what I’ll be working on in my free time for now. I’ll probably start working on a GUI system next as I’d need to do this for a future game anyway.

Hopefully I’ll get back to actually writing some new music afterwards.

All the movies I watched in 2017

Happy 2018! In 2017, I watched a total of of 180 movies. That’s 54 less than last year’s count, but who’s counting? Here’s my annual collage (full list here):

Favorite films…

My two favorite live-action films from 2016 would definitely be Guardians of the Galaxy 2 and A Monster Calls. Guardians of the Galaxy 2 was a bit of a surprise. I enjoyed the first film, but it didn’t feel overly special to me. I enjoyed this sequel a lot more. It was funnier, the story seemed tighter, and the main conflict felt more meaningful. Baby Groot was hilarious; I fear the next installment won’t be able to compete with him being an adult again. A Monster Calls was a more serious film, and I loved the way it merged fantasy with the real world. Beautiful cinematography and music as well.

Animation-wise, no film came close to Pixar’s Coco. It was a beautiful story with super-catchy music. And I loved how its main theme song, “Remember Me”, actually played a very important role in the plot; it wasn’t just some arbitrary addition. Not only is this movie my favorite animated film of the year, I’d have to say it has become my favorite Pixar film of all, taking the place from Finding Nemo. (It’s also Pixar’s highest-rated film on IMDb at the time of this writing. Yay!)

Other enjoyable films of the year include DunkirkKing Arthur: Legend of the SwordThe Dark TowerBlade Runner 2049, and It: Chapter One. The two fantasy films were a bit cheesy and had some flaws, but I still enjoyed them.

I really enjoyed the 3D re-release of Terminator 2: Judgment Day. I don’t think it did very well at the box office, which is too bad. I love 3D movies and I love older films being 3D-ized. Considering how much the process of 3D-izing a film costs, T2’s box office results will only discourage the practice. Tragedy, I say!

I saw Terrence Malick’s 2011 film The Tree of Life and loved it. Long and contemplative and somewhat weird, but overall very thought-provoking. I also really enjoyed the 2014 foreign film A Hard Day, an action thriller with a lot of great twists, both humorous and suspenseful, almost Hitchcockian.

Older films I saw for the first time in 2017 and highly enjoyed include Excalibur (great fantasy with a classic 80’s feel to it), Stand By MeMan of La Mancha (Peter O’Toole is not so great in this, but I just love the musical), Lone Wolf and Cub: Baby Cart to Hades (love this series), and High Noon with Gary Cooper, a classic.


So that’s my 2017 in movies.

And guess what I got for Christmas this year? A year-long MoviePass subscription! Remember “MoviePass”? I blogged about it way back in 2013 here. Their service was a bit too expensive then; I’m glad costs have gone down. My card hasn’t arrived in the mail yet, but I’m really looking forward to it! So I’m hoping to see a lot more new releases in theaters this year.