2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

SuperCollider+CommonLispで曲を作る環境を揃えてみた。

Last updated at Posted at 2020-01-19

はじめに

CommonLispで作曲したいのでそれができる環境を揃えた。

SonicPiやTidalCycles等、現状だと選択肢は存在するものの、自分がCommonLisp(Lisp族、Scheme等も含むよ)を推す理由は以下の通り。
(自分がLisp触って1ヶ月程度なので理由についてはあとで整理するかも)

  • 関数型言語の参照透過性+副作用の関係で途中修正がプログラマにとって容易
  • リストと譜面の相性はすごくいい(リスト内のデータも場合によっては途中で関数化するのも他と同じルールで書ける)
  • 処理の途中で関数の再定義が可能なため、展開を広げやすい

どちらかというとTidalCyclesはHaskellなので似たような性質があると思います。

あとは個人的な理由ですが、プログラミング始めたときからずっと手続き型言語をお腹いっぱい使っていたので、そこから離れたく視点でプログラム書いてみたくなった、というのもあります。

環境

Windows10
Roswell経由でSBCL1.4.14をインストール済み
SuperColliderは3.10.3

Roswell
https://github.com/roswell/roswell

準備

下記モジュールを使います。
CommonLispによるSuperColliderクライアントだそうです。

操作

  • SuperColliderをインストールする
  • Roswellからros installを実行、Lispの実行環境を構築する
  • コマンドラインから「ros run」を実行、REPL環境を起動する
  • 上記URLの「Usage:」に従い、命令を入力していく
    (ちなみに上記のモジュールはquicklispでダウンロードしてくることが可能です)

あとはシンセサイザーの定義と鳴らす命令を書くだけという。

ソフトウェアの準備もそれほどしなくて済むのでありがたい。

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?