Monday, April 18, 2011

HTML5 Video... what??

Over these few years, there has been quick changes and movements in web video. With Apple's decision to block Flash out of the i-devices at all costs, which is consistent with their draconian control over their device, many websites have starting to provide video delivered using html5. So what is the difference?

First, we have to start with how video formats work. In the simplest form, a video file contains a video and an audio track. The video track is encoded in a codec such as H.264, Xvid, MPEG-2, etc. The audio track is usually encoded in MP3, Ogg-vorbis, or AC3. Then, the video and the audio is combined into a container format such as avi, mov, mkv, or flv. As a result, just because a.mov and b.mov are both mov files, it doesn't mean your media player will play it, since they can have radically different codecs.

In the 1990s, web video was in a horrendous mess with various bloated and CPU-hogging video players such as Windows Media Player and Real Player. Every time a video is embedded in a webpage, some users are bound to not have the player and not able to view it. Other users will experience lag and even crashing of browsers because the players were horrible and the computers were slow. Flash came to rescue in the end. When flash started to dominate the web with the highest install base, using Flash to deliver web video becomes a much more reliable way. Not only is it faster than the horrible alternatives, almost every single user is guaranteed to have it.

Flash video is delivered in a container format, flv. It gradually adopted newer and more efficient codecs such as H.264 as time went on and adoption spread. Eventually, most video becomes encoded H.264 and most players are able to play them well. Even graphics hardware are optimized to decode H.264 so that low power devices such as phones can play video as well.

However, flash has its own problems. The plugin itself was not exactly the most efficient piece of software even though it was much better than the alternatives. On certain computers, the plugin creates lag and causes browsers to crash. Linux platforms were not supported very well. As well, Apple claims that flash does not play well with mobile devices, and that is true to a certain extent. Of course the real reason Apple blocks Flash is so that developers can't bypass the AppStore (and develop apps on the highly versatile Flash platform that is free from Apple bureaucracy and lock-down) and are forced to let Apple have a cut in app sales and in-app purchases. Lastly, many people feel that letting a single company (Macromedia, now Adobe) control the whole web video business is scary.

HTML5 was developed with many new features. One of them was the ability to embed video directly. The video would be played by the browser directly without jumping through the hoop that is flash. However, there was a problem. Firefox refuses to play H.264 encoded videos because the browser is open source and the non-profit Mozilla organization cannot afford the possibility of having to pay a license to MPEG-LA in the future (or face lawsuit) for including it. Similarly, Google has its own plans to dominate the web video space; Google's Chrome browser, which is gaining market share fast, only plays Google's new codec Web-M, meant as a competitor to H.264, and is completely new and not a recognized standard at all.

The bottom line is that HTML 5 video is encumbered with the problem that there is no single codec that every major browser plays. When you encode a video in any codec, and then embed it on a web page using html5, there is bound to be a major browser, be it Firefox, Chrome, or Internet Explorer, that refuses to play it. Until the major players such as Microsoft, Apple, Google, and Mozilla sort out this issue and come up with something that plays in every browser (or if MPEG-LA releases H.264 to be free forever), html5 video is definitely not ready for production. In the mean time, flash is the only solution.

Sunday, March 27, 2011

Reflection on the Jazz Band Filming Project

Of course, this project was my first time operating a camera. I did not really know what to do. I only did what I was told, which I guess prevented me from completely botching the video. However, there were numerous glaring mistakes that I made. For example, I was wearing white and standing in wide shots all the time, in every single take. Me and Jacky also accidentally shot each other in one of the videos. Then, when I moved to operate the camera on the lift (for wide shots), I made the same mistake as the previous person - shooting many film crew and forgetting to move the camera.

There was also many ways the project could have been improved. For example, if we were taught what to do beforehand instead of on scene, we would not have screwed up as much. Also, non of us camera operators saw the rundown sheet and we missed many opportunities to shoot the solos (especially most of the trumpet solos were missed). I also did not really know when to move where, contributing to the confusion and the mistakes.

Overall, the project turned out decent enough, mostly due to our teacher's expertise in directing. If it had been one of the students (like me), the video would have been a nightmare to watch. Perhaps with more practice and preparation, our class can become more competent next time.

Regarding Internet Privacy

Just as most people are completely ignorant on how to use a computer and end up with their Windows machines becoming a malware cesspool, many people are similarly ignorant on internet privacy. Of course, not only are the users to blame, but the website administrators can't escape the hook either.

Recently my website was hacked, multiple times. Apparently there was a XSS vulnerability in one of the extensions I used in my website (built using Joomla). Of course this is my fault, as I hadn't updated that extension for more than 3 years! The first time was relatively harmless, with only 1 file disappearing. The 2nd time was much more malicious. Tens of infected files were uploaded somehow and the whole website was deleted (!) using those scripts. With this kind of security breach, the hackers probably would've obtained the passwords to the database and such. If the website had stored user information, we would have a huge security breach. My website is not a singular example. Many commercial websites have been hacked before. Many more are still vulnerable. With the website admins and programmers using bad coding practice and not maintaining code, everybody's privacy and security are at risk.

The biggest problems, however, imo is the users. Many people put hundreds of photos on Facebook and tag each other. What they don't know is that the photos are usually nearly public; it is very easy to gain access to them. Similarly, a friend of a friend of the person can view many aspects of his profile. With people having 500+ friends, all the information is practically public. In case anyone is wondering, this is obviously very disadvantage to everyone. If I'm the employer, I would check the applicant's Facebook profile before deciding to hire them. Much more honest information exists on Facebook than on the facade called resume. These information can only harm you, since your resume is supposed to represent you in the best possible way.

Then there is the egregious and ugly examples of cyberbullying. For example, Jesse Slaughter. She was plainly an idiot to post a video in the public, and to do it repeatedly. Not only that, she posted her phone number, address, name, age, etc in a public forum. With those information at hand, people from shadier sites such as 4chan can easily harrass her with things like fake deliveries, blackmail, etc.

Really, what people need to do is simply stop exposing information on the net. Your Facebook friends will know who you are without many photos and without those personal info. You don't need to status update every minute telling everybody what you are doing. Providing your personal email to non-important (and possibly compromised) websites is a stupid idea, and so is using the same password when creating an account in that website. Imagine the internet like a public place, and don't think you will remain anonymous if you simply shout out all your personal info.