RSSAmplifier

Blog

Joseph Petitti's Blog

This blog is a collection of random opinions and ramblings on a variety of topics including programming, software, films, and the great outdoors.

josephpetitti.comRSS feed ↗51 posts

Latest posts

Heat wave hiking in the Gila Wilderness

Last week I flew out to New Mexico to spend 4 days backpacking in America's oldest wilderness area. It would be my first backpacking trip outside the Northeastern US, and my first time hiking in desert and canyon terrain. Unfortunately it also happened to be right in the middle of a heat wave and drought, producing temperatures over 100 degrees and ensuring water would be scarce.

2025 in review

I look back on everything I did in 2025.

Backpacking Mount Isolation in the rain

Last weekend I headed out into one of the most remote parts of the White Mountain National Forest to climb Mount Isolation via some less-used trails. On the two-day trip I experienced pouring rain, difficult trails, a bear encounter, and lots of true isolation.

Backpacking the Adirondacks in April

Early Spring can mean a variety of conditions in the mountains, and I got to experience exactly that when I went on an overnight backpacking trip last weekend. In just 18 miles round-trip I summitted four 4,000-footers and experienced steep scrambles, roaring waterfalls, deep snow, hot sun, and cold rain.

2024 in review

I look back on everything I did in 2024.

Solving Advent of Code the lazy way

Advent of Code is an annual set of programming puzzles that I've written about previously. I've participated in AoC for several years, but 2023 was only the second time I've completed a full year as it came out. All my solutions are written in Haskell, but I had to use some 'hacky' techniques to get some of the answers.

Backpacking the southern Presidentials

This past weekend I took a day off work to get in some solo backpacking in New Hampshire's Presidential Range. It ended up being the most scenic, and the most strenuous hiking trip I've ever done.

Gunbuster references in Nadia

It's no secret that Studio Gainax likes to hide references to other anime in their shows, with varying degrees of subtlety. But perhaps the most interesting are the parallels between their first OVA series, Gunbuster, and their first TV series Fushigi no Umi no Nadia.

Assembling jigsaw puzzles for Advent of Code

While waiting for this year's Advent of Code to start I've been going back to complete some of the challenges I never got around to finishing in previous years. One of these is Day 20, 2020.

I watched all of Gundam

Over the past 14 months I watched every TV episode, OVA, and movie in the Mobile Suit Gundam franchise in production order. I've seen plenty of mecha anime before, but this was the first time I had seen anything from the biggest real robot franchise in the world. And I have to say I was quite impressed. Gundam has its reputation for a reason, with incredible mechanical designs, compelling…

Winter is the best season for hiking

A lot of people seem to be afraid of hiking in the winter, but it's actually my favorite time of the year to get outdoors. Winter weather can make hiking a lot easier and more enjoyable, at least here in the north east.

Participating in my first game jam

This past weekend I participated my first game jam—a competition in which individuals or teams rush to design and create a new game within a time limit, in this case 48 hours. The jam in question was the annual GMTK game jam, one of the biggest in the world. I worked with four of my friends (three other programmers and an artist) from 2 PM Friday through 2 PM Sunday to create SCHLORP, finishing…

Detecting stealthy Android malware

A brief outline of my goals and approach to my thesis project, using Android UI context to enable the detection of stealthy malware.

Object-oriented functions in JavaScript

As you may know, JavaScript is a bit of an indecisive language. It doesn't fully commit to any one paradigm, instead having features from object-oriented, procedural, and functional languages. Its mish-mash of philosophies can make it confusing to learn, but once in a while it manages to surprise me with some clever design decision. For example, the fact that all functions are objects that can be…

How accessibility undermines Android's security

As smartphones become more powerful and ubiquitous the incentives for malicious actors to hijack them continue to grow. Gaining access to a target's phone can yield bank account passwords, 2-factor authentication codes, contacts information, and all kinds of other juicy data. Google is constantly trying to protect their platform while still giving app developers freedom to make what they want, and…

How CSS can leak your browser history

Despite the huge effort that goes into making browsers secure, there are still a few ways they can expose your private data to attackers if you aren't careful. Most involve some kind of complex fingerprinting using JavaScript, but there is a way to trick users into giving up their browsing history using only CSS: with the :visited pseudo-class.

Hiking Cannon Mountain

I had last Friday off from work on account of Independence Day weekend, so I decided to spend the day hiking one of New Hampshire's most famous 4000-footers. Cannon Mountain is part of the Kinsman Ridge in the White Mountains of New Hampshire, and made for a challenging but rewarding day hike.

Lupin III: The First brings the franchise to 3D—and it works

It's nice to see that Japan is getting better at 3D animation. For too long we've had to put up with horrible 3DCG posing as traditional animation by using ugly flat shading and animating on twos, like Graphinica's Expelled from Paradise or Polygon Pictures' Knights of Sidonia, Blame! and Godzilla films. This style always ends up looking stiff and janky, and far worse than the 2D animation it's…

