Video publication to different mobile devices.

3 downloads 268257 Views 138KB Size Report
be accessed trough Android, Symbian and Iphone mobile devices. KEY WORDS. Mobile devices, Video, Symbian, Android, Iphone, Ubiquity, Interoperability.
Libro Nuevos Medios, Nueva Comunicación

Video publication to different mobile devices. Telmo Silva, Jorge Trinidad Ferraz de Abreu University of Aveiro Aveiro, Portugal Curriculum Vitae Telmo Silva: Activity: Assistant Professor at Department of Communication and Arts in University of Aveiro PhD Student in ICPD (‘Informação e Comunicação em Plataformas Digitais’) Doctoral Program Investigation interests: - Design and development of Interactive TV services, mostly based on IPTV platforms; - Computer networks; - Design and development of applications to mobile devices; - Web applications based on Content Management Systems. Jorge Ferraz de Abreu: Jorge Trinidad Ferraz de Abreu got is graduation and Master degree in Electronic and Telecommunication by the University of Aveiro, Portugal. After his participation in several European projects he joined the Department of Communication and Arts and concluded is PhD in Sciences and Communication Technologies. Currently he teaches in the three levels of courses offered by its department: Undergraduate course, master and PHD program. As a member of the research unit CETAC.MEDIA he develops his research activities in new media, cross-platform content and Interactive Television with particular interest in the development and evaluation of Social iTV applications

ABSTRACT Users’ adoption of sophisticated handheld devices in addition to the increasing of interoperability among platforms has resulted in expansion of video consumption. Despite this, if a regular user wants to set a custom video platform to provide videos to different mobile devices, he must have specific skills to accomplish the task due to specificities of each mobile operating system in terms of supported video codecs, streaming technologies and video players. In this context, this paper presents some technical solutions that allow the implementation of a CMS based video platform that can be accessed trough Android, Symbian and Iphone mobile devices.

KEY WORDS Mobile devices, Video, Symbian, Android, Iphone, Ubiquity, Interoperability

Grupo temático 1: Televisión 3.0, nuevos modelos de negocio en la red.

______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

1

Libro Nuevos Medios, Nueva Comunicación

1. Introduction The sales of mobile phones increases every year as shown by Gartner, Inc. “Worldwide mobile phone sales to end users totaled 314.7 million units in the first quarter of 2010, a 17 per cent increase from the same period in 2009, according to Gartner, Inc. Smarpthone sales to end users reached 54.3 million units, an increase of 48.7 per cent from the first quarter of 2009” (Tudor and Pettey 2010). In addition, Nielsen Company refers in (Company. 2008) that Americans who watch video over the Internet consume 3 hours of online video per month with an increment between those that use mobile devices (almost 4 hours per month). This justifies that mobile devices are today’s hottest electronics items on the market. They are used as handheld gadgets and also as business productivity tools. Consumers demand new features every day: to talk, e-mail, take photos and videos, and pinpoint their geographic location. The number of possibilities to connect to the Internet and to other devices increases the use of video, GPS and other features. In addition, new mobile devices should have some important characteristics: i) be at low cost; ii) consume low power; iii) be easy to operate. Furthermore, operating systems of mobile devices must be flexible enough to accommodate third party applications and promote a favorable environment for developing technology, exchanging ideas and information. In this overall context, the spectrum of operating systems and applications to mobile devices is quite large. In addition, video players are different from device to device which creates important challenges in role of publishing and consuming video content. This document is structured as follows: after this introduction, the main concepts concerning encoders and containers is explained, then the operating systems of mobile devices and their particularities concerning playing video are presented; After that, the processes from capture to publication of video content are described. In section 5 the use of Content Management Systems to publish video content to multiple types of mobile devices is discussed. Finally some final remarks about video publishing to mobile devices are presented.

