Windows Media Format SDK System Overview
Windows Media media content using the ASF file format. Microsoft offers Windows Media Format SDK, in order to support the following three functions: ASF file is generated (including the ASF streaming data), ASF file editing and playback of ASF files (including the ASF streaming media playback). Begin programming before the system has one of the SDK in general awareness and understanding is necessary. (Note: If you do not make special note of the SDK, or described in this book are the WMF SDK means Windows Media Format SDK.)
WMF SDK with object-oriented design, is a COM component model based entirely on the high-level development package. Here that high-level, meaning that SDK shields ASF data formats, network transmission control, the more the underlying implementation details of the streaming media technology, leaving the developer only compare the upper programming interface.
Figure 2.1 WMF SDK architecture
Shown in Figure 2.1, SDK introduces a series of objects, such as generators, readers, editors and so on. It is these SDK objects shield the details of the Windows Media technology, enabling application developers do not need to know a lot of streaming media the underlying technology, but also be able to develop a very professional streaming media applications.
Introduced a number of objects in the SDK, the most important than those listed in Figure 2.1 has three. Among them, generators are generally used for non-compressed media data encoded into Windows Media format. Throughout the encoding process is very simple, as long as the object through a call Profile configured target data stream format, and then to tell the format of the input data generator, followed by the input data transmitted in accordance with established ways generator, the rest are all things on can be handed over to the generator. Profile Generator based on the configuration of the internal, automatically select a Windows Media Encoder, and then enter the data compression coding, and complete packing, the final written document or streamed to the network.
Figure 2.2 workflow Builder
Shown in Figure 2.2 is a rough workflow generator. You can see, the generator within the input data may have a pretreatment process. Because the encoder can accept a specific data format is always limited. If you enter the encoder data format can not be accepted, the generator will automatically within a pretreatment process. These include video pre-processing image size scaling, frame rate adjustment, color space conversion, watermark overlay, audio sampling frequency conversion and so on. In addition, the generator itself is not responsible for the encoded data, the final destination, but this task to a known receiver (Sink) object, such as the receiver to the file on the data can be saved as a file, to the Network receiver can broadcast the data, to push the receiver on the data can be distributed to a server running Windows Media Services on and so forth. SDK using this "Builder + receiver" design is very advanced, it guarantees the SDK system is highly scalable. For instance, we can develop your own receiver, according to our decision to compress the data requirements of the final destination.
If you have used Microsoft's official release of Windows Media content encoding software Windows Media Encoder, then, do not doubt that learning through the WMF SDK, you can develop a similar encoding software.
WMF SDK there are two readers: asynchronous and synchronous reader reader. 2 readers have similar functionality, the data are used to read the ASF, and different is their way of working: asynchronous reader comes with a thread within the data stream onto the application; while simultaneously reading data flow is not driven inner thread, the application directly (in the application thread) through synchronous reader interface functions to obtain the data. (Note: Asynchronous reader is usually referred to as readers, but only when compared with the synchronous reader emphasis on "asynchronous" feature.)
Figure 2.3 workflow reader
By default, the read output of a non-compressed format. In other words, the internal reader will automatically select the appropriate decoder to the ASF decompress the data stream, shown in Figure 2.3. Of course, through the appropriate settings, the reader can also output the original ASF streaming data compression format.
It is noteworthy that, asynchronous reader in the various versions of the SDK can be used; while the synchronous reader is 9 Series SDK, and some began. The increase of synchronous reader, because reading the data synchronization model in some special occasions, more advantages, such as in a number of applications for content editing, use the synchronous reader can quickly read the part of the specified location data. In addition, the synchronous reader through a direct interface function calls to provide data, is also relatively simple to use. Of course, the synchronous reader also has obvious deficiencies, such as network file does not support the reading and does not support DRM (Digital Rights Management) and others. Thus, in the vast majority of occasions, ASF files to read or use the asynchronous reader.Finally come to a brief editor. Said the editor, we should not think that it can do media content changes. In fact, it can only edit some metadata. The so-called meta-data, that is, the media content title, description, author, copyright and other information.
C/C++ Tutorial Articles
- C + + design patterns of the Adapter
- USB port anomaly and C + + & Java
- Windows Media Format SDK System Overview
- Good books: Accelerated C + +
- boiz in C + + memorandum (1)
- Point to Point voice communication
- How do I customize the dialog box ENTER
- Interrelated design of the drop-down box control
- Visual C + + programming file operations
- Visual C + + programming file operations
- Member function pointers with a high-performance C + + commission (Part)
- Member function pointer and high-performance C + + commission ()
- Member function pointer and high-performance C + + commission (Part)
- IPv6 name to address translation function getaddrinfo () Detailed
- [Translation] C + + in the file input / output: some useful function
- With ENTER button to switch the focus of control and simulation of key
- Learning C + + the way smooth
- C + + frequently cited category of how to avoid unnecessary re-compile
- A realization of the type of HTTP FTP
- CListCtrl landscaping shown in the focus of Bank
Can't Find What You're Looking For?
Rating: Not yet rated