JP5246473B2 - Musical sound generator and musical sound generation processing program - Google Patents

Musical sound generator and musical sound generation processing program Download PDF

Info

Publication number
JP5246473B2
JP5246473B2 JP2008025860A JP2008025860A JP5246473B2 JP 5246473 B2 JP5246473 B2 JP 5246473B2 JP 2008025860 A JP2008025860 A JP 2008025860A JP 2008025860 A JP2008025860 A JP 2008025860A JP 5246473 B2 JP5246473 B2 JP 5246473B2
Authority
JP
Japan
Prior art keywords
waveform
mode
sound
value
sounding
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
JP2008025860A
Other languages
Japanese (ja)
Other versions
JP2009186698A (en
Inventor
博毅 佐藤
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Casio Computer Co Ltd
Original Assignee
Casio Computer Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Casio Computer Co Ltd filed Critical Casio Computer Co Ltd
Priority to JP2008025860A priority Critical patent/JP5246473B2/en
Publication of JP2009186698A publication Critical patent/JP2009186698A/en
Application granted granted Critical
Publication of JP5246473B2 publication Critical patent/JP5246473B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Electrophonic Musical Instruments (AREA)

Description

本発明は、管楽器や弦楽器を実際に演奏しているような不自然さの無いリトリガ奏法を実現する楽音発生装置および楽音発生処理プログラムに関する。   The present invention relates to a musical sound generating apparatus and a musical sound generating processing program for realizing a retriggering method without unnaturalness when actually playing a wind instrument or a stringed musical instrument.

従来より、単音のみしか発音しないようにするモノモード(ソロ機能)を備えた楽音発生装置が知られている。モノモードでは、複数の鍵が同時に押鍵された場合、それら押鍵の内から所定の優先順位に従って選択される1つの鍵に発音を割り当てる。このため、発音中に新たな押鍵があると、その発音中の音を消音させて新たな押鍵音を発生させるか、あるいは発音中の音を押鍵された鍵の音高に変更する、いわゆるレガート奏法となる。また、ある鍵を離鍵した時に、他に押鍵中の鍵が複数存在する場合には、押鍵されている複数の鍵の中から優先鍵(例えば押鍵されている鍵の内で最も音高の高い鍵)を選択し、選択した優先鍵の音を再発音する、いわゆるリトリガ発音となる。なお、モノモード(ソロ機能)においてレガート奏法やリトリガ発音を具現する楽音発生装置については、例えば特許文献1に開示されている。   2. Description of the Related Art Conventionally, a musical sound generating device having a mono mode (solo function) that generates only a single sound is known. In the mono mode, when a plurality of keys are pressed at the same time, a sound is assigned to one key selected according to a predetermined priority from among the pressed keys. For this reason, if there is a new key press during sound generation, the current sound is muted and a new key press sound is generated, or the sound being generated is changed to the pitch of the key pressed. This is a so-called legato playing method. In addition, when a key is released and there are multiple other keys being pressed, a priority key (for example, the highest key among the pressed keys is selected). A key with a high pitch) is selected, and the sound of the selected priority key is re-sound, that is, so-called retrigger sounding. Note that a musical sound generating device that implements legato performance or retrigger sounding in mono mode (solo function) is disclosed in, for example, Patent Document 1.

特開2001−125572号公報JP 2001-125572 A

ところで、上述したリトリガ発音は、あるポジションの指を離した時に、残っている指の押さえ方で別の音程の音を発生する奏法、すなわち自然楽器における管楽器や弦楽器のリトリガ奏法をシミュレートするものと捉えることができる。実際、持続音を発音する管楽器では、比較的音量変化の無い滑らかな音程変化となり、一方、減衰音を発音する弦楽器であるギターの場合には、再発音の音量を大きくするために弦から指を離す時にプリングオフと呼ばれる奏法、つまり弦を弾きながら離す操作が多用される。プリングオフ奏法で再発音される音は、周知のピッキング音のようなノイズ成分を含まないものの、弦を引っ張ってからリリースすることから、ある程度のアタック感を備えた音となることが知られている。 By the way, the above-mentioned retrigger sounding simulates a rendition method that generates a sound with a different pitch by pressing the remaining finger when a finger at a certain position is released, that is, a retrigger method for natural or wind instruments. Can be considered. In fact, a wind instrument that produces sustained sound has a smooth pitch change with relatively little volume change, while a guitar that is a stringed instrument that produces attenuated sound has a finger pointing from the string to increase the re-sounding volume. A performance technique called pulling off, that is, an operation of releasing a string while playing it, is often used. The sound re-produced by the pull-off technique does not contain noise components like the well-known picking sound, but since it is released after pulling on the strings, it is known that the sound has a certain degree of attack. Yes.

さて一方、近年の楽音発生装置は波形メモリ読み出し方式で構成されることが多い。周知のように、波形メモリ読み出し方式では、発音域を幾つかの鍵域に分割し、分割した各鍵域毎のサンプル波形(原波形データ)を用意しておき、発音指示された鍵域のサンプル波形(原波形データ)を読み出して楽音形成する。したがって、上述したリトリガ発音時に、リトリガ発音される音とそれ以前に発音していた音とが同じ鍵域ならば、同じサンプル波形をそのまま使用できるが、リトリガ発音される音とそれ以前に発音していた音とが異なる鍵域であると、リトリガ発音される音を含む鍵域のサンプル波形を新たに読み出して楽音形成しなければならない。   On the other hand, recent musical tone generators are often configured by a waveform memory reading system. As is well known, in the waveform memory reading method, the tone range is divided into several key ranges, sample waveforms (original waveform data) for each divided key range are prepared, A sample waveform (original waveform data) is read to form a musical tone. Therefore, if the retriggered sound and the previously sounded sound have the same key range during the retrigger sounding described above, the same sample waveform can be used as it is, but the retriggered sound and the sound sounded before that sound will be sounded. If the key range is different from the recorded sound, it is necessary to newly read a sample waveform of the key range including the sound that is retriggered to form a musical tone.

つまり、波形メモリ読み出し方式の楽音発生装置でリトリガ発音動作を実現しようとすると、リトリガ発音の都度、音高、音色および音量を制御する各エンベロープジェネレータを再起動して楽音形成する必要が生じる。しかしながら、リトリガ発音の都度、エンベロープジェネレータを再起動して楽音形成する態様であると、上述したように、管楽器を演奏した時のような比較的音量変化の無い滑らかな音程変化や、ギターに代表される弦楽器を演奏した時の独特のアタック感を備えた音を得ることが出来ない。結局、以上の内容を換言すると、管楽器や弦楽器を実際に演奏しているような不自然さの無いリトリガ奏法を実現することが出来ないという問題がある。   In other words, when a retrigger sound generation operation is to be realized by a waveform memory reading type musical sound generator, it is necessary to restart each envelope generator for controlling the pitch, tone color and volume every time a retrigger sound is generated. However, if the envelope generator is restarted each time the retrigger sounds, the musical tone is formed as described above. It is impossible to obtain a sound with a unique attack feeling when playing a stringed instrument. After all, in other words, there is a problem that it is not possible to realize a retrigger method without unnaturalness that is actually playing a wind instrument or a stringed instrument.

本発明は、このような事情に鑑みてなされたもので、管楽器や弦楽器を実際に演奏しているような不自然さの無いリトリガ奏法を実現することができる楽音発生装置および楽音発生処理プログラムを提供することを目的としている。   The present invention has been made in view of such circumstances, and a musical sound generating apparatus and a musical sound generating processing program capable of realizing a retriggering method without unnaturalness that is actually playing a wind instrument or a stringed instrument. It is intended to provide.

上記目的を達成するため、請求項1に記載の発明では、発音域を複数の音高域に分割し、分割された各音高域毎の波形データを記憶する波形記憶手段と、第1の楽音の消音を指示した時に、発音指示中にある第2の楽音を検出する検出手段と、前記検出手段により第2の楽音が検出された場合に、第1および第2の楽音の各音高が異なる音高域に含まれる場合には第1の再発音モードでの再発音を指示し、一方、同じ音高域に含まれる場合には第2の再発音モードでの再発音を指示する再発音指示手段と、前記第1の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第1の読み出し開始アドレスと、前記第2の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第2の読み出し開始アドレスとを記憶するアドレス記憶手段と、前記第1の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第1の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを通常エンベロープ波形よりも波形レベルの小さい第1のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第1のリトリガ発音手段と、前記第2の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第2の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを前記通常エンベロープ波形よりも波形レベルの小さい第2のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第2のリトリガ発音手段とを具備することを特徴とする。 In order to achieve the above object, according to the first aspect of the present invention, a waveform storage means for dividing the sound generation range into a plurality of pitch ranges and storing waveform data for each divided pitch range , A detection means for detecting a second musical sound that is being instructed to generate a sound when a musical sound is instructed to be turned off, and each pitch of the first and second musical sounds when the second musical sound is detected by the detection means. Are included in different pitch ranges, the re-sounding in the first re-sounding mode is instructed. On the other hand, in the same pitch range, re-sounding in the second re-sounding mode is instructed Re-pronunciation instruction means, a first read start address for reading waveform data of the pitch range including the second musical tone from the waveform storage means under the first re-sound mode, and the second re-sound generation Read waveform data of the pitch range including the second musical tone from the waveform storage means under the mode. And a first read start address stored in the address storage means when a re-sound in the first re-sound mode is instructed. The first retrigger sounding means that retriggers the second musical sound formed by modulating the waveform data read from the waveform storage means with the first envelope waveform having a waveform level smaller than the normal envelope waveform, and the second When the re-sounding in the re-sounding mode is instructed, the waveform data read from the waveform storing unit according to the second reading start address stored in the address storing unit is smaller in waveform level than the normal envelope waveform. A second retrigger sounder that retriggers the second musical sound formed by modulating with the second envelope waveform Characterized by including and.

上記請求項1に従属する請求項2に記載の発明では、前記検出手段は、第1の楽音の消音を指示した時に、発音指示中にある楽音が複数存在した場合、それらの中で最後に発音指示された楽音を第2の楽音として検出することを特徴とする。   In the invention according to claim 2 that is dependent on claim 1, when the detection means instructs to mute the first music sound, if there are a plurality of music sounds that are in the sound generation instruction, the detection means is the last of them. The musical tone instructed to be generated is detected as a second musical tone.

請求項3に記載の発明では、発音域を複数の音高域に分割し、分割された各音高域毎の波形データを記憶する波形記憶手段と、第1の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第1の読み出し開始アドレスと、第2の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第2の読み出し開始アドレスとを記憶するアドレス記憶手段と、を有するコンピュータに、第1の楽音の消音を指示した時に、発音指示中にある第2の楽音を検出する検出処理と、前記検出処理により第2の楽音が検出された場合に、第1および第2の楽音の各音高が異なる音高域に含まれる場合には前記第1の再発音モードでの再発音を指示し、一方、同じ音高域に含まれる場合には前記第2の再発音モードでの再発音を指示する再発音指示処理と、前記第1の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第1の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを通常エンベロープ波形よりも波形レベルの小さい第1のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第1のリトリガ発音処理と、前記第2の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第2の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを前記通常エンベロープ波形よりも波形レベルの小さい第2のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第2のリトリガ発音処理とを実行させることを特徴とする。 According to a third aspect of the present invention, a waveform storage means for dividing a tone generation range into a plurality of pitch ranges and storing waveform data for each divided pitch range, and the waveform under a first re-sound generation mode. A first read start address for reading waveform data of the pitch range including the second musical tone from the storage means, and a pitch range including the second musical tone from the waveform storage means in the second re-sounding mode. Detection for detecting the second musical sound that is in the sound generation instruction when the computer having the address reading means for storing the second read start address for reading the waveform data is instructed to mute the first musical sound. and processing, if the second tone is detected by the detection process, re in the first re-sound mode if each pitch of the first and second tone may be included in different pitch ranges Instructs pronunciation, but is included in the same pitch range If the case where the re-sounding instruction process for instructing a re pronunciation in the second re-sound mode, re pronunciation in the first re-sound mode is instructed, the stored in said address storage means A first retrigger sound generation process that retriggers a second musical tone formed by modulating waveform data read from the waveform storage means in accordance with a read start address of 1 with a first envelope waveform having a waveform level smaller than the normal envelope waveform. When the re-sounding in the second re-sounding mode is instructed, the waveform data read from the waveform storing unit according to the second reading start address stored in the address storing unit is obtained from the normal envelope waveform. A second retrigger sound generation process that retriggers the second musical sound formed by modulating the second envelope waveform with a small waveform level. Characterized in that to execute and.