2. Encoders and Containers The Video codecs and formats are really multifaceted and are normally related with complex mathematical equations. Due to highly disseminated video content, nowadays lots of people heard about them, most of the times without an exact notion of what they represent. When streaming using Apple TV, dump some video onto their phones or just trying to grab last night's episode of “24”, encoding and containers of video are always present. The first encoder used was H.261 and it is the base technology used by most of video standards and codecs ((ITU-T) 1988). MPEG-1 Part 2 (Standardization 2010) is another codec, developed by the Movie Picture Experts Group, based on H.261, and was designed to take VHS quality video to a bit rate of about 1.5Mbps, optimized for CD transfers. MPEG-2 Part 2 (Standardization 2010) was the next standard used and was approved in 1994. It is also known as H.262, and is an extension of MPEG-1 that delivers better resolution and higher bit rates. This codec is used by DVD and digital television, however it is being replaced by the more efficient MPEG-4 (Standardization 2010) (will be discussed later). After it, appeared H.263 that was designed to send video over slow connections. Nowadays it is used to encode Flash videos and to send video over mobile networks.

______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

2

Libro Nuevos Medios, Nueva Comunicación

Finally, MPEG-4 is the mostly used standard. The spectrum of use is much larger than other MPEG standards, because it aims to be used in low and high bandwidth systems. There are two relevant parts of this standard: i) Part 2; and ii) Part 10, which is also known as H.264 or Advanced Video Coding (AVC). Both are more efficient at compression than other MPEG codecs, delivering better quality using less bandwidth. Beside the codecs, it is necessary to consider the files where data is placed (containers). There are not files of type .h264 or .h261 or the like. The videos are packaged in containers that join things like the audio, navigational info, etc. along with the video in a single file. There are about as many file types as there are codecs. For example, a video encoded with H.264, can be found in containers like .mp4 or .avi. Probably, the most used are: i) AVI (Audio Video Interleave) is Windows' standard multimedia container; ii) MPEG-4 Part 14 (known as .mp4) is the standardized container for MPEG-4; iii) FLV (Flash Video) is the format used to deliver MPEG video through Flash Player; iv) MOV is Apple's QuickTime container format; and v) MKV (Mastroska) is an open-specification container. As result, to play a video, the software must be able to handle the video codec and the container. For example, Windows Media Player can handle videos in .wmv container, but it is not able to decode a specific .WMV file that has a video coded in DivX. An iPod is able to decode H.264, but cannot handle a file MKV, so is not possible to view a video in an iPod, coded in H.264 and stored in a MKV file.

3. Mobile Operating Systems and Video Support In addition to size, features, and price, nowadays users consider also operating system as an important factor in mobile device purchase. The spectrum of possibilities is large. Probably the top market players are Palm, Google Android, Blackberry, Symbian, Windows Phone 7 series and the iPhone OS. Some are briefly described below: • Symbian Is an operating system designed by Symbian Ltd that was acquired by Nokia in 2008. Nowadays is an open source operating system and is very popular outside United States. In the world market, Symbian is the most used operating system (Fildes 2010). The Symbian phones can decode and play videos encoded in H264 and stored in 3GP(3GPP 2004) and FLV (Adobe 2008) containers. • Android The Android operating system was developed by Android Corporation that was bought by Google in 2005. Android is powered by a Linux Kernel and is constantly getting changes to fix bugs and add new features. Android OS has lots of new features comparing to other market players, such as multi-touch and support to a great number of media formats. These features make it appealing for consumers and hardware manufacturers. As Symbian phones, Android ones’ can also decode and play videos encoded in H264 and stored in 3GP (3GPP 2004) and FLV containers (Adobe 2008). • iPhone OS The iPhone OS is a mobile version of Mac OSX made by Apple Inc.. A feature that distinguishes iPhone is that all the interaction with the phone can be conducted ______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

3

Libro Nuevos Medios, Nueva Comunicación

through a powerful and extremely well designed touch screen. The operating system came with several applications (Apple proprietary and third party). Apple phones do not support FLV file format which is often used in video publication platforms. There are other important players in market of operating systems to mobile devices such as Windows Phone 7, Blackberry and Palm. These players are important, but they are mainly dedicated to corporate world and because of that they were not considered in this work.

