Giter VIP home page Giter VIP logo

madsyn's Introduction

Madsyn uses genetic programming to evolve weird noise. You give it a sound formula, and it generates random mutations of that formula and plays each of the original and the mutations for a fixed length of time. Then you try again with the mutation you like best.

This software is in the public domain.

Usage

Madsyn takes a formula on the standard input and outputs the audio on the standard output, in raw CD-audio format (44.1 KHz, stereo, 16-bit little-endian linear PCM). This is really convenient for me because I can pipe its output into a sound-playing program like this:

madsyn <formula | wavplay -sr

You can also redirect the output into a raw file to open in an audio editor:

madsyn <formula >output.raw

The full set of options is: madsyn [-f] [-a amp] [-l len_in_ms] [-m num_mutations]

-f: Instead of raw CD-audio format, output samples as 32-bit floats. This lets you avoid clipping and manipulate the sound using, for example, the effects in my Synth software.

-a amp: Set the output amplitude, as a ratio to the default. So "-a 0.5" will cut the output amplitude in half, making it about 6 dB softer.

-l len_in_ms: Set the length in milliseconds for which each formula (the original and the mutations) will be played. Default is 5000.

-m num_mutations: The number of mutations to generate; default 3. Set to 0 if you only want to hear the input formula.

Tips

Start with a simple formula, like the one in sine.madsyn (time 1000.0 * sin), and eventually evolve something complicated out of it.

The output can get extremely loud, so watch out for that.

Portability

It should be fairly portable, and is expected to compile and work on BSD, Windows, and Linux, on little- and big-endian CPUs. Nearly 20% of the code is portability goop needed because Windows and Linux aren't as awesome as BSD.

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.