AMAB-to-neutrois GRS

While nearly anyone who has heard of anything regarding transgender issues has heard of the more “traditional” GRS for AMAB people (used to construct a neovagina and labia from existing penile/scrotal tissues), this procedure does not cover the bases for every AMAB person. In particular, a growing number of non-binary-identified people — in particular, ones with a neutrois identity — are much more interested in simply eschewing their external genitalia entirely.

Although controversial, there are now a few surgeons who will, under the right circumstances, provide this sort of surgery. In January of 2017 I had this procedure done with Dr. Peter Davis in Palo Alto.

Disclaimer

This is a thing that I did because it was right for me, and I knew very well that it was what I needed. I am providing this information as a helpful resource for those who need it. There isn’t any one right way to be trans or nonbinary, and what’s right for me isn’t necessarily right for anyone else.

Read more... (CW: surgery)

The Trouble with PHP

This article was originally written for the Publ blog. I have reproduced a slightly modified version here so that it hopefully finds a wider audience.

Whenever I build a piece of software for the web, almost invariably somebody asks why I’m not using PHP to do it. While much has been written on this subject from a standpoint of what’s wrong with the language (and with which I agree quite a lot!), that isn’t, to me, the core of the problem with PHP on the web.

So, I want to talk a bit about some of the more fundamental issues with PHP, which actually goes back well before PHP even existed and is intractibly linked with the way PHP applications themselves are installed and run.

(I will be glossing over a lot of details here.)

Read more...

Keyboard.io Model 01

A few people have asked me to write up a review of my Keyboard.io Model 01 now that I’ve had it for a little while. Here are my thoughts.

First, some backstory. I have used computers my whole life, and ever since the age of 19 I’ve had quite a bit of trouble with chronic wrist pain. This has only gotten worse over the past 20 years. I have tried all sorts of keyboards, from various mechanical keyboards such as from Filco, to ergonomist-recommended split keyboards such as the Kinesis Freestyle, all the way to incredibly exotic weird-as-heck things like the Datahand and ErgoDox. All of them had pluses and minuses, but ultimately none of them really let me escape the orbit of horrible wrist pain; almost universally, their design flaws would end up ultimately making it worse than it was before and I’d end up going back to a more-traditional Filco 10keyless.

Read more...

Watermarking hotlinked images

What’s hotlinking?

“Hotlinking” is where you link to an image stored on someone else’s site without making your own local copy. It’s done a lot by people posting to forums, weblogs, or to social networking sites such as MySpace.

The usual solution to this problem is to redirect them to another (often tasteless) image indicating one’s dissatisfaction with the act of hotlinking. This is a pretty good disincentive from using other peoples' bandwidth; however, I care more about people maintaining attribution, and standard hotlink-prevention stuff simply just causes people to upload a copy of the image to another site and then keep on not attributing it; in this case it’s even worse because if someone were to look at the image’s URL, they don’t see anything regarding where the image originally came from.

One solution is to make a simple image proxy script which adds a watermark to an image, and also logs the hotlinked image.

Read more...

Base-10 File Sizes

So, Mac OS X 10.6 (Snow Leopard) will be using base-10 file sizes. There has been a lot of nerd outcry over this, but frankly, I think it’s about freaking time.

There is absolutely no reason to use base-2 file sizes. Yes, computers deal with things in terms of base 2, but nobody else does. When you look at a file that is 104768926 bytes big, you think, “oh, 105 megabytes,” not “100 megabytes.” As files get bigger and bigger, the disparity between MB and MiB gets worse and worse.

People have long accused hard drive manufacturers of “inflating” drive sizes by using base-10 instead of base-2, but really it’s been the fault of OS makers for deflating it, based on some really ridiculous legacy which dates back to the 70s, namely that it was a lot easier for OSes to just say how many 1K clusters were available, or divide the bytes available by >>10 instead of /1024, or whatever.

