GithubHelp home page GithubHelp logo

casperschipper / cisp Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 1.0 265.83 MB

translates custom scheme-like syntax into chuck

Common Lisp 52.32% Python 27.41% ChucK 1.96% SuperCollider 1.44% Shell 0.01% Max 4.26% NewLisp 11.78% JavaScript 0.20% HTML 0.55% Csound 0.02% Roff 0.05%

cisp's Introduction

Cisp is a simple (scheme inspired) interpreter that translates "Cisp" code into ChucK code.

Cisp is my live coding tool that is specifically targeted at:

  1. Non-standard synthesis (the use of compositional techniques directly on generating waveforms).
  2. Algorithmic composition generating live Midi or OSC output.

video demo

[performance at Segmod event]

Requirements / Setup

Install Chuck, which has both the MiniAudicle and the ChucK command line (building from source no longer required). [ChucK Command Line]https://github.com/ccrma/chuck

Build my chugins:

  1. My chugins (specifically: Linseg, DelayC)
  2. make osx|windows|linux
  3. make install

Clone my tools: My chuck Tools

My live coding sessions are set up like this:

Cisp.py takes a scheme like input file (example.lisp), and translates it to a chuck file (output.ck), which is added to the chuck virtual machine (by Cisp). Output.ck is not in "vanilla" chuck, it is using my Chuck-Tools library and chugins (for non-standard synthesis).

You will need to start chuck in loop mode, with my chugins and tools loaded, something like this:

chuck --loop --chugin-path:yourChuginPath ~/pathToChuckTools/tools.ck

yourChuginPath is probably /usr/local/lib/chuck

Using sublime build script

To make coding faster, I use a build script wich runs the .lisp file into cisp.

Basic syntax

non-standard synthesis

(step-gen [amp] [number-of-samples])

  • white noise *
	(step-gen 
  		(rv -1 1) 
  		(st 1))
  • very fast sequencer
	(step-gen
  		(seq -1 1) // seq loops through a list ad infinitum -1 1 -1 1 -1 1 etc..
  		(seq 10 11 12 11 100 1100)) 
  • gendy like
	(fun amp
		(bounded-walk -1 1 (ch -0.01 0.01))) // bounded-walk min max step

	(fun tim
		(bounded-walk 1 100 (ch -1 1))) // this is time steps

	(step-gen
		(seq amp amp amp amp)
		(seq tim tim tim tim)) 
(t
	(seq 10 20 30)
	(ch 1 2 3 5))
	

easy bus

(~ casper (rv 1 100)) creates a bus

(~ casper) to read back the bus somewhere else (note, these are completely global)

define table

(# casper (fillf 32 0 128))

write to table

(~ foo (write casper (rv -1 1) (count 128))

The arguments for write are: table name, value generator, write index into the table.

which can be scheduled as (schedule (~ foo) (st 0.5)) // which means that foo is executed each 0.5 seconds

You can also use a more direct notation, for example:

(samp-schedule ARG1 ARG2)

evaluates its ARG1 stream each ARG2 samples.

(samp-schedule (write casper (rv -1 1) (count 128)) (st 1))

cisp's People

Contributors

casperschipper avatar

Stargazers

NCM avatar federico lopez avatar Andrew Prentice avatar

Watchers

James Cloos avatar  avatar

Forkers

ansahmadiba

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.