Wednesday, 18 November 2009

Bug finding but not much fixing

This morning I was still working on fixing browser specific CSS and javascript bugs on my photo website.

I had a problem with IE8 not sticking the footer at the bottom of the page, which I managed to solve by applying the min-height to a div containing the content rather than the body.

I had a problem with getting a 'Stack Overflow at line 0' in IE, which I wasn't able to diagnose, so I asked about this on the WebSqueeze.

I had a problem with IE6 not supporting max-width. How to fix it without javascript was buried a couple of pages down in the results - How to fix max-width in IE6 without using javascript or CSS expressions. A nice solution, but in the end I decided that most IE6 users will have small screens, and so the extra work to set a max-width for IE6 that will only come into effect at higher screen resolutions wasn't really worth it.

I found that in IE the tinyMCE Comment plugin wasn't working. The reason for this is that it outputs some javascript into the page. The XSL Stylesheet I'm using for IE then takes the CDATA section of the javascript and writes it back to the page with the & converted to & so where's there a line of javascript saying something like if (n && n != -), what is output by the XSL processor is if (n && n != -), thus breaking the page.

I spent all afternoon trying to work out a way to print the content of script nodes or CDATA nodes without the values being escaped, but couldn't find any way to get it to work. I did read a few solutions to this problem, that said that if your output method is set html, then script blocks won't be escaped. However, in my case the script blocks content IS being escaped, and I am using the html output method.

So in the end I just gave up and turned off the tinyMCE comments plugin. I'll re-enable it once I've re-written it sometime in the future so as not to dump any js in the page but rather use an external js file.

In the evening I looked for some songs to go with my first video for my photo website. I looked at MusOpen, which has public domain classical performances, and a few sites featured on the creative commons website. Of the ones listed on the Creative Commons website, the Internet Archive Netlabels had a great chiptunes christmas album.

Jamendo had songs that were free to download, but you had to pay a license fee to use them in a video (€10 for use in a short educational video to be available on the internet for all time). I ended up finding a nice couple of acoustic guitar tracks at ccmixter.org. It's actually a site for remixing, but I thought the two sample tracks that I downloaded sounded good by themselves.

Updating my video with a soundtrack, I found that my video was over five minutes long, whilst the two tracks I'd downloaded were both about three and half minutes long. At first tried using part of one track, then most of the other track, and then part of the first track again to make up the full 5 minutes. But although they were both acoustic guitar tracks in a similar style by the same artist, they didn't really 'mix' together.

So I ended up just using one track, and cutting it into sections so I could create an 'extended mix' of that one track, which lasted for the full length of the song.

It took quite a while to get the song cut up and 'synced' with the video okay, and when that was done I had to try and look at the different encoding options and settings in Adobe Media Encoder, which is what Adobe Premier uses to save/encode/export the video.

When I encoded the video last time, I noticed that Adobe Media Encoder was only maxing out core of my dual core CPU. Since it took about 7 or 8 hours to encode the video last time, if it could use both cores it should be quite a bit faster.

I couldn't see any settings to change it to make it use both cores, so I googled and found a thread about Adobe Media Encoder only using one core. In that thread, someone says that it may depend on the codec you use.

The codec I was using before was something like h264, so I tried a different codec this time, though it was quite difficult to get the options correct so that the video would be
  1. In a format suitable for uploading to youtube
  2. Decent quality
  3. Not using the h264 codec
Also, it wasn't helpful that Adobe Media Encoder has loads of different settings for each codec or format, and there doesn't seem to be any explanation of what the settings mean.

After setting the encoding going I just listened to Christmas Chiptunes and read an e-book about blogging.

Food
Breakfast: Orange marmalade toast sandwich; cup o' tea.
Morning snack: Maryland Cookie; Hob-nob; cup o' tea.
Lunch: Ham with mustard sandwich; Clementine; Orange marmalade toast sandwich; Slice of Tesco all butter Madeira cake; Rocky; cup o' tea.
Afternoon snack: Maryland Cookie; Fox's Crinkle crunch cream; cup o' tea.
Dinner: Slice of pepperoni pizza; chips; peas; salt. Pudding was a slice of Tiramisu. Coffee; Piece of Sainsbury's caramel chocolate.

No comments: