Skip to content

Instantly share code, notes, and snippets.

View qguv's full-sized avatar
vibing

Quint Guvernator qguv

vibing
View GitHub Profile
@NeuroWinter
NeuroWinter / ffmpeg cheatsheet for glitching
Last active March 19, 2025 17:29
ffmpeg cheatsheet for glitching
FFMPEG '-i', file, '-c:v', 'libopenjpeg', "jpeg2000\\" + name + ".jp2"\
Convert image to jpeg2000
ffmpeg -i in.png -c:v libopenjpeg out.jp2
Hex Edit out.jp2
ffmpeg -i in.jp2 -c:v png out.png
General Edit
ffmpeg -i input.avi -c:v mpeg2video -g 999 -q:v 1 output.avi
*edit in avidemux/whatever*
#include "color.h"
#include "utilities.h"
#include <math.h>
/*
* Algorithm adapted from https://gist.github.com/hdznrrd/656996. Uses a little libmath.
* */
void color_HSV2RGB(struct color_ColorHSV const *hsv, struct color_ColorRGB *rgb) {
int i;
@evadne
evadne / gist:440558b18228ca657ef22b465793a0c3
Last active June 21, 2024 01:57
Using SchemaCrawler on PostgreSQL databases
@qoomon
qoomon / conventional-commits-cheatsheet.md
Last active April 25, 2025 12:55
Conventional Commits Cheatsheet

Conventional Commit Messages starline

See how a minor change to your commit message style can make a difference.

Tip

Take a look at git-conventional-commits , a CLI util to ensure these conventions, determine version and generate changelogs

Commit Message Formats

Default

@CMCDragonkai
CMCDragonkai / Makefile
Last active February 8, 2021 23:50
Runtime Conditionals in Makefiles
# this phony target shows how to use a conditional within a recipe
# this conditional is executed at "run-time"
# rather than at "build-time" which is when the Makefile `ifeq` are evaluated
# notice how everything in the conditional must be joined up as one line
test_conditional:
@echo 'NESTED CONDITIONAL'
[ "$$(echo 1)" -lt 2 ] && { \
echo 'oh no'; \
exit 1; \
} || { \
@muodov
muodov / empty-hash-assignment.md
Last active February 24, 2022 17:42
Location and links behaviour when setting empty hash
Command (executed in this order) Chrome 72 Firefox 65 Safari 12.0.3 IE11
window.location.hash "" "" "" ""
window.location.href "https://example.com/" "http://example.com/" "http://example.com/" "http://example.com/"
window.location.hash = '#' "#" "#" "#" "#"
window.location.href "https://example.com/" "http://example.com/#" "http://example.com/" "http://example.com/#"
window.location.hash "" "" "" "#"
window.location.hash = '#1' "#1" "#1" "#1" "#1"
window.location.href "https://example.com/#1" "http://example.com/#1" "http://example.com/#1"
:xdg-support: https://wiki.archlinux.org/index.php/XDG_Base_Directory
:xdg-spec: https://specifications.freedesktop.org/basedir-spec/basedir-spec-latest.html
:fhs: https://en.wikipedia.org/wiki/Filesystem_Hierarchy_Standard
:madness: http://pub.gajendra.net/2012/09/dotfiles
:litter: https://www.reddit.com/r/linux/comments/971m0z/im_tired_of_folders_littering_my_home_directory/
:systemd: https://www.freedesktop.org/wiki/Software/systemd/
:systemd-fhs: https://www.freedesktop.org/software/systemd/man/file-hierarchy.html
:systemd-fhs-bin: https://www.freedesktop.org/software/systemd/man/file-hierarchy.html#~/.local/bin/
:toc: macro
@muodov
muodov / cheatsheet.js
Last active April 24, 2024 10:05
JS prototype inheritance cheatsheet
// normal function x
function x() {
this.a = 1;
}
// First of all, the term "prototype" is confusing because it can refer to 2 different things.
// There is an object's prototype, which is another object used to look up missing properties.
// But there is also an actual `prototype` property on Function and class objects, which is NOT a prototype for that function object!
// Instead, it serves a very specific purpose: that object becomes a prototype of all instances returned when that function is used as a constructor:
(new x()).__proto__ === x.prototype
@charlieroberts
charlieroberts / equinox_marchingjs.md
Created March 21, 2020 00:38
Equinox Marching.js Tutorial

Marching.js

This demo tutorial will mainly focus on getting started using marching.js playground, a browser-based tool for live coding with ray marchers. I’ve added some extra information at the beginning on the demoscene, which was an important source of inspiration for marching.js. Here’s a recent article on the demoscene: Here’s some Sanity, literally, and Amiga Dreams as read for you in French - CDM Create Digital Music

Demoscene

The demoscene is a culture that began in the 1980s, when hackers created “cracktros” for the software they cracked… these were short audiovisual demos that showed off the skills of the hacker and often contained shoutouts to their other hackers / friends.

Over time, some hackers/artists became more interested in the audiovisual demos than they were in pirating software, and this became the birth of the “demoscene”, where programmers would create audiovisual “demos” that

#include <stdint.h>
#include <Arduino.h>
#include <FastLED.h>
#define DATA_PIN_LED 27
static CRGB leds[25];
void setup(void)