Commit Graph

37 Commits

Author SHA1 Message Date
Thomas Wouters 7e47402264 Spelling fixes supplied by Rob W. W. Hooft. All these are fixes in either
comments, docstrings or error messages. I fixed two minor things in
test_winreg.py ("didn't" -> "Didn't" and "Didnt" -> "Didn't").

There is a minor style issue involved: Guido seems to have preferred English
grammar (behaviour, honour) in a couple places. This patch changes that to
American, which is the more prominent style in the source. I prefer English
myself, so if English is preferred, I'd be happy to supply a patch myself ;)
2000-07-16 12:04:32 +00:00
Guido van Rossum 2663c13c5b Sjoerd Mullender:
The (relatively) new chunk module uses seek, not setpos.  One instance
of the call still needed to be fixed.
2000-03-07 15:19:31 +00:00
Guido van Rossum 4acc25bd39 Mass patch by Ka-Ping Yee:
1. Comments at the beginning of the module, before
       functions, and before classes have been turned
       into docstrings.

    2. Tabs are normalized to four spaces.

Also, removed the "remove" function from dircmp.py, which reimplements
list.remove() (it must have been very old).
2000-02-02 15:10:15 +00:00
Guido van Rossum 3601e88cb3 Sjoerd Mullender writes:
"""
Extended chunk so that it can also handle formats that are almost
according to EA IFF 85.  In particular, added options to handle
little-endian and to handle formats that include the header size in
the chunk size value.

Fixed a bug where the header size was included in the chunk size, which
it isn't according to EA IFF 85.

Added a new method getsize() to get the size of the chunk (excluding
header).

Fixed chunk documentation (TIFF doesn't look like it uses chunks).
Converted wave to use chunk.  Wave uses EA IFF 85 chunks except that
it uses little-endian encoding of integer data.

Removed __del__ methods from aifc and wave since I got an
AttributeError there upon exit.
"""
1999-08-26 15:50:43 +00:00
Fred Drake 4316135a44 Make the mode parameter to open() default in the same way as for wave.open(). 1999-06-22 21:23:23 +00:00
Guido van Rossum 8ea7bb8e78 Patch/new code by Sjoerd Mullender:
Separate the Chunk class out of the aifc module into a new "chunk" module.
1999-06-09 13:32:28 +00:00
Guido van Rossum 5c071fab8f The _comp_data() function never worked, it contained a reference to
undefined 'nframes'.  Should be self._nframes.  (Andrew Dalke & kjpylint)
1999-05-03 18:02:44 +00:00
Guido van Rossum 2c2f731daf [Sjoerd Mullender]
Don't use CL module since all constants are now in cl.
1998-08-07 15:28:23 +00:00
Guido van Rossum bb189dbcb0 Small corrections to comments that were cloned from aifc; moreover
the description of setparams() was wrong.

wave.py: Include the tag of an unknown format in the exception.
1998-04-23 21:40:02 +00:00
Guido van Rossum afe3ebfa5c Use newer struct, which handles unsigned long right 1997-01-11 19:21:09 +00:00
Guido van Rossum 36bb181cdf Rewrote _{read,write}_{short,long} to use the newly revamped struct
module.  (Small problem: struct.pack() won't deal with the Python long
ints returned by struct.unpack() for the 'L' format.  Worked around
that for now.)
1996-12-31 05:57:34 +00:00
Guido van Rossum d7abed3b14 Get rid of access statement 1996-08-20 20:40:07 +00:00
Guido van Rossum 3e7a697c55 temporarily disabled the access statements 1995-08-10 19:23:37 +00:00
Sjoerd Mullender ebea896e20 Ignore empty markers. 1994-10-03 10:21:06 +00:00
Guido van Rossum e174c1500f audiodev.py: Mac port.
Audio_mac.py: Mac specific class for audiodev.py.
aifc.py: open files for reading/writing in binary mode ('rb', 'wb').
1994-09-16 10:55:53 +00:00
Sjoerd Mullender 1f05754640 Added support for ADPCM compression. 1994-09-06 16:17:51 +00:00
Guido van Rossum b6775db241 Merge alpha100 branch back to main trunk 1994-08-01 11:34:53 +00:00
Guido van Rossum 3db6ebcc3f Use __builtin__ instead of builtin 1994-01-28 09:59:35 +00:00
Sjoerd Mullender ffe9490d79 aifc.py: framerate should be an int.
sunau.py: should convert number of frames correctly to number of bytes
	when reading.