Training a computer to play Jotto

I've always liked word games like Scattergories and Scrabble, they tend to be a good mix of creativity and strategy. When I had to decide on a final project for a graduate-level artificial intelligence class last term it was a perfect opportunity to make a program that played a word game. But Scattegories and Scrabble are both trivial for machines to play—their decision trees are narrow enough…

The corrupting influence of television in Network

Sidney Lumet's 1976 classic Network ends with a blunt summary of its plot: "This was the story of Howard Beale, the first known instance of a man who was killed because he had lousy ratings." While the life and death of network news anchorman Howard Beale (played by Peter Finch) is certainly an important part of the film, it's telling that Beale's actor is third billed in what is ostensibly his…

Finally getting some use out of my trackball with Spin Rhythm XD

I've had a trackball mouse for a couple of years now, and while I like it for most casual browsing it is definitely not good for games. You just can't match the speed and precision of a real mouse when it comes to first person games that require aiming. For pointer-based games like Factorio or Cities: Skylines a trackball is about the same as a regular mouse. But I may have just found the one game…

Enlightenment through repetition in Groundhog Day

In this post, I examine some of the philosophical meaning behind the film Groundhog Day, and argue for an existentialist reading of the film.

Half-Life: Alyx is what VR games should be

Thirteen years after Episode 2, Valve finally returns to the Half-Life universe with a VR-exclusive prequel titled Half-Life: Alyx. You play as resistance member Alyx Vance in between the events of the first and second game, attempting to fight the brutal alien combine enslaving Earth. The game is designed for Valve's new Index headset, but will work with any PC VR headset on the market.…

Presenting at PAX East

For the past few months I've been workin on a procedurally-generated top-down twinstick shooter game for the web, as I've written about previously. Although I've just been developing it when my friends in our spare time, WPI selected it to be shown off at their booth at PAX East. The WPI booth showcases student-made games as a way of promoting the school's Interactive Media and Game Design (IMGD)…

Ray marching in a grid-aligned world

In many games or other graphical applications, there is often a need to draw a ray from a point until it hits an object. This is the fundamental operation of ray tracing, an essential technique in computer graphics: drawing reflecting and refracting light rays from a light source to the camera. Unfortunately, this process is quite computationally expensive, which is why most real-time graphics…

Making a 2D game with no art assets

In my last blog post I wrote about the game I'm working on with two of my friends. It now officially has a name, Afterlight Caves, and we're going to be showing it off at the WPI booth at PAX East, February 27 through March 1 2020. In this post I'll talk about how three computer science majors with no artistic ability between them were able to make a decent looking game.

Designing an extensible power up system

Continuing to work on a project I started last term in AI for Interactive Media and Games, I designed a flexible power up system in which power ups synergize with each other automatically.

How to install Koel on Fedora 30

Koel is a cool web application built on PHP and Vue.js for streaming your music collection over the internet. Basically it's like having your own personal Spotify, except it's free and open source. Since I couldn't find any detailed guide for installing it and all its dependencies on a Fedora server, I decided to write my own.

My favorite media of 2019

It's the start of a brand new year! And what better way to boldly step into 2020 than by talking about a bunch of stuff that happened in 2019. Here I'll list my favorite movie, album, anime, manga, western TV show, and video game from 2019. Consider all of these strong recommendations.

Some trivia I've noticed about FLCL

FLCL, a classic six-episode OVA series from Studio Gainax and director Kazuya Tsurumaki (known for his work on Evangelion), is well known for being kind of confusing. Its blistering fast pace, wild animation style, and total disdain for holding the viewer's hand makes it difficult to follow on a first viewing. But after watching the series maybe a dozen times, I finally think I mostly get what…

The Dilbert TV series is way better than it should be

Everyone's read Dilbert in the daily newspaper or seen it taped to a boss or professor's door, but few know about the animated TV series based on it that ran for 30 episodes in 1999-2000. I had the good fortune of stumbling across this cartoon recently, and it turned out to be way better than I expected, given the lack of acclaim I hear for it.

Using AI to make and play Mario Levels

