1.0.13 • Published 10 months ago

code-to-music v1.0.13

Weekly downloads
-
License
ISC
Repository
github
Last release
10 months ago

Code To Music

As simple as posible api for produce melody on JS

Installation

Install my-project with npm

  npm install code-to-music

Usage/Examples

import { Note, produceMelody } from "code-to-music";

const greenTreeMelody: Note[] = [
  { pitch: "E4", duration: 4 },
  { pitch: "C#4", duration: 8 },
  { pitch: "C#4", duration: 8 },
  { pitch: "E4", duration: 4 },
  { pitch: "C#4", duration: 8 },
  { pitch: "C#4", duration: 8 },
  { pitch: "E4", duration: 8 },
  { pitch: "D4", duration: 8 },
  { pitch: "C#4", duration: 8 },
  { pitch: "B3", duration: 8 },
  { pitch: "A3", duration: 2 },
  { pitch: "F#4", duration: 4 },
  { pitch: "A4", duration: 8 },
  { pitch: "F#4", duration: 8 },
  { pitch: "E4", duration: 4 },
  { pitch: "C#4", duration: 8 },
  { pitch: "C#4", duration: 8 },
  { pitch: "E4", duration: 8 },
  { pitch: "D4", duration: 8 },
  { pitch: "C#4", duration: 8 },
  { pitch: "B3", duration: 8 },
  { pitch: "A3", duration: 2 },
];

produceMelody(greenTreeMelody, 120);
1.0.11

10 months ago

1.0.10

10 months ago

1.0.13

10 months ago

1.0.12

10 months ago

1.0.9

10 months ago

1.0.8

10 months ago

1.0.7

10 months ago

1.0.6

10 months ago

1.0.5

11 months ago

1.0.4

11 months ago

1.0.3

11 months ago

1.0.2

11 months ago

1.0.1

11 months ago

1.0.0

11 months ago