Starting the School Year

Today is my first official day of class attending the Advanced Programming program at Sheridan College. To commemorate this, I’ve reorganized my whole directory structure for this blog to be organized by year and month rather than sub topics. I’ve been finding the subtopic folders to be growing far to fast (particularly the dev folder) to keep posting all in one place. This way, my working directory is ever only so large for each month and I’m also relieved of the duty of figuring out which folder I should be making my post in....

September 5, 2023

Pianotypes Devlog 5

I finally put a start into replacing the current ribbon visualizer implementation with an HTML canvas drawn one. Why Bother? To reiterate, the current visualizers works by filling the screen with vertical divs that are positioned identically to the piano keys so each key essentially has a identically width column above it. I then spawn divs inside each lane that act as each of the ribbons. The extending animation works by settings each ribbon to the max size of the lane and running a scaleY transition from 0 to 1 to mimic the ribbon growing from nothing....

September 4, 2023

Shader Layering

I’ve been working on putting together a layered parallax scene as per https://www.youtube.com/watch?v=XaiYKkxvrFM. I’m a good ways there writing most of the code on my own. I’ve made series of repeating trees across a sloping hill and it’s time for me to start layering them on top with a for loop. In the tutorial, he wrote all of the shape functions to return vec4 so they include the alpha channel in addition to the colours....

August 26, 2023

Which Way Does the UV Go?

While I was working on writing simple shape patterns in GLSL, I ended up with an interesting conundrum. I fell into the pattern of creating shapes by closing in each side of the shape with a smoothstep in the following form. smoothstep(-blur, +blur, uv.x); In this case, this creates a vertical edge where the left side is 0 and the right side is 1. I then do the same thing for the rest of the side of the shape, until I enclose it so that all values inside the shape are 1 and everywhere else remains 0....

August 25, 2023

Pianotypes Devlog 4

Not too much to report. I had the realization that I can pause the scheduled notes by suspending the AudioContext since they depend on the context’s timer. It’d be pretty easy to add pause functionality. The only caveat is that if I pause the AudioContext, than all sound from the piano is also paused. Perhaps I could code in a notice to resume the timer given the user inputs a key press but I don’t want to resume the context on every key press....

August 25, 2023

Reviving Tabby Sort

A couple years ago I made a little extension for chrome to organize and sort tabs by url domains. It was really quick and crudely designed and since I wasn’t even a Chrome user, I didn’t think too much about improving it. Fast forward to now, I decided to do exactly that. Looking at old code Actually the code was mostly better than I expected, other than some variable naming and redundant lines, I didn’t see much need to rewrite it....

August 23, 2023

Pianotypes Devlog 3

Today I spent some time working on getting the instructions dialogues up. I originally planned on creating a secondary overlay window that pops up given a trigger. Very similar to how to the toast notifications work but instead with a much larger area. The only problem with that is I wanted a clean way to inject custom html into the dialogue box depending on who triggers it. In the case of the toast notification I just pass it a string which is fine given it’s only suppose to be a sure notifier anyways....

August 23, 2023

Pianotypes Devlog 2

I’m a bit more than late for a second devlog but I figured there’s no better thing to call this. I originally made this blog for the purposes of short and sweet devlogs but my recent posts have been bit larger than what I originally intended. I’m hoping with this log to bring that focus back down to just that. Since my previous post, I’ve done a lot of fine tuning of the UI and functionality of the site....

August 21, 2023

Revisting Pianotypes

I recently finished a course in deep learning and wanted to took a look at a few ways I could apply my knowledge to. The idea the came to me was to create an ai music generation model and feed it into my old pianotypes app. Simple right! It’s all broken So I booted up my old, dusty, untouched, forgotten, delapidated, abused, ramshackled, repository, and lo and behold, I can’t get it to run....

August 18, 2023

Svelte Reactive Classes

I’ve been working on migrating my old PianoTypes project over from Vue to Svelte. So far the syntax has been much cleaner to use and has been an overall a great experience. My first and primary pain point thus far has been implementing a global reactive state for the piano. The Problem In Vue, it’s possible to add a reactive wrapper to any object. In my case, I had created a class containing all of the piano data and property methods so all I had to do was wrap this class in the wrapper and state is maintained across all instances of my piano class....

August 12, 2023