This term I decided to branch out from my usual computer science courseload and try out a class from a very similar department: Interactive Media and Game Development. To that end I took a class called 'Artificial Intelligence in Interactive Media and Games,' which turned out to be a lot of fun. (It's also nice that it counts for CS credit). One of the projects I did for the class was to use…

Making a simple text-based game in C++

For the WPI course IMGD 3000 - Technical Game Development 1, I worked over the course of seven weeks to make a fully-featured game engine in C++. It uses simple text-based ASCII graphics and handles events, input, sounds, sprites, collisions, and other basic features. As a final project, to show off the features of this engine, I worked with a partner to make a fun game using it. The game, called…

The C ??!??! operator

The C programming language has a bit of a reputation for having weird syntax. The #define directive, pointer declaration, and uncommon array indexing methods can all make it hard to understand what's going on in a C program. Still, some of C's weirdness manages to surprise me even after using it for a few years. For example, what do you think this expression does: !x ??!??! y();

How to take beautiful notes with Pandoc

Taking notes by hand is so old fashioned. You can't version control or backup paper, it's hard to search through, and a small mistake can force you to cross out or erase a whole line of text. But taking good notes on a computer has a host of problems of its own. Fiddling with formatting and typesetting is time-consuming, and it's hard to include mathematical notation, images, and other elements…

Quines in JavaScript

Because programmers have nothing better to do with their free time, they often amuse themselves by finding clever solutions to difficult logic problems. One such problem is called a "quine," and it goes something like this: write the shortest possible program the prints its own source code.

Leap seconds are actually a terrible idea

About once every four years the powers that be slide an extra day into the calendar between February 28th and March 1st, to ensure that our timekeeping system stays in sync with the actual rotation of the Earth. We call this a leap year, and the current system of deciding when to add these extra days has remained unchanged for the past 437 years. However, recently Coordinated Universal Time has…

How to climb Mount Fuji

Last week, after spending a day at Fuji-Q Highland, I set out with a group of three other students to climb to the highest point in Japan, the summit of Mount Fuji.

Fuji-Q Highland: proof that you can make a theme park out of anything

This weekend I traveled across Japan to climb Mount Fuji, the highest mountain in the country and one of the most beautiful and recognizable mountains in the world. But before starting the climb, three fellow students and I spent a night in Fujiyoshida, Yamanashi to go to Fuji-Q Highland, a Mount Fuji-themed amusement park.

Japanese rhythm games: my new addiction

I've written previously about my love of Audica and Beat Saber but those aren't the only rhythm games I play. I used to be pretty good at Guitar Hero, and I've recently gotten into Stepmania. However, studying in Japan has introduced me to the magical world of Japanese arcade rhythm games, a new class of game that is threatening to consume all my money.

Thoughts on Japan

As I mentioned in my last blog post, I'm spending three months in Japan to work on my Major Qualifying Project, a graduation requirement of WPI. Now that I've been here for almost four weeks I can talk a bit about what Japan is like, and my experiences here.

Four days in Seoul

After an exhausting 44-hour journey involving planes, trains, and automobiles, I arrived in Seoul, South Korea this past Sunday. I'll be spending the next three months in Kyoto, Japan working on my Major Qualifying Project for WPI, but before that I wanted to spend some time seeing another city I had never been to before.

My top 10 favorite research papers

Some of the most amusing or intriguing studies, reports, and scientific papers I've stumbled across

How to toggle styles on click in pure CSS

There are plenty of times in front-end web development where you want to toggle between two different CSS rules when an element is clicked. Maybe you want a custom menu to drop down, or a set of tabs to show different information. Either way, you could do this with some simple JavaScript. Or, you could use a CSS hack to do it without any scripts at all.

Adventures in system administration - Part 2

Part 2 of an ongoing series about setting up a network of virtual servers. In this post, we configure Foreman and and a virtual network to allow unattended creation and provisioning of virtual hosts.

How to change Wordpress URLs in the database

Wordpress has a nasty habit of redirecting you to what it thinks the correct domain name is, and this value is hidden in multiple obscure places in the database. If you've ever had to migrate a Wordpress site from one domain name to another you've probably encountered this problem. Fortunately, there is a relatively painless way to reconfigure Wordpress to use the new domain name from inside its…

Adventures in system administration - Part 1

Part 1 of an ongoing guide documenting my process of setting up a virtual network of servers to host various services for me

Meet the Cloud Office: the workplace of the future

Nobody wants to deal with the hassle of maintaining hardware. It's expensive, difficult, and time consuming to set up your own networked infrastructure, and many companies just aren't dealing with it any more. But as more and more of our computer systems are transitioned into the cloud, we could end up in a world where the office as we know it is obsolete.

Exploring the Shinichirō Watanabe Cinematic Universe

Director Shinichirō Watanabe is well known for his science fiction and fantasy anime worlds filled with memorable characters, creative technology, and wonderous adventures. It appears that three of his critically acclaimed series, Cowboy Bebop, Space Dandy, and Carole & Tuesday take place in the same universe, but the truth is much more complicated than that.

Audica and Beat Saber: how to do early access right and wrong

Very rarely do you get such a perfect case study handed to you as with Audica and Beat Saber. Both are early access VR rhythm games on Steam and Oculus, both involve hitting red and blue notes with the correctly-colored weapon carried in each of you hands, and both are damn good fun. Let's take a look at how Audica takes advantage of early access to push content to early adopters while Beat Saber…