Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction to the Media Kit Matt Wronkiewicz Be Users Group at UIUC.

Similar presentations


Presentation on theme: "Introduction to the Media Kit Matt Wronkiewicz Be Users Group at UIUC."— Presentation transcript:

1 Introduction to the Media Kit Matt Wronkiewicz Be Users Group at UIUC

2 Introduction n This presentation gives an overview of the structure and use of the new Media Kit, part of BeOS R4.

3 What is the BeOS? n Multimedia OS n Can run with Windows or MacOS on the same computer n Designed for video and audio professionals n Newer and more efficient than other operating systems n Easy to program

4 Topics of Discussion n Uses n Structure n Classes n Communicating with the Media Kit n A simple application

5 Uses n Allows you to write video and audio players and editors. n Reads audio from files and sound cards n Reads video from files (QuickTime, MPEG, AVI) n Simplifies development of applications. n Example: The Media Kit can be used to write a DVD disk player.

6 Structure n Media Kit provides translators and the foundation for writing players and editors n Translator add-ons read media files such as MPEG movies from disk n Allows you to create your own translators and filters n Applications can use translators and filters to play video and sound

7 Architecture Kernel Level Drivers Application Media Server Media Kit Library Add-Ons Media Add-Ons

8 Classes n Media Nodes: (Can mix these) u Media Producer (BBufferProducer) u Media Consumer (BBufferConsumer) u Time Source (BTimeSource) u Media File (BFileInterface) n Media Roster (BMediaRoster)

9 Media Producer n Sends audio or video data to other objects n Represents a file or piece of hardware like a sound card n Connects to Media Consumers n Example: Sound generator

10 Media Consumer n Receives A/V data from Media Producers n Can be paired with a Media Consumer to create a filter n Example: Audio mixer n Example: Video player

11 Time Source n Can be used to synchronize audio and video n Default time source is the computer’s clock n Example: Satellite transmission

12 Media File n Accesses data files to provide media n Writes sound and movie files

13 Media Roster n Keeps track of media translators and filters n Supplies media nodes for requested format n Supplies default audio and video sources and the audio mixer

14 Communicating with the Media Kit n Subclass media node classes to create new nodes n Link Producers with Consumers (BBufferProducer::Connect) n Ask the Media Roster to provide system and third-party nodes n Put a media node in a user- installable add-on (BMediaAddOn)

15 Using the Nodes Together Sound File (BBufferProducer, BFileInterface) High Frequency Filter (BBufferConsumer, BBufferProducer) Audio Mixer (BBufferConsumer)

16 Sample Audio Player void playsound(entry_ref* file) { BSound sound(&file); BSoundPlayer player; player.Start(); player.SetVolume(1.0); BSoundPlayer::play_id id; id = player.StartPlaying(sound); player.WaitForSound(id); }

17 Summary n Media Kit makes it easier to write multimedia applications n Pluggable architecture allows programs to work together n Pre-made add-ons reduce development time


Download ppt "Introduction to the Media Kit Matt Wronkiewicz Be Users Group at UIUC."

Similar presentations


Ads by Google