本発明では、管楽器や弦楽器を実際に演奏しているような不自然さの無いリトリガ奏法を実現することができる。   In the present invention, it is possible to realize a retriggering method without unnaturalness that is actually playing a wind instrument or a stringed instrument.

以下、図面を参照して本発明の実施形態について説明する。
A.構成
(1)全体構成
図1は、本発明の実施の一形態である楽音発生装置10の全体構成を示すブロック図である。楽音発生装置10は、鍵盤1、MIDIインタフェース2、スイッチ部3、CPU4、ROM5、RAM6、音源7、D/A変換器(DAC)8およびサウンドシステム9を備える。鍵盤1は、押離鍵操作(演奏操作)に応じたキーオン/キーオフ信号、鍵番号およびベロシティ等からなる演奏情報を発生する。MIDIインタフェース2は、CPU4の制御の下に、例えばMIDIキーボードなどの外部MIDI装置とMIDIデータを授受する。
Hereinafter, embodiments of the present invention will be described with reference to the drawings.
A. Configuration (1) Overall Configuration FIG. 1 is a block diagram showing an overall configuration of a musical sound generating apparatus 10 according to an embodiment of the present invention. The musical sound generator 10 includes a keyboard 1, a MIDI interface 2, a switch unit 3, a CPU 4, a ROM 5, a RAM 6, a sound source 7, a D / A converter (DAC) 8, and a sound system 9. The keyboard 1 generates performance information composed of a key-on / key-off signal, a key number, velocity, and the like corresponding to a press / release key operation (performance operation). The MIDI interface 2 exchanges MIDI data with an external MIDI device such as a MIDI keyboard under the control of the CPU 4.

スイッチ部3は、装置電源をパワーオン/パワーオフする電源スイッチの他、例えば発生する楽音の音色を選択する音色選択スイッチなどの各種スイッチを備え、これらスイッチ操作に応じた種類のスイッチイベントを発生する。CPU4は、スイッチ部3から供給される各種スイッチイベントに基づき装置各部の動作状態を設定する他、鍵盤1から供給される演奏情報(又はMIDIインタフェース2を介して外部MIDI装置から供給されるMIDIデータ)に基づき音源7に楽音発生を指示する。また、CPU4では、管楽器や弦楽器を実際に演奏しているような不自然さの無いリトリガ奏法を実現するよう音源7を制御するようになっており、その詳細については追って述べる。 The switch unit 3 includes various switches such as a timbre selection switch for selecting a tone color of a generated musical tone in addition to a power switch for powering on / off the apparatus power source, and generates a switch event of a type corresponding to the operation of the switch. To do. The CPU 4 sets the operating state of each part of the apparatus based on various switch events supplied from the switch part 3, and also provides performance information supplied from the keyboard 1 (or MIDI data supplied from an external MIDI apparatus via the MIDI interface 2). ) To instruct the sound source 7 to generate a musical tone. Further, the CPU 4 controls the sound source 7 so as to realize a retrigger method without unnaturalness that is actually playing a wind instrument or a stringed instrument, and details thereof will be described later.

ROM5は、上記CPU4にロードされる各種制御プログラムや制御データ等を記憶する。ここで言う各種制御プログラムとは、後述するメインルーチン、エンベロープ処理、ノートオン処理およびノートオフ処理を含む。RAM6は、CPU4のワークエリアとして用いられ、各種レジスタ・フラグデータを一時記憶する。ここで、図2を参照してRAM6に設けられる主要レジスタの構成を説明する。 The ROM 5 stores various control programs and control data that are loaded into the CPU 4. The various control programs referred to here include a main routine, envelope processing, note-on processing, and note-off processing, which will be described later. The RAM 6 is used as a work area for the CPU 4 and temporarily stores various register / flag data. Here, the configuration of main registers provided in the RAM 6 will be described with reference to FIG.

図2において、レジスタnew_keyには、鍵盤1において新たに押鍵又は離鍵された鍵の鍵番号が一時記憶される。レジスタcurrent_keyには、現在発音中の鍵番号が一時記憶される。なお、無発音状態では、レジスタcurrent_keyには「−1」がストアされる。レジスタkey_status[key_number]には、鍵番号key_numberの鍵のオンオフ状態を表す値(「1」の場合にオン、「0」の場合にオフ)が一時記憶される。 In FIG. 2, the register new_key temporarily stores the key number of the key newly pressed or released from the keyboard 1. In the register current_key, the key number that is currently sounding is temporarily stored. Note that in the silent state, “−1” is stored in the register current_key. In the register key_status [key_number], a value indicating the key on / off state of the key number key_number (on when “1”, off when “0”) is temporarily stored.

レジスタcurrent_modeには、現在発音中にある楽音の発音モードを表す値が一時記憶される。本実施形態では、「0」の場合に通常発音モード、「1」の場合に異スプリット・リトリガ発音モード、「2」の場合に同スプリット・リトリガ発音モードを表す。これら発音モードが意図するところについては追って述べる。レジスタstart_address[current_mode]には、現在の発音モードを表すレジスタcurrent_modeの値で指定される波形読み出し開始アドレスが格納される。   The register current_mode temporarily stores a value indicating the tone generation mode of the tone currently being generated. In this embodiment, “0” represents the normal sound generation mode, “1” represents the different split retrigger sound generation mode, and “2” represents the split retrigger sound generation mode. The purpose of these pronunciation modes will be described later. The register start_address [current_mode] stores a waveform readout start address specified by the value of the register current_mode indicating the current sound generation mode.

すなわち、レジスタcurrent_modeの値が「0」の通常発音モードであれば、レジスタstart_address[0]に格納される通常読み出し開始アドレス(図7参照)が指定される。レジスタcurrent_modeの値が「1」の異スプリット・リトリガ発音モードであれば、レジスタstart_address[1]に格納される異スプリット・リトリガ用読み出し開始アドレス(図7参照)が指定される。レジスタcurrent_modeの値が「2」の同スプリット・リトリガ発音モードであれば、レジスタstart_address[2]に格納される同スプリット・リトリガ用読み出し開始アドレス(図7参照)が指定される。なお、図7に図示する各アドレスが意図するところについては追って述べる。 That is, if the value of the register current_mode is “0”, the normal reading start address (see FIG. 7) stored in the register start_address [0] is designated. In the different split retrigger sound generation mode in which the value of the register current_mode is “1”, the different split retrigger read start address (see FIG. 7) stored in the register start_address [1] is designated. In the same split / retrigger sound generation mode in which the value of the register current_mode is “2”, the read start address for the same split / retrigger stored in the register start_address [2] (see FIG. 7) is designated. Note that the purpose of each address shown in FIG. 7 will be described later.

レジスタosc_env_level[current_mode][break_point]には、後述する波形発生器75に供給するエンベロープ波形のレベル値がストアされる。レベル値は、レジスタcurrent_modeの値(現在の発音モード値)とブレークポイントbreak_pointとで定義される。   The register osc_env_level [current_mode] [break_point] stores the level value of the envelope waveform supplied to the waveform generator 75 described later. The level value is defined by the value of the register current_mode (current sounding mode value) and the breakpoint break_point.

ブレークポイントbreak_pointは、ADSR型エンベロープにおける各波形ステップL0〜L5を表す値「0」〜「5」である。本実施形態におけるエンベロープ波形ステップは、例えば図6に図示するように定義される。すなわち、波形ステップL0は、初期ポイント(キーオン時点)のレベルを指す。波形ステップL1は、第1アタック・ブレーク・ポイントのレベルを指す。波形ステップL2は、第2アタック・ブレーク・ポイントのレベルを指す。波形ステップL3は、サステインレベルを指す。波形ステップL4は、第1リリース・ブレイク・ポイントのレベルを指す。波形ステップL5は、第2リリース・ブレイク・ポイントのレベルを指す。 Breakpoints break_point are values “0” to “5” representing the waveform steps L0 to L5 in the ADSR type envelope. The envelope waveform step in this embodiment is defined as shown in FIG. 6, for example. That is, the waveform step L0 indicates the level of the initial point (at the time of key-on). Waveform step L1 indicates the level of the first attack break point. Waveform step L2 refers to the level of the second attack break point. Waveform step L3 indicates a sustain level. Waveform step L4 refers to the level of the first release break point. Waveform step L5 refers to the level of the second release break point.

レジスタosc_env_rate[current_mode][break_point]には、後述する波形発生器75に供給するエンベロープ波形のレート値がストアされる。レート値は、レジスタcurrent_modeの値(現在の発音モード値)とブレークポイントbreak_pointとで定義される。   The register osc_env_rate [current_mode] [break_point] stores the rate value of the envelope waveform supplied to the waveform generator 75 described later. The rate value is defined by the value of the register current_mode (current sounding mode value) and the breakpoint break_point.

ブレークポイントbreak_pointは、ADSR型エンベロープにおける各波形ステップR1〜R5を表す値「1」〜「5」である。各波形ステップR1〜R5は、例えば図6に図示する通り、波形ステップL0から波形ステップL1までの区間が波形ステップR1、波形ステップL1から波形ステップL2までの区間が波形ステップR2、波形ステップL2から波形ステップL3までの区間が波形ステップR3、波形ステップL3から波形ステップL4までの区間が波形ステップR4、波形ステップL4から波形ステップL5までの区間が波形ステップR5となる。 Breakpoints break_point are values “1” to “5” representing the waveform steps R1 to R5 in the ADSR type envelope. For example, as shown in FIG. 6, each of the waveform steps R1 to R5 includes a waveform step R1 from the waveform step L0 to the waveform step L1, a waveform step R2 from the waveform step L1 to the waveform step L2, and the waveform step L2. The section from the waveform step L3 is the waveform step R3, the section from the waveform step L3 to the waveform step L4 is the waveform step R4, and the section from the waveform step L4 to the waveform step L5 is the waveform step R5.

レジスタosc_env_stepには、後述する波形発生器75に供給するエンベロープ波形のステップ状態を表す値、すなわち上述したブレークポイントbreak_pointで指定される各波形ステップL0〜L5の値「0」〜「5」が一時記憶される。 In the register osc_env_step, a value indicating a step state of an envelope waveform supplied to a waveform generator 75 described later, that is, values “0” to “5” of the waveform steps L0 to L5 specified by the breakpoint break_point described above are temporarily stored. Remembered.

