Method and system of audio synthesis capable of reducing CPU load

A method and system of audio synthesis capable of reducing CPU load is disclosed, which establishes a parameter look-up table in a read-only memory (ROM). When a computer system synthesizes audio signals, the required coefficients are obtained from the table, which relatively reduces the amount of parameter transferred between an audio chip and a central processing unit (CPU). Thus, the load of the CPU can be reduced.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to a method and system of audio synthesis and, more particularly, to a method and system of audio synthesis capable of reducing CPU load.

2. Description of Related Art

In current audio syntheses, a synthetic audio is generated by performing frequency modulation based on huge mathematical calculation by an audio synthesizer after communicating a lot of audio coefficients required by the synthesis with corresponding hardware, and output to a speaker for playing.

FIG. 1is a block diagram of a typical audio synthesizer80. The audio synthesizer80can be divided into three circuit-based sections: a modulation circuit10(FIG. 2), a controller40, and an output circuit50. The modulation circuit10can be implemented in many ways, for example, U.S. Pat. No. 4,813,326 granted to Hirano et al. for a “Method and apparatus for synthesizing music tones with high harmonic content”, as shown inFIG. 2, is provided to generate desired audio synthesis based on a predetermined modulation. The predetermined modulation can be frequency modulation (FM) or amplitude modulation (AM). An example is given in FM. For representing a modulating wave (assume that the timbre is piano) as an equation A(t)*SIN(ωct+I(t)*SIN ωmt), it only requires inputting modulation parameters to the modulation circuit10. Thus, the timbre's wave is produced. Further, the modulation parameters includes modulating wave phase angle data ωmt, modulation wave data I(t), carrier phase angle data ωct, amplitude coefficient signal A(t) and tone color selection signal TC. Accordingly, the circuit10finally generates modulating wave shown inFIG. 3, which is the timbre of piano. However, the modulating wave is periodically repeated to present only a corresponding timbre. Different sounds of a timbre are generated only when the modulating wave is further input to the controller40to generate an audio wave.

FIG. 4is a schematic diagram of control parameters for an exemplary ‘DO’ scale ofFIG. 3.FIG. 5shows an audio wave outputted by the controller40for the control parameters ofFIG. 4. The control parameters include four kinds: attack, decay, sustain and release. The attack parameter amplifies the amplitude of the modulating wave. The decay parameter weakens the amplitude of the modulating wave. The sustain parameter nearly keeps on the amplitude of the modulating wave. The release parameter fades away the amplitude. When the controller40receives the modulating wave and applies the parameters to the modulating wave, as shown inFIG. 5, the audio wave of ‘DO’ scale for the timbre of piano is outputted.

The audio wave requires further generating left channel synthetic audio L and right channel synthetic audio R through the output circuit50. The output circuit50receives the audio wave and modulates it based on characteristic parameters, to output the audio L and R. The characteristic parameters include mute parameter Mute, volume control parameter VoCol, channel control parameter ChCol, left selection parameter L-Col and right selection parameter R-Col. The parameter Mute determines whether or not each audio wave is outputted. The parameter VoCol adjusts current volume of an audio wave. The parameter ChCol determines if the audio wave is output. The parameters L-Col and R-Col control an output ratio of left to right channels of the audio wave. Finally, the left audio L and another left audio L′ generated by output circuits50of another channels are added, and similarly the right audio R and another right audio R′ are added, thus generating and outputting the synthetic audio.

FIG. 6is a block diagram of a typical computer system performing audio synthesis. In the computer system, the cited modulation, control and characteristic parameters are outputted by a CPU32to an audio chip30(implemented on a sound card). The audio chip30has an internal audio synthesizer80for FM processing. The audio synthesized by the chip30is outputted to a speaker34for appropriate sound output. This is shown in a flowchart ofFIG. 7. As shown inFIG. 7, modulation parameter, control parameter and property parameter are outputted from a CPU32to an audio chip30(step S70). In step S72, the audio chip30generates and outputs a synthetic audio based on the cited parameters. In step S74, the speaker34sounds based on the synthetic audio.

