Archive for the 'general' Category

Which Weekend?! (new app)

For anyone who’s been following my extremely sparse postings - here’s something exciting to look at - http://whichweekend.com - small simple useful. A week’s work (in the evenings) and it was super fun. Like they say - build something you want to use! I’ll be rolling out new features this coming week or two, then back to polishing off courseway (which I admit has been on hold for a while).

Mpeg1 muxed hell

How to convert muxed mpeg1 videos to something/anything(!) better… the demuxxing is the key step. I had to find this out for a site I made - laurechan.com

This is simply a cut and paste from my own notes. Hope it can help someone:

  • Start with the .mpg (mpeg1 muxed - audio and video combined)
  • Make MP2 - Use the free program ffmpegX (for the Mac) to demux into .m1v (video) and .mp2 (audio). Simply click the ‘demux’ button. the plugins aren’t required. You don’t need m1v so bin it. If anyone knows of a Windows equivalent then feel free to post a comment.
  • Make MP4 - Export the original .mpg as mpeg-4 (includes video only) using Quicktime Pro - my settings were: MP4, H. 264, 256kbits/s, 400×300 preserve letterbox, frame current, key auto.
  • Make M4A - Open the mp2 in iTunes and convert to AAC (right click). Find file and copy.
  • Make MOV - Open .mp4 in Quicktime Pro. Select all. Open .m4a in Quicktime, select and copy all. ‘Add to Selection & Scale’ into .mp4 . Save mp4 to make the .mov
  • Make FLV - Export .mov to .flv changing max video rate to 256kbit/s

Note: This uses Quicktime Pro which is not free. (Although I think it should be!)

Bug for the day

If you’ve got a date_select in a partial on a collection and the date in the AR object isn’t being rendered by the date helper (and it defaults to Time.now) then the fix is to pass an :object parameter to the date_select holding the AR object (which is the partial’s local in my case). Got that?

eg

<%= render :partial => 'duck', :collection => @list_of_ducks %>

<%= date_select("duck"+duck.ref, "dob", :object => duck) %>

This one had me trawling the rails source on my hands and knees!