We will be talking about primitive mathematical models for the path of objects on ballistic trajectories: There will be ramblings, sample code, and a simple Unity WebGL demo. Definition of ballistic What exactly is something that’s moving ballistically? ballistic bəˈlɪstɪk ) ADJECTIVE Denoting or relating to the flight of projectiles after power has been cut off, moving under their own momentum and …
Category Archives: Unity WebGL Demo
TechnoOrganic Crustacean Timelapse
Still going through my old 2020 stuff and found some old modeling and rigging footage that I’ve time-lapsed. The WebGL build of the demo was originally this blog’s first post to test if Unity WebGLs apps play nice with WordPress. That post got removed, but since the files are still on the server, I’ve cut …
IK Solver From Scratch In Unity
In this post, we will cover a really simple (CCD) implementation of inverse kinematics. We’ll structure this with the typical format of waxing poetic, then some code samples and an embedded Unity WebGL demo. What is Inverse Kinematics? I’m assuming you’re here because you’re already familiar with the subject. But if not, IK is basically …
Streaming Microphone Audio To Unity WebGL
This is going to cover the steps I used to get the microphone working for the granulation demo.The GitHub repo for that demo can be found here. NOTE: Before reading further, please note that this only covers recording the microphone from the browser’s Unity WebGL app. It does NOT cover streaming audio playback or internet …
Continue reading “Streaming Microphone Audio To Unity WebGL”
Transferring Binary Files Between Unity and Browser
In a recent post, I had a font parsing Unity WebGL application receive binary data, either by hitting an “Upload” button that would bring up a file selection dialog for upload or by dragging and dropping a file onto the app in the browser. These True Type Font (*.TFF) files are binary – so how …
Continue reading “Transferring Binary Files Between Unity and Browser”
Notes on Audio Granulation
Retiming audio with granulation – and a simple sample in a Unity WebGL example. If we had data for an audio clip and asked someone how to change the playback speed, we’d get a common answer for both, “change the rate we process and play the audio” or “resample the audio data to go through …
Calculating an Even Width For a Line Strip
The operation goes by several names: expanding, dilating, inflating, etc. Basically, given a series of ordered points, how do we calculate a path that’s the line strip, but with an even width? A caveat, this is not going to be an optimized solution, but given the basic intuition I hope to bring, and the resulting …
Continue reading “Calculating an Even Width For a Line Strip”
Font Viewer
A Unity WebGL tool to browse the internals of font files. It supports OTF and TTF files. Either hit the “Load” button or drag and drop a file into the Unity player. Fullscreen The font parsing library and path boolean library are still a work in progress so there are quite a few edge cases …
Viewing Debug Log Messages In a Unity WebGL App
TL;DR When debugging Unity WebGL apps, use the web browser’s developer tools. For Chrome browsers press the F12 key – for other browsers see below in the browser section. Unity Debug.Log*() calls redirect to the browser’s dev tools console. With that being said, if you have the spare time and want a more elaborate deep-dive …
Continue reading “Viewing Debug Log Messages In a Unity WebGL App”
Completely Suspending Unity WebGL Apps
I’ve previously posted about pausing an application in Unity. What if we want to pause it completely? Unfortunately, I haven’t been able to find an official way – and the fact that there’s a pause function that doesn’t actually pause (it throttles) leads me to assume there might not actually be an official way to …