As cited, for audio synthesis, the CPU32requires transmitting the modulation parameter, the control parameter and the characteristic parameter to the audio chip30. Thus, huge data transmission between the devices32and30is required, and the performance of the CPU32is reduced because the reading, calculating and outputting operations for parameters largely add the load of the CPU32. Therefore, it is desirable to provide an improved method to mitigate and/or obviate the aforementioned problems.

SUMMARY OF THE INVENTION

An object of the present invention is to provide a method of audio synthesis, which can reduce central processing unit (CPU) load on audio synthesis.

Another object of the present invention is to provide a method of audio synthesis, which can reduce required data communication between a CPU and an audio chip.

A further object of the present invention is to provide a system of audio synthesis, which can reduce CPU load on audio synthesis.

Another further object of the present invention is to provide a system of audio synthesis, which can reduce required data communication between a central processing unit (CPU) and an audio chip.

In accordance with one aspect of the invention, there is provided a method of audio synthesis, which applies frequency modulation for processing audio to output a synthetic audio. The method includes: establishing a parameter look-up table, outputting a wave parameter and a property parameter from a microprocessor to an audio processor, extracting a modulation parameter and a control parameter from the parameter look-up table based on the wave parameter by the audio processor, and applying frequency modulation to generate the synthetic audio by the audio processor based on the modulation parameter, the control parameter and the property parameter.

In accordance with another aspect of the invention, there is provided a system of audio synthesis, which applies frequency modulation for processing audio to output a synthetic audio. The system includes: a microprocessor to output a wave parameter and a property parameter, a memory to store a parameter look-up table of which records a modulation parameter and control parameter corresponding to the wave parameter, and an audio processor to input the wave parameter and the property parameter for reading the modulation parameter and the control parameter from the parameter look-up table based on the wave parameter and further performing frequency modulation to produce the synthetic audio based on the modulation parameter, the control parameter, and the property parameter.

DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENT

FIGS. 8 and 9respectively illustrate a computer system and corresponding audio synthesis in accordance with the present invention, wherein devices with the same or similar functions have the same number.

As shown, a parameter look-up table is first established in a read-only memory (ROM)36. The content of the table is given, but not limited to, in a simple illustration ofFIG. 10. As shown inFIG. 10, the table has wave parameters and the corresponding modulation parameters and control parameters. Each wave parameter can be divided into a timbre parameter and a sound parameter. The timbre parameter presents a tone color such as a piano, corresponding to a modulation parameter. The sound parameter presents a scale such as ‘DO’ scale, corresponding to a control parameter. The modulation parameter and the control parameter respectively have the same functions as in the prior art. That is, the modulation parameter is used to generate a modulating wave and the control parameter is used to generate an audio wave. In addition, the table can also be stored in a flash memory, a PROM or the like.

The method of the present invention performs audio synthesis by applying FM technique, which includes, as shown inFIG. 9, the following steps.

In step S94, a synthetic audio is generated and outputted by the audio chip30based on the modulation parameter, the control parameter and the characteristic parameter. The audio chip30synthesizes audio using FM technique. As cited, the audio chip30uses the modulation parameter, the control parameter and the characteristic parameter to generate the synthetic audio and output the synthetic audio to the speaker34.

In step S96, the speaker34produces sound based on the synthetic audio.

In this invention, data transmission between the CPU32and the audio chip30requires only wave parameters and characteristic parameters because modulation parameters and control parameters are from the parameter look-up table (based on corresponding wave parameters), so that the data transmission amount is less than that in the prior art (in this example, 7 parameters are removed). Therefore, the load of the CPU32is greatly reduced.

Furthermore, since modulation parameters and control parameters are stored in the ROM36, as compared to storing them in registers of the CPU32or the audio chip34, system resource is saved and audio synthesis system costs less.