<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>mobile device &#8211; stoimen&#039;s web log</title>
	<atom:link href="/tag/mobile-device/feed/" rel="self" type="application/rss+xml" />
	<link></link>
	<description>on web development</description>
	<lastBuildDate>Tue, 13 Feb 2018 08:18:15 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.0.3</generator>
	<item>
		<title>Computer Algorithms: Data Compression with Prefix Encoding</title>
		<link>/2012/02/06/computer-algorithms-data-compression-with-prefix-encoding/</link>
		<comments>/2012/02/06/computer-algorithms-data-compression-with-prefix-encoding/#respond</comments>
		<pubDate>Mon, 06 Feb 2012 20:50:58 +0000</pubDate>
		<dc:creator><![CDATA[Stoimen]]></dc:creator>
				<category><![CDATA[algorithms]]></category>
		<category><![CDATA[Apple Inc.]]></category>
		<category><![CDATA[Computer science]]></category>
		<category><![CDATA[Computing]]></category>
		<category><![CDATA[Data compression]]></category>
		<category><![CDATA[Decoder]]></category>
		<category><![CDATA[Delta encoding]]></category>
		<category><![CDATA[Dictionary coder]]></category>
		<category><![CDATA[Google Inc.]]></category>
		<category><![CDATA[Johnson Clarkson Jackson]]></category>
		<category><![CDATA[Mathematics]]></category>
		<category><![CDATA[mobile device]]></category>
		<category><![CDATA[same algorithm]]></category>
		<category><![CDATA[Technology/Internet]]></category>
		<category><![CDATA[Trie]]></category>
		<category><![CDATA[United Kingdom]]></category>
		<category><![CDATA[Yahoo! Inc.]]></category>

		<guid isPermaLink="false">/?p=2699</guid>
		<description><![CDATA[Overview Prefix encoding, sometimes called front encoding, is yet another algorithm that tries to remove duplicated data in order to reduce its size. Its principles are simple, however this algorithm tend to be difficult to implement. To understand why, first let’s take a look of its nature. Please, have a look on the following dictionary. &#8230; <a href="/2012/02/06/computer-algorithms-data-compression-with-prefix-encoding/" class="more-link">Continue reading <span class="screen-reader-text">Computer Algorithms: Data Compression with Prefix Encoding</span> <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href="/2012/01/30/computer-algorithms-data-compression-with-relative-encoding/" rel="bookmark" title="Computer Algorithms: Data Compression with Relative Encoding">Computer Algorithms: Data Compression with Relative Encoding </a></li>
<li><a href="/2012/01/09/computer-algorithms-data-compression-with-run-length-encoding/" rel="bookmark" title="Computer Algorithms: Data Compression with Run-length Encoding">Computer Algorithms: Data Compression with Run-length Encoding </a></li>
<li><a href="/2012/01/23/computer-algorithms-data-compression-with-diagram-encoding-and-pattern-substitution/" rel="bookmark" title="Computer Algorithms: Data Compression with Diagram Encoding and Pattern Substitution">Computer Algorithms: Data Compression with Diagram Encoding and Pattern Substitution </a></li>
<li><a href="/2012/01/16/computer-algorithms-data-compression-with-bitmaps/" rel="bookmark" title="Computer Algorithms: Data Compression with Bitmaps">Computer Algorithms: Data Compression with Bitmaps </a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<h2>Overview</h2>
<p>Prefix encoding, sometimes called front encoding, is yet another algorithm that tries to remove duplicated data in order to reduce its size. Its principles are simple, however this algorithm tend to be difficult to implement. To understand why, first let’s take a look of its nature.</p>
<p>Please, have a look on the following dictionary.</p>
<pre lang="PHP">
use
used
useful
usefully
usefulness
useless
uselessly
uselessness
</pre>
<p>Instead of keeping all these words in plain text or transferring all them over a network, we can compress (encode) them with prefix encoding. </p>
<p><figure id="attachment_2700" style="width: 299px" class="wp-caption alignnone"><a href="/wp-content/uploads/2012/02/Prefixencoding.png"><img src="/wp-content/uploads/2012/02/Prefixencoding.png" alt="Prefix Encoding" title="Prefix encoding" width="299" height="457" class="size-full wp-image-2700" srcset="/wp-content/uploads/2012/02/Prefixencoding.png 299w, /wp-content/uploads/2012/02/Prefixencoding-196x300.png 196w" sizes="(max-width: 299px) 100vw, 299px" /></a><figcaption class="wp-caption-text"> </figcaption></figure><br />
<span id="more-2699"></span><br />
It’s clear that each of these words begin with the prefix “use” which is also the first word from the list. So we can easily compress them into the following array.</p>
<pre lang="PHP">
$data = array(
0 => 'use',
1 => '0d',
2 => '0ful',
3 => '0fully',
4 => '0less',
5 => '0lessly',
6 => '0lessness',
);
</pre>
<p>It’s clear that this is not the best compression and we can go even further by using not only the first word as prefix.</p>
<pre lang="PHP">
$data = array(
0 => 'use',
1 => '0d',
2 => '0ful',
3 => '2ly',
4 => '0less',
5 => '4ly',
6 => '4ness',
);
</pre>
<p>Now the compression is better and the good news is that decompression is a fairly simple process. However the tricky part is compression itself. The problem is that it is quite difficult to chose an appropriate prefix. In our first example this is simple, but most of the times in practice we can have more heterogeneous data. Indeed the process of compression can be very difficult for randomly generated data and the algorithm will be not only slow, but difficult to implement.</p>
<p>The good thing is that this algorithm can be used in many cases once we know the data format in advance. So let’s see three examples where this algorithm can be very handy.</p>
<h2>Application</h2>
<p>Here are three examples of prefix encoding. As I said above the process of compression can be very difficult for random data, so it is a good practice to use only it if you know in advance the format of the input data.</p>
<h3>Date and time prefixes</h3>
<p>We humans often skip the first two digits of an year, so for instance we don’t always write 1995 or 1996, but we use the shorter &#8211; ‘95 and ‘96. Thus years can be encoded with shorter strings.</p>
<pre lang="PHP">
input: 	(1991, 1992, 1993, 1994, 1995, 1996)
output:	(91, 92, 93, 94, 95, 96)
</pre>
<p>The problem is that with small changes of the input stream we can confuse the decoder. Thus if we add years from the 21st century we lose the uniqueness of the data.</p>
<pre lang="PHP">
input:	(1998, 1992, 1999, 2011, 2012)
output: (98, 92, 99, 11, 12)
</pre>
<p>Now the decoder can decode the last two values as (1911, 1912) as “19” is considered to be the prefix. So we must know in advance that our prefix is absolutely equal for each of the values. If not the encoding format must be different. For instance we can encode also the prefix, with some special maker.</p>
<pre lang="PHP">
input:	(1998, 1992, 1932, 1924, 2001, 2012)
output:	(#19, 98, 92, 32, 24, #20, 01, 12)
</pre>
<p>Once the decoder reads the # character it will know to decode the following number as prefix.</p>
<p>This can be used in practice for date and time formats. Let’s say we have some datetime values, but we know that all of them are in the same day.</p>
<pre lang="PHP">
2012-01-31 15:33:45
2012-01-31 16:12:11
2012-01-31 17:32:35
2012-01-31 18:54:34
</pre>
<p>Obviously we can omit the date part of these strings and send (keep) only the time. Once again, we must be absolutely sure that all these values are in the same day. If not, we can use the encoding strategy of the previous example.</p>
<h3>Phone numbers</h3>
<p>Phone numbers are the typical case of prefix encoding. Not only the international code, but also the mobile network operators use prefixes for their phone numbers. Thus if we have to transfer phone numbers from, let’s say the <strong>UK</strong>, we can replace the leading <strong>“+44”</strong> with something shorter. </p>
<p>If you happen to code a phone book for a mobile device you can spend some space by compressing the data using prefix encoding and thus the user will have more space and will store more phone numbers on his mobile.</p>
<p>Phone number prefixes can be also used for database normalization. Thus you can store them in a separate db table and leave only the unique numbers from the phonebook.</p>
<h3>Geo Coordinates</h3>
<p>Using the same example from <a href="/2012/01/30/computer-algorithms-data-compression-with-relative-encoding/" title="Computer Algorithms: Data Compression with Relative Encoding">my previous post</a> we can send GEO coordinates by removing a common prefix, for large levels of zoom. Indeed when you’ve to send lots of markers to your map application you can expect all of these markers to be fairly close to each other in large zoom level.</p>
<figure id="attachment_2701" style="width: 620px" class="wp-caption alignnone"><a href="/wp-content/uploads/2012/02/NY-map.png"><img src="/wp-content/uploads/2012/02/NY-map.png" alt="NY Subway Map" title="NY Subway Map" width="620" class="size-full wp-image-2701" srcset="/wp-content/uploads/2012/02/NY-map.png 843w, /wp-content/uploads/2012/02/NY-map-300x199.png 300w" sizes="(max-width: 843px) 100vw, 843px" /></a><figcaption class="wp-caption-text">On large zoom levels we can expect markers to be with the same prefix.</figcaption></figure>
<p>Now the coordinates of those points can have a common prefix, like the example bellow with the Subway stations.</p>
<pre lang="PHP">
LatLon(40.762959,-73.985989)
LatLon(40.761886,-73.983629)
LatLon(40.762861,-73.981612)
LatLon(40.764616,-73.98056)
</pre>
<p>We can see that all of these GEO points have the same prefix (40.76x, -73.98x), so we can send the prefix only once.</p>
<pre lang="PHP">
Prefix: (40.76, -73.98)
Data: 
LatLon(2959,5989)
LatLon(1886,3629)
LatLon(2861,1612)
LatLon(4616,056)
</pre>
<p>These are only three examples of prefix encoding and this algorithm must be considered as very useful when transferring homogeneous data. </p>
<h2>Suffix Encoding</h2>
<p>Suffix encoding practically the same algorithm as prefix encoding, with the small difference that we use to encode duplicating suffixes. Like the examples bellow suffix encoding can be useful is replacing repeating last name suffixes.</p>
<pre lang="PHP">
Johnson
Clarkson
Jackson
</pre>
<p>Or company names.</p>
<pre lang="PHP">
Apple Inc.
Google Inc.
Yahoo! Inc.
</pre>
<p>Here we can replace “ Inc.” with something else, but shorter.</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href="/2012/01/30/computer-algorithms-data-compression-with-relative-encoding/" rel="bookmark" title="Computer Algorithms: Data Compression with Relative Encoding">Computer Algorithms: Data Compression with Relative Encoding </a></li>
<li><a href="/2012/01/09/computer-algorithms-data-compression-with-run-length-encoding/" rel="bookmark" title="Computer Algorithms: Data Compression with Run-length Encoding">Computer Algorithms: Data Compression with Run-length Encoding </a></li>
<li><a href="/2012/01/23/computer-algorithms-data-compression-with-diagram-encoding-and-pattern-substitution/" rel="bookmark" title="Computer Algorithms: Data Compression with Diagram Encoding and Pattern Substitution">Computer Algorithms: Data Compression with Diagram Encoding and Pattern Substitution </a></li>
<li><a href="/2012/01/16/computer-algorithms-data-compression-with-bitmaps/" rel="bookmark" title="Computer Algorithms: Data Compression with Bitmaps">Computer Algorithms: Data Compression with Bitmaps </a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>/2012/02/06/computer-algorithms-data-compression-with-prefix-encoding/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Reading GPS Latitude and Longitude from Image and Video Files</title>
		<link>/2011/02/04/reading-gps-latitude-and-longitude-from-image-and-video-files/</link>
		<comments>/2011/02/04/reading-gps-latitude-and-longitude-from-image-and-video-files/#comments</comments>
		<pubDate>Fri, 04 Feb 2011 10:16:14 +0000</pubDate>
		<dc:creator><![CDATA[Stoimen]]></dc:creator>
				<category><![CDATA[micro tutorial]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[Apple Inc.]]></category>
		<category><![CDATA[Application software]]></category>
		<category><![CDATA[Computing]]></category>
		<category><![CDATA[Container formats]]></category>
		<category><![CDATA[Digital photography]]></category>
		<category><![CDATA[Exchangeable image file format]]></category>
		<category><![CDATA[ExifTool]]></category>
		<category><![CDATA[Geotagging]]></category>
		<category><![CDATA[GPS]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[jpeg]]></category>
		<category><![CDATA[Metadata]]></category>
		<category><![CDATA[mobile device]]></category>
		<category><![CDATA[Mobile Devices]]></category>
		<category><![CDATA[MPEG-4]]></category>
		<category><![CDATA[navigation software]]></category>
		<category><![CDATA[Nokia E71 Smartphone]]></category>
		<category><![CDATA[QuickTime]]></category>
		<category><![CDATA[Resolution Unit]]></category>
		<category><![CDATA[Smartphones]]></category>
		<category><![CDATA[Symbian]]></category>
		<category><![CDATA[Technology/Internet]]></category>
		<category><![CDATA[web platform]]></category>

		<guid isPermaLink="false">/?p=2153</guid>
		<description><![CDATA[The State of GPS Data from Mobile Devices Most of the mobile devices today support GPS geo tagging. In fact most of them come bundled with navigation software that uses GPS and therefore all the pictures and (maybe) videos can be geo tagged. But as expected different vendors come with different support and formats. iPhone &#8230; <a href="/2011/02/04/reading-gps-latitude-and-longitude-from-image-and-video-files/" class="more-link">Continue reading <span class="screen-reader-text">Reading GPS Latitude and Longitude from Image and Video Files</span> <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href="/2011/01/27/few-thoughts-on-web-video/" rel="bookmark" title="Few Thoughts on Web Video">Few Thoughts on Web Video </a></li>
<li><a href="/2010/03/05/video-sites-must-use-mp4-and-only-mp4/" rel="bookmark" title="Video sites must use &#8230; mp4 and only mp4!">Video sites must use &#8230; mp4 and only mp4! </a></li>
<li><a href="/2010/05/25/download-files-with-zend-framework/" rel="bookmark" title="Download Files with Zend Framework">Download Files with Zend Framework </a></li>
<li><a href="/2010/05/21/check-youtube-video-existence-with-zend_gdata_youtube/" rel="bookmark" title="Check YouTube Video Existence with Zend_Gdata_YouTube">Check YouTube Video Existence with Zend_Gdata_YouTube </a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<h2>The State of GPS Data from Mobile Devices</h2>
<p>Most of the mobile devices today support GPS geo tagging. In fact most of them come bundled with navigation software that uses GPS and therefore all the pictures and (maybe) videos can be geo tagged. But as expected different vendors come with different support and formats.<br />
<br clear="all" /><a href="/wp-content/uploads/2011/02/iphone.png"><img class="alignleft size-full wp-image-2162" title="iphone" src="/wp-content/uploads/2011/02/iphone.png" alt="" width="120" height="78" /></a><br />
<br clear="all" /></p>
<p><a title="iPhone OS" href="http://en.wikipedia.org/wiki/IOS_%28Apple%29" target="_blank">iPhone OS</a> comes with geotagging both on video and image files, while the latest <a title="Android" href="http://www.android.com/" target="_blank">Android</a> and <a title="Symbian" href="http://blog.symbian.org/" target="_blank">Symbian</a> (the Nokia main OS for smartphones) can geo tag only images.</p>
<p>Even more &#8211; until recently Symbian didn&#8217;t support any geotagging before the installation of an additional software &#8211; such as <a title="Location Tagger" href="http://betalabs.nokia.com/apps/location-tagger" target="_blank">Location Tagger</a> . So generally the things are quite simple:</p>
<ol>
<li>iPhone OS geotags both video and image files;</li>
<li>Android geotags only images;</li>
<li>Symbian geotags only images &#8211; and on some devices this is possible only after installing a software;</li>
</ol>
<p>This is in breve the state of mobile device geotagging!<span id="more-2153"></span></p>
<h2>Why Use GPS Data?</h2>
<p>Perhaps one of the main reasons why not support geotagging especially on video files can be the usage of those geo tags. First of all what a geotag means?<br />
<br clear="all" /><br />
<a href="/wp-content/uploads/2011/02/android.png"><img class="alignleft size-full wp-image-2165" title="android" src="/wp-content/uploads/2011/02/android.png" alt="Android Logo" width="150" height="150" /></a><br />
<br clear="all" /><br />
You may know that even Android doesn&#8217;t &#8220;geotag&#8221; videos this is not quite true. Because after using you gallery you can see where those videos are shot. This is fantastic, but actually the real information about where the video has been taken is not into the video file, but it&#8217;s in an additional log file that keeps it. Thus actually the video files doesn&#8217;t know the geo coordinates.</p>
<p>Here comes the problem with video format, because you cannot be sure that every format supports tags that can keep geo coordinates. Actually quicktime&#8217;s MOV can store them, while Symbian&#8217;s 3GP cannot. In fact Symbian cannot store any geo information about video files!</p>
<p>So now we&#8217;ve at least three different formats for each of those three vendors.</p>
<ol>
<li>quicktime for iPhone</li>
<li>mpeg-4 with Android</li>
<li>3gp with Symbian</li>
</ol>
<p>For now I can only say that iPhone can keep the geotag into his video files.<br />
<br clear="all" /><br />
<a href="/wp-content/uploads/2011/02/symbian.png"><img class="alignleft size-full wp-image-2164" title="symbian" src="/wp-content/uploads/2011/02/symbian.png" alt="Symbian Logo" width="200" height="55" /></a><br />
<br clear="all" /><br />
But let me return to the question &#8211; why we need this geo tags? Until the video file is on the mobile device &#8211; there&#8217;s no problem. But once you try to download it &#8211; whether on <a title="Flickr" href="http://www.flickr.com/" target="_blank">Flickr</a>, <a title="YouTube" href="http://youtube.com/" target="_blank">YouTube</a>, <a title="Picasa Web Albums" href="https://picasaweb.google.com/" target="_blank">Picasa</a>, etc. you&#8217;ll lose any geo information if it&#8217;s not into the file tags. And of course if the above sites can&#8217;t read it!</p>
<p>The general reason to store this data into the file is to move it along with the file. Once you move this file from your mobile device to a web platform you&#8217;ll see where the file has been created.</p>
<h2>EXIF, Exiftool and PHP&#8217;s exif_read_data</h2>
<p>There are several tools to read geotags. For images, and here we talk only for JPEGs, this is the <a title="EXIF" href="http://www.exif.org/" target="_blank">EXIF</a> information. You can download the exif command line program and try to reed data with it:</p>
<pre lang="bash">
exif filename.jpg
</pre>
<p>Which can result in something like that:</p>
<pre lang="bash">
Manufacturer        |Nokia                                                     
Model               |E71                                                       
Orientation         |top - left                                                
x-Resolution        |300.00                                                    
y-Resolution        |300.00                                                    
Resolution Unit     |Inch                                                      
YCbCr Positioning   |centered                                                  
Compression         |JPEG compression                                          
x-Resolution        |72.00                                                     
y-Resolution        |72.00                                                     
Resolution Unit     |Inch                                                      
FNumber             |f/3.2                                                     
Exif Version        |Exif Version 2.2                                          
Date and Time (origi|2011:01:24 12:15:01                                       
Date and Time (digit|2011:01:24 12:15:01                                       
ComponentsConfigurat|Y Cb Cr -                                                 
Aperture            |3.20 EV (f/3.0)                                           
Light Source        |0                                                         
Flash               |Flash did not fire, auto mode.                            
Focal Length        |4.9 mm                                                    
FlashPixVersion     |FlashPix Version 1.0                                      
Color Space         |sRGB                                                      
PixelXDimension     |2048                                                      
PixelYDimension     |1536                                                      
Custom Rendered     |Normal process                                            
Exposure Mode       |Auto exposure                                             
White Balance       |Auto white balance                                        
Digital Zoom Ratio  |1.00                                                      
Scene Capture Type  |Standard                                                  
GPS tag version     |0x02, 0x02, 0x00, 0x00                                    
North or South Latit|N                                                         
Latitude            |42.00, 39.00, 24.67                                       
East or West Longitu|E                                                         
Longitude           |23.00, 21.00, 28.45                                       
Altitude reference  |0x00                                                      
Altitude            |625.50 
</pre>
<p>While for video files (iPhone) exif cannot help you, this is possible through <a title="Exiftool" href="http://www.sno.phy.queensu.ca/~phil/exiftool/" target="_blank">Exiftool</a>. With it you can read even iPhone video geotags:</p>
<pre lang="bash">
./exiftool filname.mov
</pre>
<p>In addition this information can be read with PHP via <a title="read_exif_data" href="http://php.net/manual/en/function.read-exif-data.php" target="_blank">exif_read_data</a>:</p>
<pre lang="php">
$info = exif_read_data('filename.jpg');
var_dump($info);
</pre>
<p>And this will give you not only standard tags, but geo tags too.</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href="/2011/01/27/few-thoughts-on-web-video/" rel="bookmark" title="Few Thoughts on Web Video">Few Thoughts on Web Video </a></li>
<li><a href="/2010/03/05/video-sites-must-use-mp4-and-only-mp4/" rel="bookmark" title="Video sites must use &#8230; mp4 and only mp4!">Video sites must use &#8230; mp4 and only mp4! </a></li>
<li><a href="/2010/05/25/download-files-with-zend-framework/" rel="bookmark" title="Download Files with Zend Framework">Download Files with Zend Framework </a></li>
<li><a href="/2010/05/21/check-youtube-video-existence-with-zend_gdata_youtube/" rel="bookmark" title="Check YouTube Video Existence with Zend_Gdata_YouTube">Check YouTube Video Existence with Zend_Gdata_YouTube </a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>/2011/02/04/reading-gps-latitude-and-longitude-from-image-and-video-files/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>How to Make MP4 Progressive with qt-faststart</title>
		<link>/2010/11/12/how-to-make-mp4-progressive-with-qt-faststart/</link>
		<comments>/2010/11/12/how-to-make-mp4-progressive-with-qt-faststart/#comments</comments>
		<pubDate>Fri, 12 Nov 2010 11:11:31 +0000</pubDate>
		<dc:creator><![CDATA[Stoimen]]></dc:creator>
				<category><![CDATA[web development]]></category>
		<category><![CDATA[Application software]]></category>
		<category><![CDATA[author]]></category>
		<category><![CDATA[Computing]]></category>
		<category><![CDATA[Cross-platform software]]></category>
		<category><![CDATA[Daniel G. Taylor]]></category>
		<category><![CDATA[FFmpeg]]></category>
		<category><![CDATA[Flash Video]]></category>
		<category><![CDATA[Free software]]></category>
		<category><![CDATA[main software]]></category>
		<category><![CDATA[MEncoder]]></category>
		<category><![CDATA[mobile device]]></category>
		<category><![CDATA[NDs-mPeG]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Qt]]></category>
		<category><![CDATA[qt-faststart]]></category>
		<category><![CDATA[qtfaststart.py]]></category>
		<category><![CDATA[reasonable solution]]></category>
		<category><![CDATA[Technology/Internet]]></category>
		<category><![CDATA[VLC media player]]></category>

		<guid isPermaLink="false">/?p=2027</guid>
		<description><![CDATA[A big part of the developers worldwide, who have dealt with video converting, sooner or later have been used FFMPEG. In fact I&#8217;d say that two of the main software on the video converting scene are FFMPEG and Mencoder. I began to use Mencoder back in 2005 and I used it as a DVD ripping &#8230; <a href="/2010/11/12/how-to-make-mp4-progressive-with-qt-faststart/" class="more-link">Continue reading <span class="screen-reader-text">How to Make MP4 Progressive with qt-faststart</span> <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href="/2010/03/05/video-sites-must-use-mp4-and-only-mp4/" rel="bookmark" title="Video sites must use &#8230; mp4 and only mp4!">Video sites must use &#8230; mp4 and only mp4! </a></li>
<li><a href="/2011/01/27/few-thoughts-on-web-video/" rel="bookmark" title="Few Thoughts on Web Video">Few Thoughts on Web Video </a></li>
<li><a href="/2010/02/26/html5-video-support-detecting-playing-and-progressive-enhancement/" rel="bookmark" title="HTML5 video support. Detecting, playing and progressive enhancement!">HTML5 video support. Detecting, playing and progressive enhancement! </a></li>
<li><a href="/2010/10/26/ffmpeg-libx264-and-presets/" rel="bookmark" title="ffmpeg, libx264 and presets">ffmpeg, libx264 and presets </a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p>A big part of the developers worldwide, who have dealt with video converting, sooner or later have been used FFMPEG. In fact I&#8217;d say that two of the main software on the video converting scene are <a title="FFMPEG" href="http://www.ffmpeg.org/" target="_blank">FFMPEG</a> and <a title="Mencoder" href="http://www.mplayerhq.hu/DOCS/HTML/en/mencoder.html" target="_blank">Mencoder</a>. I began to use Mencoder back in 2005 and I used it as a DVD ripping tool, but my experience with it ends there, while now I use FFMPEG.</p>
<p>However FFMPEG is a converting program and many things depend on what kind of video files come as an input and what do you want to achieve as an output. Here comes the codec question, where various libraries can help. In my case, as I <a href="/2010/10/26/ffmpeg-libx264-and-presets/" target="_blank">wrote</a> few posts ago, I use MP4 as output encoded with h.264, both encoded with ffmpeg/libx264. So far so good, but there is one main problem that anyone used this pair knows.</p>
<h2>Flash Player and MP4</h2>
<p>As far as I know <a title="Flash Player" href="http://get.adobe.com/flashplayer/" target="_blank">Flash Player</a> 9 and beyond plays video files encoded with MP4/h.264 except the typical FLV (flash video files). This can help video sites not only to share their video content via web &#8211; within browser based flash players, but also to show them via some mobile device interface where MP4/h.264 is perhaps the only one reasonable solution. In this case the file is accessible in both medias.</p>
<p>By default Flash Player can play such FFMPEG encoded .mp4 files, but fist the whole file must be downloaded by the browser and only than the playback can begin. That&#8217;s because the FFMPEG puts meta info at the end of the video file, while the flash player needs it at the beginning and only than to begin playing while the file is still downloading.</p>
<h2>qt-faststart</h2>
<p>As the name of this <a title="qt-faststart" href="http://multimedia.cx/eggs/improving-qt-faststart/" target="_blank">software</a> says this program helps you move the important meta info from the end to the beginning of the file. This helps the video to playback as early as possible. In an ideal circumstances everything works just fine, but there is a serious problem in fact.</p>
<h2>qt-faststart and Server Crash</h2>
<p><a title="qt-faststart" href="http://multimedia.cx/eggs/improving-qt-faststart/" target="_blank">qt-faststart</a> is responsible to move the meta info where it must be &#8211; at the beginning of the video file, but cannot finish execution when the video file is broken or the meta info doesn&#8217;t exists. Actually this is not a problem of qt-faststart, but to the video file. However this was a critical problem in my case, because the video files remains stuck for hours of execution and 99% of CPU usage.</p>
<p>Thankfully there is a solution and it can be found in the qt-faststart wrapper &#8211; <a title="qtfaststart.py" href="https://github.com/danielgtaylor/qtfaststart" target="_blank">qtfaststart.py</a></p>
<h2>qtfaststart.py</h2>
<p>written on Python this script overcomes the disadvantages of qt-faststart. As described by his author Daniel G. Taylor:</p>
<ol>
<blockquote>
<li>Works everywhere Python can be installed</li>
<li>Handles both 32-bit (stco) and 64-bit (co64) atoms</li>
<li>Handles any file where the mdat atom is before the moov atom</li>
<li>Preserves the order of other atoms</li>
<li>Can replace the original file (if given no output file)</li>
</blockquote>
</ol>
<p>With its help not only qt-faststart doesn&#8217;t crash, but also the video files remain progressive as desired. The installation process is as difficult as copy/paste on the server where Python must be installed.</p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href="/2010/03/05/video-sites-must-use-mp4-and-only-mp4/" rel="bookmark" title="Video sites must use &#8230; mp4 and only mp4!">Video sites must use &#8230; mp4 and only mp4! </a></li>
<li><a href="/2011/01/27/few-thoughts-on-web-video/" rel="bookmark" title="Few Thoughts on Web Video">Few Thoughts on Web Video </a></li>
<li><a href="/2010/02/26/html5-video-support-detecting-playing-and-progressive-enhancement/" rel="bookmark" title="HTML5 video support. Detecting, playing and progressive enhancement!">HTML5 video support. Detecting, playing and progressive enhancement! </a></li>
<li><a href="/2010/10/26/ffmpeg-libx264-and-presets/" rel="bookmark" title="ffmpeg, libx264 and presets">ffmpeg, libx264 and presets </a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>/2010/11/12/how-to-make-mp4-progressive-with-qt-faststart/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>PHP: Mobile Devices HTTP_USER_AGENT Strings</title>
		<link>/2010/03/22/php-mobile-devices-http_user_agent-strings/</link>
		<comments>/2010/03/22/php-mobile-devices-http_user_agent-strings/#comments</comments>
		<pubDate>Mon, 22 Mar 2010 20:04:07 +0000</pubDate>
		<dc:creator><![CDATA[Stoimen]]></dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[web development]]></category>
		<category><![CDATA[.mobi]]></category>
		<category><![CDATA[Clients]]></category>
		<category><![CDATA[Computing]]></category>
		<category><![CDATA[http]]></category>
		<category><![CDATA[Mobile browser]]></category>
		<category><![CDATA[mobile device]]></category>
		<category><![CDATA[Mobile software]]></category>
		<category><![CDATA[Technology/Internet]]></category>
		<category><![CDATA[User agent]]></category>
		<category><![CDATA[web browsers]]></category>

		<guid isPermaLink="false">/?p=1376</guid>
		<description><![CDATA[So You&#8217;re Going Mobile It&#8217;s nice that at least you&#8217;re moving your site to mobile device. It&#8217;s really important. Now if you&#8217;re using PHP the question is how to detect the mobile browser. HTTP_USER_AGENT Every PHP developer knows that $_SERVER[&#8216;HTTP_USER_AGENT&#8217;] string optionally contain the browser that access your site, but what are the possible values &#8230; <a href="/2010/03/22/php-mobile-devices-http_user_agent-strings/" class="more-link">Continue reading <span class="screen-reader-text">PHP: Mobile Devices HTTP_USER_AGENT Strings</span> <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href="/2010/03/09/php-detecting-mobile-device/" rel="bookmark" title="PHP: detecting mobile device">PHP: detecting mobile device </a></li>
<li><a href="/2010/03/18/mobile-internet-users-are-getting-more-important/" rel="bookmark" title="Mobile Internet Users are Getting More Important">Mobile Internet Users are Getting More Important </a></li>
<li><a href="/2011/07/29/php-strings-how-to-get-the-extension-of-a-file/" rel="bookmark" title="PHP Strings: How to Get the Extension of a File">PHP Strings: How to Get the Extension of a File </a></li>
<li><a href="/2012/04/26/php-strings-dont-need-quotes/" rel="bookmark" title="PHP Strings Don&#8217;t Need Quotes">PHP Strings Don&#8217;t Need Quotes </a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<h2>So You&#8217;re Going Mobile</h2>
<p>It&#8217;s nice that at least you&#8217;re moving your site to mobile device. It&#8217;s really important. Now if you&#8217;re using PHP the question is how to detect the mobile browser.</p>
<h2>HTTP_USER_AGENT</h2>
<p>Every PHP developer knows that <strong>$_SERVER[&#8216;HTTP_USER_AGENT&#8217;]</strong> string optionally contain the browser that access your site, but what are the possible values of this string?</p>
<h2>The Answer is &#8230;</h2>
<p>in that really really full list of user agent strings: <a href="http://www.zytrax.com/tech/web/mobile_ids.html" target="_blank">http://www.zytrax.com/tech/web/mobile_ids.html</a></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href="/2010/03/09/php-detecting-mobile-device/" rel="bookmark" title="PHP: detecting mobile device">PHP: detecting mobile device </a></li>
<li><a href="/2010/03/18/mobile-internet-users-are-getting-more-important/" rel="bookmark" title="Mobile Internet Users are Getting More Important">Mobile Internet Users are Getting More Important </a></li>
<li><a href="/2011/07/29/php-strings-how-to-get-the-extension-of-a-file/" rel="bookmark" title="PHP Strings: How to Get the Extension of a File">PHP Strings: How to Get the Extension of a File </a></li>
<li><a href="/2012/04/26/php-strings-dont-need-quotes/" rel="bookmark" title="PHP Strings Don&#8217;t Need Quotes">PHP Strings Don&#8217;t Need Quotes </a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>/2010/03/22/php-mobile-devices-http_user_agent-strings/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Mobile Internet Users are Getting More Important</title>
		<link>/2010/03/18/mobile-internet-users-are-getting-more-important/</link>
		<comments>/2010/03/18/mobile-internet-users-are-getting-more-important/#comments</comments>
		<pubDate>Thu, 18 Mar 2010 08:17:29 +0000</pubDate>
		<dc:creator><![CDATA[Stoimen]]></dc:creator>
				<category><![CDATA[web development]]></category>
		<category><![CDATA[.mobi]]></category>
		<category><![CDATA[Internet]]></category>
		<category><![CDATA[Internet Mobile It]]></category>
		<category><![CDATA[Mobile advertising]]></category>
		<category><![CDATA[mobile device]]></category>
		<category><![CDATA[Mobile Internet]]></category>
		<category><![CDATA[Mobile phone]]></category>
		<category><![CDATA[mobile phones]]></category>
		<category><![CDATA[Mobile telecommunications]]></category>
		<category><![CDATA[Mobile Web]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Technology/Internet]]></category>
		<category><![CDATA[Windows Mobile]]></category>
		<category><![CDATA[Wireless]]></category>

		<guid isPermaLink="false">/?p=1354</guid>
		<description><![CDATA[Internet Mobile It isn&#8217;t strange that the internet is becoming more and more mobile. When it matters to news sites I think most of the mobile versions are better than the &#8220;desktop&#8221; versions of the site. Take a look at Huffingtonpost.com or LeMonde.fr. Mobile Ads The first thing that makes impression when comparing both mobile &#8230; <a href="/2010/03/18/mobile-internet-users-are-getting-more-important/" class="more-link">Continue reading <span class="screen-reader-text">Mobile Internet Users are Getting More Important</span> <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href="/2010/03/22/php-mobile-devices-http_user_agent-strings/" rel="bookmark" title="PHP: Mobile Devices HTTP_USER_AGENT Strings">PHP: Mobile Devices HTTP_USER_AGENT Strings </a></li>
<li><a href="/2010/03/17/stop-coding-iphone-apps-begin-with-html5-mobile-sites/" rel="bookmark" title="Stop Coding iPhone Apps, Begin with HTML5 Mobile Sites">Stop Coding iPhone Apps, Begin with HTML5 Mobile Sites </a></li>
<li><a href="/2010/03/09/php-detecting-mobile-device/" rel="bookmark" title="PHP: detecting mobile device">PHP: detecting mobile device </a></li>
<li><a href="/2010/03/10/change-the-viewport-be-ready-for-the-iphone/" rel="bookmark" title="Change the Viewport, be Ready for the iPhone!">Change the Viewport, be Ready for the iPhone! </a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<h2>Internet Mobile</h2>
<p>It isn&#8217;t strange that the internet is becoming more and more mobile. When it matters to news sites I think most of the mobile versions are better than the &#8220;desktop&#8221; versions of the site. Take a look at <a title="Huffingtonpost" href="http://www.huffingtonpost.com/" target="_blank">Huffingtonpost.com</a> or <a title="Le Monde Fr" href="http://www.lemonde.fr/" target="_blank">LeMonde.fr</a>.</p>
<h2>Mobile Ads</h2>
<p>The first thing that makes impression when comparing both mobile and desktop versions of a site is the layout. Of course the lack of ads on the mobile version, or if not the absolute lack at least the small number of appearing ads, seems to be quite pleasant.</p>
<p>The thing is that as the web grow and as the web 2.0 is becoming a reality most of us will prefer to use it on a mobile device, just because it&#8217;s</p>
<ol>
<li>easier to use</li>
<li>easier to find</li>
<li>easier to follow</li>
</ol>
<p>Here&#8217;s a nice example of what mobile phones are now.<a style="margin: 0 auto;" href="/wp-content/uploads/2010/03/mobile-market-share.gif"><img class="aligncenter size-medium wp-image-1357" title="Mobile Market Share 2010" src="/wp-content/uploads/2010/03/mobile-market-share-300x181.gif" alt="" width="430" height="281" /></a></p>
<p>Now lets take a look on how the mobile web will grow in the near future.</p>
<p><a style="margin: 0 auto;" href="/wp-content/uploads/2010/03/3687.gif"><img class="aligncenter size-full wp-image-1358" title="Mobile Internet Users Chart" src="/wp-content/uploads/2010/03/3687.gif" alt="" width="260" height="200" /></a></p>
<p>That graphics describe quite well what will happen in the upcoming years. Is there now a question: <em><strong>should I make a mobile version of my site?</strong></em></p>
<div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href="/2010/03/22/php-mobile-devices-http_user_agent-strings/" rel="bookmark" title="PHP: Mobile Devices HTTP_USER_AGENT Strings">PHP: Mobile Devices HTTP_USER_AGENT Strings </a></li>
<li><a href="/2010/03/17/stop-coding-iphone-apps-begin-with-html5-mobile-sites/" rel="bookmark" title="Stop Coding iPhone Apps, Begin with HTML5 Mobile Sites">Stop Coding iPhone Apps, Begin with HTML5 Mobile Sites </a></li>
<li><a href="/2010/03/09/php-detecting-mobile-device/" rel="bookmark" title="PHP: detecting mobile device">PHP: detecting mobile device </a></li>
<li><a href="/2010/03/10/change-the-viewport-be-ready-for-the-iphone/" rel="bookmark" title="Change the Viewport, be Ready for the iPhone!">Change the Viewport, be Ready for the iPhone! </a></li>
</ol></p>
</div>
]]></content:encoded>
			<wfw:commentRss>/2010/03/18/mobile-internet-users-are-getting-more-important/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
	</channel>
</rss>
