IIS Smooth Streaming

Preview:

DESCRIPTION

This presentation was held at MIND event in Microsoft Auditorium Malaysia, October 8, 2011. It covers the mechanism of video streaming and its high-view architecture

Citation preview

IIS Smooth Streaming

By: Hossein SARSHARMCP Since 2004

Basic Description• IIS Smooth Streaming is an extension of Microsoft

IIS web server 7.0 or 7.5 (or later) to deliver live or recorded (on-demand) media contents over the internet at HD quality.

• Streams based on the following conditions of viewers:o CPU conditiono Bandwidtho Capability of their display device

How it works

?

Overview of basic networking terms

SMPT/IMAP 4HTTPFTP

Telnet, …

RIPOSPFDHCPTFTP

TCP UDP

IP, ICMP, …

ARP, RARP, …

Ethernet, …

Application

Transport

Network

Data-link

Physical

SMPT/IMAP 4HTTPFTP

Telnet, …

RIPOSPFDHCPTFTP

TCP UDP

IP, ICMP, …

ARP, RARP, …

Ethernet, …

- A connection-oriented protocol- Uses port number to

communicate with its corresponding application layerprogram

- Full duplex- Reliable

SMPT/IMAP 4HTTPFTP

Telnet, …

RIPOSPFDHCPTFTP

TCP UDP

IP, ICMP, …

ARP, RARP, …

Ethernet, …

- A connection-less protocol- Uses port number to

communicate with its corresponding application layerprogram

- Best effort- Small packet size- not reliable

History of media streaming

• The first Internet video streaming:

Victoria’s Secret annual fashion show at NCY 1999.

RTP and RTSP• These are the first protocols in media streaming.• RTP:

o Based on UDPo Starts its communication without any connection establishment.o Unreliableo Fast

• RTSP:o Based on TCP.o Has communication with server.o State-full.o Communicating with sender.

walking carefully is better that running with closed eyes

HTTP Based protocols• HTTP:

o TCP based protocol.o Is easily passed through routers and firewalls (TCP:80).o But stateless ….

Progressive Download• A simple file download from an HTTP Web server.• Progressive download is supported by most media

players and platforms, including Adobe Flash, Silverlight, and Windows Media Player

• Can also seek to positions in the media file that haven't been downloaded yet

• YouTube, Vimeo, MySpace, and MSN Soapbox, almost use progressive download.

• Downloads all of the media even if player is paused.

Adaptive Streaming• HTTP based file download.• Performs media download as a long series of very

small progressive downloads (Chunks).• Chunks are typically 2-to-4-seconds long as GOP

(Group of Pictures).• Server adapts the quality of its chunks according

to the receiver’s capability in receiving data. (No need to change the bit-rate)

• IIS Smooth is and example of adaptive streaming.• If you pause, only some seconds are buffered.

Request

Chunck of data

Progressive download of small chunks

Adaptive part of the story

Request 420p

Chunck of data

Request 1080p

Request 720p

IIS Smooth Streaming

Microsoft Expression Encoder

Features• Streams MPEG-4 chunks (H.264 video codec).• They are created virtually upon each request.• No buffer.• It is possible to have other encoders.• You can view videos in different platforms instead of

Silverlight.• Simultaneous streaming with different video angles.• Translation scripts and different languages.• Media advertisement.• Multi channeling.• ….

Use Cases• 2008 Summer Olympics in Beijing and NBC

Sunday Night Football

Use Cases• 2010 FIFA World Cup Silverlight Smooth

Streaming Player with Live Messenger

Read more on http://www.iis.net/media/showcase

Deployment• Two methods for deployment:

o On-demando Live

• On-demand:o It is possible on Windows Vista sp1, Windows 7, and Windows Server

2008o Install IIS server 7 or 7.5o Installing IIS Media Services 4.0 on IIS.

Encode Video• Resulting files after encoding with Expression

blend:o *.ismv (Audio + Video)o *.isma (Audio)There will be an encoded file for each bit-rate.

o *.ism “XML based file that describes the relationships between the media tracks, bit rates and files on disk”IIS uses this file

o *.ismc “XML based file that describes the available streams to the client”Clients use this file

Player• Silverlight player:

o There is an open source project called SMF (Silverlight Media Framework) in order to start and test streaming.

• Or anything that supports: VC-1/WMA/H.264/AAC decoding and HTTP transport

Demo• In the next article :D

Player Arguments• MediaUrl: Location of media XML file• DeliveryMethod: “Adaptive”or “Progressive

Download”• AutoPlay: it is true by default • ThumbnailUrl: Thumbnail picture before being

played.

JavaScript Methodsvar Player = null;function onPlayerReady(playerArg) { Player = playerArg; }

//The event handler of Player Load that is useful to access the player’s object.function Play() { Player.Play(); }//Simple way to call player’s Play method.

<input type="button" value="Play" onclick="Play()" />

Other JavaScript Methods

• Player.Pause();• Player.Stop();• Player.Replay();• ….

Q & A

Recommended