BIT EXPANSION PROCESSING DEVICE, BIT EXPANSION PROCESSING METHOD, AND BIT EXPANSION PROCESSING PROGRAM
The bit extension processing device and method address the issue of varying sound quality in digital music by correcting flat regions in digital music signals, ensuring high-quality expansion across different songs through frame conversion, differential signal processing, and re-quantization error correction.
Patent Information
- Application Number
- JP2021101324
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-06-18
- Publication Date
- 2025-01-28
- Estimated Expiration
- 2041-06-18
AI Technical Summary
Existing bit extension processing methods fail to improve sound quality in digital music signals when the sample values change drastically, limiting their effectiveness across different types of songs.
A bit extension processing device and method that includes a frame conversion unit, differential signal calculation, flat region detection and correction, differential signal averaging, and re-quantization error correction to enhance sound quality by adjusting sample values within flat regions.
The method and device ensure high-quality bit expansion of digital music signals regardless of song type by correcting flat regions, improving sound quality and maintaining correlation with re-quantization error signals.
Smart Images

Figure 0007622564000001 
Figure 0007622564000002 
Figure 0007622564000003
Abstract
Description
[Technical field]
[0001] The present invention relates to a bit extension processing device, a bit extension processing method, and a bit extension processing program for expanding the number of quantization bits of a digital music signal. [Background technology]
[0002] A digital audio signal with a quantization bit rate of m bits (where m and n are positive integers and n>m) may be extended to n bits by a bit extension processing device. A bit extension processing device that employs a simple bit extension processing method adds (nm) bits of zero data to the lower bits of an m-bit digital audio signal to generate an n-bit digital audio signal. Generally, bit extension processing tools built into audio editing software employ such a simple bit extension processing method. [Prior art documents] [Patent documents]
[0003] [Patent Document 1] JP 2004-180017 A Summary of the Invention [Problem to be solved by the invention]
[0004] Patent Document 1 describes an improved bit extension processing program. According to the bit extension processing program described in Patent Document 1, when a digital music signal of a quiet piece of music in which the same sample values are successively processed as a target for bit extension processing is processed, the quality (sound quality) of the bit extension processing can be improved. However, when a digital music signal of a piece of music in which the sample values change drastically is processed, the quality cannot be improved much.
[0005] An object of the present invention is to provide a bit extension processing device, a bit extension processing method, and a bit extension processing program that are capable of performing high-quality bit extension processing on digital music signals regardless of the type of music. [Means for solving the problem]
[0006] The present invention provides a bit expansion processing device including a framing processing unit, a difference signal calculation unit, a flat region detection unit, a flat region correction unit, a difference signal averaging unit, a requantization error generation unit, and an addition unit.
[0007] The framing processing unit divides samples of the first digital music signal quantized with a first quantization bit rate into frames by dividing them into a plurality of sample numbers. The difference signal calculation unit calculates a first difference signal using a difference value between two adjacent samples of the first digital music signal included in each frame as a sample. The flat region detection unit detects the start and end positions of a flat region in which two or more samples having the same sample value are consecutive in the first difference signal, and the number of samples in the flat region.
[0008] The flat region correction unit selects one or more samples from the samples in the flat region as samples to be corrected, depending on whether the sample values rise or fall from the sample just before the flat region to the sample at the start position, and whether the sample values rise or fall from the end position to the sample just after the flat region, and corrects the sample values to be corrected by adding or subtracting a correction value to the sample values to be corrected, thereby generating a second differential signal in which the flat region is non-flattened.
[0009] The differential signal averaging unit sums up sample values of the second differential signal included in each of the frames, divides the sum by the number of samples of the second differential signal included in each of the frames to calculate an average differential value, and subtracts the average differential value from each sample value of the second differential signal to generate a third differential signal.
[0010] The requantization error generating section generates a requantization error signal expressed by a number of bits that is a difference between the first quantization bit rate and a second quantization bit rate that is greater than the first quantization bit rate, based on the third difference signal. The adding section adds the requantization error signal to the first digital music signal included in each frame, and outputs a second digital music signal having the second quantization bit rate.
[0011] The present invention provides a bit extension processing method that executes the following process: The bit extension processing method divides samples of a first digital music signal quantized with a first quantization bit rate into frames for each number of samples, calculates a first differential signal using the difference value between two adjacent samples of the first digital music signal included in each frame as a sample, and detects the start and end positions of a flat region in the first differential signal where two or more consecutive difference samples have the same difference value, and the number of difference samples in the flat region.
[0012] The bit extension processing method selects one or more of the difference samples of the flat region as difference samples to be corrected depending on a pattern of whether the difference value rises or falls from the difference sample immediately before the flat region to the difference sample at the start position, and whether the difference value rises or falls from the end position to the difference sample after the flat region, and corrects the sample value to be corrected by adding or subtracting a correction value to the sample value to be corrected, thereby generating a second difference signal in which the flat region is non-flattened.
[0013] The bit extension processing method sums up the sample values of the second differential signal included in each frame, divides the sum by the number of samples of the second differential signal included in each frame to calculate an average difference value, determines whether the average difference value is zero, and if the average difference value is zero, sets the second differential signal to a third differential signal, and if the average difference value is not zero, subtracts the average difference value from each sample value of the second differential signal to generate the third differential signal.
[0014] The bit expansion processing method generates a re-quantization error signal for each frame expressed in a number of bits that is the difference between the first quantization bit number and a second quantization bit number that is greater than the first quantization bit number, based on the third difference signal, and adds the re-quantization error signal to the first digital music signal included in each frame to generate a second digital music signal having the second quantization bit number.
[0015] The present invention provides a bit extension processing program for causing a computer to execute the following steps: dividing samples of a first digital music signal quantized with a first quantization bit rate into frames for each number of samples, calculating a first differential signal using a difference value between two adjacent samples of the first digital music signal included in each frame as a sample, and detecting start and end positions of a flat region in the first differential signal where two or more consecutive difference samples have the same difference value, and the number of difference samples in the flat region.
[0016] The bit extension processing program causes the computer to execute a step of selecting one or more of the difference samples of the flat region as difference samples to be corrected depending on a pattern of whether the difference value rises or falls from the difference sample immediately before the flat region to the difference sample at the start position, and whether the difference value rises or falls from the end position to the difference sample after the flat region, and correcting the sample value to be corrected by adding or subtracting a correction value to the sample value to be corrected, thereby generating a second difference signal in which the flat region is non-flat.
[0017] The bit extension processing program causes a computer to execute the steps of: summing sample values of the second differential signal included in each frame, dividing the sum by the number of samples of the second differential signal included in each frame to calculate an average differential value, and determining whether the average differential value is zero; and, if the average differential value is zero, treating the second differential signal as a third differential signal, and, if the average differential value is not zero, subtracting the average differential value from each sample value of the second differential signal to generate the third differential signal.
[0018] The bit extension processing program causes a computer to execute the steps of generating a re-quantization error signal for each frame, expressed in a number of bits that is the difference between the first quantization bit number and a second quantization bit number that is greater than the first quantization bit number, based on the third difference signal, and adding the re-quantization error signal to the first digital music signal included in each frame to generate a second digital music signal having the second quantization bit number. Effect of the Invention
[0019] According to the bit extension processing device, the bit extension processing method, and the bit extension processing program of the present invention, it is possible to perform high-quality bit extension processing on a digital music signal regardless of the type of music. [Brief description of the drawings]
[0020] [Figure 1] FIG. 1 is a block diagram showing a bit extension processing device according to an embodiment. [Diagram 2] FIG. 2 is a diagram conceptually illustrating the operations of a differential signal calculation unit and a flat region detection unit in the bit extension processing device of an embodiment. [Diagram 3] FIG. 3 is a waveform diagram showing requantization error signals of two digital music signals that have been quantized and recorded in two formats, one with a quantization bit rate of 24 bits and the other with a quantization bit rate of 16 bits. [Figure 4]FIG. 4 is a waveform diagram showing the difference between two adjacent samples in a digital music signal with a quantization bit rate of 16 bits. [Figure 5A] FIG. 5A is a diagram showing a first example of an up-flat-down pattern in which the number of samples in the flat region is two and a correction method for the flat region in this case. [Figure 5B] FIG. 5B is a diagram showing a first example of an up-flat-up pattern in which the number of samples in the flat region is two and a correction method for the flat region in this case. [Figure 5C] FIG. 5C is a diagram showing a first example of a fall-flat-rise pattern in which the number of samples in the flat region is two and a correction method for the flat region in this case. [Figure 5D] FIG. 5D is a diagram showing a fall-flat-fall pattern in which the number of samples in the flat region is two, and a first example of a correction method for the flat region in this case. [Figure 6A] FIG. 6A is a diagram showing an up-flat-down pattern in which the number of samples in the flat region is 3, and a first example of a correction method for the flat region in this case. [Figure 6B] FIG. 6B is a diagram showing an up-flat-up pattern in which the number of samples in the flat region is 3, and a first example of a correction method for the flat region in this case. [Figure 6C] FIG. 6C is a diagram showing a fall-flat-up pattern in which the number of samples in the flat region is 3, and a first example of a correction method for the flat region in this case. [Figure 6D] FIG. 6D is a diagram showing a fall-flat-fall pattern in which the number of samples in the flat region is 3, and a first example of a correction method for the flat region in this case. [Figure 7A] FIG. 7A is a diagram showing an up-flat-down pattern in which the number of samples in the flat region is four, and a first example of a correction method for the flat region in this case. [Figure 7B] FIG. 7B is a diagram showing an up-flat-up pattern in which the number of samples in the flat region is 4, and a first example of a correction method for the flat region in this case. [Figure 7C] FIG. 7C is a diagram showing a first example of a fall-flat-rise pattern in which the number of samples in the flat region is four and a correction method for the flat region in this case. [Figure 7D] FIG. 7D is a diagram showing a fall-flat-fall pattern in which the number of samples in the flat region is 4, and a first example of a correction method for the flat region in this case. [Figure 8A] FIG. 8A is a diagram showing a first example of an up-flat-down pattern in which the number of samples in the flat region is five, and a correction method for the flat region in this case. [Figure 8B] FIG. 8B is a diagram showing an up-flat-up pattern in which the number of samples in the flat region is 5, and a first example of a correction method for the flat region in this case. [Figure 8C] FIG. 8C is a diagram showing a first example of a fall-flat-rise pattern in which the number of samples in the flat region is 5 and a correction method for the flat region in this case. [Figure 8D] FIG. 8D is a diagram showing a first example of a fall-flat-fall pattern in which the number of samples in the flat region is 5, and a correction method for the flat region in this case. [Figure 9] FIG. 9 is a diagram showing a second example of a fall-flat-fall pattern in which the number of samples in the flat region is two, and a correction method for the flat region in this case. [Figure 10A] FIG. 10A is a diagram showing a second example of an up-flat-down pattern in which the number of samples in the flat region is three and a correction method for the flat region in this case. [Figure 10B] FIG. 10B is a diagram showing a second example of an up-flat-up pattern in which the number of samples in the flat region is 3 and a correction method for the flat region in this case. [Figure 11A] FIG. 11A is a diagram showing an up-flat-down pattern in which the number of samples in the flat region is four, and a second example of a correction method for the flat region in this case. [Figure 11B] FIG. 11B is a diagram showing a second example of an up-flat-up pattern in which the number of samples in the flat region is four and a correction method for the flat region in this case. [Figure 11C] FIG. 11C is a diagram showing a second example of a fall-flat-up pattern in which the number of samples in the flat region is four and a correction method for the flat region in this case. [Figure 11D]FIG. 11D is a diagram showing a second example of a fall-flat-fall pattern in which the number of samples in the flat region is 4 and a correction method for the flat region in this case. [Figure 12A] FIG. 12A is a diagram showing a second example of an up-flat-down pattern in which the number of samples in the flat region is five and a correction method for the flat region in this case. [Figure 12B] FIG. 12B is a diagram showing a second example of an up-flat-up pattern in which the number of samples in the flat region is five, and a correction method for the flat region in this case. [Figure 12C] FIG. 12C is a diagram showing a second example of a fall-flat-rise pattern in which the number of samples in the flat region is five, and a correction method for the flat region in this case. [Figure 12D] FIG. 12D is a diagram showing a second example of a fall-flat-fall pattern in which the number of samples in the flat region is 5 and a correction method for the flat region in this case. [Figure 13] FIG. 13 is a waveform diagram showing a requantization error signal of a digital music signal obtained by quantizing and recording a performance of a specific piece of music in a format with a quantization bit rate of 24 bits. [Figure 14] FIG. 14 is a waveform diagram showing a requantization error signal of a digital music signal obtained by bit-extending the number of quantization bits to 24 bits using a bit extension processing device according to an embodiment of the present invention, the digital music signal being the same piece of music as that shown in FIG. [Figure 15] FIG. 15 is a block diagram illustrating an example of the configuration of a computer that executes a bit extension processing program according to an embodiment. [Figure 16] FIG. 16 is a flowchart showing the operation of a bit extension processing device according to an embodiment, a process according to a bit extension processing method according to an embodiment, and a process executed by a computer according to a bit extension processing program according to an embodiment. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0021] Hereinafter, a bit extension processing device, a bit extension processing method, and a bit extension processing program according to an embodiment will be described with reference to the accompanying drawings.
[0022] 1 performs bit extension processing on an input digital music signal quantized with a quantization bit rate of m bits (first quantization bit rate), where m and n are positive integers and n>m, and outputs a digital music signal with a quantization bit rate of n bits (second quantization bit rate). As an example, the sampling frequency (fs) of the input digital music signal is 192 kHz, the quantization bit rate is 16 bits, and the sampling frequency of the output digital music signal is 192 kHz, and the quantization bit rate is 24 bits.
[0023] The bit extension processing device 100 includes a framing processing unit 1, a differential signal calculation unit 2, a flat region detection unit 3, a flat region correction unit 4, a differential signal averaging unit 5, a requantization error generation unit 6, an adder 7, and a delay unit 8.
[0024] The framing processor 1 divides samples input in sequence in the digital music signal into frames at predetermined time intervals (i.e., at predetermined multiple sample intervals). As an example, the framing processor 1 divides a series of samples of the input digital music signal into 128 samples each to form one frame including 128 samples. The differential signal calculation unit 2 calculates a differential signal (first differential signal) using the difference value between a current sample and the previous sample of the samples input in sequence in each frame as a sample. To distinguish between samples of the input digital music signal and samples of the differential signal, the samples of the differential signal will be referred to as differential samples.
[0025] The operations of the differential signal calculation unit 2 and flat region detection unit 3 will be described in detail with reference to Fig. 2. In Fig. 2, (a) shows an example of changes in sample values of samples S0 to S8 of a digital music signal supplied from the framing processing unit 1 to the differential signal calculation unit 2. It is assumed that the sample values of samples S0 to S8 are 0, 1, 4, 5, 6, 7, 3, 2, and 4, respectively.
[0026] As shown in Fig. 2(b), the differential signal calculation unit 2 calculates the differential value between each of the samples S1 to S8, which are the current sample, and the previous sample S0 to S7. In the waveform shown in Fig. 2(a), differential values of 1, 3, 1, 1, 1, -4, -1, and 2 are obtained corresponding to the samples S1 to S8. Fig. 2(c) shows a differential signal based on the differential values shown in Fig. 2(b). The differential signal calculated by the differential signal calculation unit 2 is a numeric sequence of the differential values obtained corresponding to each sample. The differential signal shown in Fig. 2(c) includes differential samples D1 to D8.
[0027] If sample S0 is the first sample in a frame, there is no sample immediately preceding sample S0. As described below, the difference signal calculated by the difference signal calculation unit 2 is supplied to the flat region detection unit 3, which detects a flat region in which the difference values in the difference signal (sample values of the difference sample) are the same value. If the difference signal calculation unit 2 mistakenly outputs a difference value at the time of sample S0 that is the same as the difference value obtained at the time of sample S1, the flat region detection unit 3 will mistakenly detect a flat region. Therefore, it is preferable that the difference signal calculation unit 2 is configured to output, at the time of the first sample S0, an extremely large value as the difference value that cannot occur after sample S1.
[0028] The differential signal calculation unit 2 may not calculate the differential value for the first sample S0, but may calculate the differential value for samples S1 and onward. In this embodiment, as shown in (c) of Fig. 2, the differential signal calculation unit 2 outputs a differential signal formed by differential samples from sample S1 onward.
[0029] The difference signal calculated by the difference signal calculation unit 2 is supplied to the flat region detection unit 3. The flat region detection unit 3 detects the start and end positions of a flat region in which two or more consecutive difference values having the same value in the difference signal are present, and the number of samples in the flat region (the number of consecutive identical values). In the example shown in Fig. 2(c), the flat region detection unit 3 detects difference sample D3 as the start position of the flat region, difference sample D5 as the end position of the flat region, and the number of samples in the flat region as 3.
[0030] Figure 3 shows the requantization error signal obtained from two digital music signals recorded at the same time using the same equipment, with a sampling frequency of 192 kHz, and quantized in two formats, 16 bits and 24 bits. The requantization error signal shown in Figure 3 is calculated as follows.
[0031] To compare a first digital music signal with a quantization bit rate of 16 bits and a second digital music signal with a quantization bit rate of 24 bits, the second digital music signal is multiplied by 1 / 256 and the lowest 8 bits of the second digital music signal are expressed with a decimal point. The leading positions of the first digital music signal and the second digital music signal with the lowest 8 bits expressed with a decimal point are aligned, and the difference between the sample values of both signals is calculated for each sample as the re-quantization error.
[0032] If a first digital music signal with a quantization bit rate of 16 bits is M1, a second digital music signal with a quantization bit rate of 24 bits is M2, the requantization error signal is ERROR (a decimal value), and i is a sample number, the requantization error signal ERROR[i] at each sample number is expressed by equation (1). Equation (1) can be rewritten to obtain equations (2) and (3). In equation (3), ROUND represents rounding off to the nearest integer. ERROR[i]=M2[i] / 256-M1[i] …(1) M2[i] / 256=M1[i]+ERROR[i] …(2) M2[i]=ROUND[(M1[i]×256)+(ERROR[i]×256)] …(3)
[0033] From equation (3), it can be seen that if the requantized error signal is added to the first digital music signal M1 quantized at 16 bits, the second digital music signal M2 at 24 bits can be reproduced. Here, the coefficient by which M2 in equation (1) is divided is determined according to the value of (nm), which is the difference between the quantization bit rates of the two.
[0034] 4 shows the difference between two adjacent samples in the first digital music signal M1. If the difference between the current sample pcm[i] and the previous sample pcm[i-1], which are adjacent to each other in the first digital music signal M1, is denoted as DIFF(M1)[i], then DIFF(M1)[i] is expressed by equation (4). DIFF(M1)[i]=pcm[i]-pcm[i-1] …(4)
[0035] Comparing Figure 3 with Figure 4, it can be seen that there is a high correlation between the requantization error signal of the first digital music signal M1 and the second digital music signal M2 and the difference value between two adjacent samples in the first digital music signal M1. However, the flat waveform portion with successive identical difference values enclosed by the dashed ellipse in Figure 4 does not exist in the requantization error signal of Figure 3. If the flat waveform portion enclosed by the dashed ellipse is corrected so that it approaches the waveform of the requantization error signal, the correlation between the requantization error signal and the difference value can be further increased.
[0036] 1, the difference signal calculated by the difference signal calculation unit 2, the start position and end position of the flat region, and the number of samples in the flat region detected by the flat region detection unit 3 are supplied to the flat region correction unit 4. The flat region correction unit 4 corrects the flat region of the difference signal so as to bring the waveform of the difference signal closer to the waveform of the requantization error signal.
[0037] A first example of a flat region correction method by the flat region correction unit 4 when the number of samples in the flat region is 2 to 5 will be described using Figures 5A to 5D, 6A to 6D, 7A to 7D, and 8A to 8D. In each figure, a dashed circle indicates a difference sample before correction, and a solid circle indicates a difference sample after correction. Figures 5A to 5D, 6A to 6D, 7A to 7D, and 8A to 8D show sample numbers of locations where flat regions with 2 to 5 samples actually occur when a digital music signal of a predetermined song is input to the bit extension processing device 100.
[0038] In the difference signal shown in Fig. 5A, two difference samples D74 and D75 having sample numbers 74 and 75 form a flat region. Fig. 5A shows a pattern in which the difference value rises from difference sample D73 having sample number 73, which is one before the flat region, to difference sample D74, and falls from difference sample D75 to difference sample D76 having sample number 76, which is one after the flat region. A pattern in which the difference value rises before the flat region and falls after the flat region is referred to as an rise-flat-fall pattern. The difference values before correction of difference samples D73 to D76 are 2, 3, 3, and 2, respectively.
[0039] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D74 to correct the difference value to 3.5, and subtracts a correction value of 0.5 from the difference sample D75 to correct the difference value to 2.5. In FIG. 5A, the difference samples D74 and D75 are the difference samples to be corrected. The difference sample D74 is corrected to a corrected difference sample D74' having a difference value larger than that of the difference sample D74. The difference sample D75 is corrected to a corrected difference sample D75' having a difference value between the difference sample D75 and the difference sample D76.
[0040] Adding a correction value of 0.5 is equivalent to treating the current difference sample as a value that is rounded up to the positive side and adding a decimal part. Subtracting a correction value of 0.5 is equivalent to treating the current difference sample as a value that is rounded down to the negative side and adding a decimal part.
[0041] In this manner, the flat region correction unit 4 non-flattens a flat region of two samples having an up-flat-down pattern in the differential signal.
[0042] In the difference signal shown in Fig. 5B, two difference samples D999 and D1000 having sample numbers 999 and 1000 form a flat region. Fig. 5B shows a pattern in which the difference value rises from difference sample D998 having sample number 998, which is one before the flat region, to difference sample D999, and then rises from difference sample D1000 to difference sample D1001 having sample number 1001, which is one after the flat region. A pattern in which the difference value rises before the flat region and then rises after the flat region is referred to as an rise-flat-rise pattern. The difference values before correction of difference samples D998 to D1001 are 0, 3, 3, and 4, respectively.
[0043] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D999 to correct the difference value to 2.5, and adds a correction value of 0.5 to the difference sample D1000 to correct the difference value to 3.5. In FIG. 5B, the difference samples D999 and D1000 are the difference samples to be corrected. The difference sample D999 is corrected to a corrected difference sample D999' having a difference value between the difference sample D998 and the difference sample D999. The difference sample D1000 is corrected to a corrected difference sample D1000' having a difference value between the difference sample D1000 and the difference sample D1001.
[0044] In this manner, the flat region correction unit 4 non-flattens a flat region of two samples having an up-flat-up pattern in the differential signal.
[0045] In the difference signal shown in Fig. 5C, two difference samples D168 and D169 having sample numbers 168 and 169 form a flat region. Fig. 5C shows a pattern in which the difference value falls from difference sample D167 having sample number 167, which is one before the flat region, to difference sample D168, and rises from difference sample D169 to difference sample D170 having sample number 170, which is one after the flat region. A pattern in which the difference value falls before the flat region and rises after the flat region is referred to as a fall-flat-rise pattern. The difference values before correction of difference samples D167 to D170 are 3, 2, 2, and 4, respectively.
[0046] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D168 to correct the difference value to 1.5, and adds a correction value of 0.5 to the difference sample D169 to correct the difference value to 2.5. In FIG. 5C, the difference samples D168 and D169 are the difference samples to be corrected. The difference sample D168 is corrected to a corrected difference sample D168' having a difference value smaller than that of the difference sample D168. The difference sample D169 is corrected to a corrected difference sample D169' having a difference value between the difference sample D169 and the difference sample D170.
[0047] In this manner, the flat region correction unit 4 non-flattens a flat region of two samples having a fall-flat-rise pattern in the differential signal.
[0048] In the difference signal shown in Fig. 5D, two difference samples D574 and D575 having sample numbers 574 and 575 form a flat region. Fig. 5D shows a pattern in which the difference value falls from difference sample D573 having sample number 573 just before the flat region to difference sample D574, and then falls from difference sample D575 to difference sample D576 having sample number 576 just after the flat region. The pattern in which the difference value falls before the flat region and falls after the flat region is referred to as a fall-flat-fall pattern. The difference values before correction of difference samples D573 to D576 are 0, -2, -2, and -4, respectively.
[0049] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D575 to correct the difference value to −2.5. In FIG. 5D, the difference sample D575 is the difference sample to be corrected. The difference sample D575 is corrected to a corrected difference sample D575′ having a difference value between the difference sample D575 and the difference sample D576.
[0050] In this manner, the flat region correction unit 4 non-flattens a flat region of two samples having a fall-flat-fall pattern in the differential signal.
[0051] In the differential signal shown in Fig. 6A, three differential samples D591-D593 having sample numbers 591-593 form a flat region. Fig. 6A shows an up-flat-down pattern in which the differential value rises from differential sample D590 having sample number 590, which is one before the flat region, to differential sample D591, and then falls from differential sample D593 to differential sample D594 having sample number 594, which is one after the flat region. The differential values before correction of differential samples D590-D594 are -3, -2, -2, -2, and -3, respectively.
[0052] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D592 to correct the difference value to -1.5, and subtracts a correction value of 0.5 from the difference sample D593 to correct the difference value to -2.5. In FIG. 6A, the difference samples D592 and D593 are the difference samples to be corrected. The difference sample D592 is corrected to a corrected difference sample D592' having a difference value larger than that of the difference sample D592. The difference sample D593 is corrected to a corrected difference sample D593' having a difference value between the difference sample D593 and the difference sample D594.
[0053] In this manner, the flat region correction unit 4 non-flattens the flat region of three samples having an up-flat-down pattern in the differential signal.
[0054] In the differential signal shown in Fig. 6B, three differential samples D493 to D495 having sample numbers 493 to 495 form a flat region. Fig. 6B shows an increase-flat-increase pattern in which the difference value increases from differential sample D492 having sample number 492, which is one before the flat region, to differential sample D493, and then increases from differential sample D495 to differential sample D496 having sample number 496, which is one after the flat region. The difference values before correction of differential samples D492 to D496 are -7, -6, -6, -6, and -5, respectively.
[0055] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D494 to correct the difference value to -6.5, and adds a correction value of 0.5 to the difference sample D495 to correct the difference value to -5.5. In FIG. 6B, the difference samples D494 and D495 are the difference samples to be corrected. The difference sample D494 is corrected to a corrected difference sample D494' having a difference value between the difference sample D492 and the difference sample D494. The difference sample D495 is corrected to a corrected difference sample D495' having a difference value between the difference sample D495 and the difference sample D496.
[0056] In this manner, the flat region correction unit 4 non-flattens the flat region of three samples having an up-flat-up pattern in the differential signal.
[0057] In the differential signal shown in Fig. 6C, three differential samples D314-D316 having sample numbers 314-316 form a flat region. Fig. 6C shows a fall-flat-rise pattern in which the difference value falls from differential sample D313 having sample number 313, which is one before the flat region, to differential sample D314, and then rises from differential sample D316 to differential sample D317 having sample number 317, which is one after the flat region. The difference values before correction of differential samples D313-D317 are 9, 8, 8, 8, and 9, respectively.
[0058] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D314 to correct the difference value to 7.5, and adds a correction value of 0.5 to the difference sample D316 to correct the difference value to 8.5. In FIG. 6C, the difference samples D314 and D316 are the difference samples to be corrected. The difference sample D314 is corrected to a corrected difference sample D314' having a difference value smaller than that of the difference sample D314. The difference sample D316 is corrected to a corrected difference sample D316' having a difference value between the difference sample D316 and the difference sample D317.
[0059] In this manner, the flat region correction unit 4 non-flattens the flat region of three samples having a fall-flat-rise pattern in the differential signal.
[0060] In the differential signal shown in Fig. 6D, three differential samples D135-D137 having sample numbers 135-137 form a flat region. Fig. 6D shows a fall-flat-fall pattern in which the difference value falls from differential sample D134 having sample number 134, which is one before the flat region, to differential sample D135, and then falls from differential sample D137 to differential sample D138 having sample number 138, which is one after the flat region. The difference values before correction of differential samples D134-D138 are 4, 3, 3, 3, and 2, respectively.
[0061] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D135 to correct the difference value to 3.5, and subtracts a correction value of 0.5 from the difference sample D137 to correct the difference value to 2.5. In FIG. 6D, the difference samples D135 and D137 are the difference samples to be corrected. The difference sample D135 is corrected to a corrected difference sample D135' having a difference value between the difference sample D134 and the difference sample D135. The difference sample D137 is corrected to a corrected difference sample D137' having a difference value between the difference sample D136 and the difference sample D138.
[0062] In this manner, the flat region correction unit 4 non-flattens the flat region of three samples having a fall-flat-fall pattern in the differential signal.
[0063] In the differential signal shown in Fig. 7A, four differential samples D822 to D825 having sample numbers 822 to 825 form a flat region. Fig. 7A shows an up-flat-down pattern in which the differential value rises from differential sample D821 having sample number 821, which is one before the flat region, to differential sample D822, and then falls from differential sample D825 to differential sample D826 having sample number 826, which is one after the flat region. The differential values before correction of differential samples D821 and D826 are both 7, and the differential values before correction of differential samples D822 to D825 are 8.
[0064] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D823 to correct the difference value to 7.5, and adds a correction value of 0.5 to the difference sample D824 to correct the difference value to 8.5. The flat area correction unit 4 also subtracts a correction value of 0.5 from the difference sample D825. In Fig. 7A, the difference samples D823 to D825 are the difference samples to be corrected.
[0065] The difference sample D823 is corrected to a corrected difference sample D823' having a difference value between the difference sample D821 and the difference sample D823. The difference sample D824 is corrected to a corrected difference sample D824' having a difference value larger than the difference sample D824. The difference sample D825 is corrected to a corrected difference sample D825' having a difference value between the difference sample D825 and the difference sample D826.
[0066] In this manner, the flat region correction unit 4 non-flattens the flat region of four samples having an up-flat-down pattern in the differential signal.
[0067] In the differential signal shown in Fig. 7B, four differential samples D655-D658 having sample numbers 655-658 form a flat region. Fig. 7B shows an up-flat-up pattern in which the differential value rises from differential sample D654 having sample number 654, which is one before the flat region, to differential sample D655, and then rises from differential sample D658 to differential sample D659 having sample number 659, which is one after the flat region. The differential values before correction of differential samples D654 and D659 are 7 and 11, respectively, and the differential value before correction of differential samples D655-D658 is 9.
[0068] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D655 to correct the difference value to 8.5, and subtracts a correction value of 0.5 from the difference sample D657 to correct the difference value to 8.5. The flat area correction unit 4 also adds a correction value of 0.5 to the difference sample D658 to correct the difference value to 9.5. In FIG. 7B, the difference samples D655, D657, and D658 are the difference samples to be corrected.
[0069] The difference sample D655 is corrected to a corrected difference sample D655' having a difference value between the difference sample D654 and the difference sample D655. The difference sample D657 is corrected to a corrected difference sample D657' having a difference value between the difference sample D654 and the difference sample D657. The difference sample D658 is corrected to a corrected difference sample D658' having a difference value between the difference sample D658 and the difference sample D659.
[0070] In this manner, the flat region correction unit 4 non-flattens the flat region of four samples having an up-flat-up pattern in the differential signal.
[0071] In the differential signal shown in Fig. 7C, four differential samples D253-D256 having sample numbers 253-256 form a flat region. Fig. 7C shows a fall-flat-rise pattern in which the difference value falls from differential sample D252 having sample number 252, which is one before the flat region, to differential sample D253, and then rises from differential sample D256 to differential sample D257 having sample number 257, which is one after the flat region. The difference values before correction of differential samples D252 and D257 are both 12, and the difference values before correction of differential samples D253-D256 are 11.
[0072] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D253 to correct the difference value to 10.5, and subtracts a correction value of 0.5 from the difference sample D255 to correct the difference value to 10.5. The flat area correction unit 4 also adds a correction value of 0.5 to the difference sample D256 to correct the difference value to 11.5. In FIG. 7C, the difference samples D253, D255, and D256 are the difference samples to be corrected.
[0073] The difference sample D253 is corrected to a corrected difference sample D253' having a difference value smaller than the difference sample D253. The difference sample D255 is corrected to a corrected difference sample D255' having a difference value smaller than the difference sample D255. The difference sample D256 is corrected to a corrected difference sample D256' having a difference value between the difference sample D256 and the difference sample D257.
[0074] In this manner, the flat region correction unit 4 non-flattens the flat region of four samples having a fall-flat-rise pattern in the differential signal.
[0075] In the differential signal shown in Fig. 7D, four differential samples D342 to D345 having sample numbers 342 to 345 form a flat region. Fig. 7D shows a fall-flat-fall pattern in which the difference value falls from differential sample D341 having sample number 341, which is one before the flat region, to differential sample D342, and then falls from differential sample D345 to differential sample D346 having sample number 346, which is one after the flat region. The difference values before correction of differential samples D341 and D346 are 12 and 10, respectively, and the difference value before correction of differential samples D342 to D345 is 11.
[0076] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D343 to correct the difference value to 11.5, and subtracts a correction value of 0.5 from the difference sample D345 to correct the difference value to 10.5. In FIG. 7D, the difference samples D343 and D345 are the difference samples to be corrected. The difference sample D343 is corrected to a corrected difference sample D343' having a difference value between the difference sample D341 and the difference sample D343. The difference sample D345 is corrected to a corrected difference sample D345' having a difference value between the difference sample D345 and the difference sample D346.
[0077] In this manner, the flat region correction unit 4 non-flattens a flat region of four samples having a fall-flat-fall pattern in the differential signal.
[0078] In the differential signal shown in Fig. 8A, five differential samples D282 to D286 having sample numbers 282 to 286 form a flat region. Fig. 8A shows an up-flat-down pattern in which the differential value rises from differential sample D281 having sample number 281, which is one before the flat region, to differential sample D282, and then falls from differential sample D286 to differential sample D287 having sample number 287, which is one after the flat region. The differential values before correction of differential samples D281 and D287 are both -7, and the differential values before correction of differential samples D282 to D286 are -6.
[0079] The flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D283 to correct the difference value to -6.5, and adds a correction value of 0.5 to the difference sample D285 to correct the difference value to -5.5. In FIG. 8A, the difference samples D283 and D285 are difference samples to be corrected. The difference sample D283 is corrected to a corrected difference sample D283' having a difference value between the difference sample D281 and the difference sample D283. The difference sample D285 is corrected to a corrected difference sample D285' having a difference value larger than that of the difference sample D285.
[0080] In this manner, the flat region correction unit 4 non-flattens the flat region of five samples having an up-flat-down pattern in the differential signal.
[0081] In the differential signal shown in Fig. 8B, five differential samples D446-D450 having sample numbers 446-450 form a flat region. Fig. 8B shows an up-flat-up pattern in which the difference value rises from differential sample D445 having sample number 445, which is one before the flat region, to differential sample D446, and then rises from differential sample D450 to differential sample D451 having sample number 451, which is one after the flat region. The difference values before correction of differential samples D445 and D451 are -7 and -5, respectively, and the difference value before correction of differential samples D446-D450 is -6.
[0082] The flat area correction unit 4 corrects the difference value to -6.5 by subtracting a correction value of 0.5 from the difference sample D447, and corrects the difference value to -6.5 by subtracting a correction value of 0.5 from the difference sample D449. In FIG. 8B, the difference samples D447 and D449 are the difference samples to be corrected. The difference sample D447 is corrected to a corrected difference sample D447' having a difference value between the difference sample D445 and the difference sample D447. The difference sample D449 is corrected to a corrected difference sample D449' having a difference value between the difference sample D445 and the difference sample D449.
[0083] In this manner, the flat region correction unit 4 non-flattens the flat region of five samples having an up-flat-up pattern in the differential signal.
[0084] In the differential signal shown in Fig. 8C, five differential samples D618-D622 having sample numbers 618-622 form a flat region. Fig. 8C shows a fall-flat-rise pattern in which the difference value falls from differential sample D617 having sample number 617, which is one before the flat region, to differential sample D618, and rises from differential sample D622 to differential sample D623 having sample number 623, which is one after the flat region. The difference values before correction of differential samples D617 and D623 are both -5, and the difference values before correction of differential samples D618-D622 are -6.
[0085] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D619 to correct the difference value to -5.5, and subtracts a correction value of 0.5 from the difference sample D621 to correct the difference value to -6.5. In FIG. 8C, the difference samples D619 and D621 are the difference samples to be corrected. The difference sample D619 is corrected to a corrected difference sample D619' having a difference value between the difference sample D617 and the difference sample D619. The difference sample D621 is corrected to a corrected difference sample D621' having a difference value smaller than that of the difference sample D621.
[0086] In this manner, the flat region correction unit 4 non-flattens the flat region of five samples having a fall-flat-rise pattern in the differential signal.
[0087] In the differential signal shown in Fig. 8D, five differential samples D875-D879 having sample numbers 875-879 form a flat region. Fig. 8D shows a fall-flat-fall pattern in which the difference value falls from differential sample D874 having sample number 874, which is one before the flat region, to differential sample D875, and then falls from differential sample D879 to differential sample D880 having sample number 880, which is one after the flat region. The difference values before correction of differential samples D874 and D880 are -5 and -7, respectively, and the difference value before correction of differential samples D875-D879 is -6.
[0088] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D876 to correct the difference value to -5.5, and adds a correction value of 0.5 to the difference sample D878 to correct the difference value to -5.5. In FIG. 8D, the difference samples D876 and D878 are the difference samples to be corrected. The difference sample D876 is corrected to a corrected difference sample D876' having a difference value between the difference sample D874 and the difference sample D876. The difference sample D878 is corrected to a corrected difference sample D878' having a difference value between the difference sample D874 and the difference sample D878.
[0089] In this manner, the flat region correction unit 4 non-flattens the flat region of five samples having a fall-flat-fall pattern in the differential signal.
[0090] Incidentally, the flat area occurring in the difference signal calculated based on the digital music signal is at most 5 samples, and flat areas of 6 samples or more rarely occur. Therefore, the flat area correction unit 4 may set the positions for correcting the difference samples in the flat area and the correction values to be added or subtracted in accordance with each of the patterns of 2 samples shown in Figures 5A to 5D, 3 samples shown in Figures 6A to 6D, 4 samples shown in Figures 7A to 7D, and 5 samples shown in Figures 8A to 8D.
[0091] In the flat region correction unit 4, the positions and correction values for correcting the difference samples in the flat region, up to a certain number of samples, can be set arbitrarily.
[0092] The method of correcting the flat region by the flat region correction unit 4 is not limited to the first example shown in Figs. 5A to 5D, 6A to 6D, 7A to 7D, and 8A to 8D. The flat region correction unit 4 may correct the flat region so as to lower the difference sample at the start position of the flat region and raise the difference value of the difference sample at the end position, based on the center point of the flat region. The flat region correction unit 4 may also correct the flat region so as to raise the difference sample at the start position of the flat region and lower the difference value of the difference sample at the end position, based on the center point of the flat region. Figs. 9, 10A, 10B, 11A to 11D, and 12A to 12D show an example of a second example of the method of correcting the flat region, in which the entire flat region is corrected to be raised or lowered.
[0093] In the correction of the up-flat-down pattern, up-flat-up pattern, and down-flat-up pattern with two samples shown in Figures 5A to 5C, the flat region is corrected so that one side is raised and the other is lowered, or one side is lowered and the other is raised, based on the center point of the flat region. Therefore, the correction method according to the first example shown in Figures 5A to 5C can be used as the correction method according to the second example.
[0094] In the second example, the flat region correction unit 4 uses the correction method shown in FIG. 9 instead of the correction method shown in FIG. 5D as a correction method for a fall-flat-fall pattern with two samples.
[0095] The flat area correction unit 4 adds a correction value of 0.5 to the difference sample D574 to correct the difference value to -1.5, and subtracts a correction value of 0.5 from the difference sample D575 to correct the difference value to -2.5. In FIG. 9, the difference samples D574 and D575 are the difference samples to be corrected. The difference sample D574 is corrected to a corrected difference sample D574' having a difference value between the difference sample D573 and the difference sample D574. The difference sample D575 is corrected to a corrected difference sample D575' having a difference value between the difference sample D575 and the difference sample D576.
[0096] In the second example, the flat area correction unit 4 uses the correction method shown in Figures 10A and 10B instead of Figures 6A and 6B as a correction method for the rise-flat-fall pattern and rise-flat-rise pattern with three samples. In the correction of the fall-flat-rise pattern and fall-flat-fall pattern with three samples shown in Figures 6C and 6D, the flat area is corrected so that one side is raised and the other is lowered, or one side is lowered and the other is raised, based on the center point of the flat area. Therefore, the correction method according to the first example shown in Figures 6C and 6D can be used as the correction method according to the second example.
[0097] As shown in Fig. 10A, in the up-flat-down pattern, the flat area correction unit 4 adds a correction value of 0.5 to the difference sample D591 to correct the difference value to -1.5, and subtracts a correction value of 0.5 from the difference sample D593 to correct the difference value to -2.5. In Fig. 10A, the difference samples D591 and D593 are the difference samples to be corrected. The difference sample D591 is corrected to a corrected difference sample D591' having a difference value larger than that of the difference sample D591. The difference sample D593 is corrected to a corrected difference sample D593' having a difference value between the difference sample D593 and the difference sample D594.
[0098] As shown in Fig. 10B, in the rise-flat-rise pattern, the flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D493 to correct the difference value to -6.5, and adds a correction value of 0.5 to the difference sample D495 to correct the difference value to -5.5. In Fig. 10B, the difference samples D493 and D495 are difference samples to be corrected. The difference sample D493 is corrected to a corrected difference sample D493' having a difference value between the difference sample D492 and the difference sample D493. The difference sample D495 is corrected to a corrected difference sample D495' having a difference value between the difference sample D495 and the difference sample D496.
[0099] In the second example, the flat region correction unit 4 uses the correction method shown in FIGS. 11A to 11D instead of the correction method shown in FIGS. 7A to 7D as a correction method for all patterns with four samples.
[0100] As shown in Fig. 11A, in the up-flat-down pattern, the flat area correction unit 4 adds a correction value of 0.5 to the difference sample D822 to correct the difference value to 8.5, and adds a correction value of 0.25 to the difference sample D823 to correct the difference value to 8.25. The flat area correction unit 4 also subtracts a correction value of 0.25 from the difference sample D824 to correct the difference value to 7.75, and subtracts a correction value of 0.5 from the difference sample D825 to correct the difference value to 7.5. In Fig. 11A, the difference samples D822 to D825 are the difference samples to be corrected.
[0101] The difference sample D822 is corrected to a corrected difference sample D822' having a difference value larger than the difference sample D822. The difference sample D823 is corrected to a corrected difference sample D823' having a difference value between the corrected difference sample D822' and the difference sample D823. The difference sample D825 is corrected to a corrected difference sample D825' having a difference value between the difference sample D825 and the difference sample D826. The difference sample D824 is corrected to a corrected difference sample D824' having a difference value between the difference sample D824 and the corrected difference sample D825'.
[0102] In this way, the correction value added to and subtracted from the difference sample is not limited to 0.5, but may be 0.25.
[0103] As shown in Fig. 11B, in the rise-flat-rise pattern, the flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D655 to correct the difference value to 8.5, and subtracts a correction value of 0.25 from the difference sample D656 to correct the difference value to 8.75. The flat area correction unit 4 also adds a correction value of 0.25 to the difference sample D657 to correct the difference value to 9.25, and adds a correction value of 0.5 to the difference sample D658 to correct the difference value to 9.5. In Fig. 11B, the difference samples D655 to D658 are the difference samples to be corrected.
[0104] The difference sample D655 is corrected to a corrected difference sample D655' having a difference value between the difference sample D654 and the difference sample D655. The difference sample D656 is corrected to a corrected difference sample D656' having a difference value between the difference sample D655' and the difference sample D656. The difference sample D658 is corrected to a corrected difference sample D658' having a difference value between the difference sample D658 and the difference sample D659. The difference sample D657 is corrected to a corrected difference sample D657' having a difference value between the difference sample D657 and the corrected difference sample D658'.
[0105] As shown in Fig. 11C, in the fall-flat-rise pattern, the flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D253 to correct the difference value to 10.5, and subtracts a correction value of 0.25 from the difference sample D254 to correct the difference value to 10.75. The flat area correction unit 4 also adds a correction value of 0.25 to the difference sample D255 to correct the difference value to 11.25, and adds a correction value of 0.5 to the difference sample D256 to correct the difference value to 11.5. In Fig. 11C, the difference samples D253 to D256 are the difference samples to be corrected.
[0106] The difference sample D253 is corrected to a corrected difference sample D253' having a difference value smaller than the difference sample D253. The difference sample D254 is corrected to a corrected difference sample D254' having a difference value between the corrected difference sample D253' and the difference sample D254. The difference sample D256 is corrected to a corrected difference sample D256' having a difference value between the difference sample D256 and the difference sample D257. The difference sample D255 is corrected to a corrected difference sample D255' having a difference value between the difference sample D255 and the corrected difference sample D256'.
[0107] As shown in Fig. 11D, in the fall-flat-fall pattern, the flat area correction unit 4 adds a correction value of 0.5 to the difference sample D342 to correct the difference value to 11.5, and adds a correction value of 0.25 to the difference sample D343 to correct the difference value to 11.25. The flat area correction unit 4 also subtracts a correction value of 0.25 from the difference sample D344 to correct the difference value to 10.75, and subtracts a correction value of 0.5 from the difference sample D345 to correct the difference value to 10.5. In Fig. 11D, the difference samples D342 to D345 are the difference samples to be corrected.
[0108] The difference sample D342 is corrected to a corrected difference sample D342' having a difference value between the difference sample D341 and the difference sample D342. The difference sample D343 is corrected to a corrected difference sample D343' having a difference value between the corrected difference sample D342' and the difference sample D343. The difference sample D345 is corrected to a corrected difference sample D345' having a difference value between the difference sample D345 and the difference sample D346. The difference sample D344 is corrected to a corrected difference sample D344' having a difference value between the difference sample D344 and the corrected difference sample D345'.
[0109] In the second example, the flat region correction unit 4 uses the correction method shown in FIGS. 12A to 12D instead of the correction method shown in FIGS. 8A to 8D as a correction method for all patterns with five samples.
[0110] As shown in Fig. 12A, in the up-flat-down pattern, the flat area correction unit 4 adds a correction value of 0.5 to the difference sample D282 to correct the difference value to -5.5, and adds a correction value of 0.25 to the difference sample D283 to correct the difference value to -5.75. The flat area correction unit 4 also subtracts a correction value of 0.25 from the difference sample D285 to correct the difference value to -6.25, and subtracts a correction value of 0.5 from the difference sample D286 to correct the difference value to -6.5. In Fig. 12A, the difference samples D282, D283, D285, and D286 are the difference samples to be corrected.
[0111] The difference sample D282 is corrected to a corrected difference sample D282' having a difference value larger than the difference sample D282. The difference sample D283 is corrected to a corrected difference sample D283' having a difference value between the corrected difference sample D282' and the difference sample D283. The difference sample D286 is corrected to a corrected difference sample D286' having a difference value between the difference sample D286 and the difference sample D287. The difference sample D285 is corrected to a corrected difference sample D285' having a difference value between the difference sample D285 and the corrected difference sample D286'.
[0112] As shown in Fig. 12B, in the rise-flat-rise pattern, the flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D446 to correct the difference value to -6.5, and subtracts a correction value of 0.25 from the difference sample D447 to correct the difference value to -6.25. The flat area correction unit 4 also adds a correction value of 0.25 to the difference sample D449 to correct the difference value to -5.75, and adds a correction value of 0.5 to the difference sample D450 to correct the difference value to -5.5. In Fig. 12B, the difference samples D446, D447, D449, and D450 are the difference samples to be corrected.
[0113] The difference sample D446 is corrected to a corrected difference sample D446' having a difference value between the difference sample D445 and the difference sample D446. The difference sample D447 is corrected to a corrected difference sample D447' having a difference value between the corrected difference sample D446' and the difference sample D447. The difference sample D450 is corrected to a corrected difference sample D450' having a difference value between the difference sample D450 and the difference sample D451. The difference sample D449 is corrected to a corrected difference sample D449' having a difference value between the difference sample D449 and the corrected difference sample D450'.
[0114] As shown in Fig. 12C, in the fall-flat-rise pattern, the flat area correction unit 4 subtracts a correction value of 0.5 from the difference sample D618 to correct the difference value to -6.5, and subtracts a correction value of 0.25 from the difference sample D619 to correct the difference value to -6.25. The flat area correction unit 4 also adds a correction value of 0.25 to the difference sample D621 to correct the difference value to -5.75, and adds a correction value of 0.5 to the difference sample D622 to correct the difference value to -5.5. In Fig. 12C, the difference samples D618, D619, D621, and D622 are the difference samples to be corrected.
[0115] The difference sample D618 is corrected to a corrected difference sample D618' having a difference value smaller than the difference sample D618. The difference sample D619 is corrected to a corrected difference sample D619' having a difference value between the corrected difference sample D618' and the difference sample D619. The difference sample D622 is corrected to a corrected difference sample D622' having a difference value between the difference sample D622 and the difference sample D623. The difference sample D621 is corrected to a corrected difference sample D621' having a difference value between the difference sample D621 and the corrected difference sample D622'.
[0116] As shown in Fig. 12D, in the fall-flat-fall pattern, the flat area correction unit 4 adds a correction value of 0.5 to the difference sample D875 to correct the difference value to -5.5, and adds a correction value of 0.25 to the difference sample D876 to correct the difference value to -5.75. The flat area correction unit 4 also subtracts a correction value of 0.25 from the difference sample D878 to correct the difference value to -6.25, and subtracts a correction value of 0.5 from the difference sample D879 to correct the difference value to -6.5. In Fig. 12D, the difference samples D875, D876, D878, and D879 are the difference samples to be corrected.
[0117] The difference sample D875 is corrected to a corrected difference sample D875' having a difference value between the difference sample D874 and the difference sample D875. The difference sample D876 is corrected to a corrected difference sample D876' having a difference value between the difference sample D875' and the difference sample D876. The difference sample D879 is corrected to a corrected difference sample D879' having a difference value between the difference sample D879 and the difference sample D880. The difference sample D878 is corrected to a corrected difference sample D878' having a difference value between the difference sample D878 and the corrected difference sample D879'.
[0118] In the first and second examples described above, the flat region correction unit 4 needs to non-flatten the flat region so that adjacent difference samples in the flat region do not have the same difference value after correction. When the flat region correction unit 4 non-flattens the flat region, it means correcting the difference samples in the flat region without leaving any flat region with two or more samples.
[0119] In the second example, when the number of samples of the differential signal is 3 and 5, which means that the central differential sample is in the flat region, the flat region correction unit 4 may set the correction value of the central differential sample to 0.
[0120] In the second example, if the difference signal of the up-flat-down pattern and the difference signal of the down-flat-up pattern have waveforms symmetrical to each other in the time axis direction, the flat region correction unit 4 should also use a symmetric correction method for the flat region. Also, if the difference signal of the up-flat-up pattern and the difference signal of the down-flat-down pattern have waveforms symmetrical to each other in the time axis direction, the flat region correction unit 4 should also use a symmetric correction method for the flat region.
[0121] 1, the difference signal (second difference signal) in which the flat region has been made non-flat by the flat region correction unit 4 is supplied to the difference signal averaging unit 5. The difference signal averaging unit 5 sums up the values of the difference samples included in each frame, and divides the sum by the number of difference samples included in the frame to calculate an average difference value.
[0122] If the difference average value is zero, it means that the amount of change in the difference signal on the positive side and the amount of change in the difference signal on the negative side are equal within each frame. The difference signal averaging unit 5 supplies the difference signal supplied from the flat area correction unit 4 to the requantization error generation unit 6 as a third difference signal.
[0123] When the difference average value is a predetermined value other than zero, the difference signal averaging unit 5 subtracts the difference average value from the difference value of each difference sample of the difference signal. As a result, the difference average value of the difference signal becomes zero, and the amount of change on the positive side and the amount of change on the negative side of the difference signal in each frame can be made equal. The difference signal averaging unit 5 supplies the difference signal (third difference signal) corrected so that the amount of change on the positive side and the amount of change on the negative side of the difference signal become equal to the requantization error generating unit 6.
[0124] 1, a first digital music signal with a quantization bit rate of 16 bits and a second digital music signal with a quantization bit rate of 24 bits are targeted. Therefore, the requantization error generating unit 6 multiplies the inputted difference signal by a coefficient to generate a requantization error signal to be added to the 8 bits of (nm). If the requantization error signal to be added to the 8 bits is Qerror[i] and the difference value of the inputted difference signal is diff[i], the requantization error signal Qerror[i] is expressed by equation (5). Qerror[i]=(512 / 131070)·diff[i] …(5)
[0125] Since the requantization error signal needs to be expressed by 8 bits plus a sign bit (1 bit), there are 512 stages on the positive side, from 0 to 255, and on the negative side, from -1 to -256. Therefore, the difference value is divided into 512 stages.
[0126] The maximum difference amount when the first digital music signal with 16 quantization bits changes from negative to positive is 65535, which is calculated by subtracting the maximum negative 16 bit value, -32768, from the maximum positive 16 bit value, 32767. The maximum difference amount when the first digital music signal with 16 quantization bits changes from positive to negative is -65535, which is calculated by subtracting the maximum positive 16 bit value, 32767, from the maximum negative 16 bit value, -32768.
[0127] Therefore, since there is a possibility that a maximum positive value and a maximum negative value will occur, the variation range of the difference amount is |65535-(-65535)|, which is 131070.
[0128] The coefficient by which the difference value diff[i] in formula (5) is multiplied is the inverse of the division width obtained by dividing the change width of the difference amount by the division number. The coefficient by which the difference value diff[i] is multiplied is determined according to the number of quantization bits of the first digital music signal and the degree to which the first digital music signal is bit-extended, i.e., the value of (nm).
[0129] The requantization error generating unit 6 supplies the requantization error signal generated as described above to the adding unit 7. The delay unit 8 delays the framed digital music signal output from the framing processing unit 1 by one sample and supplies the delayed signal to the adding unit 7. This is because, as described above, the difference value is not calculated for the first sample of each frame.
[0130] As shown in equation (3), the adder 7 multiplies the input digital music signal by a value of 256 to generate an 8-bit space, and then adds the requantized error signal. The adder 7 rounds off the decimal point and outputs a digital music signal that has been bit-extended to 24 bits.
[0131] Figure 13 shows the requantization error signals obtained from two digital music signals recorded at the same time using the same equipment, with a sampling frequency of 192 kHz, and quantized in two formats, 16 bits and 24 bits, of a performance of a specific piece of music different from that shown in Figure 3.
[0132] In Fig. 13, similarly to Fig. 3, in order to compare a first digital music signal with a 16-bit quantization bit rate and a second digital music signal with a 24-bit quantization bit rate, the second digital music signal is multiplied by 1 / 256 and the lowest 8 bits of the second digital music signal are expressed using a decimal point. The leading positions of the first digital music signal and the second digital music signal with the lowest 8 bits expressed using a decimal point are aligned, and the difference between the sample values of both signals is calculated as the re-quantization error for each sample.
[0133] Fig. 14 shows a quantization error signal of a second digital music signal obtained by bit-extending the number of quantization bits to 24 bits using the bit extension processing device 100 shown in Fig. 1 for a first digital music signal, which is the same piece of music as in Fig. 13. The second digital music signal is multiplied by 1 / 256, and the lowest 8 bits of the second digital music signal are expressed using a decimal point. The leading positions of the first digital music signal and the second digital music signal whose lowest 8 bits are expressed using a decimal point are aligned, and the difference between the sample values of the two is calculated for each sample as the re-quantization error.
[0134] Comparing the requantized error signal shown in Fig. 13 with the requantized error signal shown in Fig. 14, it can be seen that the two are very similar. According to the bit extension processing device 100 and the bit extension processing method executed by the bit extension processing device 100, it is possible to perform high-quality bit extension processing on a digital music signal. This effect can be obtained regardless of the type of music. Even if the method of correcting the difference sample for making the flat region non-flat is different, if the flat region that does not actually exist is made non-flat, it is possible to increase the correlation between the requantized error signal and the difference value. Therefore, the method of correcting the difference sample is not limited.
[0135] The bit extension processing device 100 shown in Fig. 1 may be configured as hardware using a circuit, or may be configured as software. The bit extension processing device 100 shown in Fig. 1 can be realized by a central processing unit (CPU) of a microcomputer executing a bit extension processing program.
[0136] 15, a CPU 10, a main memory 15, and a storage medium 20 are connected by a bus. The storage medium 20 is any non-transitory storage medium such as a hard disk drive, an optical disk, or a semiconductor memory. A bit extension processing program is stored in the storage medium 20. The bit extension processing program may be transmitted from an external server via a communication line such as the Internet and stored in the storage medium 20.
[0137] The CPU 10 loads the bit extension processing program stored in the storage medium 20 into the main memory 15. The CPU 10 executes each instruction described in the bit extension processing program loaded into the main memory 15, thereby performing the processing shown in FIG.
[0138] The processing executed by the CPU 10 according to the bit extension processing program will be described with reference to the flowchart shown in Fig. 16. Fig. 16 also shows the operation of the bit extension processing device 100 shown in Fig. 1, and processing according to the bit extension processing method executed by the bit extension processing device 100.
[0139] 16, in step S1, the CPU 10 frames the input first digital music signal. In step S2, the CPU 10 calculates a difference signal within the frame. In step S3, the CPU 10 detects the start position, end position, and number of difference samples of a flat region in the difference signal. In step S4, the CPU 10 non-flattens the flat region according to the pattern of the difference signal. In step S5, the CPU 10 calculates an average difference value within the frame.
[0140] In step S6, the CPU 10 determines whether the difference average value is zero. If the difference average value is zero (YES), the CPU 10 shifts the process to step S8. If the difference average value is not zero (NO), the CPU 10 corrects the difference signal in step S7 so that the amount of change on the positive side of the difference signal is equal to the amount of change on the negative side, and shifts the process to step S8.
[0141] In step S8, the CPU 10 generates a quantization error within the frame. In step S9, the CPU 10 adds the quantization error to the first digital music signal within the frame and outputs the result as a second digital music signal.
[0142] In step S10, the CPU 10 determines whether or not the first digital music signal is being continuously input. If the first digital music signal is being continuously input (YES), the CPU 10 repeats the processes of steps S1 to S10. If the first digital music signal is not being continuously input (NO), the CPU 10 ends the process.
[0143] The present invention is not limited to the above-described embodiment, and various modifications are possible without departing from the gist of the present invention. [Explanation of symbols]
[0144] 1. Frame Processing Section 2. Differential signal calculation section 3 Flat area detection section 4 Flat area correction section 5 Differential signal averaging section 6 Requantization error generation section 7 Addition section 8 Delay Unit 10 Central Processing Unit (CPU) 15. Main memory 20 Storage medium
Claims
1. a framing processing unit that divides samples of a first digital music signal quantized with a first quantization bit rate into frames for each of a plurality of sample numbers; a differential signal calculation unit that calculates a first differential signal by using a differential value between two adjacent samples of the first digital music signal included in each frame as a sample; a flat region detection unit that detects a start position and an end position of a flat region in which two or more consecutive samples having the same sample value are included in the first differential signal, and the number of samples in the flat region; a flat region correction unit that, depending on whether the sample values rise or fall from the sample immediately preceding the flat region to the sample at the start position and whether the sample values rise or fall from the end position to the sample immediately following the flat region, sets one or more samples among the samples in the flat region as samples to be corrected, and corrects the sample values to be corrected by adding or subtracting a correction value to the sample values to be corrected, thereby generating a second differential signal that non-flattens the flat region; a differential signal averaging unit that calculates a differential average value by summing sample values of the second differential signal included in each of the frames and dividing the sum by the number of samples of the second differential signal included in each of the frames, and subtracts the differential average value from each sample value of the second differential signal to generate a third differential signal; a requantization error generating unit that generates a requantization error signal expressed by a number of bits that is a difference between the first number of quantization bits and a second number of quantization bits that is greater than the first number of quantization bits, based on the third difference signal; an adder section that adds the requantization error signal to the first digital music signal included in each of the frames to output a second digital music signal having the second quantization bit rate; A bit expansion processing device comprising:
2. Dividing the samples of the first digital music signal quantized with a first quantization bit rate into frames for each of a plurality of sample numbers; calculating a first differential signal by sampling a difference between two adjacent samples of the first digital music signal included in each frame; Detecting a start position and an end position of a flat region in which two or more difference samples having the same difference value are consecutive in the first difference signal, and the number of difference samples in the flat region; depending on a pattern of whether the difference value rises or falls from the difference sample immediately before the flat region to the difference sample at the start position, and whether the difference value rises or falls from the end position to the difference sample immediately after the flat region, one or more difference samples of the flat region are set as difference samples to be corrected, and a correction value is added to or subtracted from the sample value to be corrected to correct the sample value to be corrected, thereby generating a second difference signal in which the flat region is non-flattened; summing sample values of the second differential signal included in each of the frames, and dividing the sum by the number of samples of the second differential signal included in each of the frames to calculate an average difference value, and determining whether the average difference value is zero; if the difference average value is zero, the second difference signal is set as a third difference signal, and if the difference average value is not zero, the difference average value is subtracted from each sample value of the second difference signal to generate a third difference signal; generating a requantization error signal for each frame expressed by a number of bits that is a difference between the first number of quantization bits and a second number of quantization bits that is greater than the first number of quantization bits, based on the third difference signal; adding the requantization error signal to the first digital music signal included in each frame to generate a second digital music signal having the second quantization bit rate; Bit extension processing method.
3. On the computer, A step of dividing samples of a first digital music signal quantized with a first quantization bit rate into frames for each of a plurality of sample numbers; calculating a first differential signal by sampling a difference between two adjacent samples of the first digital music signal included in each frame; detecting a start position and an end position of a flat region in which two or more consecutive difference samples having the same difference value are included in the first difference signal, and the number of difference samples in the flat region; a step of determining one or more difference samples of the difference samples in the flat region as difference samples to be corrected depending on a pattern of whether a difference value increases or decreases from the difference sample immediately before the flat region to the difference sample at the start position, and whether a difference value increases or decreases from the end position to the difference sample immediately after the flat region, and correcting the sample value to be corrected by adding or subtracting a correction value to or from the sample value to be corrected, thereby generating a second difference signal in which the flat region is non-flattened; a step of calculating an average difference value by summing sample values of the second difference signal included in each of the frames and dividing the sum by the number of samples of the second difference signal included in each of the frames, and determining whether the average difference value is zero; if the difference average value is zero, the second difference signal is treated as a third difference signal, and if the difference average value is not zero, the difference average value is subtracted from each sample value of the second difference signal to generate a third difference signal; generating a requantization error signal for each frame expressed by a number of bits that is a difference between the first number of quantization bits and a second number of quantization bits that is greater than the first number of quantization bits, based on the third difference signal; adding the requantization error signal to the first digital music signal included in each frame to generate a second digital music signal having the second quantization bit rate; A bit expansion processing program that executes the above.
Citation Information
Patent Citations
Method and device for bit length extension, and digital audio reproducing device
JP1998242859A
Program for quantization bit extending
JP2004180017A
Apparatus and program for quantized bit extension processing
JP2005106933A
Quantization bit number expanding method and quantization bit number expanding device
JP2011180479A