Lecture 7: Media Player Topics: Media Player, Async prepare Date: Mar 3, 2016.

Slides:



Advertisements
Similar presentations
Windows 7 demo.
Advertisements

10.2. Audio with SD Card Prof. Oum Saokosal Master of Engineering in Information Systems, South Korea
MicroCast: Cooperative Video Streaming on Smartphones Lorenzo Keller, Anh Le, Blerim Cic, Hulya Seferoglu LIDS, Christina Fragouli, Athina Markopoulou.
Global MP3 Geoffrey Beers Deborah Ford Mike Quinn Mark Ridao.
                      Digital Audio 1.
Investigating the sound quality of different audio file formats In this activity, we are going to record a short voice sample with a sound recording tool,
Using Multimedia on the Web Enhancing a Web Site with Sound, Video, and Applets.
CNIT 132 – Week 9 Multimedia. Working with Multimedia Bandwidth is a measure of the amount of data that can be sent through a communication pipeline each.
FM Transmitter (Carvox) Discover the freedom of sending a wireless broadcast of any audio to any FM radio anywhere in your car !!! Wireless.
TouchDevelop Chapter 5-7 Chapter 5 Audio Chapter 6 Camera, Graphics and Video Chapter 7 Sensors Mengfei Ren.
Cosc 5/4730 Multimedia Part 1: Audio media. PLAYING AUDIO Android android.media.
It provides a framework for embedded multimedia facilities in java enabled mobile devices.
Group 8: Dylan Lentini (AE), Mandy Minuti (WSE), Jean Paul Galea (TL)
3G v.s WIFI Radio Energy with YouTube downloads. Energy in Mobile Phone Data Transfers In 3G, there are three states –Idle –DCH (Dedicated Channel), do.
V Avon High School Tech Crew Agenda Old Business –Scorers Table –Tech Talks New Business –Week 7 Topics: Delete files XBMC Demo/Mini-PC Demo.
Chapter 6 Jam! Implementing Audio in Android Apps.
John Meilak Reuben Sant Jason Farrugia Media API Web Science APT 2007/2008.
SPOT Slide Presentation Over Telephony A CS 790 Project by Jason Howes.
Internet video sub-titling cases Henning Schulzrinne
Java Audio.
Bush Library Proposal By Yvana. Introduction The museum will assume that people have their own wireless devices such as iPods, cell phones, and MP3 players.
Mobile Application Development
Electrical & Computer Engineering Wireless Music Sharing Team Ganz: Mike O’Malley™ Ben LaPointe Erik Christensen Nhat Khai Nguyen.
Chapter 9 Audio.
CS371m - Mobile Computing Audio.
1 NETE4631 Communicating with the Cloud and Using Media and Streaming Lecture Notes #14.
Basic Audio and Video. Audio Primary components – Audio file stored in ‘raw’ folder within ‘res’ folder ‘raw’ directory must be created while many formats.
Multimedia.
The fight between the two greatest Game Consoles PS3 vs. Xbox.
Windows audio architecture Win MM Application DirectSound Application SysAudio.SYS Kmixer.SYS WinMM.DLLDSound.DLL Device Drive Container USB Device Driver.
© 2009 Research In Motion Limited Advanced Java Application Development for the BlackBerry Smartphone Trainer name Date.
HTML5. What is HTML5? HTML5 will be the new standard for HTML. HTML5 is the next generation of HTML. HTML5 is still a work in progress. However, the major.
CIS 102Introduction to Hardware and Software Chapter 2 Input and Output part 3 output devices.
Farryl Kaplan, Zane Galyan, Jon Marshall, Courtney Carmichael.
ScreenPlay Director Training By Erik Collett
11 Adding Sounds Session 7.1. Session Overview  Find out how to capture and manipulate sound on a Windows PC  Show how sound is managed as an item of.
Μ [sic] patent liability wesley :: chris :: dave :: josh.
Integrating Technology in Today’s Classroom Presented by: TJ Mears SEE 2010 Huntington, IN TJ Mears - SEE 2010.
Creating a Podcast. What is a podcast? A podcast is a media file that is shared over the Internet that can be played on mobile devices i.e. iPods or MP3.
Audio Yu Feng CGDD Review 1. Set up 2. IOS sound – Core Audio – Short Sound – Long Sound – Control Sound – Background Sound 3.Cocos2d sound.
Podcasting with Audacity for Second Language Acquisition.
ISA 673 Operating Systems Security Exploring the Android Platform.
Podcasting in teaching & learning
What is gaming console & platform? A game console is a device which outputs video signal into TV screen to display the video game. A platform is in which.
HTML 5. Introduction In modern browsers, adding a video to your page is as easy as adding an image. No longer do you need to deal with special plug-ins.
Podcasting The Basics. The How To! Requirements –Microphone Blue Tooth Headset USB Headset Built in Mic –Laptop/computer –Software Audacity Lame File.
Sound and the Web. Transferring sound Download Progressive Download Stream.
ISA 673 Operating Systems Security Exploring the Android Platform.
CS378 - Mobile Computing Audio.
Mission Computers Inc.  In 2013 ◦ 1,000,000,000 phones were hacked  because of ◦ lack of a secure password or ◦ no password at all Source:
Introduction to sound using processing. 2 Minim –A sound library which uses javasound library –Provide convenient but flexible way to play,, synthesize.
MUSIC GENRE JUKEBOX. CLIENT SPECIFICATIONS Audio Player Create, delete, and modify play lists Play, pause, stop, skip, fast forward, and rewind Send Streaming.
Multimedia. Audio,vedio and Images End user typically refer to vedio/audio using the respective file format MP4 or AVI(audio vedio interleave) Developer.
How to Get around on a ipod Table of Contents Which ipod are you ? There are 6 different ipods they have some different features but all do the same.
 Digital Rights Management  To prevent you from making copies of audio files you have downloaded on your personal media player. It also prevent from.
CS371m - Mobile Computing Audio. Audio on Device Devices have multiple audio streams: – music, alarms, notifications, incoming call ringer, in call volume,
GStreamer in OpenOffice.org? Cédric Bosdonnat, Radek Doulík.
How to Convert/Transfer iTunes to Sony Walkman through Mac/Windows? All rights reserved— I got my kids.
Audio and Haptic Feedback
Network Controllable MP3 Player
Android Application Audio 1.
Objective % Explain concepts used to create digital audio.
Lecture 7: Service Topics: Services, Playing Media.
Lecture 7: Media Player Topics: Media Player, Async prepare
Objective % Explain concepts used to create digital audio.
                      Digital Audio 1.
Press ESC for Startup Options © Microsoft Corporation.
Lecture 7: Service Topics: Services, Broadcast Receiver, Playing Media.
Objective Explain concepts used to create digital audio.
Presentation transcript:

Lecture 7: Media Player Topics: Media Player, Async prepare Date: Mar 3, 2016

References (study these)

Media Playback Play Audio/Video from: Application Resources (raw resource) File System Data Stream over a Network. Support for Output Devices: Speaker Bluetooth Headset However, you cannot play sound files in the conversation audio during a phone call.

Media Playback API Two important classes – MediaPlayer AudioManager

Using Media Player API Permissions: INTERNET, WAKE_LOCK Playing from Local Resource: Playing from a local URI:

Using Media Player API Playing from an Internet URL Supported media format: Must be progressively downloadable

Media Player State Diagram

Asynchronous Preparation For files: It is “OK” to use prepare() For streams: You should always use prepareAsync() Implement MediaPlayer.OnPreparedListener mp.setOnPreparedListener(this); public void onPrepared(MediaPlayer mp) { mp.start(); } BLOCKING NON- BLOCKING

Code practice Create a MediaPlayer and play a song. Modify the code to prepare a media player asynchronously.

Playing songs in a background service

Using Wake Locks When device sleeps, the system tries to shut off features that are not necessary – including CPU and WiFi hardware. Use “Wake Locks” to let the system know you need some features even if the phone is idle. mp.setWakeMode(getApplicationContext(), PowerManager.PARTIAL_WAKE_LOCK); WifiManager.WifiLock wifiLock = ((WifiManager) getSystemService(Context.WIFI_SERVICE)).createWifiLock(WifiManager.WIFI_MODE_FULL, "mylock"); wifiLock.acquire();