Sound DirectMusic & DirectSound. DirectShow Video Formats DirectShow is an open architecture, it can support any format as long as there are filters to.

Slides:



Advertisements
Similar presentations
3.01C Multimedia Elements and Guidelines 3.01 Explore multimedia systems, elements and presentations.
Advertisements

Developing Windows ® CE Multimedia Solutions Using Windows Media Rod Deyo Program Manager Windows CE Platforms Microsoft Corporation
CS335 Principles of Multimedia Systems Audio Hao Jiang Computer Science Department Boston College Oct. 11, 2007.
Chapter 11 Media and Interactivity Basics Key Concepts Copyright © 2013 Terry Ann Morris, Ed.D 1.
Tae-wan You, Seoul National University, Korea
2 Information Processing
Chapter 11 Media and Interactivity Basics Key Concepts
4.2 Multimedia Elements Audio 1. Learning Outcomes: At the end of the lesson, students should be: a) describe the purpose of using audio in multimedia.
HTML Structure & Web Design Basics
3.6 Multimedia/Digital Media Components (Audio and Video) by Francisco Oliveira.
© 2008 Verizon. All Rights Reserved. PTEXXXXX XX/08 GLOBAL CAPABILITY. PERSONAL ACCOUNTABILITY. Customized Net Conference New Features in Microsoft Office.
Using Animation and Multimedia Lesson 9. Software Orientation The Animation Pane, shown at right, enables you to manage all the animation effects on the.
Sounds, Images & Other Objects Website Production.
 Multimedia is everything you can hear or see: texts, books, pictures, music, sounds, CDs, videos, DVDs, Records, Films, and more.  Multimedia comes.