1994-01-28 09:56:05 +00:00
Sjoerd Mullender e03bf9c497 Removed now useless convert functions. 1994-01-06 17:00:04 +00:00
Sjoerd Mullender 49c2df16f5 Removed silly dependence on AL module. 1994-01-06 16:35:34 +00:00
Sjoerd Mullender 2a45141741 aifc.py, sunau.py: Adapted comments; added access statements.
SUNAUDIODEV.py: Added some constants for Solaris.
1993-12-20 09:36:01 +00:00
Guido van Rossum 6ed9df2641 * aifc.py (Aifc_write): fix bogus reference to filename 1993-12-17 16:43:43 +00:00
Guido van Rossum 7bc817d5ba * Mass change: get rid of all init() methods, in favor of __init__()
constructors.  There is no backward compatibility.  Not everything has
  been tested.
* aiff.{py,doc}: deleted in favor of aifc.py (which contains its docs as
  comments)
1993-12-17 15:25:27 +00:00
Sjoerd Mullender feaa7d296f Don't close the file. 1993-12-16 13:56:34 +00:00
Sjoerd Mullender 43bf0bc857 aifc.py: added missing tell() method in AIFC write class;
use audioop module as backup for cl module when reading or
	 writing u-law compressed files.
sunau.py: interface with the same methods as aifc for Sun and NeXT
	  audio files
1993-12-13 11:42:39 +00:00
Sjoerd Mullender 4150ede53c Fixed dealing with faulty COMM chunks. 1993-08-26 14:12:07 +00:00
Guido van Rossum 9b3bc71598 * aifc.py: don't die on invalid MARK chunk
* calendar.py: remove stuff now built in time; some cleanup and
  generalization in the calendar printing
* cmd.py: use __init__.
* tzparse.py: This module is no longer necessary -- use builtin time instead!
1993-06-20 21:02:22 +00:00
Guido van Rossum 52fc1f607e * calendar.py: minor cleanups
* ftplib.py: support __init__ with optional host, port args
* aifc.py: ensure header is written on close even when no data is written
1993-06-17 12:38:10 +00:00
Guido van Rossum 17ed1ae163 * toaiff.py: import whatsound instead of sndhdr
* sndhdr.py: renamed to whatsound.py; use new aifc module for AIFF/AIFC
* ftplib.py: added close() (closes without sending QUIT command)
* aifc.py: documented close()
1993-06-01 13:21:04 +00:00
Guido van Rossum d316607732 * ftplib.py: added abort() command (sends oob data).
* Several modules: change "class C(): ..." to "class C: ...".
* flp.py: support for frozen forms.
* Added string.find() which is like index but returns -1 if not found
1993-05-24 14:16:22 +00:00
Sjoerd Mullender 4ab6ff80ff AWARE.py: New file with definitions for Aware Inc.'s compression
algorithms in cl module.
aifc.py: fixed a small bug.
1993-02-05 13:43:44 +00:00
Sjoerd Mullender 3a997279d5 CL.py, clmodule.c: Adapted to new CL library. Lots of new methods.
aifc.py: Several small improvements.  Use new methods from CL module.
1993-02-04 16:43:28 +00:00
Sjoerd Mullender 8d733a00f0 added kludge for buggy soundfiler from SGI; when reading 0 frames,
just set file pointer correctly instead of returning the complete
file.
1993-01-29 12:01:00 +00:00
Sjoerd Mullender 93f0740073 Fixed a bug where the library inadvertently skipped over the sound
data.
Pass an extra parameter to the compression library.
1993-01-26 09:24:37 +00:00
Sjoerd Mullender 7564a641e5 Found and fixed a few bugs in the handling of audio files with MARKs. 1993-01-22 14:26:28 +00:00
Sjoerd Mullender eeabe7eb35 New module aifc to read and write AIFF-C and AIFF files. See
(extensive) comments in the file for usage.
1993-01-22 12:53:11 +00:00