A Roadmap to This Book

A Roadmap to This Book

This book has been written for the complete DirectShow novice; you don t need to know anything about DirectShow or even audio or video to get started. If you re already familiar with DirectShow, chances are you ll be able to race through the first three chapters of this book very quickly. However, it s always a good idea to review the pages, just to see if there s anything covered that you might not be familiar with.

The basics covered in Part I of this book include a firm understanding of the DirectShow filter, which is the core component of all DirectShow applications. Filters come in three flavors, as mentioned earlier capture filters, transform filters, and render filters and they re connected together to process a media stream from source to renderer. To demonstrate this, we ll open up the DirectShow prototyping application, GraphEdit, which allows you to visually explore DirectShow filters, creating your own DirectShow applications with nothing more than a few clicks of the mouse. Next we ll dive headlong into some C++ programming with the Microsoft Component Object Model (COM), the interface wrapper for DirectShow filters, and create some very simple C++ programs (only a few tens of lines of code each) illustrating how DirectShow can be used to play a range of media files. If you re planning to use DirectShow only to add some media playback to your application, this basic information might be all you ll ever need to read.

With the basics behind us, we ll dive headlong into DirectShow. The organization of Part II of the book echoes the three basic types of DirectShow filters: capture, transform and renders. We ll explore how to capture audio and video from a broad range of sources, including camcorders, broadcast TV capture cards, and webcams. Each of these devices has its own peculiar properties, so each chapter explores a different capture device. An example application is included with each chapter, which could be used in a cookbook formula for your own applications. (Go ahead; reuse this code.) Next, we ll explore the DirectShow editing services, which allow you to slice-and-dice video and audio streams and then paste them back together along a timeline. Finally, we ll focus on the Video Mixing Renderer (VMR), a powerful new addition to DirectShow that allows you to mix multiple video streams into a single stream. By the end of Chapter 9, you ll have a thorough understanding of media capture, editing, and rendering within DirectShow.

In Part III you ll learn how to write your own DirectShow transform filters; when you re done with this section, you ll be able to extend DirectShow in any way you d like, either with a custom DirectShow filter or by creating a DirectX Media Object (DMO), which is similar to a DirectShow filter but can also be used in other DirectX applications. Starting with a DirectShow filter that converts color video to black and white, we ll explore a framework that could form the basis of almost any transform filter of your own design. Using another DirectShow filter known as Sample Grabber, which grabs media samples as they pass through the filter, you ll see how to add your own application-level processing to DirectShow. That ll be followed by coverage of source filters, and you ll learn how to write your own source filters, producing media streams for DirectShow to process. Finally, we ll explore the world of DMOs, creating an audio delay effect that can be used within DirectShow or in DirectSound, the audio library for DirectX applications.

The two concluding chapters cover advanced topics that will interest dedicated DirectShow programmers: the AVI format and the Windows Media Format. We ll get down and dirty into the bits and bytes of the AVI format, which will come in handy if you re ever creating the kind of code that manipulates or creates media streams inside or outside of DirectShow. Windows Media Format is a brand-new architecture that provides unprecedented flexibility in the creation and management of a wide range of media formats, and we ll learn how to compose our own Windows Media streams programmatically.

A comprehensive reference for DirectShow could easily run to 1000 pages. The DirectX SDK has a complete set of documentation on DirectShow, and those pages are the final authority. This book is a complement to the SDK documentation to help you get your feet wet with DirectShow. Before you finish this book, you ll find that DirectShow is one of the hidden jewels of the Microsoft operating systems a powerful platform for multimedia that s easy to use and performs well on a wide range of hardware. You ll have no trouble dreaming up your own DirectShow applications, and after you ve read this book, you ll understand how to bring them to life.

Although this book has been reviewed and fact-checked, I alone am responsible for any factual errors you might find in the text. Please e-mail me at mark@playfulworld.com if you find one so that it can be corrected in subsequent editions.



Programming Microsoft DirectShow for Digital Video and Television
Programming Microsoft DirectShow for Digital Video and Television (Pro-Developer)
ISBN: 0735618216
EAN: 2147483647
Year: 2002
Pages: 108
Authors: Mark D. Pesce

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net