This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| synth.setFunction('josh', { type: 'src', inputs: [], glsl: ` | |
| float josh_circle(vec2 st, float cr, float cx, float cy) { | |
| float dx = cx-st.x, dy = cy-st.y; | |
| float z = cr*cr - dx*dx - dy*dy; | |
| return (z < 0.) ? 0. : sqrt(z)/cr; | |
| } | |
| vec4 josh(vec2 st){ | |
| float z = josh_circle(st, .35, .5, .5); | |
| z = z-josh_circle(st, .25, .5, .5)+josh_circle(st, 0.2, 0.5, 0.5)*0.75; | |
| for(int i = 0; i < 10; i+=1) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use std::collections::HashMap; | |
| use std::fmt; | |
| use std::io; | |
| use std::num::ParseFloatError; | |
| use std::rc::Rc; | |
| /* | |
| Types | |
| */ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| z = SimpleMIDIFile.read("/home/mauro/Downloads/General MIDIMan - Ageispolis.mid") | |
| ( | |
| x = { |smf, channel, track| | |
| var pending = IdentitySet.new, buf = MIDIRecBuf(\seq).absoluteOnsets_(true), | |
| events = smf.noteEvents(channel, track).sort { |a, b| | |
| if(a[1] == b[1]) { | |
| a[2] > b[2] // equal time, put noteOn first | |
| } { | |
| a[1] < b[1] // earlier time first | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Example of OSC control of Hydra video synth w/Orca programming language | |
| // by Yancy Way (echophon) | |
| // | |
| // https://github.com/hundredrabbits/Orca | |
| // https://github.com/ojack/hydra | |
| // https://github.com/ojack/hydra-examples | |
| // https://atom.io/packages/atom-hydra | |
| // | |
| // Prerequisites: Orca, Atom, Atom-hydra extension | |
| // |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include <time.h> // Robert Nystrom | |
| #include <stdio.h> // @munificentbob | |
| #include <stdlib.h> // for Ginny | |
| #define r return // 2008-2019 | |
| #define l(a, b, c, d) for (i y=a;y\ | |
| <b; y++) for (int x = c; x < d; x++) | |
| typedef int i;const i H=40;const i W | |
| =80;i m[40][80];i g(i x){r rand()%x; | |
| }void cave(i s){i w=g(10)+5;i h=g(6) | |
| +3;i t=g(W-w-2)+1;i u=g(H-h-2)+1;l(u |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Name | Party | State | Public Engagement | Press Releases | Bills Sponsored | Bills Cosponsored | Caucuses | Website | Total | Senator | 2020 Hopeful | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Whitehouse, Sheldon | D | RI | 30 | 7 | 7 | 7 | 10 | 10 | 71 | Whitehouse, Sheldon (D-RI) | No | |
| Schatz, Brian | D | HI | 24 | 5 | 14 | 8 | 4 | 10 | 65 | Schatz, Brian (D-HI) | No | |
| Markey, Ed | D | MA | 20 | 8 | 11 | 6 | 10 | 10 | 65 | Markey, Ed (D-MA) | No | |
| Sanders, Bernie | I | VT | 17 | 7 | 15 | 4 | 10 | 10 | 63 | Sanders, Bernie (I-VT) | Yes | |
| Boxer, Barbara | D | CA | 22 | 4 | 6 | 4 | 10 | 10 | 56 | Boxer, Barbara (D-CA) | No | |
| Cardin, Ben | D | MD | 20 | 6 | 0 | 1 | 10 | 10 | 47 | Cardin, Ben (D-MD) | No | |
| King, Angus | I | ME | 25 | 6 | 0 | 1 | 10 | 5 | 47 | King, Angus (I-ME) | No | |
| Cantwell, Maria | D | WA | 19 | 5 | 0 | 3 | 10 | 10 | 47 | Cantwell, Maria (D-WA) | No | |
| Menendez, Robert | D | NJ | 17 | 4 | 0 | 5 | 10 | 10 | 46 | Menendez, Robert (D-NJ) | No |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| This is based on the tips from, | |
| http://hamelot.io/visualization/using-ffmpeg-to-convert-a-set-of-images-into-a-video/ | |
| and adapted it to this line to export to HAP directly from a tif sequence, | |
| "ffmpeg -r 30 -f image2 -s 1920x1080 -i test%02d.tif -vcodec hap -pix_fmt rgba test.mov" | |
| (without quotes of course) | |
| - i is where you set the pattern for the image sequence naming, | |
| (where the %02d means that zeros will be padded until the length of the string is 2 i.e 01…20…30… and so on. If no padding is needed use something similar to pic%d.png or %d.png) | |
| -r is the framerate (fps) | |
| -s is the resolution |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| javascript: void (()=>{ | |
| let text = null; | |
| try { | |
| text = document | |
| .querySelector("ytd-transcript-renderer") | |
| .__data | |
| .data | |
| .body | |
| .transcriptBodyRenderer | |
| .cueGroups |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| FourteenBitCC { | |
| /* | |
| //Use Case: | |
| MIDIIn.connectAll; | |
| ~x = FourteenBitCC.new("x", 72, 104); | |
| ~x.func = {|val| ("x: "++val).postln}; | |
| //MPE Example with Sensel Morph | |
| MIDIIn.connectAll |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| WAYLAND_PROTOCOLS=/usr/share/wayland-protocols | |
| # wayland-scanner is a tool which generates C headers and rigging for Wayland | |
| # protocols, which are specified in XML. wlroots requires you to rig these up | |
| # to your build system yourself and provide them in the include path. | |
| xdg-shell-protocol.h: | |
| wayland-scanner server-header \ | |
| $(WAYLAND_PROTOCOLS)/stable/xdg-shell/xdg-shell.xml $@ | |
| xdg-shell-protocol.c: xdg-shell-protocol.h |