Skip to content

Commit 4edb07c

Browse files
committed
Updated documentation for 1.1
1 parent de8bcbe commit 4edb07c

1 file changed

Lines changed: 46 additions & 13 deletions

File tree

README.md

Lines changed: 46 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,45 @@
11
python-wavefile
22
===============
33

4-
'wavefile' python module to read and write audio files.
5-
It is a pythonic wrapper to the sndfile library featuring:
6-
* Attribute access to format, channels, length, sample rate...
7-
* Numpy interface using in place arrays (optimal for block processing)
8-
* Works as context manager
9-
* Different objects for reading and writing (no modes, consistent interface)
10-
* Shortened constants accessing for formats and the like
11-
* Matlab like whole file interface (not recommended but convenient)
4+
Pythonic libsndfile wrapper to read and write audio files.
5+
6+
Features:
7+
8+
* Attribute access for format, channels, length, sample rate...
9+
* Numpy interface using in-place arrays (optimal for block processing)
10+
* Real multichannel (not just mono/stereo)
11+
* Separate classes for reading and writing, so that available operations are consistent with the mode.
12+
* Writer and reader objects work as context managers for [RAII idiom](http://en.wikipedia.org/wiki/Resource_Acquisition_Is_Initialization)
13+
* Shortened constant names for formats (Using scopes instead of prefixes)
14+
* Matlab like whole-file interface (not recommended in production code but quite convenient for quick scripting)
15+
* No module compilation required (wraps the dll using ctypes)
16+
* Works both for Python3 >= 3.3 and Python2 >= 2.6
1217

1318
You can find the latest version at:
1419
https://github.com/vokimon/python-wavefile
1520

1621
TODO:
22+
1723
* Handling properly different physical numpy layouts: use a view, assert or reshape
18-
* sndfile command interface
24+
* Exposing sndfile command API
1925
* Seeking
2026
* Use file name extension to deduce main format, if not specified
21-
* Use main format to deduce subformat if not specified
22-
* Providing strings for formats
27+
* Use main format to deduce subformat, if not specified
28+
* Separate Formats scope into Formats, Subformats and Endianess
29+
* Expose descriptive strings for formats
30+
* Handling properly unicode in text strings (now considers them UTF-8, which is not always true)
2331

2432
Installation
2533
------------
2634

35+
### Using PyPi
36+
37+
```bash
38+
pypi-install wavefile
39+
```
40+
41+
### From sources
42+
2743
A setup.py script is provided so the common procedure for
2844
installing python packages in you platfrom will work.
2945
For example in Debian/Ubuntu systems:
@@ -185,13 +201,30 @@ So this is a summary of what I found, just in case it is useful to anyone.
185201

186202
- libsndfilectypes
187203
- http://code.google.com/p/pyzic/wiki/LibSndFilectypes
188-
- ctypes based wrapper
189-
- No compilation required
204+
- ctypes based wrapper: no compilation required
190205
- numpy supported
191206
- Windows only setup (fixable)
192207
- Long access to constants
193208
- Not inplace read (creates an array every time)
194209

195210

211+
python-wavefile reuses most of the libsndfilectypes ctypes wrapper,
212+
as not requiring module compilation was seen as a good point.
213+
A pythonic layer was added on the top of it.
214+
215+
216+
217+
Version history
218+
---------------
219+
220+
### 1.1
221+
222+
- Python 3 support
223+
- Support for unicode filenames
224+
225+
### 1.0
226+
227+
- First version
228+
196229

197230

0 commit comments

Comments
 (0)