レジスタfilter_env_level[current_mode][break_point]には、後述するフィルタ77に供給するエンベロープ波形のレベル値がストアされる。レベル値は、レジスタcurrent_modeの値(現在の発音モード値)とブレークポイントbreak_pointで定義される。ブレークポイントbreak_pointは、ADSR型エンベロープにおける各波形ステップL0〜L5を表す値「0」〜「5」である。 The register filter_env_level [current_mode] [break_point] stores the level value of the envelope waveform supplied to the filter 77 described later. The level value is defined by the value of the register current_mode (current sounding mode value) and the breakpoint break_point. Breakpoints break_point are values “0” to “5” representing the waveform steps L0 to L5 in the ADSR type envelope.

レジスタfilter_env_rate[current_mode][break_point]には、後述するフィルタ77に供給するエンベロープ波形のレート値がストアされる。レート値は、レジスタcurrent_modeの値(現在の発音モード値)とブレークポイントbreak_pointで定義される。ブレークポイントbreak_pointは、ADSR型エンベロープにおける各波形ステップR1〜R5を表す値「1」〜「5」である。   The register filter_env_rate [current_mode] [break_point] stores the rate value of the envelope waveform supplied to the filter 77 described later. The rate value is defined by the value of the register current_mode (current sounding mode value) and the breakpoint break_point. Breakpoints break_point are values “1” to “5” representing the waveform steps R1 to R5 in the ADSR type envelope.

レジスタfilter_env_stepには、後述するフィルタ77に供給するエンベロープ波形のステップ状態を表す値、すなわち上述したブレークポイントbreak_pointで指定される各波形ステップL0〜L5の値「0」〜「5」が一時記憶される。 The register filter_env_step temporarily stores a value representing the step state of the envelope waveform supplied to the filter 77 described later, that is, the values “0” to “5” of the waveform steps L0 to L5 specified by the breakpoint break_point described above. The

レジスタamp_env_level[current_mode][break_point]には、後述する増幅器79に供給するエンベロープ波形のレベル値がストアされる。レベル値は、レジスタcurrent_modeの値(現在の発音モード値)とブレークポイントbreak_pointで定義される。ブレークポイントbreak_pointは、ADSR型エンベロープにおける各波形ステップL0〜L5を表す値「0」〜「5」である。 The register amp_env_level [current_mode] [break_point] stores the level value of the envelope waveform supplied to the amplifier 79 described later. The level value is defined by the value of the register current_mode (current sounding mode value) and the breakpoint break_point. Breakpoints break_point are values “0” to “5” representing the waveform steps L0 to L5 in the ADSR type envelope.

レジスタamp_env_rate[current_mode][break_point]には、後述する増幅器79に供給するエンベロープ波形のレート値がストアされる。レート値は、レジスタcurrent_modeの値(現在の発音モード値)とブレークポイントbreak_pointで定義される。ブレークポイントbreak_pointは、ADSR型エンベロープにおける各波形ステップR1〜R5を表す値「1」〜「5」である。   A register amp_env_rate [current_mode] [break_point] stores a rate value of an envelope waveform supplied to an amplifier 79 described later. The rate value is defined by the value of the register current_mode (current sounding mode value) and the breakpoint break_point. Breakpoints break_point are values “1” to “5” representing the waveform steps R1 to R5 in the ADSR type envelope.

レジスタamp_env_stepには、後述する増幅器79に供給するエンベロープ波形のステップ状態を表す値、すなわち上述したブレークポイントbreak_pointで指定される各波形ステップL0〜L5の値「0」〜「5」が一時記憶される。 The register amp_env_step temporarily stores a value representing a step state of an envelope waveform supplied to the amplifier 79 described later, that is, values “0” to “5” of the waveform steps L0 to L5 specified by the breakpoint break_point described above. The

次に、再び図1を参照して実施形態の構成について説明を進める。図1において、音源7は、周知の波形メモリ読み出し方式にて構成され、CPU4から供給されるパラメータで指定される音色、音高および音量の楽音データWを出力する。D/A変換器8は、音源7から出力される楽音データWをアナログ形式の楽音信号に変換して出力する。サウンドシステム9は、D/A変換器8が出力する楽音信号から不要ノイズを除去する等のフィルタリングを施した後、これを増幅してスピーカから発音させる。   Next, the configuration of the embodiment will be described with reference to FIG. 1 again. In FIG. 1, the sound source 7 is configured by a well-known waveform memory reading method, and outputs tone data W of tone color, pitch and volume specified by parameters supplied from the CPU 4. The D / A converter 8 converts the musical sound data W output from the sound source 7 into an analog musical signal and outputs it. The sound system 9 performs filtering such as removing unnecessary noise from the musical sound signal output from the D / A converter 8, and then amplifies it to make it sound from the speaker.

(2)音源7の構成
次に、図3を参照して音源7の構成について説明する。音源7は周知のDSPから構成される。したがって、図3はそのDSPにおいて実行されるマイクロプログラムの各機能をハードウェアイメージとして捉らえた機能ブロックを図示している。
(2) Configuration of Sound Source 7 Next, the configuration of the sound source 7 will be described with reference to FIG. The sound source 7 is composed of a known DSP. Therefore, FIG. 3 illustrates functional blocks in which each function of the microprogram executed in the DSP is regarded as a hardware image.

図3において、EG70は、CPU4から与えられるパラメータ、すなわち上述したレジスタosc_env_level[current_mode][break_point]に格納されるレベル値と、レジスタosc_env_rate[current_mode][break_point]に格納されるレート値とに応じて音高制御用のエンベロープ波形を発生する。 In FIG. 3, the EG 70 responds to parameters given from the CPU 4, that is, a level value stored in the above-described register osc_env_level [current_mode] [break_point] and a rate value stored in the register osc_env_rate [current_mode] [break_point]. Generates an envelope waveform for pitch control.

具体的には、レジスタcurrent_modeの値が「0」の通常発音モードの場合には通常エンベロープ波形を、レジスタcurrent_modeの値が「1」の異スプリット・リトリガ発音モードの場合には異スプリット・リトリガ・エンベロープ波形を、レジスタcurrent_modeの値が「2」の同スプリット・リトリガ発音モードの場合には同スプリット・リトリガ・エンベロープ波形をそれぞれ発生する。 Specifically, the normal envelope waveform is used in the normal sound generation mode where the value of the register current_mode is “0”, and the different split retrigger sound mode is used in the different split retrigger sound mode where the value of the register current_mode is “1”. In the same split / retrigger sound generation mode in which the value of the register current_mode is “2”, the same split / retrigger / envelope waveform is generated.

リトリガ発音とは、前述したように、ある鍵を離鍵した時に、他に押鍵中の鍵が存在する場合に押鍵されている鍵の中から優先鍵(例えば押鍵されている鍵の内で最も音高の高い鍵)を選択し、選択した優先鍵の音を再発音する動作を指すが、こうしたリトリガ発音の際に、リトリガ発音される音とそれ以前に発音していた音とが同じ鍵域ならば、同スプリット・リトリガ発音モードとなり、一方、リトリガ発音される音とそれ以前に発音していた音とが異なる鍵域であると、異スプリット・リトリガ発音モードとなる。   As described above, retrigger sounding means that when a key is released, if there is another key being pressed, a priority key (for example, the key being pressed) The key that has the highest pitch in the list) is selected, and the sound of the selected priority key is re-played. Are in the same split / retrigger sound generation mode, and when the sound that is sounded by retrigger is different from the sound that was sounded before, the different split / retrigger sound generation mode is set.

図4は、EG70が発生する「通常エンベロープ波形」、「異スプリット・リトリガ・エンベロープ波形」および「同スプリット・リトリガ・エンベロープ波形」の一例を示す図である。この図に示す一例では、リトリガ発音時の音高変化を小さくするために通常エンベロープ波形よりも波形レベルを小さく設定している。また、同スプリット・リトリガ・エンベロープ波形では、同じ鍵域のサンプル波形(原波形データ)を使用する為、異なる鍵域のサンプル波形を使用する異スプリット・リトリガ・エンベロープ波形よりレベル変化を大きくしてある。   FIG. 4 is a diagram showing an example of “normal envelope waveform”, “different split / retrigger envelope waveform”, and “same split / retrigger envelope waveform” generated by the EG 70. In the example shown in this figure, the waveform level is set smaller than the normal envelope waveform in order to reduce the pitch change during retrigger sounding. Since the same split / retrigger envelope waveform uses the same key range sample waveform (original waveform data), the level change is larger than the different split / retrigger envelope waveform that uses a different key range sample waveform. is there.

なお、図4において、L0〜L5は、前述したレジスタosc_env_level[current_mode][break_point]のブレークポイントbreak_pointで指定される波形ステップを表す。また、R1〜R5は、前述したレジスタosc_env_rate[current_mode][break_point]のブレークポイントbreak_pointで指定される波形ステップを表す。 In FIG. 4, L0 to L5 represent waveform steps specified by the breakpoint break_point of the register osc_env_level [current_mode] [break_point] described above. R1 to R5 represent waveform steps specified by the breakpoint break_point of the register osc_env_rate [current_mode] [break_point] described above.

図3において、加算器73はCPU4から供給される音高データに、EG70から出力される音高制御用のエンベロープ波形を加算して波形発生器75に供給する。波形メモリ74は、各鍵域毎のサンプル波形(原波形データ)を記憶する。各鍵域毎のサンプル波形には、図7に図示するように、発音モード毎の読み出し開始アドレスが設けられる。 In FIG. 3, the adder 73 adds the envelope waveform for pitch control output from the EG 70 to the pitch data supplied from the CPU 4 and supplies the result to the waveform generator 75. The waveform memory 74 stores a sample waveform (original waveform data) for each key range. The sample waveform for each key range is provided with a read start address for each sound generation mode, as shown in FIG.

すなわち、レジスタcurrent_modeの値が「0」の通常発音モードの場合には、通常読み出し開始アドレスからサンプル波形が読み出される。レジスタcurrent_modeの値が「1」の異スプリット・リトリガ発音モードの場合には、異スプリット・リトリガ用読み出し開始アドレスからサンプル波形が読み出される。レジスタcurrent_modeの値が「2」の同スプリット・リトリガ発音モードの場合には、同スプリット・リトリガ用読み出し開始アドレスからサンプル波形が読み出される。 That is, in the normal sound generation mode in which the value of the register current_mode is “0”, the sample waveform is read from the normal read start address. In the different split retrigger sound generation mode in which the value of the register current_mode is “1”, the sample waveform is read from the read start address for different split retrigger. In the same split / retrigger sound generation mode in which the value of the register current_mode is “2”, the sample waveform is read from the read start address for the same split / retrigger.

発音モード毎の読み出し開始アドレスを設けた理由は次の通りである。リトリガ発音は、通常発音と比較してアタック音が小さい為、サンプル波形の立ち上がり部分であるアタック領域以降を読み出し開始アドレスに設定している。また、図7に図示する一例の場合、同スプリット・リトリガ発音では同じ鍵域のサンプル波形を使用する為、異なる鍵域のサンプル波形を使用する異スプリット・リトリガ発音よりもアタック部分を含む読み出し開始アドレスに設定している。   The reason for providing the read start address for each sound generation mode is as follows. In the retrigger sounding, the attack sound is smaller than that in the normal sounding. Therefore, the read start address is set after the attack region which is the rising portion of the sample waveform. In the case of the example shown in FIG. 7, since the same retrigger sound uses the same key range sample waveform, the readout start including the attack portion is different from the different split retrigger sound using the different key range sample waveform. The address is set.

波形発生器75は、CPU4から供給されるパラメータ、すなわちレジスタstart_address[current_mode]で指定される読み出し開始アドレスに従って波形メモリ74からサンプル波形(原波形データ)を、加算器73の出力に応じた読み出し速度で読み出す。これにより指定音高の波形データが発生する。 The waveform generator 75 reads the sample waveform (original waveform data) from the waveform memory 74 according to the parameter supplied from the CPU 4, that is, the read start address specified by the register start_address [current_mode], according to the output of the adder 73. Read with. As a result, waveform data of the specified pitch is generated.

