Method for fast compressing and decompressing music data and system for executing the same
AssigneeVTech Telecommunications Limited
InventorHan Chang
Life of this patent
Estimating the term…
Abstract
MIDI compression and decompression methods that reduce the size of a standard MIDI file and maintains information to play the MIDI music. The exemplary method of the invention makes use of the high correlation and repetitions between a look-ahead MIDI event and previous set of MIDI events. An adjustable size Lempel-Ziv-like MIDI Event Search Window (MESW) is created during the compression and decompression process to allow searching of matched events or event elements in previous window size of MIDI events. Further reduction of the MIDI events can be made by discarding the matched events in the event search window. Therefore, with 4-bit of MIDI event search window, the number of MIDI events stored in the window can be more than 16.
Claims52
A method for compressing music data files, comprising:
- extracting music data events from a music data file;
- generating a music data event search window, wherein the music data event search window comprises a plurality of previous events and is used for searching for at least one previous event that matches with an event of a look-ahead window;
- and wherein each event comprises a number of event elements;
- searching for one previous event in the music data event search window that has optimal matching with the event of the look-ahead window;
- and
- storing an index of the optimal matching event in a compressed codeword.
The method of claim 10, wherein the compressed codeword further comprises a part B, wherein if any one of the event elements is not the same as the corresponding one in the event with optimal matching in the music event search window, the different element is packed into the part B of the codeword.
A method for decompressing a compressed music data file, comprising:
- extracting music data events from the compressed music data file;
- generating a music event search window, wherein the music event search window comprises a plurality of previous events and is used for searching for at least one previous event that matches with an event of a look-ahead window;
- and wherein each event comprises a number of event elements;
- obtaining an index of a previous event in the music event search window that has optimal matching with the event of the look-ahead window, the optical matching event comprising a codeword;
- checking the codeword of the optimal matching event;
- if a respective bit of the codeword of the optimal matching event is set to “HIGH”, an event element corresponding to the respective bit is read from the music event search window;
- and
- if a respective bit of the codeword of the optimal matching event is not set to “HIGH”, an element corresponding to the respective bit is read from the codeword.
A system for compressing music data files, comprising:
- a reader for reading a music data file;
- an extractor for extracting music events from the music file;
- a compressor for compressing the music events into a compressed music data file;
- and
- a search window generator for generating a music event search window, wherein the music event search window is generated during a compression process performed by the compressor,
- wherein the music event search window comprises a plurality of previous events and is used by the compressor for searching events matched with a look-ahead window event, and
- wherein each event comprises a number of event elements, and
- wherein when a previous event in the music event search window that has optimal matching with the event of the look-ahead window is found, an index of the optimal matching event is stored in a compressed codeword.
A system for decompressing music data files, comprising:
- a reader for reading the music data files, wherein the music data files are compressed music data;
- a decompressor for extracting music events from the compressed music data and decompressing the music events;
- a search window generator for generating a music event search window during a decompression process performed by the decompressor;
- and
- a music reproduction module for receiving decompressed music data from the decompressor and playing music songs corresponding to the decompressed music data,
- wherein the music event search window comprises a plurality of previous events and is used for searching an event that is optimal matched with a look-ahead window event;
- and wherein each event comprises a number of event elements;
- wherein the decompressor obtains an index of the optimal matched event in the music event search window, wherein the optimal matched event of the music event search window comprises a codeword, and
- wherein the decompressor decompresses the compressed music data according to the index.
The system of claim 48, wherein the Velocity and the Instrument elements are considered as a unit and correspond to one bit of the codeword.
Dependencies are inferred from the claim text.