Archives for the month of: July, 2007

I’ve been using MVC frameworks for a while now, and it makes me think why I didn’t use it earlier… Yeah, back when I started learn programming I was exposed to procedural way of thinking, remember BASIC on IBM XT ( Yup, I wrote my first program on those awkward looking beige box from IBM, with amber monitor and glorious Hercules graphic card ), and that’s already called a luxurious home PC, considering that at the time, my sister work involving boxes of punched cards and magnetic tapes :)

Ok, back to MVC, I’m not going to do another framework comparison here, rather, just a story about my learning experience…

My first encounter with MVC was using Java, learning to program desktop application using Swing and AWT, pretty enlightening experience, but i dropped it somehow because I have no real use for it, let alone any project to work on using it… then came J2ME, when I really have fun with, creating interesting stuff for mobile devices. I also learn a lot about object oriented programming concept here, another interesting stuf, tightly related to MVC.

Now, so many MVC frameworks pops up, it’s confusing … all popular programming languages have at least one implementation of it as a framework, notably Ruby on Rails, Python’s Django & Turbogears, PHP’s Prado, CakePHP, CodeIgniter, and many others…

Which one do I use ? I tried not to get stuck and become single minded on a framework, since in my perspective, all is just tools to get things done. Currently I use CodeIgniter for my project, while I also use Django to learn Python. Why, because CodeIgniter seems to be easiest to learn, and have certain tolerance to my lazy and messy programming practice :) , tried CakePHP once, and I was lost in convention of plural singular naming… I notice Django has similar idiosyncracies, but I think I’m a bit more ready for it , after all, it’s in different language so everything is new ( I think it’s just me, it is hard to do things on convention, while I already get used to the way PHP done stuff, free and very tolerance to any kind of programming style )

Beware though, for those who just want to start learn programming, jumping into a framework to learn the language ( and learn programming in general ), is not recommended practice. I suggest learning from the very basic, the very fundamental concept like what is programming, what is procedural, OOP, functional programming, and so on. Otherwise, learning using a framework is like signing up to a flying school to learn to fly, but jump direct into the cockpit of a 747 to learn the “basic” of flying and being a pilot.

Well, at least it is in my world :)

Doing some googling on ffmpeg again last night, and then attempting another install on my ubuntu server, which I actually thought just another useless attemp, but I got nice surprise this time, here’s the story :

I was stumble upon this url :

http://desukyu.blogspot.com/2007_05_01_archive.html

an Indonesian blog with nice step by step instruction on how to install ffmpeg in Ubuntu Dapper. The result I got was just barely working ffmpeg… This is useless… I want my amr and aac codecs !!! …

Then I notice one of the step mention a url that finally lead to this url :
enable-mp3-and-amr-support-in-ffmpeg-ubuntudebian

It was an old one, which I saw and try to follow before, but no luck… Anyway, what the heck… I’d try again… and again, no luck, it’s working but no amr and / or aac… Hmm, I saw that there’s one thing I haven’t try, install from precompiled binary… yep, there it is.

I remove old ffmpeg ( apt-get remove ffmpeg ), then download the precompiled binary from here

Install…
dpkg -i ffmpeg_0.cvs20050918-5ubuntu1_i386.deb

then wala !! amr_nb and aac pops out in supported codecs formats … sweet !!

I’m not sure if the precompiled package comes with all necessary dependencies, or it was result of the steps I previously taken, but the stuff works, and that is all I need :)

Feeling turbocharged :) I move on to find a way to install ffmpeg in my mac, and here’s what I found…

http://www.ffmpegx.com/download

Yeah, I know, it’s a GUI software, but hang on… The GUI is just front end for many other back end programs, and one of them, the big part of it, is good old ffmpeg. So, I figure it must be there somewhere to be utilized via command line. After another googling while waiting for the 30Mb download, I’ve found another enlightenment :

http://codex.gallery2.org/Gallery2:Modules:ffmpeg#Usage

Which says :

if you are using Mac OS X for development/test/webserver and you have Gallery2 installed on it, use the steps listed below to get and install the ffmpeg binary and to configure the ffmpeg Gallery2 module:

  1. Download ffmpeg [1]
  2. Open the .dmg package
  3. Control-click on ffmpegX.app and select “Show Package Contents”
  4. Find Contents/Resources/ffmpeg
  5. Copy ffmpeg to somewhere like /usr/local/bin
  6. … ( the rest is irrelevant to my need :)

Installed ffmpegX, find the ffmpeg binary and copy to /usr/local/bin… check

run ffmpeg -formats … sweeet !!! amr_nb, amr_wb, aac nicely sit there :)

run a couple of tests converts from and to 3gp, mp4 and flv, everything worked… video ok, audio ok, it simply works like a charm.

Oh the joy of open source :)

Okay, I need to sleep, suddenly got a headache… just realized the sun is rising, it was 6 am, another all nighter, but nice one…