EG71は、CPU4から与えられるパラメータ、すなわち上述したレジスタfilter_env_level[current_mode][break_point]に格納されるレベル値と、レジスタfilter_env_rate[current_mode][break_point]に格納されるレート値とに応じて、音色制御用(カットオフ周波数制御用)のエンベロープ波形を発生する。 The EG 71 uses the color control according to the parameter given from the CPU 4, that is, the level value stored in the register filter_env_level [current_mode] [break_point] and the rate value stored in the register filter_env_rate [current_mode] [break_point]. Generate an envelope waveform (for cut-off frequency control).

具体的には、レジスタcurrent_modeの値が「0」の通常発音モードの場合には通常エンベロープ波形を、レジスタcurrent_modeの値が「1」の異スプリット・リトリガ発音モードの場合には異スプリット・リトリガ・エンベロープ波形を、レジスタcurrent_modeの値が「2」の同スプリット・リトリガ発音モードの場合には同スプリット・リトリガ・エンベロープ波形をそれぞれ発生する。 Specifically, the normal envelope waveform is used in the normal sound generation mode where the value of the register current_mode is “0”, and the different split retrigger sound mode is used in the different split retrigger sound mode where the value of the register current_mode is “1”. In the same split / retrigger sound generation mode in which the value of the register current_mode is “2”, the same split / retrigger / envelope waveform is generated.

図5は、EG71が発生する「通常エンベロープ波形」、「異スプリット・リトリガ・エンベロープ波形」および「同スプリット・リトリガ・エンベロープ波形」の一例を示す図である。この図に示す一例では、リトリガ発音時の音色変化を小さくするために通常エンベロープ波形よりも波形レベルを小さく設定している。また、同スプリット・リトリガ・エンベロープ波形では、同じ鍵域のサンプル波形(原波形データ)を使用する為、異なる鍵域のサンプル波形を使用する異スプリット・リトリガ・エンベロープ波形よりレベル変化を大きくしてある。   FIG. 5 is a diagram showing an example of a “normal envelope waveform”, “different split / retrigger envelope waveform”, and “same split / retrigger envelope waveform” generated by the EG 71. In the example shown in this figure, the waveform level is set smaller than the normal envelope waveform in order to reduce the timbre change during retrigger sounding. Since the same split / retrigger envelope waveform uses the same key range sample waveform (original waveform data), the level change is larger than the different split / retrigger envelope waveform that uses a different key range sample waveform. is there.

なお、図5において、L0〜L5は、前述したレジスタfilter_env_level[mode][break_point]のブレークポイントbreak_pointで指定される波形ステップを表す。また、R1〜R5は、前述したレジスタfilter_env_rate[mode][break_point]のブレークポイントbreak_pointで指定される波形ステップを表す。 In FIG. 5, L0 to L5 represent waveform steps designated by the breakpoint break_point of the register filter_env_level [mode] [break_point] described above. R1 to R5 represent waveform steps specified by the breakpoint break_point of the register filter_env_rate [mode] [break_point] described above.

図3において、加算器76はCPU4から供給されるカットオフ周波数指定データに、EG71から出力される音色制御用のエンベロープ波形を加算してフィルタ77に供給する。フィルタ77は、周知のDCF(デジタル制御フィルタ)から構成され、加算器76の出力に応じて、DCFのカットオフ周波数を変調してローパス特性を変化させ、これにより前段の波形発生器75から出力される波形データに音色変化を与える。 In FIG. 3, the adder 76 adds the tone waveform control envelope waveform output from the EG 71 to the cutoff frequency designation data supplied from the CPU 4 and supplies the result to the filter 77. The filter 77 is composed of a well-known DCF (digital control filter), and modulates the cut-off frequency of the DCF in accordance with the output of the adder 76 to change the low-pass characteristic, thereby outputting from the waveform generator 75 in the previous stage. The timbre change is given to the waveform data.

EG72は、CPU4から与えられるパラメータ、すなわち上述したレジスタamp_env_level[current_mode][break_point]に格納されるレベル値と、レジスタamp_env_rate[current_mode][break_point]に格納されるレート値とに応じて、音量制御用のエンベロープ波形を発生する。 The EG 72 is used for volume control in accordance with a parameter given from the CPU 4, that is, a level value stored in the register amp_env_level [current_mode] [break_point] and a rate value stored in the register amp_env_rate [current_mode] [break_point]. Generate an envelope waveform.

具体的には、レジスタcurrent_modeの値が「0」の通常発音モードの場合には通常エンベロープ波形を、レジスタcurrent_modeの値が「1」の異スプリット・リトリガ発音モードの場合には異スプリット・リトリガ・エンベロープ波形を、レジスタcurrent_modeの値が「2」の同スプリット・リトリガ発音モードの場合には同スプリット・リトリガ・エンベロープ波形をそれぞれ発生する。 Specifically, the normal envelope waveform is used in the normal sound generation mode where the value of the register current_mode is “0”, and the different split retrigger sound mode is used in the different split retrigger sound mode where the value of the register current_mode is “1”. In the same split / retrigger sound generation mode in which the value of the register current_mode is “2”, the same split / retrigger / envelope waveform is generated.

図6は、EG72が発生する「通常エンベロープ波形」、「異スプリット・リトリガ・エンベロープ波形」および「同スプリット・リトリガ・エンベロープ波形」の一例を示す図である。この図に示す一例では、リトリガ発音時の音量変化を小さくするために通常エンベロープ波形よりも波形レベルを小さく設定している。また、同スプリット・リトリガ・エンベロープ波形では、同じ鍵域のサンプル波形(原波形データ)を使用する為、異なる鍵域のサンプル波形を使用する異スプリット・リトリガ・エンベロープ波形よりレベル変化を大きくしてある。   FIG. 6 is a diagram showing an example of “normal envelope waveform”, “different split / retrigger envelope waveform”, and “same split / retrigger envelope waveform” generated by the EG 72. In the example shown in this figure, the waveform level is set smaller than the normal envelope waveform in order to reduce the volume change during retrigger sounding. Since the same split / retrigger envelope waveform uses the same key range sample waveform (original waveform data), the level change is larger than the different split / retrigger envelope waveform that uses a different key range sample waveform. is there.

図3において、加算器78はCPU4から供給される音量データに、EG72から出力される音量制御用のエンベロープ波形を加算して増幅器79に供給する。増幅器79は、加算器78の出力に応じて増幅率を可変制御して前段のフィルタ77から供給される波形データに音量変化を与えて楽音データWを発生する。 In FIG. 3, the adder 78 adds the envelope waveform for volume control output from the EG 72 to the volume data supplied from the CPU 4 and supplies the result to the amplifier 79. The amplifier 79 variably controls the amplification factor in accordance with the output of the adder 78, changes the volume of the waveform data supplied from the previous filter 77, and generates the musical sound data W.

B.動作
次に、図8〜図14を参照して実施形態の動作を説明する。以下では、全体動作としてCPU4が実行するメインルーチンの動作を説明した後、タイマ割り込みにより所定周期毎に実行されるエンベロープ処理、メインルーチンからコールされるノートオン処理およびノートオフ処理の各動作について述べる。
B. Operation Next, the operation of the embodiment will be described with reference to FIGS. In the following, after describing the operation of the main routine executed by the CPU 4 as the overall operation, the operations of envelope processing executed every predetermined period by timer interruption, note-on processing and note-off processing called from the main routine will be described. .

(1)メインルーチンの動作
図8は、CPU4が実行するメインルーチンの動作を示すフローチャートである。上述した構成による楽音発生装置10がパワーオンされると、CPU4は図8に示すメインルーチンのステップSA1に処理を進め、RAM6に格納される各種レジスタ/フラグ類をリセットしたり、初期値セットする他、音源7に対して各種レジスタ・フラグを初期化するよう指示するイニシャライズを実行する。
(1) Operation of Main Routine FIG. 8 is a flowchart showing the operation of the main routine executed by the CPU 4. When the tone generator 10 having the above-described configuration is powered on, the CPU 4 proceeds to step SA1 of the main routine shown in FIG. 8 to reset various registers / flags stored in the RAM 6 and to set initial values. In addition, initialization for instructing the sound source 7 to initialize various register flags is executed.

そして、イニシャライズが完了すると、ステップSA2に処理を進め、スイッチ部3のスイッチ操作に対応したスイッチ処理を行う。このスイッチ処理では、例えば音色選択スイッチの操作により選択される音色の楽音を発生させるパラメータ、例えば選択された音色のサンプル波形(原波形データ)を指定するデータや、フィルタ77のカットオフ周波数を指定するデータ等を音源7にセットする。次いで、ステップSA3では、鍵イベントの有無を判断する。鍵盤1で押離鍵操作が行われず、鍵イベントが発生しなければ、上述のステップSA2に処理を戻す。 When the initialization is completed, the process proceeds to step SA2, and a switch process corresponding to the switch operation of the switch unit 3 is performed. In this switch processing, for example, a parameter for generating a musical tone of a timbre selected by operating the timbre selection switch, for example, data for specifying a sample waveform (original waveform data) of the selected timbre, or a cutoff frequency of the filter 77 is specified. The data to be performed is set in the sound source 7. Next, in step SA3, it is determined whether or not there is a key event. If no key release operation is performed on the keyboard 1, and no key event occurs, the process returns to step SA2.

一方、鍵盤1の押鍵によりキーオンイベントが生じた場合には、ステップSA4を介してノートオン処理(後述する)を実行した後、上記ステップSA2に処理を戻す。鍵盤1の離鍵によりキーオフイベントが生じた場合には、ステップSA5に進み、離鍵された鍵の音高で発音している楽音を消音したり、リトリガ発音を音源7に指示したりするノートオフ処理を実行した後、上記ステップSA2に処理を戻す。以後、楽音発生装置10がパワーオフされる迄、上述したステップSA2〜SA5を繰り返す。 On the other hand, when a key-on event occurs due to the key depression of the keyboard 1, a note-on process (described later) is executed via step SA4, and then the process returns to step SA2. If a key-off event occurs due to the release of the keyboard 1, the process proceeds to step SA 5, where the musical sound produced at the pitch of the released key is muted, and the retrigger sound is instructed to the sound source 7. After executing the off process, the process returns to step SA2. Thereafter, the above steps SA2 to SA5 are repeated until the musical tone generator 10 is powered off.

(2)エンベロープ処理の動作
図9〜図10は、タイマ割り込みによってCPU4が所定周期毎に実行するエンベロープ処理の動作を示すフローチャートである。割り込みタイミングになると、CPU4は先ず図9に図示するステップSB1〜SB5においてEG70(図3参照)に目標レベル値と目標レート値をセットして音高制御用のエンベロープ波形の発生を指示する。
(2) Operation of Envelope Processing FIGS. 9 to 10 are flowcharts showing the operation of envelope processing executed by the CPU 4 at predetermined intervals by a timer interrupt. At the interrupt timing, the CPU 4 first sets a target level value and a target rate value in the EG 70 (see FIG. 3) in steps SB1 to SB5 shown in FIG. 9, and instructs generation of an envelope waveform for pitch control.

