Beginning Game Audio Programming [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Beginning Game Audio Programming [Electronic resources] - نسخه متنی

Mason McCuskey

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
توضیحات
افزودن یادداشت جدید





STRUCTURE OF OGG VORBIS

The Ogg Vorbis API consists of a slew of different lib files, each one designed for a particular purpose. To start with, the Ogg Vorbis API allows both static linking and the use of DLLs. The static libraries are self-contained, and require no external DLL files, so for most games you'll want to use those and avoid the hassle of DLLs. However, you can also use the stub libraries, which require certain DLLs to operate. You can find these DLLs in your bin directory.

The Ogg Vorbis API is divided into four different libraries: the Ogg library, the Vorbis library, the Vorbisenc library, and the Vorbisfile library.


The Ogg and Vorbis Libraries


These two libraries contain the basic functions needed to work with Ogg Vorbis files.

Not surprisingly then, the Ogg library contains general-purpose routines for dealing with Ogg files. It knows nothing about Vorbis; in fact, the Ogg library doesn't know (and doesn't care) if you're manipulating audio or video data. It just creates the base framework. The Vorbis library contains the foundation functions necessary for decoding streams using the Vorbis codec.



Ogg Vorbis: Funny Name, Serious Codec


Some enlightenment on the funny name: Xiph.org has created a framework for compressing audio and video. This framework is called Ogg. The actual audio codec is called Vorbis. This is analogous to RIFF—just as a RIFF file can contain MP3-encoded data, an Ogg file can contain Vorbis-encoded data. Currently the Vorbis codec is the only codec that uses the Ogg framework, but Xiph.org plans to release additional codecs for a wide variety of applications. These codecs, when released, will also use the Ogg framework, so think of Ogg as sitting above Vorbis.




The Vorbisenc Library


This library is designed to help you with encoding Vorbis files. In here, you'll find functions to set up and tear down the Vorbis encoder. If you're creating an application that rips audio CDs into Ogg Vorbis files, this is your library, but games don't usually need to use this.


The Vorbisfile Library


This is a convenience library used to deal with Ogg Vorbis files. This library uses the Ogg and Vorbis libraries and adds some code that creates a much simpler interface to them, specifically designed for decoding files. This is the library best suited to games, so it's the library you'll learn the most about during this chapter.


Getting Help


There's one last thing I should mention before we move on, and that's how to get to the documentation for the Ogg Vorbis libraries. Inside your installation folder is a doc folder which contains an HTML file called indexl. That's the root of the documentation. If you know specifically what API you want help with, you can shortcut that and go into one of the folders located under doc (ogg, vorbis, vorbisenc, or vorbisfile), and fire up the indexl file located there for help specific to that library.

/ 127