Understanding DC offset <<-- Source Link
DC(Direct or continuous current) Offset is good for changing the baseline of an audio file (e.g. wav) to compensate for electrical mismatches between your audio card and the input device, thus obtaining a louder amplitude after normalization. If DC off set exists, getting more loudness in the mix maybe a problem.
DC offset occurs when hardware, such as a sound card, adds DC current to a recorded audio signal. This current results in a recorded waveform that is not centered around the baseline (-infinity). In some cases, when DC-Offset is present, glitches and other unexpected results can occur when sound effects are applied to the audio file. You can compensate for this DC offset by adding a constant value to the samples in the sound file.
In the example above, the red line represents the baseline. The lower waveform exhibits DC offset; note that the waveform is centered approximately 2 dB above the baseline.Technical ExplanationDC offset is an offsetting of a signal from zero. The term originated in electronics, where it refers to a direct current voltage, but the concept has been extended to any representation of a waveform. DC offset is the mean amplitude of the waveform; if the mean amplitude is zero, there is no DC offset.
DC offset is usually undesirable. For example, in audio processing, a sound that has DC offset will not be at its loudest possible volume when normalized (because the offset consumes headroom), and this problem can possibly extend to the mix as a whole, since a sound with DC offset and a sound without DC offset will have DC offset when mixed. It may also cause other artifacts depending on what is being done with the signal.
DC offset can be reduced in real-time by a one-pole one-zero high-pass filter. When one already has the entire waveform, subtracting the mean amplitude from each sample will remove the offset. Often, very low frequencies are called "slowly changing DC". While not technically accurate, a highpass filter can remove such a "changing offset" better because its cutoff does not extend to as low a bandwidth as the above method.
When describing a periodic function in the frequency domain, the term DC coefficient or DC component refers to the mean value of the waveform (possibly scaled according to the norm of the corresponding basis function of the frequency analysis filter bank). The name comes from the middle 20th century design of electrical line codes for use with transmission channels unable to transmit a DC voltage or current. In such usage, this coefficient represents the useless DC, whilst the coefficients representing various other frequencies are analogous to superimposed AC voltages or currents.
A waveform with a zero DC component is known as a DC-balanced waveform. DC-balanced waveforms are useful in communications systems, since they can be used on AC-coupled electrical connections to avoid voltage imbalance problems between connected systems or components. For this reason, most line codes are designed to produce DC-balanced waveforms. The most common classes of DC balanced line codes are constant-weight codes and paired-disparity codes.