続いて、ステップSB6〜SB10では、EG71に目標レベル値と目標レート値をセットして音色制御用(カットオフ周波数制御用)のエンベロープ波形の発生を指示する。そして、図10に図示するステップSB11〜SB15では、EG72に目標レベル値と目標レート値とをセットして音量制御用のエンベロープ波形を発生する。以下、音高、音色および音量をそれぞれ制御するエンベロープ波形別の動作に分けて説明を進める。 Subsequently, in steps SB6 to SB10, a target level value and a target rate value are set in the EG 71 to instruct generation of an envelope waveform for timbre control (for cut-off frequency control). In steps SB11 to SB15 shown in FIG. 10, a target level value and a target rate value are set in the EG 72 to generate a volume control envelope waveform. The following description is divided into operations for each envelope waveform for controlling the pitch, tone color, and volume respectively.

<音高制御用のエンベロープ波形の発生>
ステップSB1では、EG70の目標レベル値が「0」であるか否かを判断する。目標レベル値が「0」ならば、判断結果は「YES」となり、後述のステップSB6に進むが、目標レベル値が「0」でなければ、上記ステップSB1の判断結果は「NO」となり、ステップSB2に進む。ステップSB2では、レジスタosc_env_stepに格納されるステップ値が「3」、つまりサステイン状態でないかどうかを判断する。サステイン状態であると、判断結果は「NO」になり、後述のステップSB6に進むが、サステイン状態以外ならば、判断結果は「YES」になり、次のステップSB3に進む。
<Generation of envelope waveform for pitch control>
In step SB1, it is determined whether or not the target level value of the EG 70 is “0”. If the target level value is “0”, the determination result is “YES”, and the process proceeds to step SB6, which will be described later. If the target level value is not “0”, the determination result in step SB1 is “NO”. Proceed to SB2. In step SB2, it is determined whether or not the step value stored in the register osc_env_step is “3”, that is, whether or not the sustain state is set. If it is in the sustain state, the determination result is “NO”, and the process proceeds to Step SB6 described later. However, if it is not in the sustain state, the determination result is “YES”, and the process proceeds to the next Step SB3.

ステップSB3では、レジスタosc_env_stepに格納されるステップ値が「5」、つまり第2リリース・ブレーク・ポイント(最終状態)でないかどうかを判断する。最終状態であると、判断結果は「NO」になり、後述のステップSB6に進むが、最終状態以外ならば、判断結果が「YES」になり、次のステップSB4に進み、レジスタosc_env_stepに格納されるステップ値をインクリメントして歩進させる。   In step SB3, it is determined whether or not the step value stored in the register osc_env_step is “5”, that is, the second release break point (final state). If it is the final state, the determination result is “NO”, and the process proceeds to step SB6, which will be described later. However, if it is not the final state, the determination result is “YES”, the process proceeds to the next step SB4, and is stored in the register osc_env_step. Increment the step value.

次いで、ステップSB5では、レジスタcurrent_modeに格納され、現在の発音モードを表す値と、上記ステップSB4にて歩進されたレジスタosc_env_stepのステップ値とで指定されるレベル値を、レジスタosc_env_level[current_mode][ osc_env_step]から読み出し、これをEG70の目標レベル値に設定する。   Next, in step SB5, the level value specified by the value stored in the register current_mode and indicating the current sound generation mode and the step value of the register osc_env_step advanced in step SB4 is stored in the register osc_env_level [current_mode] [ osc_env_step] and set this to the target level value of the EG 70.

また、ステップSB5では、レジスタcurrent_modeの値と、上記ステップSB4にて歩進されたレジスタosc_env_stepのステップ値とで指定されるレート値を、レジスタosc_env_rate[current_mode][ osc_env_step]から読み出し、これをEG70の目標レート値に設定する。これにより、EG70は、現在のレベル値から目標レベル値に達するまで目標レート値に従って変化するエンベロープ波形を発生する。 In step SB5, the rate value specified by the value of the register current_mode and the step value of the register osc_env_step stepped in step SB4 is read from the register osc_env_rate [current_mode] [osc_env_step], and this is read out from the EG70. Set to the target rate value. As a result, the EG 70 generates an envelope waveform that changes according to the target rate value until the target level value is reached from the current level value.

<音色制御用(カットオフ周波数制御用)のエンベロープ波形の発生>
ステップSB6では、EG71の目標レベル値が「0」であるか否かを判断する。目標レベル値が「0」ならば、判断結果は「YES」となり、図10に図示するステップSB11(後述する)に進むが、目標レベル値が「0」でなければ、上記ステップSB6の判断結果は「NO」となり、ステップSB7に進む。ステップSB7では、レジスタfilter_env_stepに格納されるステップ値が「3」、つまりサステイン状態でないかどうかを判断する。サステイン状態であると、判断結果は「NO」になり、後述のステップSB11に進むが、サステイン状態以外ならば、判断結果は「YES」になり、次のステップSB8に進む。
<Generation of envelope waveform for timbre control (for cut-off frequency control)>
In step SB6, it is determined whether or not the target level value of the EG 71 is “0”. If the target level value is “0”, the determination result is “YES”, and the process proceeds to step SB11 (described later) shown in FIG. 10, but if the target level value is not “0”, the determination result of step SB6 above. Becomes “NO” and the flow proceeds to Step SB7. In step SB7, it is determined whether or not the step value stored in the register filter_env_step is “3”, that is, the sustain state. If it is in the sustain state, the determination result is “NO”, and the process proceeds to Step SB11 described later. If it is not in the sustain state, the determination result is “YES”, and the process proceeds to the next Step SB8.

ステップSB8では、レジスタfilter_env_stepに格納されるステップ値が「5」、つまり第2リリース・ブレーク・ポイント(最終状態)でないかどうかを判断する。最終状態であると、判断結果は「NO」になり、後述のステップSB11に進むが、最終状態以外ならば、判断結果が「YES」になり、次のステップSB9に進み、レジスタfilter_env_stepに格納されるステップ値をインクリメントして歩進させる。   In step SB8, it is determined whether or not the step value stored in the register filter_env_step is “5”, that is, the second release break point (final state). If it is the final state, the determination result is “NO”, and the process proceeds to step SB11, which will be described later. If it is not the final state, the determination result is “YES”, and the process proceeds to the next step SB9 and is stored in the register filter_env_step. Increment the step value.

次いで、ステップSB10では、レジスタcurrent_modeの値と、上記ステップSB9にて歩進されたレジスタfilter_env_stepのステップ値とで指定されるレベル値を、レジスタfilter_env_level[current_mode][ osc_env_step]から読み出し、これをEG71の目標レベル値に設定する。   Next, in step SB10, the level value specified by the value of the register current_mode and the step value of the register filter_env_step advanced in step SB9 is read from the register filter_env_level [current_mode] [osc_env_step], and this is read out from the EG71. Set to the target level value.

また、ステップSB10では、レジスタcurrent_modeの値と、上記ステップSB9にて歩進されたレジスタfilter_env_stepのステップ値とで指定されるレート値を、レジスタfilter_env_rate[current_mode][ osc_env_step]から読み出し、これをEG71の目標レート値に設定する。これにより、EG71は、現在のレベル値から目標レベル値に達するまで目標レート値に従って変化するエンベロープ波形を発生する。 In step SB10, the rate value specified by the value of the register current_mode and the step value of the register filter_env_step advanced in step SB9 is read from the register filter_env_rate [current_mode] [osc_env_step], and is read from the EG71. Set to the target rate value. As a result, the EG 71 generates an envelope waveform that changes according to the target rate value until the target level value is reached from the current level value.

<音量制御用のエンベロープ波形の発生動作>
図10に図示するステップSB11では、EG72の目標レベル値が「0」であるか否かを判断する。目標レベル値が「0」ならば、判断結果は「YES」となり、本処理を終えるが、目標レベル値が「0」でなければ、上記ステップSB11の判断結果は「NO」となり、ステップSB12に進む。ステップSB12では、レジスタamp_env_stepに格納されるステップ値が「3」、つまりサステイン状態でないかどうかを判断する。サステイン状態であると、判断結果は「NO」になり、本処理を終えるが、サステイン状態以外ならば、判断結果は「YES」になり、次のステップSB13に進む。
<Generation operation of envelope waveform for volume control>
In step SB11 shown in FIG. 10, it is determined whether or not the target level value of the EG 72 is “0”. If the target level value is “0”, the determination result is “YES”, and this process is completed. If the target level value is not “0”, the determination result in step SB11 is “NO”, and the process proceeds to step SB12. move on. In step SB12, it is determined whether or not the step value stored in the register amp_env_step is “3”, that is, the sustain state is not set. If it is in the sustain state, the determination result is “NO”, and this process ends. If it is not in the sustain state, the determination result is “YES”, and the process proceeds to the next step SB13.

ステップSB13では、レジスタamp_env_stepに格納されるステップ値が「5」、つまり第2リリース・ブレーク・ポイント(最終状態)でないかどうかを判断する。最終状態であると、判断結果は「NO」になり、本処理を終えるが、最終状態以外ならば、判断結果が「YES」になり、次のステップSB14に進み、レジスタamp_env_stepに格納されるステップ値をインクリメントして歩進させる。   In step SB13, it is determined whether or not the step value stored in the register amp_env_step is “5”, that is, the second release break point (final state). If it is in the final state, the determination result is “NO”, and this process is completed. If it is not in the final state, the determination result is “YES”, and the process proceeds to the next step SB14 and is stored in the register amp_env_step. Increment value to step.

次いで、ステップSB15では、レジスタcurrent_modeの値と、上記ステップSB14にて歩進されたレジスタamp_env_stepのステップ値とで指定されるレベル値を、レジスタamp_env_level[current_mode][ osc_env_step]から読み出し、これをEG72の目標レベル値に設定する。   Next, in step SB15, the level value specified by the value of the register current_mode and the step value of the register amp_env_step stepped in step SB14 is read from the register amp_env_level [current_mode] [osc_env_step], and this is read out from the EG72. Set to the target level value.

また、ステップSB15では、レジスタcurrent_modeの値と、上記ステップSB14にて歩進されたレジスタamp_env_stepのステップ値とで指定されるレート値を、レジスタamp_env_rate[current_mode][ osc_env_step]から読み出し、これをEG72の目標レート値に設定する。これにより、EG72は、現在のレベル値から目標レベル値に達するまで目標レート値に従って変化するエンベロープ波形を発生する。 In step SB15, the rate value specified by the value of the register current_mode and the step value of the register amp_env_step advanced in step SB14 is read from the register amp_env_rate [current_mode] [osc_env_step], and this is read out. Set to the target rate value. As a result, the EG 72 generates an envelope waveform that changes according to the target rate value until the target level value is reached from the current level value.

(3)ノートオン処理の動作
図11は、ノートオン処理の動作を示すフローチャートである。前述したメインルーチンのステップSA4(図8参照)を介して本処理が実行されると、CPU4は図11に図示するステップSC1に進み、押鍵された鍵の鍵番号をレジスタnew_keyにストアする。なお、複数の鍵が同時に押鍵された場合には、後着優先にて発音割り当てを行い、発音割り当てされた鍵の鍵番号をレジスタnew_keyにストアする。続いて、ステップSC2では、レジスタnew_keyにストアされた鍵番号で指定されるレジスタkey_status[new_key]に「1」をストアする。これにより、新たに押鍵された鍵がオン状態に設定されたことを表す。
(3) Operation of Note On Process FIG. 11 is a flowchart showing the operation of the note on process. When this process is executed through step SA4 (see FIG. 8) of the main routine described above, the CPU 4 proceeds to step SC1 shown in FIG. 11, and stores the key number of the key that has been pressed in the register new_key. When a plurality of keys are pressed at the same time, sound assignment is performed with priority on later arrival, and the key number of the sound assigned key is stored in the register new_key. Subsequently, in step SC2, “1” is stored in the register key_status [new_key] specified by the key number stored in the register new_key. This indicates that the newly pressed key is set to the on state.

