LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 11-29-2011, 04:36 PM   #1
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Rep: Reputation: 78
Hosting video files using HTML5: advice?


Having just looked at the HTML5 video compatibility table on wikipedia, it would seem that HTML5 video has a big problem: Namely that there is no single video format supported by all major browsers.

There is a secondary problem: That a significant fraction of web browsers currently in use do not support HTML5. I've got Firefox 8 right now and It doesn't support quite a few features -- notably mpeg4 and h.264. The situation looks pretty grim.

Does anyone have advice about handling video in HTML5 rather than Flash? I'm inclined to either use Flash (again) or rely on Youtube or Vimeo for hosting my video.
 
Old 11-29-2011, 06:23 PM   #2
neonsignal
Senior Member
 
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Bookworm (Fluxbox WM)
Posts: 1,391
Blog Entries: 54

Rep: Reputation: 360Reputation: 360Reputation: 360Reputation: 360
Actually, it looks like only one major browser company, Microsoft, has a philosophical problem with supporting multiple codecs, because apparently they are concerned about the poor customer getting tied up by intellectual property rights!

So yes, you have a quandry; you have to predict the future of that browser.

But for now, if you want to support all the major browsers, you have to serve the video in multiple codecs, or provide both html5 and flash (as youtube does), or do flash only, or use a third party host who does one of these for you, or put up an annoying message saying 'please upgrade your browser'.

Last edited by neonsignal; 11-29-2011 at 06:39 PM.
 
Old 11-29-2011, 06:45 PM   #3
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Original Poster
Rep: Reputation: 78
thx, neonsignal.

I don't think M$ is entirely to blame here. According to the compatibility table, Firefox doesn't support H.264 or MPEG-4 and Safari only supports H.264 and Chrome is going to remove H.264. And publishing 4 different video formats for every video is just STUPID.

Any tips on how to detect video support for a given browser via Javascript so that I know when to put up that 'please upgrade' message? Seems to me like I'll have to manually maintain a database of browser video support and that this database is likely to change frequently.
 
Old 11-29-2011, 07:04 PM   #4
neonsignal
Senior Member
 
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Bookworm (Fluxbox WM)
Posts: 1,391
Blog Entries: 54

Rep: Reputation: 360Reputation: 360Reputation: 360Reputation: 360
Quote:
Originally Posted by sneakyimp View Post
Any tips on how to detect video support for a given browser via Javascript so that I know when to put up that 'please upgrade' message? Seems to me like I'll have to manually maintain a database of browser video support and that this database is likely to change frequently.
You shouldn't use a browser database, because this will fail for people who have manually installed plugins, or who run a browser that isn't in your database.

You can just put up multiple source statements inside the video tag, and let the user agent decide. You can also listen to the error event (MEDIA_ERR_SRC_NOT_SUPPORTED) on the last source element with a script, and decide what to do then. You might also be able to use the 'canPlayType' method. The W3C page has some details http://www.w3.org/TR/html5/video.html.

I don't know why you would need to have four codecs; either VP8 or Ogg Theora coupled with H.264 would cover all the bases. Of course, if this is a commercial project, you may need to pay royalties to encode the H.264 versions.

Last edited by neonsignal; 11-29-2011 at 07:11 PM.
 
Old 11-29-2011, 07:36 PM   #5
sneakyimp
Senior Member
 
Registered: Dec 2004
Posts: 1,056

Original Poster
Rep: Reputation: 78
Thanks for the seriously good info.

Quote:
Originally Posted by neonsignal View Post
I don't know why you would need to have four codecs; either VP8 or Ogg Theora coupled with H.264 would cover all the bases. Of course, if this is a commercial project, you may need to pay royalties to encode the H.264 versions.
All the bases? Android? Blackberry?

ROYALTIES? grrrr. Define "commercial?"
 
Old 11-29-2011, 08:29 PM   #6
neonsignal
Senior Member
 
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Bookworm (Fluxbox WM)
Posts: 1,391
Blog Entries: 54

Rep: Reputation: 360Reputation: 360Reputation: 360Reputation: 360
Quote:
Originally Posted by sneakyimp View Post
Define "commercial?"
In this case, video that is not "free to end users" or is not distributed over the internet.

Quote:
All the bases? Android? Blackberry?
Both of these support HTML5 to some extent (Blackberry using Webkit). Not sure how well it works, but I think you will find that codec-wise recent Android versions support VP8, and Blackberry supports H.264. Though you will need to be careful about encoding specifics if you are planning to support these lower end devices.

Last edited by neonsignal; 11-29-2011 at 08:38 PM.
 
  


Reply

Tags
flash, html5, video



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Use yafc's fxp command to FTP transfer all files from old hosting to new hosting? Ultrus Linux - Server 4 06-23-2011 03:33 AM
[SOLVED] Firefox 4 in Slackware 12.2 and HTML5 video problem mycinka Slackware 1 03-23-2011 08:52 AM
LXer: 15 HTML5 Demos Showcasing Prowess of HTML5 Over Adobe Flash LXer Syndicated Linux News 0 08-14-2010 02:42 PM
LXer: Watch HTML5 Video on Ubuntu 10.04 LXer Syndicated Linux News 0 05-07-2010 06:20 PM
LXer: Open Letter to Mozilla Regarding Their Use of HTML5 Video LXer Syndicated Linux News 0 06-20-2009 11:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration