Monthly Archives: May 2012

Some more Radio Commercials

I thought I would follow my previous post Radio Commercials with another similar themed and very creatively named….. “More Radio Commercials” post

ThiscommercialforConnexwasafinalistin the London International Awards acoupleofyearsback.

1. Connex-Radio-Commercial.mp3     

This was one of a set of commercials in which I spent the day traveling with the police and interviewing them about their experiences dealing with road accidents.

2. TAC-Radio-Commercial.mp3     

This commercial was one of a small campaign to promote the Puma Love Run. The actors were recorded in the booth (although I made them run around a little) and after a bit sound design and some reverb, care of my favorite convolution reverb plug-in Altiverb, it came to life.

3. PUM0002_T.mp3     

Change the background colour of UITableViewCell

In one of the IOS apps I am currently working on I been using a table view controller to display information for a core data database.  I was wanting to change the background colour of the UITableCell depending on a boolean variable in my manged objects.

Originally I tried setting this in the UITableView delegate method

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath

After I quick test I realised that because the UITableViewCell is effectively recycled (de-cued and used again) this approach was not going to work.

After a little more reading I found the UITableView delegate method

-(void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath

This is what you need to use if you want to change a cell that is displaying a specific row (index path) in your table.

Here is an example of the code I used in my app:

 

-(void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath
{
    MonkeyManagedObject *monkey = [self.fetchedResultsController objectAtIndexPath:indexPath];
    
    
    if ([monkey.hasBanana isEqualToNumber:[NSNumber numberWithBool:YES]] ) {
        
        cell.backgroundColor = [UIColor redColor];
        
        
        
    } else {
        
        
        cell.backgroundColor = [UIColor whiteColor];        
    }
    
    
    
    
    
    
}

In my code I am using a NSFetchedResultsController to populate my table view also because the Boolean type in a managed object is actually an NSNumber you need to use the NSNumber class method:

[NSNumber numberWithBool:YES]

Recent TV commercial sound design work

Over the last year or so there has been some great TVC sound design work flowing through the studios at Risksound so I thought that I would post a couple commercials I have worked on recently.

The first commercial was done for the Suzuki Swift R1.  The background atmosphere  was created by using an automated eq to sweep down an audio track that contained white noise. This was then fed through a convolution reverb plug-in using an impulse response of a big metal tank.  The noise for the lights was created by processing two wine glasses clicking together with reverb and reversing the sound.

This second TVC for cars guide was a lot more music and voiceover focused but I still had some fun the sound effects.  I used a lost of whooshes and servo motor sound effects and a recording of wind with the the volume automated on the camera moments to give it a sense of movement.

 

 

View your core data SQLite database

I am currently writing an ios app that uses a medium size pre-populated core data database. Having worked with mysql previously along side php and java I have to say that the way core data is implemented makes it very powerful and great to use for object persistence.
In my app I am opening a plist file as a dictionary and looping through each entry to create the core database within the app.
I am also using a UITableView and a NSFetchedResultsController to display the table in the app which is another strength of core data as it automatically reloads the table when the data changes.
The first time I ran the app and viewed the table some of the objects had the wrong section  headers and also some of the section titles were incorrect.
When I checked the plist files the entires that were showing up incorrectly were fine in the plist file.  In mysql I would have just done a select * to see all the entires in the table to see what the database looked like but wasn’t sure how to do this with core data.

This is what I ended up doing to find the incorrect entities:

I set the SQL debug flag in xcode. In xcode 4 this can be done from the Product menu by selecting “Manage Schemes” and then editing the current scheme you are using. Select the “Run “phase and then select the “Arguments” tab. Here you will see options to set arguments and environment variables. Add the code below as an argument:

-com.apple.CoreData.SQLDebug 1

I then ran my app in the ios simulator which gave me the location of the sql file on my computer. I copied the location (minus the sql file name) and pasted it into the “Go to Folder” field in the “Go” menu of finder then copied the .sql file into my user folder.

I then downloaded SQLite Database Browser which is a free open source SQLite browser (the title is pretty explanatory really) and opened my .sql file and viewed the tables.

I found the entires which were incorrectly entered and fixed them in my .plist file that populates my core data database which in tern fixed the problem with the section headers I was having. All without too many (more) hairs turning grey!

Radio Commercials

Script 1:
Product: Radio Commercials by Sandy Milne

Person 1: Have you heard the radio commericals by Sandy Milne?
Person 2: Sandy Milne? no I didn’t know he produced radio commercials?
Person 1: Yes, Sandy Milne makes great radio commercials.
Person 2: Well I will have to get some of these radio commercials by Sandy Milne then.
Person 1: Great idea, call Sandy Milne on 04blahblahblah or www.sandymilne.com forward slash radio-commercials

Fast voice: offer not valid on weekends or public holidays
Faster voice: LMCT402932323/123/BLAH123

This is pretty much the format of 95% of the radio commercials you hear on the radio so it’s nice when I get to work on things that are a little different. I thought I would upload a some radio commercials I have worked on over the last couple of years starting with these four.

For this commercial I managed to wrangle in all the people in the building and did several overdubs to create a chorus of people. It was great to pull out the Neumann u87s. This one also featured on http://www.bestadsontv.com

1. Salvos-Miss-Out-Radio-Commercial.mp3     

 

This spot for Victoria uni was highly commended at the siren awards.
Part of the challenge of an commercial like this is not only the sound design element but the direction that you give the voice over artist. I found some old episodes of the superman radio show on record on a shelf in the back of Risksound and played as a reference and played it to them before we started.

2. Vic-Uni-Save-The-World.mp3     

This spot was just fun to work on and was a reminder that when working with kids keep recording as you don’t want to miss out on a golden moment.

3. SPC-Fruit-Snacks-Radio-Commercial.mp3     

This was just a fun little sport for Melbourne Airport. I had both VO actors setup in chairs in the studio to simulate a car and had actually got a work colleague to record his kids the day before which was a great help

4. Melbourne-Airport-Radio-2011-.mp3     

Play a random sample Kontakt with scripting

Over the last year or so I have been working on creating a sample based software instrument in Native Instruments’ Kontakt, which has its own scripting language Kontakt Script Processing.  I had to learn the language from scratch but found the KSP reference  pdf  bundled with Kontakt and information on the Kontakt scripting forums at the Native Instruments website great resources.

The instrument I am currently working on is now over 3000 lines of code and I have started dreaming of $EVENT_NOTE variables but one of the first requirements was to trigger a sample from a range of samples randomly. This was pretty easy to do but because it was random it often played the same sample twice in a row. I then added a couple of extra lines to make sure that it didn’t play the same notes twice. I thought I would upload this code as it may prove useful to people who are leaning KSP.  It also shows how to create and call functions and declare variables.

 

on init
       
    {declare variables to hold previous values}
 declare polyphonic $random
 declare $last1 := 0
 declare $last2 := 0

 
 
declare $lastTime := 0
declare polyphonic $velocity := 1
    
    
{Declare keys for Random Triggers ie the note that will trigger the random sample  }
 
declare $key_trigger := 108
   
{declare the range of the samples that will be triggered randomly}    
    
declare $lower_limit := 0
declare $upper_limit := 23    
    
    
{Set key colours}

set_key_color($key_trigger, $KEY_COLOR_RED)     
set_key_color($lower_limit, $KEY_COLOR_GREEN)
set_key_color($upper_limit, $KEY_COLOR_GREEN)   
    
    
end on

{Random sample Function}


function playRandomSample
    
     
            
            $random := (random($lower_limit, $upper_limit))
        
           
        {check to see if the next step has been used in the last two }
                
                while ($random = $last1 or $random = $last2)
               
                $random := (random($lower_limit, $upper_limit))
            
                end while
                
                play_note ($random, $velocity, 0, 0)
  
        
            $last2 := $last1
            $last1 := $random
       
   end function

on note
  if ($EVENT_NOTE = $key_trigger)
      
      $velocity := $EVENT_VELOCITY
      
      call playRandomSample
      
      end if  
    
    
    
    
end on

 

feel free to leave any questions/comments below