The practice of 1024-as-K has also led to all sorts of weirdness, like 1.44MB disks (which were 1440KiB, i.e. 1474560 bytes - neither 1.44MB nor 1.44MiB).

“But computer parts are sold in terms of 1024 units!” is also crap. The only part that has ever been sold on that basis is RAM, which actually makes sense for various technological reasons not worth getting into. CPU speed is base-10. Network adapters are base-10. Bus speed is base-10. And hard drives are sold based on base-10, but reported based on base-2.

Okay, so RAM sizes will be somewhat disparate from hard disk sizes, but really, why does that matter? RAM sizes only matter to programmers, and as a ballpark figure for users for having “enough” memory. Just because a file on disk takes 1200KB doesn’t mean it will take 1200KB of RAM; chances are it will take much more. (Granted, there are a lot of spots where it makes sense for code to use power-of-2 sizes, for things like memory allocation and caches and the like, but that doesn’t need to be reported to the user.)

The only place where hard disk size really has any base-2 issue is because file systems tend to allocate things in base-2-sized chunks (usually 512 or 1024 bytes), but that’s not counting overhead of the filesystem itself, and anyway the vast majority of files (the ones which take enough space for hard drive availability to be an issue) are so large that the cluster size essentially just amounts to rounding error anyway. Okay, so the “real” storage space taken by a 123456789-byte file is actually 123457536 bytes, but that’s still a lot closer to 123.4MB than it is to 117.7MB!

In short: Apple is doing a good thing by finally freeing us of some ridiculous legacy which has no bearing on reality.

Okay, so it does mean there will be a mismatch between file sizes reported on OSX 10.6 vs. any other OS, but when does that actually matter?

How to fix an iPod reboot loop

The classic (pre-Touch) iPods from Apple are pretty good portable jukeboxes, but they have a critical flaw in how they handle certain database problems; rather than try to fix the error, they just reboot immediately, getting stuck in a boot loop. I have seen this happen on several generation of iPod, including the 5G, the 6G/Classic, and several revisions of the iPod Nano.

There are a number of things that can cause this problem, such as the COMM (comment) field exceeding the iTunes hard limit of 254 characters, or due to invalid UTF-8 byte sequences in ID3 tags (which are pretty common in the wild since ID3’s encoding standard is a bit ad-hoc and nobody can even agree on what it’s supposed to be).

Sometimes you can find the culprit by exporting your iTunes library as XML and then running an XML validator on it – this will find the most egregious encoding issues – but often you simply have to search through your library to find the files which are causing your iPod to reboot constantly. Here is a simple procedure for that.

Read more...

Filling gaps in line art

Every digital artist knows the pain; you’re trying to do a quick flood-fill into some line art and then suddenly you’re playing everyone’s favorite game, “spot the pixel gap.” Well, as fun as this activity is, there is a shortcut you can use to fill the gaps so that you can get along with making your art! This approach works in most current graphics applications which support layers and selection modification operations; I use it in Photoshop.

Read more...

Monitor calibration

How to calibrate your monitor to the sRGB color space (more or less) without any special tools.

Note: This article was written way back in 2003, and things have changed quite a lot. The calibration charts are still useful for roughly calibrating TVs and projectors and the like, but there are better approaches to monitor calibration these days, and most decent monitors come pre-calibrated from the factory.

Also, these images only work correctly if they are displayed at a 1:1 pixel scale. Many combinations of newer monitors/operating systems/etc. — notably “high-DPI” or “Retina” displays — end up resampling images to display at a different pixel scale. This is fine for displaying most images, but these images will not work correctly when resampled. If you want to use these images for calibrating a display, please make sure they are displayed at 100% scale and that your monitor is set to a 1:1 pixel scale!

Nowadays my preferred method for calibrating a monitor is with a ColorMunki Smile. For a software-only approach on macOS you can try SuperCal, which is much more comprehensive than the built-in display calibrator.

Read more...