Perlinized Hexagons

In my last post, Hexagons, I talked a bit about how cool hexagons are, and gave one method of creating a hex grid. I also used this image as a header: This was a bit of a tease, as I didn’t show how to create such an image. But I promised I’d come back around and give some code for it, so here we go. First, some refactoring As I’m sure most of you guessed, this image uses Perlin noise, but you could use any other function to get different textures. Check out my articles on flow fields (parts one

Continue reading

Hexagons

I know what you’re thinking. I’m thinking it too. So let’s stop tiptoeing around the subject and just say it out loud: Hexagons are freaking cool. Oh… you weren’t thinking that? Oops. My bad. I just assumed. Must be just me. So let me state my case on why hexagons are so damn neat. First, let’s get some definitions out of the way. A hexagon is a six-sided polygon. And just to be clear, the hexagon I’m talking about is the regular, convex polygon type of hexagon. Which is to say that all of its sides are the same length

Continue reading

2018 in Review

Here were are again… At the rate I’m going here, this blog will just be a collection of annual years in review. Anyway, an interesting year. For most of my programming career, I’ve had my job and then my personal projects. This past year drew to a close, the day job took a lot more of my focus. In fact, for the last 2-3 months at least, I haven’t really had any big personal projects. Work has been taking most of my attention. That’s not a bad thing. I’ve taken on a new role, really a whole new career path

Continue reading

tinpig 1.4.0 and sales pitch

For the past few weeks I’ve been putting a lot of work into an app called “tinpig“. It’s a tool for creating projects out of custom templates. I’ve described it in a previous post and the readme file details how to use it in depth, so I’m not going to go to much into that here. This past weekend I got tinpig to version 1.4.0 and I think it’s pretty stable and feature complete in terms of what I envisioned for it. At this point, I’m mainly thinking about fleshing out some of the templates that can be used with

Continue reading

Introducing “tinpig”

Years ago, I was a big fan of Sublime Text as an editor. It’s a great general purpose editor. There was one thing I missed though. Prior to that, I had mostly worked in dedicated, language/platform IDEs. These always had a “new project” functionality. They knew how to set up a new project in the language they were dedicated to. Because Sublime is a general purpose editor, it couldn’t really supply that functionality, because every type of project is different. So, I wrote a plugin called STProjectMaker, now, just ProjectMaker. This allowed you to create a template for whatever language/platform

Continue reading

Introducing bitlib-rs for Rust and Cairo

This article builds off my previous article, Intro to Cairo Graphics in Rust. In that, I briefly described how to install Rust and the Cairo graphics library and set up a Rust project using the cairo-rs bindings. With that article, and a bit of dedicated research on your own, you should have been able to start coding some drawings using the Rust programming language. In this article, I’m going to build on what I described there, and introduce my own library, bitlib-rs, that adds a bunch of new functionality on top of Cairo. I used to do a lot of

Continue reading

My Resolution Guidelines

So here’s the obligatory New Year’s Resolution post. I’m not going to tell you what my resolutions are, or what yours should be, but I have been mulling over some guiding principles for quite a while. These aren’t resolutions, per se. But they are guideposts I try to keep in mind personally when thinking about my resolutions, or in fact, whenever I’m taking any action. So here you go, my four principles. These are all in the form of “X is greater than Y”. In each case, this does not mean that X is holy and Y is evil. It

Continue reading

2017 in Review

It’s that time of year when we look back to see how things have gone in the last year, what we accomplished, how well we stuck to our goals, any major changes – good or bad, and start making plans for the next year. All arbitrarily based on a calendar system someone made up centuries ago, but so be it. If there’s no natural origin point, make one up. 2017 was a year of massive change for me. I changed companies once and changed jobs twice. And to a large degree, I actually changed careers once. I abandoned one coding

Continue reading

Intro to Cairo Graphics in Rust

In the past few weeks, I’ve been itching to learn some new stuff. Those who know me even just a little bit know that “new stuff” is generally going include “new ways of creating graphics and/or animations”. And so it does this time. I’ve been creating graphics in HTML5 Canvas for quite a few years now, and that’s cool. But there are a few pain points with its workflow: 1. It sometimes seems silly to pipe everything through the browser all the time. I’d like to just be able to run a program and have it create a file and

Continue reading

Flow Fields, Part II

In Flow Fields, Part I, we covered what a flow field is and looked at a few different formulas to create them. And we rendered flow fields in a various ways. We even animated particles being influenced by fields. In this article we’ll cover a couple more ways to generate flow fields and some new ways to render them. As I said in the first part, the possibilities are endless. I’m just pointing you in a few directions to get started. Perlin Noise Using simple math and minimal trigonometry gave us some pretty interesting patterns, but they wound up being

Continue reading