presentations/audiocodecs/slides/02-1-pcm.md

40 lines
1.6 KiB
Markdown
Raw Normal View History

2024-09-16 21:27:30 -04:00
### Digital Audio Representation
<div style="text-align: center; display: grid; grid-template-columns: 1fr 1fr;">
<div> <!-- Left pane -->
<!-- Title -->
![Picture of PCM encoded sine wave](media/sinewave.svg) <!-- .element: style="image-rendering: crisp-edges;background-color:white;" -->
<div style="font-size: 0.33em; line-height: 0.1em;">
Image by Aquegg
Licensed under [CC-BY-SA 3.0](https://creativecommons.org/licenses/by-sa/3.0/deed.en)
</div>
</div>
<div> <!-- Right pane -->
<!-- Title -->
![Picture of PCM encoded waveform](media/linear-PCM.svg) <!-- .element: style="image-rendering: crisp-edges;background-color:white;" -->
<div style="font-size: 0.33em; line-height: 0.1em;">
Image by Aquegg
Licensed under [CC-BY-SA 3.0](https://creativecommons.org/licenses/by-sa/3.0/deed.en)
</div>
</div>
</div>
Note:
Audio is typically represented in a digital form using Pulse Code Modulation, or PCM.
On the left there is an example of a sine wave. The red line represents the original analog signal, with the blue dots representing the data points
in the PCM encoded version. A similar idea is happening on the right, but with a more complex waveform.
During the conversion process from analog to digital, better know as "quantization", the amplitude of the analog signal is converted into digital data points
at regular intervals. In this example, a simple rounding algorithm is used. Do however note that there are more complicated algorithms,
but you could spend many hours just talking about those alone, and the specifics aren't particularly important here.
[comment]: # (|||) <!--------------------------------------------------------->