Movies Play on Some Computers, Not Others. PowerPoint 2000 Movie Troubleshooter 2Fsupport%2Fpowerpoint%2Fppt2000%2Fmmed.
SCA Introduction to Multimedia
Using PlayCap. Introduction  Based on: 1. Win32 API 2. DirectShow API 3. GDI+ API  Platform Windows XP  IDE Visual Studio.Net 2003.
Digital Video Teppo Räisänen LIIKE/OAMK. General Information Originally video material was processed using analog tools Nowadays it is common, that digital.
Direct Show Introduction Direct Show Introduction to DirectShow And, I wish, a discussion.
Chapter 9 Audio.
1 Different Video Properties
Graphics and Multimedia In visual Studio. Net (C#)
Video Streaming © Nanda Ganesan, Ph.D..
3dtv.at DV/HDV Tape Drive Synchronization Stereoscopic Displays and Applications Conference 29 th – 31 th January 2007 San Jose, United States.
Windows audio architecture Win MM Application DirectSound Application SysAudio.SYS Kmixer.SYS WinMM.DLLDSound.DLL Device Drive Container USB Device Driver.
Computer Science [3] Java Programming II - Laboratory Course Lab 7: Multimedia: Applets and Applications Faculty of Engineering & IT Software Engineering.
Video file format.
What are the common format for video files?
A Tutorial to DirectShow Ruigang Yang August, 2001.
DirectShow.
1 Lecture 12: Multimedia Not in Web 101 Text  Important Multimedia Issues  Audio  Movies and Video  Multimedia and HTML Documents.
Audio and Video CGS Some Common Audio Formats Format Use Extension MIDI instrumental music.mid MPEG songs.mp3 RealAudio live broadcasts.ra Wave.
2.02G Publishing Animated Videos 2.02 Develop Computer Animations.
HTML Use of Multimedia on web page. HTML Media Q. How to call Image file in our web page ? A. That is the easy syntax for defining an image. 2.
1.1 What is Multimedia Multimedia
Video & Scanning Overview IT 130 Web Graphics and Multimedia.
GIF - Graphics Interchange Format JPEG - Joint Photographic Experts Group PNG - Portable Network Graphics GIF images are limited to the 8 bit palette which.
Multimedia From Greenlaw/Hepp, In-line/On-line: Fundamentals of the Internet and the World Wide Web 1 Introduction Important Multimedia Issues Audio Movies.
H.323, IP Multicast Conferencing, And TAPI 3.0 Don Ryan Development Lead Windows Networking And Communications Microsoft Corporation.
File Format. Graphics file Format GIF (Graphics Interchange Format) JPEG (Joint Photographic Experts Group) PNG (Portable Network Graphics) TIFF (Tag.
5-1 OBJ Copyright 2003, Paradigm Publishing Inc. Adding Sound, Video, and Basic Interactivity with Buttons Macromedia Flash Design & Application.
视频处理相关技术. Basic Concept Image Sequence (图像序列) FPS ( Frames Per Second ) Resolution 1080p , 720i , DVD , VCD , HD Compression Codec H.264 、 MPEG Quick.
1 Contents  Audio  Sprite  Input devices  Game production milestones  Course summary.
Microsoft DirectX 8.0 Project Introduction Microsoft COM DirectShow Instruction: Hsiao Kung Wu Students: 賴建利、林廷駿、楊惟仁.
GAM666 – Introduction To Game Programming ● DirectX is implemented as a collection of COM objects ● To use a DirectX program, the user must have the correct.
Chapter 10. The Role of Video in Multimedia  Any presentation or application that uses sound and graphics qualifies as multimedia  Clip A segment of.
Multimedia. What is multimedia? Multimedia is everything you can hear or see: texts, books, pictures, music, sounds, CDs, videos, DVDs, Records, Films,
Digital Video File Formats an overview. Introduction Digital Video & Audio files are also known as container formats. These “containers” are digital files.
Music files in PowerPoint 2007? By Ashley Wiger.
Audio Streaming © Nanda Ganesan, Ph.D.. Audio File Features Audio file is a record of captured sound that can be played back –The WAV File is an example.
 „BB FlashBack stores its movies in FlashBack (FBR) format. If you want non-FlashBack users to be able to watch your movie, you'll need to export it.
© 2008 Verizon. All Rights Reserved. PTEXXXXX XX/08 GLOBAL CAPABILITY. PERSONAL ACCOUNTABILITY. Reserved Net Conference New Features in Microsoft Office.
Multimedia Multimedia obuhvata sve što može da se vidi, čuje, pročita Multimedijalni sadržaji mogu biti u različitim formatima Podrška Internet browser-ima.
DaVinci Overview (features and programming) Kim dong hyouk.
What is DirectX? DirectX is built by Microsoft as a collection of API’s (Application Programming Interfaces) for the purpose of multimedia processing.
P2P Digital TV Recorder Supervisor: Professor Michael R. Lyu
Section 9.1 Section 9.2 YOU WILL LEARN TO…
Section 9.1 Section 9.2 Identify multimedia design guidelines
Instant Net Conference
RENDERING Preparing the Project Exporting the Timeline Video Settings
VIDEO.
Reserved Net Conference
Web Programming– UFCFB Lecture 8
Instant Net Conference
Microsoft DirectShow.
Customized Net Conference
Windows Movie Maker Introduction to TDL.
Web Programming– UFCFB Lecture 8
Customized Net Conference
(c) V/2-Com (Verhaart) Multimedia Elements & standards 4/15/2019 (c) V/2-Com (Verhaart)
Presentation transcript:

Sound DirectMusic & DirectSound

DirectShow Video Formats DirectShow is an open architecture, it can support any format as long as there are filters to parse and decode it. (*= Windows Media® Format SDK needed to support this format.) Windows Media® Audio (WMA), Windows Media® Video (WMV), Advanced Systems Format (ASF)* Motion Picture Experts Group (MPEG) Audio-Video Interleaved (AVI) QuickTime (version 2 and lower) WAV, AIFF, AU, SND, MIDI Compression formats: Windows Media Video, ISO MPEG-4 video version 1.0, Microsoft MPEG-4 version 3, Sipro Labs ACELP* Windows Media Audio* MPEG Audio Layer-3 (MP3) (decompression only) Digital Video (DV) MPEG-1 (decompression only) MJPEG Cinepak DirectShow-compatible MPEG-2 decoders are available from third parties

DirectShow ( Headers and Libs ) Header Files Dshow.h Some DirectShow interfaces require additional header files. These requirements are noted in the interface reference. Library Files Strmiids.lib Exports class identifiers (CLSIDs) and interface identifiers (IIDs). Quartz.lib Exports the AMGetErrorText function. If you do not call this function, this library is not required.AMGetErrorText Note: In your build environment, place the DirectX SDK Include and Lib directories first in the Visual Studio search path. This ensures that you are using the most recent versions of these files.

Direct Show Application Programming Filters and Filter Graphs The building block of DirectShow is a software component called a filter. A filter is a software component that performs some operation on a multimedia stream. For example, DirectShow filters can read files get video from a video capture device decode various stream formats, such as MPEG-1 video pass data to the graphics or sound card Filters receive input and produce output. For example, if a filter decodes MPEG-1 video, the input is the MPEG-encoded stream and the output is a series of uncompressed video frames.

Writing a DirectShow Application The application creates an instance of the Filter Graph Manager. The application uses the Filter Graph Manager to build a filter graph. The exact set of filters in the graph will depend on the application. The application uses the Filter Graph Manager to control the filter graph and stream data through the filters. Throughout this process, the application will also respond to events from the Filter Graph Manager. When processing is completed, the application releases the Filter Graph Manager and all of the filters.

DirectShow and COM DirectShow is based on COM; the Filter Graph Manager and the filters are all COM objects. You should have a general understanding of COM client programming before you begin programming DirectShow. The article "Using COM" in the DirectX SDK documentation is a good overview of the subject. Many books about COM programming are also available.

Video Data Flow

DirectShow Play a File DirectShow application always performs the same basic steps: Creates an instance of the Filter Graph Manager.Filter Graph Manager Uses the Filter Graph Manager to build a filter graph. Runs the graph, which causes data to move through the filters.

DirectShow Play a File Start by calling CoInitialize to initialize the COM library: HRESULT hr = CoInitialize(NULL); Call CoCreateInstance to create the Filter Graph Manager: IGraphBuilder *pGraph; HRESULT hr = CoCreateInstance(CLSID_FilterGraph, NULL, CLSCTX_INPROC_SERVER, IID_IGraphBuilder, (void **)&pGraph); The Filter Graph Manager is provided by an in-process DLL, so the execution context is CLSCTX_INPROC_SERVER. The call to CoCreateInstance returns the IGraphBuilder interface, which mostly contains methods for building the filter graph.IGraphBuilder

DirectShow Play a File Two other interfaces are needed for this example: IMediaControl controls streaming. It contains methods for stopping and starting the graph. IMediaControl IMediaEvent has methods for getting events from the Filter Graph Manager. In this example, the interface is used to wait for playback to complete. IMediaEvent Both of these interfaces are exposed by the Filter Graph Manager. Use the returned IGraphBuilder pointer to query for them: IMediaControl *pControl; IMediaEvent *pEvent; hr = pGraph->QueryInterface(IID_IMediaControl, (void **)&pControl); hr = pGraph->QueryInterface(IID_IMediaEvent, (void **)&pEvent);

DirectShow Play a File Now you can build the filter graph. For file playback, this is done by a single method call: hr = pGraph->RenderFile(L"C:\\Example.avi", NULL); The IGraphBuilder::RenderFile method builds a filter graph that can play the specified file. The first parameter is the file name, represented as a wide character (2-byte) string. The second parameter is reserved and must equal NULL.IGraphBuilder::RenderFile This method can fail if the specified file does not exist, or the file format is not recognized. Assuming that the method succeeds, however, the filter graph is now ready for playback.

DirectShow Play a File To run the graph, call the IMediaControl::Run method:IMediaControl::Run hr = pControl->Run(); When the filter graph runs, data moves through the filters and is rendered as video and audio. Playback occurs on a separate thread. You can wait for playback to complete by calling the IMediaEvent::WaitForCompletion method: IMediaEvent::WaitForCompletion long evCode = 0; pEvent->WaitForCompletion(INFINITE, &evCode); This method blocks until the file is done playing, or until the specified time-out interval elapses. The value INFINITE means the application blocks indefinitely until the file is done playing. When the application is finished, release the interface pointers and close the COM library: pControl->Release(); pEvent->Release(); pGraph->Release(); CoUninitialize();

Assignments (Problems) assignments 1-4 are related to playing video files assignment 5 is about Visual C++ classes and pointers the advanced assignment is about sound and video ‘thumbnails’