4. From Capture to Publication From the moment when the user decides to make a video until the moment when it is available online, several technical steps are involved, such as capture, video encoding and video publishing. • Capture Video capture starts with a camera that captures an analog signal and then is transformed in a digital signal. The result is a digital video stream that contains the captured digital data. This is a complex process and its explanation is out of scope of this document. Today’s mobile devices are capable of doing the capture process and store video streams in different types of containers. • Encoding After the video capture it must be prepared to be delivered through a particular medium. This process is called ‘encoding‘ and it must be adjusted according with the publishing medium (encoded to DVD player high-quality and high resolution demand - is different from encode to web streaming services such as YouTube. • Video publishing and players adjustment There are multiple examples of video publishing platforms, such as: i) YouTube (the most popular platform (Alexa 2010) allows users to add metadata, embeds links; ii) DailyMotion, which is very similar to YouTube, but allows upload of longer videos; iii) Vimeo, unlike YouTube, the uploaded video must be originals; iv) Kaltura, which is a platform that, besides video upload and publishing, also allows collaborative video editing. In what concerns to mobile devices, most of the video publishing platforms adjusts their site templates to the screens of the mobile devices. Despite this, viewing of video content implies that the device’s player can handle different video containers and encoding formats. In platforms such as Youtube and DailyMotion, uploaded content is encoded according target devices and then played in an embedded player adjusted to the client device. In this scope, in the Android and Symbian devices the content can be played in a Flash player, however this does not applies to Iphones.

5. Video publishing in Content Management Systems CMS is a piece of software that allows the creation of web applications in a very easy way. It is easy to create and maintain web applications because CMS infrastructure divides the design part from the content and thus it is possible to change site appearance and preserve its content. With CMS, authors can edit content and designers can change web application layout without mutual interference. CMS are widely used to professional and commercial sites (for example for company sites), but also to “home-made”, experimental and academic ones. ______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

4

Libro Nuevos Medios, Nueva Comunicación

In this work Joomla CMS (Matters 2010) was used to build an academic web site. Concerning video publishing, there are multiple plug-ins and modules for Joomla that can be used to support video publishing (DentroVideo (Blobject 2010) like hwdVideoShare (Limited 2010) and AllVideos (Joomlawork 2010)). The plug-in hwdVideoShare was used to allow users to: play, rate, comment and upload videos. The video player used by default by hwdVideoShare is Flash based, that is not supported by some of the mobile operating systems.

a. Android and Symbian Android and Symbian cannot execute the default hwdVideoShare player version (FlowPlayer 3.x). So, in order to solve this problem, an older version of FlowPlayer (2.0) was installed in the hwdVideoShare module. To change the player it is necessary to substitute the file “flowplayer-3.0.2.swf” by the older one, but the name of the file should be maintained (flowplayer-3.0.2.swf). Using this older version of the player, the Android and Symbian devices are able to play videos in web application pages (based on Joomla and hwdVideoShare). Also, it is necessary to add to the FlowPlayer folder (“\components\com_hwdvideoshare\core\videoplayer\flow”) the file “flashembed-0.31.min.js” (a component of FlowPlayer 2.x). After this process, it is still necessary to edit the file “view.flowflv.php” of the same folder and change the following code: $code.=' flowplayer("hwdvideo_'.$ui.'", "'.JURI::root().'components/com_hwdvideoshare/core/videoplayer /flow/flowplayer-3.0.2.swf", { type: "video", clip: {url: \''.$flv_url.'\'} }); ';