次いで、ステップSC3では、レジスタcurrent_keyの値が「−1」、すなわち現在発音中の楽音が無い無発音状態であるか否かを判断する。無発音状態ならば、判断結果は「YES」となり、後述のステップSC5に進む。一方、発音中の楽音があると、上記ステップSC3の判断結果が「NO」になり、ステップSC4に進み、発音中の楽音を停止するよう音源7に指示した後、ステップSC5に進み、レジスタcurrent_modeに「0」をストアして通常発音モードであることを表す。   Next, in step SC3, it is determined whether or not the value of the register current_key is “−1”, that is, whether or not there is no sound that is currently being sounded. If no sound is generated, the determination result is “YES”, and the flow proceeds to Step SC5 described later. On the other hand, if there is a musical tone that is sounding, the determination result in step SC3 is “NO”, the process proceeds to step SC4, the sound source 7 is instructed to stop the musical sound being pronounced, and then the process proceeds to step SC5 to register register_mode. “0” is stored in to indicate the normal sound generation mode.

そして、ステップSC6では、レジスタnew_keyの内容、すなわち押鍵された鍵の鍵番号をレジスタcurrent_keyにストアする。続いて、ステップSC7では、レジスタcurrent_modeの値で指定されるレジスタstart_address[current_mode]から通常読み出しアドレスを読み出して波形発生器75にセットする。そして、ステップSC8では、レジスタcurrent_keyの鍵番号に対応した音高データを波形発生器75に設定する。   In step SC6, the contents of the register new_key, that is, the key number of the pressed key is stored in the register current_key. Subsequently, in step SC7, the normal read address is read from the register start_address [current_mode] specified by the value of the register current_mode and set in the waveform generator 75. In step SC8, pitch data corresponding to the key number of the register current_key is set in the waveform generator 75.

次いで、ステップSC9では、レジスタcurrent_modeの値とステップ値「0」とで指定されるレベル値を、レジスタosc_env_level[current_mode][0]から読み出してEG70の現在レベル値に設定する。そして、ステップSC10では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレベル値を、レジスタosc_env_level[current_mode][1]から読み出してEG70の目標レベル値に設定する。   Next, in step SC9, the level value specified by the value of the register current_mode and the step value “0” is read from the register osc_env_level [current_mode] [0] and set to the current level value of the EG 70. In step SC10, the level value specified by the value of the register current_mode and the step value “1” is read from the register osc_env_level [current_mode] [1] and set to the target level value of the EG 70.

ステップSC11では、発生楽音の音色に応じたフィルタ係数(カットオフ周波数指定データ)を初期値としてフィルタ77に設定する。続いて、ステップSC12では、レジスタcurrent_modeの値とステップ値「0」とで指定されるレベル値を、レジスタfilter_env_level[current_mode][0]から読み出してEG71の現在レベル値に設定する。そして、ステップSC13では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレベル値を、レジスタfilter_env_level[current_mode][1]から読み出してEG71の目標レベル値に設定する。 In step SC11, a filter coefficient (cutoff frequency designation data) corresponding to the tone color of the generated musical tone is set in the filter 77 as an initial value. Subsequently, in step SC12, the level value specified by the value of the register current_mode and the step value “0” is read from the register filter_env_level [current_mode] [0] and set to the current level value of the EG 71. In step SC13, the level value specified by the value of the register current_mode and the step value “1” is read from the register filter_env_level [current_mode] [1] and set to the target level value of the EG 71.

ステップSC14では、発生楽音の音色に応じた乗算係数(増幅率)を初期値として増幅器79に設定する。続いて、ステップSC15では、レジスタcurrent_modeの値とステップ値「0」とで指定されるレベル値を、レジスタamp_env_level[current_mode][0]から読み出してEG72の現在レベル値に設定する。そして、ステップSC16では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレベル値を、レジスタamp_env_level[current_mode][1]から読み出してEG72の目標レベル値に設定する。 In step SC14, a multiplication coefficient (amplification factor) corresponding to the tone color of the generated musical tone is set in the amplifier 79 as an initial value. Subsequently, in step SC15, the level value specified by the value of the register current_mode and the step value “0” is read from the register amp_env_level [current_mode] [0] and set to the current level value of the EG 72. In step SC16, the level value specified by the value of the register current_mode and the step value “1” is read from the register amp_env_level [current_mode] [1] and set to the target level value of the EG 72.

こうして、EG70〜72の各々の現在レベル値および目標レベル値を設定し終えると、ステップSC17に進み、波形発生器75に波形読み出し開始を指示する。これにより、波形発生器75は、押鍵された鍵の音高に対応する読み出し速度に従って波形メモリ74の通常読み出しアドレス(図7参照)からサンプル波形(原波形データ)を読み出す。   When the current level value and the target level value of each of the EGs 70 to 72 are thus set, the process proceeds to step SC17 to instruct the waveform generator 75 to start waveform reading. As a result, the waveform generator 75 reads the sample waveform (original waveform data) from the normal read address (see FIG. 7) of the waveform memory 74 according to the read speed corresponding to the pitch of the pressed key.

次いで、ステップSC18では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレート値を、レジスタosc_env_rate[current_mode][1]から読み出してEG70の目標レート値に設定する。この結果、EG70は現在レベル値から目標レベル値に達するまで目標レート値に従って変化する音高制御用のエンベロープ波形を発生する。   Next, in step SC18, the rate value specified by the value of the register current_mode and the step value “1” is read from the register osc_env_rate [current_mode] [1] and set to the target rate value of the EG 70. As a result, the EG 70 generates an envelope waveform for pitch control that changes according to the target rate value until the target level value is reached from the current level value.

続いて、ステップSC19では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレート値を、レジスタfilter_env_rate[current_mode][1]から読み出してEG71の目標レート値に設定する。この結果、EG71は現在レベル値から目標レベル値に達するまで目標レート値に従って変化する音色制御用のエンベロープ波形を発生する。   Subsequently, in step SC19, the rate value specified by the value of the register current_mode and the step value “1” is read from the register filter_env_rate [current_mode] [1] and set to the target rate value of the EG 71. As a result, the EG 71 generates a tone color control envelope waveform that changes in accordance with the target rate value until the target level value is reached from the current level value.

そして、ステップSC20では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレート値を、レジスタamp_env_rate[current_mode][1]から読み出してEG72の目標レート値に設定して本処理を終える。この結果、EG72は現在レベル値から目標レベル値に達するまで目標レート値に従って変化する音量制御用のエンベロープ波形を発生する。   Then, in step SC20, the rate value specified by the value of the register current_mode and the step value “1” is read from the register amp_env_rate [current_mode] [1] and set to the target rate value of the EG 72, and this process ends. As a result, the EG 72 generates an envelope waveform for volume control that changes according to the target rate value until the target level value is reached from the current level value.

なお、以上のようにして、EG70〜72が音高、音色および音量を制御するエンベロープ波形を発生し始めた後は、前述したエンベロープ処理によって各エンベロープ波形の進行が制御される。   As described above, after the EGs 70 to 72 start to generate envelope waveforms for controlling the pitch, tone color, and volume, the progress of each envelope waveform is controlled by the envelope processing described above.

(4)ノートオフ処理の動作
図12〜図13は、ノートオフ処理の動作を示すフローチャートである。前述したメインルーチンのステップSA5(図8参照)を介して本処理が実行されると、CPU4は図12に図示するステップSD1に進み、離鍵された鍵の鍵番号をレジスタnew_keyにストアし、続くステップSD2では、レジスタnew_keyにストアされた鍵番号で指定されるレジスタkey_status[new_key]に「0」をストアする。これにより、新たに離鍵された鍵がオフ状態に設定されたことを表す。
(4) Operation of Note Off Process FIGS. 12 to 13 are flowcharts showing the operation of the note off process. When this process is executed through step SA5 (see FIG. 8) of the main routine described above, the CPU 4 proceeds to step SD1 shown in FIG. 12, stores the key number of the released key in the register new_key, In the subsequent step SD2, “0” is stored in the register key_status [new_key] specified by the key number stored in the register new_key. This indicates that the newly released key is set to the off state.

次いで、ステップSD3では、レジスタcurrent_keyの値が「−1」、すなわち現在発音中の楽音が無い無発音状態であるか否かを判断する。無発音状態ならば、判断結果は「YES」となり、本処理を終える。一方、発音中の楽音があると、上記ステップSD3の判断結果が「NO」になり、ステップSD4に進む。 Next, in step SD3, it is determined whether or not the value of the register current_key is “−1”, that is, whether or not there is no tone that is currently being generated. If there is no sound, the determination result is “YES” and the process is terminated. On the other hand, if there is a musical tone being sounded, the determination result in step SD3 is “NO”, and the process proceeds to step SD4.

ステップSD4〜SD6では、ポインタiを「0」〜「127」まで歩進させながら、レジスタkey_status[i]=1の鍵番号、すなわち押鍵中の鍵番号iを検索する。押鍵中の鍵番号iが検索されると、ステップSD5の判断結果が「YES」になり、ステップSD7に進む。なお、押鍵中の鍵番号が複数検索された場合には、その中で最も音高が高い鍵番号を優先的に選択する。また、押鍵中の鍵番号が検索されず、ポインタiを「127」まで歩進させた場合もステップSD6(ループ終了端)を経てステップSD7に進む。 In steps SD4 to SD6, the key number of the register key_status [i] = 1, that is, the key number i being pressed is searched while the pointer i is incremented from “0” to “127”. When the key number i being pressed is searched, the determination result in step SD5 is “YES”, and the flow proceeds to step SD7. When a plurality of key numbers being pressed are searched, the key number having the highest pitch among them is preferentially selected. If the key number being pressed is not searched and the pointer i is incremented to “127”, the process proceeds to step SD7 via step SD6 (loop end).

そして、ステップSD7では、ポインタiが「128」であるか否か、すなわち押鍵中の鍵番号を検索することが出来なかったかどうかを判断する。押鍵中の鍵番号を検索できなかった場合には、判断結果が「YES」になり、ステップSD8に進む。ステップSD8では、レジスタcurrent_modeの値とステップ値「4」とで指定されるレベル値を、レジスタosc_env_level[current_mode][4]から読み出してEG70の目標レベル値に、レジスタfilter_env_level[current_mode][4]から読み出してEG71の目標レベル値に、レジスタamp_env_level[current_mode][4]から読み出してEG72の目標レベル値にそれぞれ設定する。   In step SD7, it is determined whether or not the pointer i is “128”, that is, whether or not the key number being pressed could not be retrieved. If the key number being depressed cannot be retrieved, the determination result is “YES”, and the flow proceeds to step SD8. In step SD8, the level value specified by the value of the register current_mode and the step value “4” is read from the register osc_env_level [current_mode] [4] and is set to the target level value of the EG 70, from the register filter_env_level [current_mode] [4]. Read out and set to the target level value of the EG 71, read from the register amp_env_level [current_mode] [4], and set to the target level value of the EG 72.

次いで、ステップSD9では、レジスタcurrent_modeの値とステップ値「4」とで指定されるレート値を、レジスタosc_env_rate[current_mode][4]から読み出してEG70の目標レート値に、レジスタfilter_env_rate[current_mode][4]から読み出してEG71の目標レート値に、レジスタamp_env_rate[current_mode][4]から読み出してEG72の目標レート値にそれぞれ設定して本処理を終える。   Next, in step SD9, the rate value specified by the value of the register current_mode and the step value “4” is read from the register osc_env_rate [current_mode] [4] and is set to the target rate value of the EG 70, and the register filter_env_rate [current_mode] [4 ] Is read out from the register amp_env_rate [current_mode] [4] and set as the target rate value of the EG 72, and the process ends.