Just watched “Remains of The Day” on tv, for the n-th times… I lost count :D … Still, I thought it was an interesting movie… kinda boring for certain perspective, who really wants to watch flash backs of bitter english butler’s life anyway, but the more I watch it, I was hooked by the subtleties. I don’t know, maybe if I watch Indonesian “sinetron” I will also find such subtleties.. hehe.. but no, thanks, I simply can’t stand watching teenagers acting up like adults, wearing suits and play managers and directors of certain great company… Ok, back to Anthony Hopkins movie… Everytime I watched it, I always felt that it was a new film, until I saw Christopher Reeves, still young, walking and making great toast about amateurs and professionals… creepy…

I couldn’t care less about the picture, the camera angle or anything as such, cos really, I don’t know much about that… I just picked up , after that n-th times watching it, the subtle and mostly hidden emotion inside each character… it was brilliant I must say… not because it was a grand drama we’re watching, but because we can really relate to each character’s feeling… very simple, subtle… well maybe it’s just me, but in general, how many times we feel helpless when somebody we love passed away, how many times we simply let life chances passed away, while we actually can grab it ? plenty I guess… everything was just muted emotion, subtle, and never outloud, as most things in our life is simply being thought but never said.

Next movie was “Russian House”, also touching, maybe we could talk about it some other time… or not… I’m so tired and sleepy now.

Let’s make a list :

  • Myriad of “infotainment programme” on TV, with crappy info and useless entertainment, legal vouyeurism on some people’s tragic moments for entertainment of others ( sad eh… I’d rather call it evil activity than entertainment )
  • The soccer team lost, then people get angry, blaming government on how they don’t pay enough attention to sports , while the sports department official shouting around blaming government and public for their lack of morale and financial support. The athletes then just sit there, eating instant noodle and pay for sex, sneaking around to avoid required daily practice ( maybe it’s just me, when I was a kid , I live next to a soccer team housing, in fact, it was my grandparent’s house bought by the team to house the players… Most of the time they had parties with women, not practicing )
  • Tech pundits like Roy Suryo ( hate the hair too, think of acute Donald Trump syndrome…), being called to advise by infotainment to analyze and confirm the originality of a picture taken from an actress’ phone while having sex. Come on, using shareware program like ACDsee to see jpeg header information ? And then can tell that the picture is manipulated with Photoshop or not… amazing how people can make a good living selling hot air and crap…

etc, you know the big picture…

What I’m thinking is why the hell people care to mess around with other people life ? This country desperately need better fundamental education on personal space.

Well, I’ll be a bit lazy and uncreative here, I saw an interesting one here :
How to Switch to the Mac at The Tao of Mac site.

I’m not going to start any platform comparison, but simply, article above should give a good insight before buying a mac. I switch to Mac for about 2 months now, and I regret I didn’t see this article beforehand. Not that I will drop my decision to switch if I did, but at least I didn’t have to learn some things the hard way.

IMHO, Mac is a great platform, I should say, way more than Windows, but less real power than UNIX / Linux. Of course I am biased, I see everything from developer standpoint, I don’t really care about how nice iPhoto could do photo album, or about downloading music from iTunes ( I wonder, how are those people listen to their 50.000 songs collection ? ). After all, I pick Mac because :

  1. Now it’s Intel based
  2. OS X is basically UNIX, with less security headache, spyware and myriad of malware lurking to get in.
  3. From price performance ratio standpoint, it’s very much worthwhile to spend a thousand buck for it, since I can get nice looking, dual core Intel system, that comes with neatly organized OS that I can use right out of the box. I reckon similarly configured Windows laptop will cost around US$ 1500, if ever it match a Mac, at all.. I don’t know how much a Windows Vista license cost, as if I ever really care :)

What I find a bit annoying about Mac is :

copying folder on top of similarly named folder will overwrite the old folder, not merge into it. I learn the hard way about it, I move a java source package into /opt directory, and all I see later on is a glob of data file named opt in the root directory… Yaiks… of course I’ve done that in terminal using command line ( for those asking “How come…” ), move a file is the same with renaming a file in UNIX world, and in my head “mv somefile.tar.gz /somedir” usually move the file into the directory, not renaming the file and overwrite the directory, the operating system should be able to distinguish the type of the target, whether it’s a regular file or a directory… pretty much a brain dead way on doing simple thing, especially for highly praised and overhyped platform … sigh..

I know, i know, there’s a warning when you do sort of thing, but mind you, I was doing it in the shell terminal, not in Finder GUI, anyway, I still think that Mac OS should be able to merge folders, or at least distinguish between regular file and directory and then act accordingly, not just giving stupid useless warning telling that user is stupid on attempting such action.

Other thing is the warning on “leaving a secure website” which only have one button “OK”, hmm.. oh no, that’s for other stuff, not Mac OS .. haha :D