Skip to content

Instantly share code, notes, and snippets.

View now-its-dark's full-sized avatar
🔍
always searching & ⭐️'ing interesting projects related to sound and MIDI

now_its_dark now-its-dark

🔍
always searching & ⭐️'ing interesting projects related to sound and MIDI
View GitHub Profile
@ansarizafar
ansarizafar / macos-app-icon.md
Created October 16, 2023 04:04 — forked from jamieweavis/macos-app-icon.md
How to create an .icns macOS app icon
@alexanderameye
alexanderameye / SceneSwitcherToolbarOverlay.cs
Last active December 1, 2023 22:37
A small scene switcher utility for Unity
using System.Collections.Generic;
using System.IO;
using UnityEditor;
using UnityEditor.Overlays;
using UnityEditor.SceneManagement;
using UnityEditor.Toolbars;
using UnityEngine;
using UnityEngine.SceneManagement;
using UnityEngine.UIElements;
@innocuo
innocuo / AddUV
Last active February 25, 2022 07:32
How to create a rigged humanoid character using Clayxels and Puppet3D.
using System.Collections;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;
public class AddUV : MonoBehaviour
{
public Mesh mesh;
void Awake()
@dvf
dvf / change-codec.md
Last active November 14, 2024 08:27
Enable High Quality mode on your headphones (Updated for macOS Catalina)

If you're using a high-end bluetooth headset on your Macbook Pro it's likely your mac is using an audio codec which favors battery efficiency over high quality. This results in a drastic degradation of sound, the SBC codec is the likely culprit, read more about it here.

Find out what codec you're using

  1. Play a song on your headphones
  2. Option (⌥) click the Bluetooth button at the top of your screen Inspect the Bluetooth Coded
  3. If you're using AAC or aptX, you can stop here—those are the highest quality codecs.

Change your codec to AAC or aptX

@loveemu
loveemu / gax_info.md
Last active April 16, 2024 03:36
Shin'en GAX Sound Engine (GBA) Specification / Research Note

Shin'en GAX Sound Engine (GBA) Specification

The research is based on GAX Engine V3. Information about V2 can be found at the end of the document.

FYI: GaXM is a tool that can analyze GAX data. You may find more information there.

FYI: You can find my IDA FLIRT signature for GAX V3 here. https://github.com/loveemu/ida-sig

FYI: Gaxtapper: Diagnostic tool / Automated GSF ripper for GAX Sound Engine.

@tablatronix
tablatronix / scrolltext.cpp
Last active May 18, 2023 12:20
dirty scroll text for adafruit gfx
void scrollString(String str) {
int yoff = 1;
display.clearDisplay();
display.setTextWrap(false); // we don't wrap text so it scrolls nicely
display.setTextSize(2);
display.setRotation(0);
int charWidth = 12; // textsize 2 @todo auto calculate charwidth from font
int pxwidth = (str.length()*charWidth)+32; // @todo get actual string pixel length, add support to gfx if needed
for (int32_t x=charWidth; x>=-pxwidth; x--) {
@chz16
chz16 / current tracklist
Last active November 9, 2024 10:34
stream jukebox
Last updated: 2024-11-09 02:34
5438 songs, 11:21:29:01 total time
A.III. - Rapid Progress
A5 - Flower Dance
A5Tours - EPISODE from "DECADE SUITE for ORCHESTRA"
A-Train 6 - Another Moon (Rural: Night)
A-Train 6 - Morning Wind (Residential: Morning)
A-Train 6 - On Line (Industrial: Daytime)
A-Train 6 - Python (Industrial: Night)
@simondotm
simondotm / SN76489 tuning.md
Last active January 14, 2021 02:25
Retuning SN76489 chip tune music written for Sega Master System on a BBC Micro

We use Deflemask to author SN76489 chip music, for which support is aimed mainly at NTSC Sega Master System. We export these tunes as VGMs from Deflemask and then to get them working on a BBC Micro we have to do some shenanigans because the BBC version of the SN76489 has two key differences from the SMS:

  1. It is clocked at 4Mhz not 3.58Mhz
  2. It has a 15-bit linear-feedback shift register (LFSR) for noise channel generation (the SMS version has 16-bits).

Because the squarewave output of the sound chip is driven by its clockspeed, to transpose frequencies from NTSC to 4Mhz we have to adjust every pitch value sent to the chip registers. This is done mathematically by converting the NTSC pitch register value to Hz and then calculating the equivalent pitch register value on a 4Mhz clocked chip to deliver the same Hz frequency.

That bit is easy (ish).

The tricky bit is when musicians use the tuned periodic noise function on the chip to create basslines. In this scenario channel 2 pitch controls the pitch of t

@edro15
edro15 / ForceUSBtoTTY.md
Last active September 1, 2024 11:00
[How To] Force a specific USB device to a certain TTY

Scenario:

  • multiple USB devices plugged via hub to a host (Linux OS based),
  • multiple services/programs interacting with TTY running on top (e.g. GPSd)

Problem:

At boot TTY are randomly assigned to devices causing depending services/programs instabilities. They could indeed fail to start because of different TTY configurations.

Solution: