A Programmer's Guide to Sound (Paperback)
暫譯: 程式設計師的聲音指南 (平裝本)

Tim Kientzle

  • 出版商: Addison Wesley
  • 出版日期: 1997-10-27
  • 售價: $2,050
  • 貴賓價: 9.5$1,948
  • 語言: 英文
  • 頁數: 464
  • 裝訂: Paperback
  • ISBN: 0201419726
  • ISBN-13: 9780201419726
  • 已絕版

買這商品的人也買了...

商品描述

 

Table Of Contents

Introduction.
Source Code.
About This Book.
Acknowledgements.

 

 

 

 

I. BASICS.

 

 

 

1. From Hollow Logs to Cyberspace.

 

What is Sound?
Natural Sounds.
Electronic Sounds.
Sounds We Hear.
Digital Sounds.
Other Resources.


2. Human Sound Perception.

 

Frequency and Pitch.
Musical Pitch.
Pitch and Frequency Aren't the Same.
Noise.

Loudness, Amplitude, and Power.
Overall Quality.


3. Storing Sound Digitally.

 

 

Sampled Sound Formats.
Pulse Amplitude Modulation (PAM).
Pulse Width Modulation (PWM).
Pulse Code Modulation (PCM).

Side Effects of Sampling.
Aliasing.
Output Aliasing.
Resampling.

Quantization Error.
Dithering.
Clipping.
Floating-Point Samples.


4. A C++ Sound Framework.

 

 

The AudioAbstract Class.
Stereo.
Negotiation.

Reading and Writing Integers.
A SineWave Class.
 

II. SYSTEM SPECIFICS.

 

 


5. Player Objects.

 

 

Player Basics.
Implementing the Queue.
Opening an Unknown Sound File.


6. Playing Audio on Windows.

 

 

Play.
The Callback.
Selecting an Audio Device.
A Sample Windows Application.


7. Playing Audio on Mac OS.

 

 

Callback.
Double Buffered Sound Under Mac OS.
A Sample Mac OS Program.
Playing a Mac File.


8. UNIX and the Network Audio System.

 

 

Servers and Flows.
Callbacks and Events.
Configuring a Flow and Attaching to the Server.
A Sample UNIX Application.
 

III. COMPRESSION.

 

 


9. Audio Compression.

 

 

Lossless Compression.
Non-Linear PCM.
Differential PCM.
Adaptive Differential PCM.
Predictor-Based Compression.
Subband Coding.
Human Speech Compression.
Checkpointing.
Progressive Compression.


10. Decompression Classes.

 

 

8-Bit PCM.
Signed 8-Bit PCM.
Unsigned 8-Bit PCM.

16-Bit PCM.
MSB 16-Bit PCM.
LSB 16-Bit PCM.


11. Nonlinear Sound Formats.

 

 

Logarithmic Compression.
mu-Law Compression.
A-Law.
Properties of Logarithmic Encodings.


12. Differential PCM.

 

 

Two DPCM Encodings.


13. IMA ADPCM Compression.

 

 

General Operation.
Decompression.
Compression.

Practical IMA ADPCM Decompression.
Microsoft's IMA ADPCM Variant.
Apple's IMA ADPCM Variant.
Comparing Microsoft's and Apple's IMA ADPCM Codecs Notes on IMA ADPCM.

Unraveling ADPCM Formats.
Credits.


14. MPEG Audio.

 

 

A Survey of the MPEG Standards.
MPEG-1.
MPEG-2.
MPEG-3.
MPEG-4.

MPEG Audio.
General Structure.
Managing the Byte Stream.
MPE's Frame Header.
Slots and Frames.

Layer 1/Layer 2 Subband Synthesis.
Matrixing.
Slow Matrixing.
Fast Matrixing.

Synthesis Window Coefficients.

MPEG Stereo Encoding.
Layer 1.
Layer 1 Allocation Storage.
Layer 1 Scale Factors.
Layer 1 Sample Storage.
Layer 1 Requantization and Scaling.

Layer 2.
Layer 2 Allocation Storage.
Layer 2 Scale Factors.
Reading Layer 2 Samples.
Layer 2 Requantization.

Layer 3.
A Reader for MPEG Files.
More Information.
 

IV. GENERAL FILE FORMATS.

 

 


15. AU File Format.

 

 

Identifying AU Files.
Reading AU Files.
Writing AU Files.
A Simple AU Filter.


16. VOC File Format.

 

 

Identifying VOC Files.
VOC Header.
Data Blocks.
Terminator Block (Type 0).
Sound Data Block (Type 1).
Sound Continuation Block (Type 2).
Silence Block (Type 3).
Marker Block (Type 4).
Text Block (Type 5).
Repeat Loops (Types 6 and 7).
Extension Block (Type 8).
Extension Block (Type 9).
Other Blocks.

Reading VOC Files.


17. WAVE File Format.

 

 

Identifying WAVE Files.
About RIFF and other IFF Files.
An Overview of WAVE.
The WaveRead Class.
Reading WAVE Files.
Containers.
The RIFF WAVE Container.
The fmt Chunk.
Creating a Decompression Object.
PCM Data.
IMA ADPCM Data.
mu-Law and A-Law.
Other Compression Methods.

The data Chunk.
Text chunks.


18. AIFF and AIFF-C File Formats.

 

 

Identifying AIFF Files.
The AiffRead Class.
Reading AIFF Files.
Containers.
The FORM AIFF Container.
The FVER Chunk.
The COMM Chunk.
PCM Data.
mu-Law Data.
IMA ADPCM Data.

The SSND Chunk.


19. IFF/8SVX File Format.

 

 

Identifying IFF/8SVX Files.
An Overview of IFF/8SVX.
Reading IFF/8SVX Files.
Overview.
Containers.
The FORM 8SVX Container.
The VHDR Chunk.
PCM Data.
Fibonacci DPCM Encoding.
Exponential DPCM Encoding.

The BODY Chunk.
IFF/8SVX Errata.
Text Chunks.
 

V. MUSIC FILE FORMATS.

 

 


20. Programming Music.

 

 

Instruments.
Notes.


21. Synthesizing Instruments.

 

 

Sampled Instruments.
A Sine Wave Generator.

Amplitude Control.
Envelope Control with Sampled Instruments.
Other Types of Envelope Control.
FM and Wavetable Synthesis.

Plucked Strings.
Implementing the Plucked-String Algorithm.

Testing Notes.


22. MIDI.

 

 

Standard MIDI Files.
Identifying MIDI Files.
MIDI Header Chunk.

MIDI Tracks.
Variable-Length Integers.
Delta Times.
Reading MIDI Tracks.

MIDI Events.
Numbering Conventions.
Running Status.
Managing MIDI Events.
Reading MIDI Events.
Sysex Events.
Meta Events.
Track Sequence Number Meta Event (Type 0).
Text Meta Events (Types 1 through 15).
End of Track Meta Event (Type 47).
Tempo Meta Event (Type 81).
Time Signature (Type 88).
Key Signature Meta Event (Type 89).
Sequencer-Specific Meta Events (Type 127).

MIDI Timing.
SMPTE-Based Timing.
Tempo-Based Timing.
General MIDI.
Downloadable Samples.

A MIDI Player.
Post-Processing the MIDI Event Stream.
Base and Extended MIDI.

Playing a MIDI Event Stream.
MIDI Channels.
Aftertouch and Pitch Wheel.
Controllers and Modes.
7-Bit Controllers.
14-Bit Controllers.
Parameters.
Channel Modes.
Implementation.

MIDI Tuning.
MIDI Instruments.
Caveats.
MIDI Wire Protocol.
Real-Time Commands.

Other MIDI File Formats.


23. MOD.

 

 

Identifying MOD Files.
Amiga Sound Hardware.
MOD Format Overview.
Instruments.
Timing.
Notes.
Beats.
Patterns.
Play list.

Format Details.
Instruments.
Notes.
Song Storage.
Overall File Structure.

Playing MOD Files.
The PlayBeat Method.
Playing Notes with Effects.
Effect 0: Arpeggio.
Effect 1: Slide Up.
Effect 2: Slide Down.
Effect 3: Pitch Slide.
Effect 4: Vibrato.
Effect 5: Pitch Slide plus Volume Slide.
Effect 6: Vibrato plus Volume Slide.
Effect 7: Tremolo.
Effect 8: Unused.
Effect 9: Set Sample Offset.
Effect 10: Volume Slide.
Effect 11: Far Jump.
Effect 12: Set Volume.
Effect 13: Pattern Break (Small Jump).
Effect 14/0: Set Filter.
Effect 14/1: Fine Slide Up.
Effect 14/2: Fine Slide Down.
Effect 14/3: Set Glissando.
Effect 14/4: Set Vibrato Waveform.
Effect 14/5: Set Finetune.
Effect 14/6: Pattern Loop.
Effect 14/7: Set Tremolo Waveform.
Effect 14/8: Unused.
Effect 14/9: Retrigger.
Effect 14/10: Volume Up.
Effect 14/11: Volume Down.
Effect 14/12: Cut Note.
Effect 14/13: Delay Note.
Effect 14/14: Delay Pattern.
Effect 14/15: Invert Loop.
Effect 15: Set Speed.
 

VI. AUDIO PROCESSING.

 

 


24. Fourier Transforms.

 

 

Fourier Transform Basics.
Sine Waves.
Measuring One Frequency at a Time.
Accounting for Phase.
Implementing the DFT.
Scaling.

Measuring the Entire Spectrum at Once.
Small FFTs.
Decomposing Long FFTs.
2-Point FFT.
Four-Point FFTs.
Formal Derivation of the FFT.

Programming the FFT.
Speed.
Playing with FFTs.

Using FFTs.
Windowing.
Observations.


25. Filtering.

 

 

Adding Sine Waves.
FIR Filters.
Designing Simple FIR Filters.

Implementing FIR Filters.
Phase Shift.

IIR Filters.
Music Synthesis with Filters.
 

II. APPENDICES.

 

 


A. About the CD-ROM.

 

 

Source Code.
Project Files.
Windows.
Mac OS.
UNIX.
Others.

Sample Files.
Contributed Materials.
Sound Forge.
Cool Edit 96.
Articles on Music Production by Donald Griffin.
SoundApp.
WHAM.
XAudio.


B. A Brief Introduction to C++.

 

 

Improving C: A Better struct.
Toward Object-Oriented Programming.
Real OOP: Classes and Inheritance.
Inheritance.
Virtual Functions.

Real-World Considerations.
Constructor Initializations.
Double-Colon Notation.
Defining Methods in Separate Files.

C++ I/O.
Operator Overloading.
I/O.

Miscellany.
C++ Casts.
References.
this.
Friends.


C. Coding Style.
D. Systems Used.
E. Reusing My Source Code.
Index. 0201419726T04062001


Back to Top

 

 

商品描述(中文翻譯)

目錄

簡介。

原始碼。

關於本書。

致謝。

 

 

I. 基礎知識。

 

1. 從空心樹幹到網際網路。

什麼是聲音?

自然聲音。

電子聲音。

我們聽到的聲音。

數位聲音。

其他資源。

2. 人類聲音感知。

頻率與音高。

音樂音高。

音高與頻率並不相同。

噪音。

音量、振幅與功率。

整體品質。

3. 數位存儲聲音。

取樣聲音格式。

脈衝振幅調變(Pulse Amplitude Modulation, PAM)。

脈衝寬度調變(Pulse Width Modulation, PWM)。

脈衝編碼調變(Pulse Code Modulation, PCM)。

取樣的副作用。

混疊。

輸出混疊。

重取樣。

量化誤差。

抖動。

削波。

浮點取樣。

4. C++ 聲音框架。

AudioAbstract 類別。

立體聲。

協商。

讀取與寫入整數。

一個 SineWave 類別。

II. 系統細節。

5. 播放器物件。

播放器基礎。

實作佇列。

開啟未知聲音檔案。

6. 在 Windows 上播放音頻。

播放。

回調。

選擇音頻設備。

一個範例 Windows 應用程式。

7. 在 Mac OS 上播放音頻。

回調。

在 Mac OS 下的雙緩衝聲音。

一個範例 Mac OS 程式。

播放 Mac 檔案。

8. UNIX 與網路音頻系統。

伺服器與流。

回調與事件。

配置流並附加到伺服器。

一個範例 UNIX 應用程式。

III. 壓縮。

9. 音頻壓縮。

無損壓縮。

非線性 PCM。

差分 PCM。

自適應差分 PCM。

基於預測的壓縮。

子帶編碼。

人聲壓縮。

檢查點。

漸進式壓縮。

10. 解壓縮類別。

8 位元 PCM。

有符號 8 位元 PCM。

無符號 8 位元 PCM。

16 位元 PCM。

MSB 16 位元 PCM。

LSB 16 位元 PCM。

11. 非線性聲音格式。

對數壓縮。

mu-Law 壓縮。

A-Law。

對數編碼的特性。

12. 差分 PCM。

兩種 DPCM 編碼。

13. IMA ADPCM 壓縮。

一般操作。

解壓縮。

壓縮。

實用的 IMA ADPCM 解壓縮。

微軟的 IMA ADPCM 變體。

蘋果的 IMA ADPCM 變體。

比較微軟與蘋果的 IMA ADPCM 編解碼器的註解。

解開 ADPCM 格式。

致謝。

14. MPEG 音頻。

MPEG 標準概述。

MPEG-1。

MPEG-2。

MPEG-3。

MPEG-4。

MPEG 音頻。

一般結構。

管理位元組流。

MPE 的幀標頭。

插槽與幀。

第 1 層/第 2 層子帶合成。

矩陣化。

慢矩陣化。

快矩陣化。

合成窗口係數。

MPEG 立體聲編碼。

第 1 層。

第 1 層分配儲存。

第 1 層比例因子。

第 1 層取樣儲存。

第 1 層重新量化與縮放。

第 2 層。

第 2 層分配儲存。

第 2 層比例因子。

讀取第 2 層取樣。

第 2 層重新量化。

第 3 層。

MPEG 檔案的讀取器。

更多資訊。

IV. 一般檔案格式。

15. AU 檔案格式。

識別 AU 檔案。

讀取 AU 檔案。

寫入 AU 檔案。

一個簡單的 AU 濾波器。

16. VOC 檔案格式。

識別 VOC 檔案。

VOC 標頭。

數據區塊。

終止區塊(類型 0)。

聲音數據區塊(類型 1)。

聲音延續區塊(類型 2)。

靜音區塊(類型 3)。

標記區塊(類型 4)。

文本區塊(類型 5)。

重複循環(類型 6 和 7)。

擴展區塊(類型 8)。

擴展區塊(類型 9)。

其他區塊。

讀取 VOC 檔案。

17. WAVE 檔案格式。

識別 WAVE 檔案。

關於 RIFF 和其他 IFF 檔案。

WAVE 概述。

WaveRead 類別。

讀取 WAVE 檔案。

容器。

RIFF WAVE 容器。

fmt 區塊。