Wednesday, January 21, 2009

Installing Adobe Flash Player 10 on Ubuntu Hardy

Due to the previously mentioned 2 GB limit with flash player 9, I attempted to upgrade Hardy with Adobe provided player 10 deb.

sudo apt-get install remove --purge flashplugin-nonfree libflashsupport
dpkg -i install_flash_player_10_linux.deb

But it did not work. After all the googling fun, this link was helpful. Briefly this is the key:

sudo ln -s /usr/lib/libssl3.so.1d /usr/lib/libssl3.so
sudo ln -s /usr/lib/libnss3.so.1d /usr/lib/libnss3.so
sudo ln -s /usr/lib/libnspr4.so.0d /usr/lib/libnspr4.so

sudo ln -s /usr/lib/libsmime3.so.1d /usr/lib/libsmime3.so
sudo ln -s /usr/lib/libplds4.so.0d /usr/lib/libplds4.so
sudo ln -s /usr/lib/libplc4.so.0d /usr/lib/libplc4.so

Yeah, it worked, for me at least.

Another overflow, or it looks like

Had a few large mp4 files unable to play on adobe flash player. The threshold happens to be 2 GB (overflow of a signed integer, it must be). Here is a bullet from Adobe Flash Player 9 release notes

  • Flash Player cannot progressively load files that are greater than 2Gb (210223)
I hope my guess was wrong. It would have been a low bug then.

Thursday, January 8, 2009

MP4Box - Out Of Memory

It wasn't this easy to find out.  It all started from when I was trying to convert my son's favorite dinosaur DVD's to h264 files.  I have a script, that calls for ffmpeg, feeding in parameters, and have the h264 files generated to the directories I want, then run MP4Box to hint them.  There were a dozen of them.  Encoding h264 isn't anything for the impatient.  So I left it running.  Day after day, there were some new h264 file created.  Then all done, finally.  But I found 2 largest VOB files (4.4 GB and 4.3 GB) ended up to be converted to mp4 files of 68 bytes each.  Bummer!

Of course I first thought it was ffmpeg, that it might have overflow problem.  Long story short, it was not.  I suddenly remembered that there was MP4Box hinting invoked at the end of the script.  Then I broke it into 2 steps, or course, ffmpeg got me a good unhinted mp4 file.  While I tried to run MP4Box on it, it gave me 

[iso file] Read Box "..A." failed (Out Of Memory)

I was using MP4Box from gpac 0.4.4.  Upgrading to gpac 0.4.5 fixed it.  What was unbelievable was 0.4.5 wasn't out until Dec 2008.  And until then, no one had such problem?  MP4Box isn't anything new to world.  Neither is DVD.  How come the fix isn't out until a month ago?  Weird.

A little side story on this.  When I first upgraded it, I did not see the upgrade fixing the problem.  What happened was that I made a build with the new source code, and ran the new MP4Box locally.  It did not work because it was pulling the libgpac.so from system directory, which was still the older version, because I did not "make install" the new version yet.  Seeing it not working, I was so pumped up to fix it myself.  So I loaded up ddd debugger.  That was where I found out it was using the libgpac.so of the older version.  So that took me no time.  Just that I did not get to have the sense of accomplishment.  But I am happy it is working now.