By: $code.='
flashembed("hwdvideo_'.$ui.'", "'.JURI::root().'components/com_hwdvideoshare/core/videoplayer /flow/flowplayer.swf", {config: {videoFile: \''.$flv_url.'\'} }); ';

______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

5

Libro Nuevos Medios, Nueva Comunicación

Videos were converted automatically by hwdVideoShare, using FFMPEG (Bellard 2010) and the conversion was done using the following configuration (the default configuration of hwdVideoShare): 200Kbits/s with video conferencing quality; 64Kbits/s Default audio quality; 11025Hz of audio sampling rate; Video frame size: 160*128 [4:3];

b. iPhone The solution presented in previous paragraphs is not suitable for iPhone devices because: i) it uses a Flash based player; ii) videos encoded by hwdVideoShare with default parameters of FFMPEG are not supported by iPhone. In order to publish videos to iPhone devices, Joomla platform must be tuned. At first glance, the player used in web pages that publish the videos must be compatible with iPhone, and thus it should be QuickTime based (Apple 2010). The CMS web page where the videos can be seen should be adapted to detect iPhone browser and adjust their behavior. The file “view.flowflv.php” is used to publish the video and thus it must be changed. First, it is necessary to add to folder of FlowPlayer (already referred) the file “AC_QuickTime.js” (Apple 2010) that contains the JavaScript functions used to play videos with QuickTime embedded player in a web page. Also, video files uploaded to hwdVideoShare are converted to a format that is not playable in iPhones, so a server operating system task must be scheduled to do a batch conversion of previously uploaded files. The procedure to schedule a task depends on the server operating system and will not be explained in this document. Moreover, the batch conversion of the files should use FFMEG with the following execution parameters (further details about FFMEG parameters can be found in (Bellard 2010): ffmpeg -i "*.flv" -r 15 -b 128k -s qcif -acodec libfaac -ar 8000 -ac 1 -ab 13 -vcodec mpeg4 -f 3gp -y "*.3gp" With this configuration, FFMEG convert previously uploaded videos in .FLV file format to videos in .3GP file format. The videos are encoded in MPEG4 (Standardization 2010) and stored in 3GP container. Thus, after the files are encoded and stored in the necessary formats, the web page that publishes the videos (view.flowflv.php) should be adapted. The following code must be added: if(ereg("iphone", $br)) { $dir = substr(strrchr($flv_path, "/"), 1); $name = stripos($dir,".flv"); $flv_file_name = substr($dir,0,$name); $code.='

______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

6

Libro Nuevos Medios, Nueva Comunicación

QT_WriteOBJECT(\''.JURI::root().'hwdvideos/uploads/'.$flv_f ile_name.'.3gp\', \'Width\',\'Height+16\', \'\', \'autoplay\', \'true\'); '; return $code; }

In this piece of code, the page gets the type of client browser from the request and if it is iPhone, the page will get the name of the video file to show (.flv_file_name) (also from the request), and uses that value and JavaScript functions from AC_QuickTime.js to create the player suitable for iPhone browser. These developments can be tested at the URL: medeca.clients.ua.pt/pdepd0910/teste.

6. Final remarks Nowadays, CMS are important players in what concerns web sites development, since they allow a short time to market being easy to maintain and update. Most of them are also free of charge. Despite this, free components of video publishing, like hwdVideoShare, are not prepared (out-of-the-box) to send video content to most of newest mobile devices. This is an important limitation of web sites based on CMS. The work presented in this document proposes an easy way to solve this issue and enhance the Joomla CMS capabilities.

7. References 3GPP, E. (2004). "3GPP TS 26.244; Transparent end-to-end packet switched streaming service (PSS); 3GPP file format (3GP)." Retrieved 2010. (ITU-T), I. T. U.-T. S. S. (1988). Recommendation H.261- Codec For Audiovisual Services At n×384 kbit/s. Adobe (2008). Video File Format Specification Version 9. Alexa (2010). "Free traffic metrics, search analytics, demographics, and more for websites...". Retrieved September, 2010, from www.alexa.com. Apple (2010). "Instructions for Updating Websites to Include QuickTime Content." Retrieved July, 2010, from http://developer.apple.com/internet/ieembedprep.html. Apple (2010). "What is QuickTime." http://www.apple.com/quicktime/what-is/.

Retrieved

July,

2010,

from

Bellard, F. (2010). "FFmpeg ". Retrieved July, 2010, from http://www.ffmpeg.org. Blobject (2010). "DentroVideo." Retrieved July, 2010, from http://www.dentrovideo.com. Company., N. (2008) A2/M2 Three Screen Report. Fildes, J. (2010). "Symbian phone operating system goes open source." Retrieved July, 2010, from http://news.bbc.co.uk/2/hi/technology/8496263.stm. Joomlawork (2010). "AllVideos (plugin): True all-in-one media management solution for Joomla! ." Retrieved July, 2010, from http://www.joomlaworks.gr/content/view/16/42/.

______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]

7

Libro Nuevos Medios, Nueva Comunicación

Limited, H. D. (2010). "hwdMediaShare! Share media on your Joomla website ". from http://hwdmediashare.co.uk/. Matters, O. S. (2010). "Joomla!". Retrieved July, 2010. Standardization, I. O. f. (2010). "ISO (International Organization for Standardization) ". Retrieved 2010. Tudor, B. and C. Pettey (2010) Worldwide Mobile Phone Sales Grew 17 Per Cent in First Quarter 2010.

8

______________________________________________________________________________ www.comunicacion3punto0.com |[email protected]