Skip to content

Commit

Permalink
update package.json and document
Browse files Browse the repository at this point in the history
  • Loading branch information
trquoccuong committed Jan 24, 2017
1 parent ec3bf06 commit f951924
Show file tree
Hide file tree
Showing 2 changed files with 55 additions and 2 deletions.
45 changes: 44 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,29 @@
# Node wave
Render audio waveform like SoundCloud on backend
> Render audio waveform like SoundCloud on backend
## Install

```
$ npm install node-wave
```

## How to use

Use with express:

```javascript

var Waveform = require('node-waveform')
var fs = require('fs')

Waveform('< mp3 link >', options, function(err , buffer) {
fs.writeFileSync('out.png', buffer)
})
```

## Requirement
This module base on `web-audio-api` and `canvas` modules.

## Attribute

| Option | Desciption | Default |
Expand All @@ -19,3 +40,25 @@ Render audio waveform like SoundCloud on backend
| padding | Top and bottom padding | 10 |
| baselineWidth | baseline width | 1 |
| baselineColor | baseline color | white |

### The MIT License (MIT)

Copyright (c) <2017> Tran Quoc Cuong

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
12 changes: 11 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,23 @@
{
"name": "node-wave",
"version": "0.0.2",
"version": "0.0.3",
"description": "Render waveform image like SoundCloud",
"main": "index.js",
"scripts": {
"lint": "standard"
},
"author": "Tran Quoc Cuong <[email protected]>",
"license": "MIT",
"keywords": [
"SoundCloud waveform",
"backend waveform",
"waveform",
"audio waveform"
],
"repository": {
"type": "git",
"url": "git+https://github.com/trquoccuong/node-wave.git"
},
"dependencies": {
"canvas": "^1.6.2",
"web-audio-api": "^0.2.2"
Expand Down

0 comments on commit f951924

Please sign in to comment.