Confrunting my fears of blank paper

November 22nd, 2011

It’s not that I am not a good developer (I like to bill myself as a great developer) – but i have a morbid fear of the ‘blank paper’ that is a project just before I start coding. I have kind of got it pinned down to the fact that there are so many ways that a project could be built that I am concerned that whichever one I choose will be the wrong one. The thing is – I need to get over this. I have always been a great person to have working in the middle or end of the development cycle. My ability to isolate and fix bugs is a well honed skill – I just need to have the same level of confidence about starting projects.

So this week I have started an AS3 project (little things) but making sure that I totally understand the underlying reasons for choosing the architecture that I have gone for. So back to the online community and reading coded 101 sites but it has been really beneficial.

No time spent learning is ever wasted – no time spent making sure that you fully understand the life cycle of your development is ever wasted either.

Javascript Fractals

September 19th, 2011

I want to get involved with JavaScript Fractals too

Javascript preloaders

September 19th, 2011

I love these and hope to be able to create something as good soon!

A Triangle – minor change

August 11th, 2011

function addTriangle(x, y, z, w, h) {
this.addLine(x, y, z,
x + w/2, y, z,
x, y - h, z,
x- w/2, y, z,
x, y, z);
}

perfection!! no matter how wide the line. Instead of drawing the triangle from 3 points (left, right, top) I am using 4 – mid to right, right to top, top to left, left to mid.

Thanks to Lori for just lying there girggling while I got this down!!

:)

Javascript to control a layered 360

August 11th, 2011

This is still a work in progress but I wanted to get it up here so that I could see what needs work.

The comments below are for the proof of concept that is available here.

I have a love / hate relationship with code 360s. On the one hand they seem to appear in pretty much every site I have worked on and so effectively they pay the bills. On the other hand – same shit – different day.

So what happens if you take a 360 player and try to make it do new things?
First lets build it with JavaScript instead of Flash – that should be fun …. I did this for the fordCmax site.

Next – how to just change the tint of an object. I had a bit of a mess around and here is the result

It needs a bit of work still – there are issues with the load management – I need to write something for this but it wasn’t obvious until I put the demo online.

How is it working – the image is created as a composite of 4 layers – base, mask, reflection and shadows. The colour is changed by dynamically changing the background

A Triangle

August 11th, 2011

So I have been watching Torchwood. The bad guys have this cool spinning triangle (very sinister).

I wanted to harness the power of this but in JavaScript and HTML5 as I haven’t had enough chance to play around with this.

I did my usual swift search – which of the coding giants can help – why Bit101 has been monkeying around too. I shall stand on his shoulders to create my masterpiece!

First off I needed read his tutorials. I got to day 3 before needing to just get on with stuff (I only get to build stuff during Lori’s nap times so I have an excuse for my impatience).

Next I added my new triangle primative to the wirelib.js.
function addTriangle(x, y, z, w, h) {
this.addLine(x - w/2, y, z,
x + w/2, y, z,
x, y - h, z,
x- w/2, y, z);
}

Then I create my aTriangle.js file (whilst humming James Blunt’s Triangle)


var x = 30;
var y = 40;
wirelib.strokeStyle = '#ffffff';
wirelib.lineWidth = lineW;
wirelib.addTriangle(x, y, 0, 500, 500);

Nice ! but narrow

so i add width
and that screws with it – I have still to sort this out but have a look and feel its power

Amended AE Expression – to work between two markers

July 20th, 2011

Countdown text initially reads 100 but once playhead reaches first marker (“1″) count down begins counting back from 100 to 0
Countdown text will reach 0 when the playhead reaches the second marker (“2″) and will stay at 0 thereafter

or to put it in a more simplistic way – it does exactly what the client wants.

var tTF = timeToFrames();
var frDuration = thisComp.frameDuration;
var endTime = thisComp.marker.key("2").time;
var stTime = thisComp.marker.key("1").time;
var currentTime = tTF*frDuration;
var totalTime = endTime - stTime;

var content = 100-(((currentTime-stTime)/totalTime)*100);

if (currentTime > stTime)
{

if (content > 0)
content
else
0
}
else
100

little note for later gotchas – can’t use the variable name ‘startTime’ as it appears to be reserved – it kept giving me the number 6 though i am not sure why

My Fyrst AfterEffects Expression

July 20th, 2011

So like the fool that I am I agreed to add some content to a friends video that he is creating for a book launch.

Initially I had planned to use Flash to create the video but then there were issues – I couldn’t get the video as an flv to start with – then Pete told me that the video would need to be distributed via youTube and the usual channels – so I started doubting that the creation of an swf file would be the best approach.

But I still needed to create a timer.

I blagged a bit of knowledge from Ivan Pinto Bravo who told me that I needed to use something called Expressions in AfterEffects and showed me the basics of getting time info from a movie clip.

So here it is – it probably isn’t the best bit of Java ever but to say that it does the job intended makes me happy and proud

100-(((timeToFrames()*(thisComp.frameDuration))/(thisComp.marker.key("1").time))*100)

But there’s more!

I don’t want the display to start showing negative values so I experimented with a bit of variable adding and guess what! it worked


var tTF = timeToFrames();
var frDuration = thisComp.frameDuration;
var markerTime = thisComp.marker.key("1").time;
var content = 100-(((tTF*frDuration)/markerTime)*100);

if (content > 0)
content
else
0

In other news

December 16th, 2010

I am the new Dave Gilmore for the Peacefest Pink Floyd tribute band. I am like Dave in every way except that I am a lady, and not actually that good at guitar and have never played lead guitar in public – ever.
Still 9 months to learn all 9 parts of Shine on You Crazy Diamond. Its doable

I so wish I had thought of this

December 16th, 2010

http://play.airside.co.uk/#flickr-30
VHS + Printer = timed curtain opener