一方、上記ステップSD7の判断結果が「NO」の場合、すなわち押鍵中の鍵番号iを検索し得た場合には、リトリガ発音させる為、図13に図示するステップSD10に進む。ステップSD10では、レジスタnew_keyにストアされ、離鍵された鍵の鍵番号に対応した音高の楽音を消音するよう音源7に指示すると共に、上記ステップSD4〜SD6にて検索された押鍵中の鍵番号iを、リトリガ発音する鍵番号としてレジスタnew_keyにストアする。   On the other hand, if the determination result in step SD7 is “NO”, that is, if the key number i being pressed can be retrieved, the process proceeds to step SD10 shown in FIG. In step SD10, the sound source 7 is instructed to mute the musical tone having a pitch corresponding to the key number of the key that has been released and stored in the register new_key, and the key pressed during the key depression searched in steps SD4 to SD6 above. The key number i is stored in the register new_key as the key number for generating the retrigger.

次いで、ステップSD11では、離鍵された鍵の鍵番号と、レジスタnew_keyにストアした鍵番号iとが同じ鍵域であるか否かを判断する。例えば図14に図示するように1オクターブ毎に鍵域分割された鍵域2において「1」(F4音)、「2」(B4音)の順に押鍵し、「2」(B4音)を離鍵した場合には、同じ鍵域でのリトリガ発音となるので、上記ステップSD11の判断結果は「YES」になり、ステップSD12に進み、同スプリット・リトリガ発音モードを表す値「2」をレジスタcurrent_modeにストアする。   Next, in step SD11, it is determined whether or not the key number of the released key and the key number i stored in the register new_key are in the same key range. For example, as shown in FIG. 14, in the key range 2 divided into one octave, “1” (F4 sound), “2” (B4 sound) are pressed in this order, and “2” (B4 sound) is pressed. When the key is released, retrigger sounding is performed in the same key range, so the determination result in step SD11 is “YES”, the process proceeds to step SD12, and the value “2” representing the split retrigger sounding mode is registered. Store in current_mode.

これに対し、例えば図14に図示する鍵域2の「1」(F4音)、鍵域3の「3」(E3音)の順に押鍵し、鍵域3の「3」(E3音)を離鍵した場合には、異なる鍵域でのリトリガ発音となるので、上記ステップSD11の判断結果は「NO」になり、ステップSD13に進み、異スプリット・リトリガ発音モードを表す値「1」をレジスタcurrent_modeにストアする。   On the other hand, for example, “1” (F4 sound) of key range 2 shown in FIG. 14 and “3” (E3 sound) of key range 3 are pressed in this order, and “3” (E3 sound) of key range 3 is pressed. When the key is released, retrigger sounding is performed in a different key range, so the determination result in step SD11 is “NO”, and the process proceeds to step SD13 to set the value “1” representing the different split / retrigger sounding mode. Store in the register current_mode.

このようにして、同スプリット・リトリガ発音モード(又は異スプリット・リトリガ発音モード)が決定されると、ステップSD14に進み、レジスタnew_keyのリトリガ発音する鍵番号iを、レジスタcurrent_keyにストアする。そして、ステップSD15に進み、レジスタcurrent_modeの値が「2」ならば、レジスタstart_address[current_mode]から同スプリット・リトリガ用読み出し開始アドレス(図7参照)を読み出して波形発生器75にセットする。一方、レジスタcurrent_modeの値が「1」ならば、レジスタstart_address[current_mode]から異スプリット・リトリガ用読み出し開始アドレス(図7参照)を読み出して波形発生器75にセットする。   When the split retrigger sound generation mode (or different split retrigger sound generation mode) is determined in this way, the process proceeds to step SD14, and the key number i that generates the retrigger of the register new_key is stored in the register current_key. In step SD15, if the value of the register current_mode is “2”, the read start address for split retrigger (see FIG. 7) is read from the register start_address [current_mode] and set in the waveform generator 75. On the other hand, if the value of the register current_mode is “1”, the read start address for different split retrigger (see FIG. 7) is read from the register start_address [current_mode] and set in the waveform generator 75.

また、ステップSD15では、レジスタcurrent_keyにストアされ、リトリガ発音する鍵番号に対応した音高データを波形発生器75にセットする。さらに、ステップSD15では、レジスタcurrent_modeの値、つまり同スプリット・リトリガ発音モード(あるいは異スプリット・リトリガ発音モード)を表す値とステップ値「0」とで指定されるレベル値を、レジスタosc_env_level[current_mode][0]から読み出してEG70の現在レベル値に設定すると共に、レジスタcurrent_modeの値とステップ値「1」とで指定されるレベル値を、レジスタosc_env_level[current_mode][1]から読み出してEG70の目標レベル値に設定する。   In step SD15, pitch data stored in the register current_key and corresponding to the key number to be retriggered is set in the waveform generator 75. Further, in step SD15, the value of the register current_mode, that is, a value indicating the same split / retrigger sound generation mode (or different split / retrigger sound generation mode) and a level value specified by the step value “0” are stored in the register osc_env_level [current_mode]. [0] is read and set to the current level value of the EG 70, and the level value specified by the value of the register current_mode and the step value “1” is read from the register osc_env_level [current_mode] [1] to be the target level of the EG 70 Set to value.

次に、ステップSD16では、発生楽音の音色に応じたフィルタ係数(カットオフ周波数指定データ)を初期値としてフィルタ77に設定すると共に、レジスタcurrent_modeの値とステップ値「0」とで指定されるレベル値を、レジスタfilter_env_level[current_mode][0]から読み出してEG71の現在レベル値に設定する。また、ステップSD16では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレベル値を、レジスタfilter_env_level[current_mode][1]から読み出してEG71の目標レベル値に設定する。   Next, in step SD16, a filter coefficient (cutoff frequency designation data) corresponding to the tone color of the generated musical tone is set in the filter 77 as an initial value, and the level designated by the value of the register current_mode and the step value “0”. The value is read from the register filter_env_level [current_mode] [0] and set to the current level value of the EG 71. In step SD16, the level value specified by the value of the register current_mode and the step value “1” is read from the register filter_env_level [current_mode] [1] and set to the target level value of the EG 71.

次いで、ステップSD17では、発生楽音の音色に応じた乗算係数(増幅率)を初期値として増幅器79に設定すると共に、レジスタcurrent_modeの値とステップ値「0」とで指定されるレベル値を、レジスタamp_env_level[current_mode][0]から読み出してEG72の現在レベル値に設定する。また、ステップSD17では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレベル値を、レジスタamp_env_level[current_mode][1]から読み出してEG72の目標レベル値に設定する。 Next, in step SD17, the multiplication coefficient (amplification factor) corresponding to the tone color of the generated musical tone is set as an initial value in the amplifier 79, and the level value specified by the value of the register current_mode and the step value “0” is set in the register. Read from amp_env_level [current_mode] [0] and set to the current level value of EG72. In step SD17, the level value specified by the value of the register current_mode and the step value “1” is read from the register amp_env_level [current_mode] [1] and set to the target level value of the EG 72.

続いて、ステップSD18では、波形発生器75に波形読み出し開始を指示すると共に、レジスタcurrent_modeの値とステップ値「1」とで指定されるレート値を、レジスタosc_env_rate[current_mode][1]から読み出してEG70の目標レート値に設定する。また、ステップSD18では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレート値を、レジスタfilter_env_rate[current_mode][1]から読み出してEG71の目標レート値に設定する。さらに、ステップSD18では、レジスタcurrent_modeの値とステップ値「1」とで指定されるレート値を、レジスタamp_env_rate[current_mode][1]から読み出してEG72の目標レート値に設定して本処理を終える。   Subsequently, in step SD18, the waveform generator 75 is instructed to start waveform reading, and the rate value specified by the value of the register current_mode and the step value “1” is read from the register osc_env_rate [current_mode] [1]. Set to the target rate value of EG70. In step SD18, the rate value specified by the value of the register current_mode and the step value “1” is read from the register filter_env_rate [current_mode] [1] and set to the target rate value of the EG 71. Further, in step SD18, the rate value specified by the value of the register current_mode and the step value “1” is read from the register amp_env_rate [current_mode] [1] and set to the target rate value of the EG 72, and the process is terminated.

以上説明したように、本実施形態では、離鍵時に押鍵中の鍵が存在すると、離鍵した鍵と押鍵中の鍵とが同じ鍵域もしくは異なる鍵域のいずれであるかを判断する。離鍵した鍵と押鍵中の鍵とが同じ鍵域であれば、同スプリット・リトリガ発音モードに設定し、一方、異なる鍵域ならば、異スプリット・リトリガ発音モードに設定する。   As described above, in this embodiment, if there is a key being pressed when the key is released, it is determined whether the released key and the key being pressed are in the same key range or different key ranges. . If the released key and the key being pressed are in the same key range, the same split / retrigger sounding mode is set. On the other hand, if the key range is different, the different split / retrigger sounding mode is set.

そして、同スプリット・リトリガ発音モードに設定された場合には、押鍵中の鍵の音高に対応した読み出し速度で波形メモリ74の同スプリット・リトリガ用読み出し開始アドレスからサンプル波形(原波形データ)を読み出し、読み出したサンプル波形を同スプリット・リトリガ・エンベロープ波形で変調してなる楽音を形成してリトリガ発音させる。これに対し、異スプリット・リトリガ発音モードに設定された場合には、押鍵中の鍵の音高に対応した読み出し速度で波形メモリ74の異スプリット・リトリガ用読み出し開始アドレスからサンプル波形(原波形データ)を読み出し、読み出したサンプル波形を異スプリット・リトリガ・エンベロープ波形で変調してなる楽音を形成して再発音する。   When the split retrigger sound generation mode is set, the sample waveform (original waveform data) is read from the read start address for split retrigger in the waveform memory 74 at a reading speed corresponding to the pitch of the key being pressed. Is read out, and the read sample waveform is modulated with the split retrigger envelope waveform to form a musical sound and generate a retrigger sound. On the other hand, when the different split / retrigger sound generation mode is set, the sample waveform (original waveform) is read from the read start address for different split / retrigger in the waveform memory 74 at a reading speed corresponding to the pitch of the key being pressed. Data), and re-sounds by generating a musical sound that is obtained by modulating the read sample waveform with a different split / retrigger / envelope waveform.

つまり、リトリガ発音する際に、離鍵した鍵と押鍵中の鍵とが同じ鍵域であるか否かに応じて楽音形成に用いるエンベロープ波形を異ならせたり、サンプル波形の読み出し開始位置を変化させる結果、管楽器を演奏した時のような比較的音量変化の無い滑らかな音程変化や、ギターに代表される弦楽器を演奏した時の独特のアタック感を備えた音を得られることから、管楽器や弦楽器を実際に演奏しているような不自然さの無いリトリガ奏法を実現することが可能になる。   In other words, when retriggering is sounded, the envelope waveform used for tone generation differs depending on whether the key released and the key being pressed are in the same key range, or the reading start position of the sample waveform is changed. As a result, it is possible to obtain a sound with a smooth pitch change that does not change relatively like when playing a wind instrument, and a unique attack feeling when playing a stringed instrument represented by a guitar. It becomes possible to realize a retriggering method free from the unnaturalness of actually playing a stringed instrument.

