This file contains 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
/* | |
Basic idea of string parsing comes from Marc Sabat and Wolfgang Von Schweinitz's "Helmholtz-Ellis" set of accidentals. These accidentals take all uninflected ("normal") accidentals like naturals, sharps and flats as 3-limit Pythatgorean alterations. Further alterations include small arrows (for the 5-limit 81/80), Tartini-inspired 7s (for 7-limit 64/63), and quarter-tones for the unidecimal alteration 33/32. | |
I've found that while SuperCollider is great at creating scales and tunings, it's tough to really sequence a full pattern without cycling through a bunch of different tunings--it still seems conceptually tied to MIDI in that sense. So in order to sequence extended just intonation, it's important to have an easy, legible way of reading these pitches. | |
I've transported my Lilypond definitions to SuperCollider. "aflatUfDs" (the test String) is a Pythagorean a-flat, up a five-limit 81/80, down a seven-limit 63/64. This creates the interval 14/15, or a perfect fourth above the septimal tri-tone against |
This file contains 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
max_iterations.times do |iter| | |
begin | |
# puts "Iteration #{iter}" | |
# puts "Now #{current_cost} away at #{current_point.to_a}" | |
print "\rIteration #{iter}: #{current_cost} away at #{current_point.to_a}" | |
cost = NMath.sqrt(((tuneable_data[true,1,true,true] - goal_vector) ** 2).sum(0)) | |
# If this is the first run-through, keep the interval index the same | |
if initial_run | |
interval_index = 0 |
This file contains 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
x = {|gate=1| Out.ar([0,1], EnvGen.ar(Env.asr(0.1, 1, 0.1), gate, doneAction: 2) * Splay.ar({[SinOsc.ar(80, 0, 0.05)] ++ Resonz.ar(WhiteNoise.ar(1), ExpRand(310,330), 0.01)}.dup(20) ++ {SinOsc.ar(ExpRand(200,280), 0, 0.01)}.dup(20) ++ [SinOsc.ar(84, 0, 0.1)] ));}.play; |
This file contains 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
require 'sinatra' | |
require 'sinatra/reloader' if development? | |
require 'digest/md5' | |
require 'haml' | |
# enable :sessions | |
use Rack::Session::Cookie, :key => 'rack.session', :path => '/', :secret => 'change_me' | |
auth_dir = "./auth" |
This file contains 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
( | |
SynthDef(\cloudin, { | |
arg freq = 440, env_input = 0; | |
var signal, envs; | |
// env_input is the number of the control-rate channel with the env signal | |
signal = Saw.ar(400 * 1) * In.kr(env_input); | |
Out.ar(0, signal); | |
}).add; | |
) |
This file contains 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
UnitTest { | |
var <assertionCount = 0, <successCount = 0, <failureCount = 0; | |
test { | |
arg name, func; | |
("Testing: " ++ name).postln; | |
func.value(this); | |
("Assertions: " ++ assertionCount ++ "\t Successes: " ++ successCount ++ "\t Failures: " ++ failureCount).postln; | |
} |
This file contains 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
[331] pry(main)> out | |
=> | |
{ layers: | |
[ | |
[0, 1] | |
[0, 0] | |
] | |
[ | |
[1, 0] |
This file contains 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 <stdio.h> | |
#include <iostream> | |
#include <fstream> | |
#include <Accelerate/Accelerate.h> | |
void print_matrix(const int row_count, const int col_count, __CLPK_real* matrix) { | |
for(int i = 0; i < row_count; i++) { | |
for(int j = 0; j < col_count; j++) { | |
printf("% 7.3f", matrix[i*row_count + j]); |
This file contains 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
function! g:SendRight(...) range | |
if a:0 > 0 | |
let start = a:1 | |
let end = a:1 | |
else | |
let start = a:firstline | |
let end = a:lastline | |
endif | |
for line in getline(start, end) |
This file contains 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
extern crate piston; | |
extern crate piston_window; | |
extern crate graphics; | |
extern crate gfx_graphics; | |
use piston::input::*; | |
use piston::window::{Window as Win, AdvancedWindow, WindowSettings}; | |
use piston_window::{PistonWindow as Window}; | |
fn main() { |
OlderNewer