なお、上述した実施形態では、離鍵時に押鍵中の鍵が複数検索された場合には、その中で最も音高が高い鍵をリトリガ発音する鍵に選択する態様としたが、これに限らず、押鍵されている鍵の中で最後に押鍵された鍵をリトリガ発音する鍵に選択する態様としても構わない。   In the above-described embodiment, when a plurality of keys being pressed are searched for when a key is released, the key with the highest pitch among them is selected as the key for retriggering, but this is not limitative. Alternatively, a mode in which the last key pressed among keys that have been pressed may be selected as a key that generates retriggers.

本発明の一実施形態である楽音発生装置10の全体構成を示すブロック図である。It is a block diagram which shows the whole structure of the musical tone generator 10 which is one Embodiment of this invention. RAM6に設けられる主要レジスタの構成を示すメモリマップである。3 is a memory map showing a configuration of main registers provided in a RAM 6; 音源7の構成を示すブロック図である。3 is a block diagram showing a configuration of a sound source 7. FIG. EG70から出力されるエンベロープ波形の一例を示す図である。It is a figure which shows an example of the envelope waveform output from EG70. EG71から出力されるエンベロープ波形の一例を示す図である。It is a figure which shows an example of the envelope waveform output from EG71. EG72から出力されるエンベロープ波形の一例を示す図である。It is a figure which shows an example of the envelope waveform output from EG72. 波形メモリ74に記憶されるサンプル波形の通常読み出し開始アドレス、同スプリット・リトリガ用読み出し開始アドレスおよび異スプリット・リトリガ用読み出し開始アドレスを示す図である。It is a figure which shows the normal read start address of the sample waveform memorize | stored in the waveform memory 74, the read start address for the same split retrigger, and the read start address for different split retriggers. CPU4が実行するメインルーチンの動作を示すフローチャートである。It is a flowchart which shows operation | movement of the main routine which CPU4 performs. CPU4が実行するエンベロープ処理の動作を示すフローチャートである。It is a flowchart which shows the operation | movement of the envelope process which CPU4 performs. CPU4が実行するエンベロープ処理の動作を示すフローチャートである。It is a flowchart which shows the operation | movement of the envelope process which CPU4 performs. CPU4が実行するノートオン処理の動作を示すフローチャートである。It is a flowchart which shows the operation | movement of the note-on process which CPU4 performs. CPU4が実行するノートオフ処理の動作を示すフローチャートである。It is a flowchart which shows the operation | movement of the note-off process which CPU4 performs. CPU4が実行するノートオフ処理の動作を示すフローチャートである。It is a flowchart which shows the operation | movement of the note-off process which CPU4 performs. ノートオフ処理の動作を説明するための図である。It is a figure for demonstrating operation | movement of a note-off process.

符号の説明Explanation of symbols

1 鍵盤
2 MIDIインタフェース
3 スイッチ部
4 CPU
5 ROM
6 RAM
7 音源
8 D/A変換器
9 サウンドシステム
1 Keyboard 2 MIDI Interface 3 Switch 4 CPU
5 ROM
6 RAM
7 Sound source 8 D / A converter 9 Sound system

Claims (3)

発音域を複数の音高域に分割し、分割された各音高域毎の波形データを記憶する波形記憶手段と、
第1の楽音の消音を指示した時に、発音指示中にある第2の楽音を検出する検出手段と、
前記検出手段により第2の楽音が検出された場合に、第1および第2の楽音の各音高が異なる音高域に含まれる場合には第1の再発音モードでの再発音を指示し、一方、同じ音高域に含まれる場合には第2の再発音モードでの再発音を指示する再発音指示手段と、
前記第1の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第1の読み出し開始アドレスと、前記第2の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第2の読み出し開始アドレスとを記憶するアドレス記憶手段と、
前記第1の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第1の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを通常エンベロープ波形よりも波形レベルの小さい第1のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第1のリトリガ発音手段と、
前記第2の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第2の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを前記通常エンベロープ波形よりも波形レベルの小さい第2のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第2のリトリガ発音手段と
を具備することを特徴とする楽音発生装置。
Waveform storage means for dividing the pronunciation range into a plurality of pitch ranges and storing waveform data for each divided pitch range;
Detecting means for detecting the second musical sound that is being instructed to generate sound when instructing to mute the first musical sound;
When the second musical tone is detected by the detecting means, if the pitches of the first and second musical sounds are included in different pitch ranges, the re-sounding in the first re-sounding mode is instructed. On the other hand, when included in the same pitch range, a re-sounding instruction means for instructing re-sounding in the second re-sound mode
A first read start address for reading waveform data of a pitch range including a second musical tone from the waveform storage means under the first re-sounding mode, and the waveform storage under the second re-sounding mode. Address storage means for storing a second readout start address for reading out waveform data of the pitch range including the second musical tone from the means;
When re-sounding in the first re-sounding mode is instructed, the waveform data read from the waveform storing unit according to the first reading start address stored in the address storing unit is set to a waveform level higher than the normal envelope waveform. First retrigger sounding means for retriggering a second musical tone formed by modulating with a small first envelope waveform;
When re-sounding in the second re-sounding mode is instructed, the waveform data read from the waveform storing unit according to the second reading start address stored in the address storing unit is set to be more waveform than the normal envelope waveform. A musical tone generator comprising: second retrigger sound generation means for retriggering a second musical sound formed by modulating with a second envelope waveform having a low level .
前記検出手段は、第1の楽音の消音を指示した時に、発音指示中にある楽音が複数存在した場合、それらの中で最後に発音指示された楽音を第2の楽音として検出することを特徴とする請求項1記載の楽音発生装置。   The detection means detects a musical tone that is instructed to be sounded last as a second musical tone when there are a plurality of musical sounds that are being instructed to be pronounced when the silence of the first musical tone is instructed. The musical tone generator according to claim 1. 発音域を複数の音高域に分割し、分割された各音高域毎の波形データを記憶する波形記憶手段と、第1の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第1の読み出し開始アドレスと、第2の再発音モード下で前記波形記憶手段から第2の楽音を含む音高域の波形データを読み出すための第2の読み出し開始アドレスとを記憶するアドレス記憶手段と、を有するコンピュータに、
第1の楽音の消音を指示した時に、発音指示中にある第2の楽音を検出する検出処理と、
前記検出処理により第2の楽音が検出された場合に、第1および第2の楽音の各音高が異なる音高域に含まれる場合には前記第1の再発音モードでの再発音を指示し、一方、同じ音高域に含まれる場合には前記第2の再発音モードでの再発音を指示する再発音指示処理と、
前記第1の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第1の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを通常エンベロープ波形よりも波形レベルの小さい第1のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第1のリトリガ発音処理と、
前記第2の再発音モードでの再発音が指示された場合に、前記アドレス記憶手段に記憶される第2の読み出し開始アドレスに従って前記波形記憶手段から読み出される波形データを前記通常エンベロープ波形よりも波形レベルの小さい第2のエンベロープ波形で変調して形成した第2の楽音をリトリガ発音する第2のリトリガ発音処理と
を実行させることを特徴とする楽音発生処理プログラム。
Waveform storage means for dividing the pronunciation range into a plurality of pitch ranges and storing waveform data for each divided pitch range, and including the second musical sound from the waveform storage means in the first re-sounding mode A first read start address for reading the waveform data of the pitch range, and a second for reading the waveform data of the pitch range including the second musical tone from the waveform storage means under the second re-sounding mode. An address storage means for storing a read start address;
A detection process for detecting a second musical sound that is in the sound generation instruction when the mute of the first musical sound is instructed;
When the second musical sound is detected by the detection process, an instruction re pronunciation in the first re-sound mode if each pitch of the first and second tone may be included in different pitch ranges and, on the other hand, the re-sounding instruction process for instructing a re pronunciation in the second re-sound mode when included in the same pitch range,
When re-sounding in the first re-sounding mode is instructed, the waveform data read from the waveform storing unit according to the first reading start address stored in the address storing unit is set to a waveform level higher than the normal envelope waveform. A first retrigger sound generation process that retriggers a second musical tone formed by modulating with a first envelope waveform having a small
When re-sounding in the second re-sounding mode is instructed, the waveform data read from the waveform storing unit according to the second reading start address stored in the address storing unit is set to be more waveform than the normal envelope waveform. A second retrigger sound generation process that retriggers a second musical tone formed by modulating with a second envelope waveform having a low level;
Tone generating processing program for causing the execution.
JP2008025860A 2008-02-06 2008-02-06 Musical sound generator and musical sound generation processing program Active JP5246473B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2008025860A JP5246473B2 (en) 2008-02-06 2008-02-06 Musical sound generator and musical sound generation processing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2008025860A JP5246473B2 (en) 2008-02-06 2008-02-06 Musical sound generator and musical sound generation processing program

Publications (2)

Publication Number Publication Date
JP2009186698A JP2009186698A (en) 2009-08-20
JP5246473B2 true JP5246473B2 (en) 2013-07-24

Family

ID=41070011

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2008025860A Active JP5246473B2 (en) 2008-02-06 2008-02-06 Musical sound generator and musical sound generation processing program

Country Status (1)

Country Link
JP (1) JP5246473B2 (en)

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS5997196A (en) * 1982-11-26 1984-06-04 ヤマハ株式会社 Touch response device for electronic musical instrument
JPH0720865A (en) * 1993-06-30 1995-01-24 Kawai Musical Instr Mfg Co Ltd Electronic musical instrument
JP4175744B2 (en) * 1999-08-20 2008-11-05 ローランド株式会社 Electronic musical instruments
JP2001125572A (en) * 1999-10-26 2001-05-11 Kawai Musical Instr Mfg Co Ltd Electronic musical instrument, musical sound generation control method and storage medium

Also Published As

Publication number Publication date
JP2009186698A (en) 2009-08-20

Similar Documents

Publication Publication Date Title
JP5700351B2 (en) Automatic performance device and program
JP6414164B2 (en) Automatic performance device, automatic performance method, program, and electronic musical instrument
JP7190284B2 (en) Harmony generator and its program
KR0130053B1 (en) Elctron musical instruments, musical tone processing device and method
JP5246473B2 (en) Musical sound generator and musical sound generation processing program
JP5030016B2 (en) Musical sound generator and musical sound generation processing program
JP2018146928A (en) Electronic musical instrument, musical sound generating method, and program
JP4029286B2 (en) Performance recording / reproducing apparatus and performance recording / reproducing program
JP5115800B2 (en) Low frequency oscillation device and low frequency oscillation processing program
JP3743993B2 (en) Code determination apparatus, code determination method, and medium recording code determination method
JP4513738B2 (en) Performance apparatus and performance processing program
JP3940999B2 (en) Performance device and performance method
JP4576565B2 (en) Performance apparatus and performance processing program
JP4207884B2 (en) Musical sound control device and musical sound control processing program
JP4206830B2 (en) Musical sound control device and musical sound control program
JP5769080B2 (en) Sound channel assignment apparatus and program
JP6439225B2 (en) Musical sound generating device, electronic musical instrument, musical sound generating method and program
JP2001282243A (en) Electronic musical tone generator, electronic musical tone generating method and recording medium
JP2007187949A (en) Musical sound generator and program for musical sound generation processing
JP5548975B2 (en) Performance data generating apparatus and program
JP4591826B2 (en) Musical sound generating device and musical sound generating program
JP4492680B2 (en) Music generator
JP3548810B2 (en) Music data recording device
JP2014153378A (en) Performance device, performance method, and program
JP2006337450A (en) Device and program for generation of musical sound

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20110124

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20120731

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20120926

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20130314

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20130327

R150 Certificate of patent or registration of utility model

Ref document number: 5246473

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20160419

Year of fee payment: 3