ID Day 1

by paul on January 15, 2010

from afsilva on flickr

Well, today wasn’t perfect. I opened my browser this morning to find a number of tabs containing content that I meant to read last night but ran out of time. I spend so much time consuming that I can barely take it all in that I’ve devised ways to make sure that I don’t miss anything. Anyway, I read the open tabs which led to opening a few more tabs. I caught myself early but still, no way to start an Information Detox (ID). But even though today wasn’t perfect it was certainly different and certainly for the better. It was funny, starting the ID actually left me more time to think and do rather than just consume. I had to find things to do to fill the time that I idly spent on the internet rationalizing that I was “keeping up” and “staying informed.”

The first thing I did? I went to work and I worked my ass off. I’m trying to think of a nicer way to say it but “worked my butt off” or “worked my tail off” do not do justice to what I did today. The only way that statement could be more accurate would be if I said “I worked my f***ing ass off.” Seriously. That’s not to say I don’t do anything at work on a usual basis but there was something totally different about today. I hit it like a freakin bengal tiger and I tore it up and it felt great. I don’t know if it was due to the ID or just from making a change in general but I just found my ability to focus today was unbelievable.

Some other things I did today? I went for a walk instead of cleaning out my feed reader and noticed a lot of cool stuff that exists downtown that I’ve never even seen before. Old interesting factories that were totally deserted (the one pictured above for instance.) Houses nestled between huge slabs of concrete whose front sidewalks seemed to bank at a 45 degree angle. People reading books and walking dogs. I walked through parking lots that I usually only drive by and smiled at people who smiled back at me. We were living our separate lives but for some reason we were together today. I wasn’t just there – I actually was in the moment – I was there.

I did some thinking, I did some walking. I planned, I read, I came, I left. It seems almost silly that I would spend so much time fooling myself that I was really improving my life with all of this information. The problem was that in one single day I feel like I’ve realized that consuming the information is really the tiniest part of the equation. If I’m not living the stuff that I’m reading then why am I reading it? Rather, why am I reading it over and over and over again?

And what else is taking root in my life that I can “detox?” What else can I get rid of that’ll free up more time for these wonderful feelings?

Anyway, on to the next day, I’m looking forward to see what will happen next.

My Information Detox…

by paul on January 14, 2010

So the trend in my circle of friends and family on facebook seems to be the idea of going on a detox. I’ve seen all kinds: fruit and veggie, water, snapple, clam and mushroom, boars head cheese and salami, etc. Apparently the idea is that by staying away from all of the delicious foods that we…well, I…consume everyday that they’ll emerge with more control, less weight, and ready to begin a new life free and devoid of the vices that got them there. Sounds great, not something I would be ready for…or would I? See, I’ve been having problems lately with data. Blogs, books, articles, magazines, newspapers, handouts – you name it – I consume it. I have so much advice across so many disciplines come across my eyeballs everyday that it’s almost ludicrous. I get up early to empty my blog reader, I use my lunch break to read email newsletters, I use the drive to and from work to listen to podcasts and I spend about an hour a night tearing through facebook, checking digg and reddit, and making my nightly pass around the blog reader, and I usually spend some time each night reading some sort of non-fiction book. As I type this out I think I’m actually getting a little nauseous…

So, I’m thinking it’s time for an information detox. I need to lay off the continuous stream that seems to be clouding my life and instead opt for things that bring results and satisfaction. So, starting now until March 1st, I’m going to abide by the following rules:

1. No blog reader. If I’m searching for info that’s one thing, but to sit down and read everything that spills out of there is really quite the chore. When I’m done, I feel like I need to trim that thing down…

2. Podcasts are ok – but the list needs to be trimmed.

3. No digg, reddit, popurls, failblog, or other junk media sites. I don’t think I’m going to miss these – I can’t remember more than one of the things I saw on there today despite having just spent 20 minutes checking them all out.

4. Sitting down at the computer needs to require a plan and a purpose. No idle surfing because there’s nothing better to do.

5. Facebook is ok, but only once a day.

6. Books are ok too, but try to read something fun and not necessarily educational.

This has been a long time coming – I’ll post some updates to let you know how it goes. I’m off to delete some often used bookmarks…

Verbosity: A Silverlight Story

by paul on January 8, 2010

Ok, so this isn’t an outright rip on Silverlight – I did say this morning that it was something that I was going to invest some time and get more familiar with and…well…more on that later. This is a sample of my experience of playing with silverlight over the past couple of days. All I wanted to do was to create a circle, add it to the stage, and animate it. Let’s jump into some code.

First, a comparison. I’ve went ahead and opened Flex Builder, created a new actionscript project and created this really simple project – create a circle and animate it. The code looked like this:

package {
	import flash.display.Sprite;
	import flash.events.Event;
	import flash.filters.DropShadowFilter;

	public class CircleTest extends Sprite
	{
		public function CircleTest()
		{
			var circle:Sprite = new Sprite();
			circle.graphics.lineStyle(1,0);
			circle.graphics.beginFill(0x1d5d8f,1);
			circle.graphics.drawCircle(0,0,100);

                        this.addChild(circle);
			circle.x = 100;
			circle.y = 100;

			circle.filters = [new DropShadowFilter(2,45,0,.5)]

			circle.addEventListener(Event.ENTER_FRAME,moveCircle);
		}

		private function moveCircle(event:Event):void
		{
			event.currentTarget.x += 1;
		}
	}
}

I will say, I’ve done this a thousand times so writing this code was almost muscle memory. It’s almost an unfair comparison but still…Anyway, nothing too crazy here. Create a Sprite, define the line style, determine the fill, draw the circle, add it to the stage, determine the circle location, add a drop shadow filter as part of an array to the filters property on the Sprite and then add an event listener for the ENTER_FRAME event which occurs 30 times a second. In that listener, I’ll move the circle 1 pixel to the right until the end of time or whenever that page is closed. Not much to it.

On to Silverlight. Now you might think I’d use XAML and while it’s a perfectly acceptable assumption I’m just not crazy about coding things like this in xml. I don’t do it with MXML either in case you were wondering. So for this example, it’s all in C#. On with the code:

So I start with this very nice partial class here:

using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Shapes;

namespace TestSilverlightApp
{
    public partial class MainPage : UserControl
    {
        public MainPage()
        {
            InitializeComponent();

        }
    }
}

Alright, let’s create a circle of some sort:

Ellipse circle = new Ellipse();
circle.Width = 100;
circle.Height = 100;

Great, now here is where things start getting a little…wordy.

SolidColorBrush stroke = new SolidColorBrush(Colors.Black);
stroke.Opacity = 100.0;
circle.Stroke = stroke;

Here I’m creating a new object to set the stroke on my circle. Not too bad, I can see where the SolidColorBrush actually has a ton of paramaters that you can set to really customize it so that’s nice. I probably don’t need to set the opacity but I do anyway. Let’s set the fill for the circle now:

byte r = System.Convert.ToByte("1d", 16);
byte g = System.Convert.ToByte("5d", 16);
byte b = System.Convert.ToByte("8f", 16);
Color s = Color.FromArgb(100, r, g, b);

SolidColorBrush fill = new SolidColorBrush(s);
fill.Opacity = 100.0;
circle.Fill = fill;

Now, to set the color on the fill you can use solid colors like Color.Blue or Color.Red but it only takes about 15 seconds with a designer before you realize that they will never ever ever use either 0x0000ff or 0xff0000 for anything ever for any reason ever. So we need to use a uint and you can see that requires some more code. Still not too bad, I can abstract some of that pain away into some function somewhere but on its face it seems to be a lot of code to set a particular color.

circle.Effect = new DropShadowEffect();
LayoutRoot.Children.Add(circle);

circle.SetValue(Canvas.LeftProperty, (double)100);
circle.SetValue(Canvas.TopProperty, (double)100);

Alright, from here we set a DropShadow on our circle, add it to the stage and….place it? Wait, what’s going on here? I honestly searched for X. I was like “Hmmmm, where did they put x?” but what I should have been looking for was Canvas.LeftProperty. Hmmm, I can understand why it would like that, I’m just not sure if I like it? It’s certainly more elegant that x but x = y is a lot easier to write and comprehend than SetValue(Canvas.LeftProperty,(double)y). Anyway, in case it’s not clear, I set the circle 100 pixels from the left and the top of the window.

Now, I’m just going to put the code to animate this circle and I’m not going to walk you through it. Just look at it and we’ll regroup on the other side:

Duration duration = new Duration(TimeSpan.FromSeconds((double)6));
DoubleAnimation animation = new DoubleAnimation();
animation.From = 100;
animation.To = 600;
animation.Duration = duration;

Storyboard storyboard = new Storyboard();
storyboard.Duration = duration;
storyboard.Children.Add(animation);

Storyboard.SetTarget(animation, circle);
Storyboard.SetTargetProperty(animation,new PropertyPath("(Canvas.Left)"));
storyboard.Begin();

I’m not exactly sure of what all is going on here – what I do know is that it’s take my circle, moving it from 100 pixels from the left to 600 pixels from the left over the course of 6 seconds. It works, but great day, that is a lot of code. 3 different objects need to be instantiated so that I can move a circle. Granted, there is a plus here – there’s not the ever present and always ticking timeline like you find in Flash. I do like that you create your animation for a specific point and time and when you don’t need it anymore, you throw it away. That pretty cool. But what make me nervous is that if this is the most simple of things that you can do in Silverlight, what does it look like when you try to accomplish something more complicated? I can see how you’d be able to start stringing things together to make a predetermined animation but how do you implement physics or changing directions based on a changing variable in the browser (like a mouse?) Here is the complete Silverlight class:

using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Media.Effects;
using System.Windows.Shapes;

namespace TestSilverlightApp
{
    public partial class MainPage : UserControl
    {
        public MainPage()
        {
            InitializeComponent();

            Ellipse circle = new Ellipse();
            circle.Width = 100;
            circle.Height = 100;

            SolidColorBrush stroke = new SolidColorBrush(Colors.Black);
            stroke.Opacity = 100.0;
            circle.Stroke = stroke;

            byte r = System.Convert.ToByte("1d", 16);
            byte g = System.Convert.ToByte("5d", 16);
            byte b = System.Convert.ToByte("8f", 16);
            Color s = Color.FromArgb(100, r, g, b);

            SolidColorBrush fill = new SolidColorBrush(s);
            fill.Opacity = 100.0;
            circle.Fill = fill;

            circle.Effect = new DropShadowEffect();

            LayoutRoot.Children.Add(circle);

            circle.SetValue(Canvas.LeftProperty, (double)100);
            circle.SetValue(Canvas.TopProperty, (double)100);

            Duration duration = new Duration(TimeSpan.FromSeconds((double)6));
            DoubleAnimation animation = new DoubleAnimation();
            animation.From = 100;
            animation.To = 600;
            animation.Duration = duration;

            Storyboard storyboard = new Storyboard();
            storyboard.Duration = duration;
            storyboard.Children.Add(animation);

            Storyboard.SetTarget(animation, circle);
            Storyboard.SetTargetProperty(animation,new PropertyPath("(Canvas.Left)"));
            storyboard.Begin();

        }
    }
}

So, wow. This makes me think of the designer exodus from Flash when they switched from AS2 to AS3. Teaching a designer how to add an event listener is really kinda hard because animation used to be fairly easy. I certainly could not teach them this. Sure, you can create this stuff in XAML and configure all of your animations but even that seems like you’d end up with this really difficult pointy and stabby xml file, one which a developer would have to rewrite in C#. I’m probably making too much out of it but as I was going through this exercise and having waves of doubt as to my proficiency as a developer I came across a sobering revelation:

I’m not having fun.

For me, the end result to gauge my satisfaction by shows up in the browser, not in the code. I certainly felt awesome being able to wield this powerful language with this awesome set of tools but after messing around with this for what seems like way too long, I was getting bored…I was doing work. Is it fair to stop playing with Silverlight based off of one example? Well…yeah. Learning a new language should be somewhat invigorating, like getting a new axe and finding trees to cut down. I’m just trying to get through the examples here, getting bored and frustrated and not being too excited about the payoff. I’m not going to end with some proclamation of one tech over the other, but I will say, I’m totally impressed with Silverlight and the tools to create Silverlight content are top notch – but it’s not a lot of fun to play with. I may do some more with it but I’m going to go play with something else for a while. :(

New Year, New Projects…

by paul on January 7, 2010

When I look back at last year I think I did two things that really stretched me in professionally good way:

Learned to Type
Learned C#

I’m certainly no master of either but having spent the last 6 months with my face buried in Visual Studio has really helped loosen some of my previous bias toward other languages and technologies. Plus, it has really done something to help my long standing problem of not having a solid, server side language in my toolbox to rely on. Granted, I can sling some php and coldfusion when needed but it usually starts with a few google searches to remember how to perform the most basic of functionality.

On the learning side, this year I feel like I want to learn a few new things. I don’t expect to be great at any of them but I do want to learn each and actually create some kind of product with each so that my experimentation is not just academic in nature. I also find that with a project or end goal I can really learn what a platform can offer. So, in no particular order, here is the list for 2010!

Silverlight
Now, I realize I’ve given silverlight some crap in the past, and I still think the platform could use a few more designers but the time to snub my nose at microsoft in this area has ended. I don’t believe that being exclusively a flash developer is going to cut it anymore and I can really start seeing a day where it’s just not going to matter which one is used. Silverlight is really compelling in some area’s – the tooling, which I’ll write about someday, include really top notch products like Visual Studio and Expression Blend 3. The file size seems to be dramatically small (3k for the sample video player that I made.) And, since I feel comfortable with C#, includes a development language that I can jump right into. There are some drawbacks for sure – one being that some of the simplest actions are incredibly verbose. Second being that player detection doesn’t appear to be a solved problem (I can’t tell you how many times I come across a silverlight example that is only a blank square on a page) but those things aside, Silverlight (version 3 in particular) can no longer be cast aside as a platform that just “doesn’t get it.” Also, the rate at which new versions are being released with entirely new feature sets is simply astounding – version 3 was released in the summer and 4 months later the beta for version 4 was released. Sweet Georgia Brown that’s fast! Anyway, I see a lot of good things happening in this area and it’s time to lay down arms and start seeing what can be done with this platform. Oh, did I mention sketchflow? I don’t know why this doesn’t get more press, it’s a slick little feature in Blend that allows you to rapidly prototype apps without really having to get into the guts of the design…

Jquery
I was going to say “javascript” but really, it seems like learning jquery will accomplish 100% of the learning I want to do in this area. It seemed my last foray into javascript ending with frustration with browser checking, poor debugging (aside for the hundreds of alert boxes I would use at any given time) and still accounting for the people who just had javascript turned off. It doesn’t seem to be that way anymore with the browser having robust javascript tools and the requirement that javascript be enabled for a site to work properly. Javascript is here to stay and not knowing it is like not being comfortable with HTML or CSS. All the difficulty has been abstracted away and now-a-days, programming web applications and not knowing how to wield jquery beyond a few simple actions is kind of a handicap. I don’t need to be a drag-and-drop using mofo here but I do need to be able to use it to whip out some front end goodness here and there to really make my applications for interactive and less kludgey. Plus, it’s the only item on the list here that doesn’t require a plugin. I need to have something to use when proprietary software is not an option. I’m finding all the polish that jquery can provide an app is invaluable and not every single action in an app requires a page load. Granted, I can use jquery but I’m just not comfortable with it yet and I really need to be.

Unity 3D
Hardware accelerated 3d content in the browser (or mac, pc, iphone, or wii) is not something to take lightly. The IDE is incredible (with a free version to boot), the rate at which content can be created is staggering, and you can literally sit down and make a game in a red bull fueled night of awesomeness. The thing about unity is that it’s the one thing on this list that does not compete with the others. It’s in a world of its own, sure there are examples of true 3d being done with the other platforms but nothing like this. No joke, I seriously want to make a fogbugz app with this thing that will show cases and workload in full 3d goodness.

Flash
Having said all that – this is not the year I give up on Flash. There is still A LOT of awesomeness in this product and the community supporting it is frankly incredible. I will admit, I’m finding myself becoming more and more of a flash purist – Flex is great but the focus on complexity (I’m looking at you cairngorm) and development frameworks rather than, well, just plain awesome stuff is kind of a turn off. Flex 4 is exciting but it’s not holding my interest like I thought it would and Catalyst is something I really just don’t even want to get into. In my Flash world I’d like to see less applications and more fun. Games, programmatic art, and animation are all things that drew me to flash and I’d like to revisit those initial feelings again. Last year, one of the most entertaining projects I worked on was a little game that didn’t really go anywhere but was a total blast to put together. I’d like to have more of those experiences this year – not just with Flash but with all of these tools. At this point, I’m certainly most comfortable with Flash though, and want to keep sharpening that edge throughout the year.

So, it seems like it’s going to be an awesome year for learning. I’lll post my updates here and if I crash your browser with one of my ridiculous experiments I apologize/warn you in advance. ;)

Droid it is then!

by paul on November 13, 2009

xkcd

from xkcd

Boundaries of Space, Boundaries of Time

by paul on November 5, 2009

What an excellent speech by someone who knows a little something about being creative…

These are my favorite quotes…

We don’t know where we get our ideas from, but we don’t get them from our laptops.

If you’re racing around all day just keeping balls in the air, checking off lists, looking at your watch…you are not going to have any creative ideas.

Adobe Max-at-Home continues

by paul on October 19, 2009

So today is the theoretical “Day Two” of my watching max videos at home. To give myself the true conference-like experience, I bought a new actionscript book from the max-at-home bookstore. I’m hoping adobe will give me a copy of Coldfusion 9 to give away to myself. I should go outside or something…nah, on with the un-conference!

Building Great Games With Flash

This was an interesting session in that the demands for innovative are presented as being very high and the power of Flash being able to deliver is also very high. I know that sounds like a schmaltzy pro-adobe marketing milkshake but it just seems like Adobe is really the place to make fun stuff happen when it comes to casual gaming. Two really great notes to take away from this session is the need to rapidly prototype idea’s before going crazy with the implementation AND that the best games are made great by the amazing amount of polish they receive. Couldn’t agree more on that last point…

Oh quick note – fast forward to the 15 minute mark or you’ll be listening to 8-bit music mixed with background noise…

Flash Platform Gaming Showcase

This session had a fair amount of interesting stuff in it – namely – that gaming is now being seen as one of the top 3 use cases for Flash. Apparently before it was video and something to do with cupcakes but now…NOW…it’s gaming! It was cool to hear that adobe actually has an arcade team and are looking to post some game-related content to the ADC in the next few weeks. Other cool tidbits – Pixel Bender apparently has some cool stuff on the horizon that doesn’t involve just manipulating images and Three Melons has a game development tool? Very interesting…

Building Browser-Based MMO’s

This was an engaging session on the business-side of building MMO’s and was really interesting to get an insight to what kind of topics need to be considered when taking on something like an MMO…Here are the standout notes on this one:

  • “…Casual gamers play just as long as hardcore games but they need to think they can stop at any moment…”
  • Figure out what you can automate early and do it.
  • You’re app is just going to break, you can’t plan for it. Build,Test,Fix.
  • The whole concept of cliffs and the funnel.

So now I’m a little brain-fried but definitely got some useful information from tonight’s session. I’m done with the Max-at-Home gaming track so I’ll probably finish up tomorrow with some of the dev sessions. It’s still a little hard to watch videos for any length of time on the internet – maybe it’s just me but it’s just too darn easy to hop over to another site the second there is a lull in the session. It’s worth it though – but it does bring home the true value in paying for the conference and seeing these folks live.

Ok, after a proofreading of this post it looks like I’m an adobe squawk box in some area’s…I’ll buy that but I really just don’t see any other technology really able to deliver like flash is right now (yes, I’m looking at you silverlight, don’t turn away from me!)

Things Every Flash Developer Should Know

by paul on October 18, 2009

So last year after Adobe Max (it’s a big Adobe conference where they get everybody together and give them candy in the flavor of awesome new tools) they put all of the sessions online which I thought was really spectacular but despite having hours of content available, I failed to watch a single one. I found that, well, it’s kinda hard to sit there for an hour and listen to a session. But this year, I certainly didn’t plan to repeat that mistake. So, short of stapling my hands to the table so I wouldn’t get distracted and head over to digg or reddit or some other site peddling delicious but useless time-wasting information I queued up the first video in my library and proceeded to fill my head with actionscript erudition. Over the next few days I’ll be watching sessions so I’ll try to give a brief synopsis of each…

First up – “Things Every Flash Developer Should Know” by Grant Skinner. This was a great session – I was totally interested from start to finish and there were definitely more than a few gems to grab onto here. From new ways to think about OOP and the pragmatic declaration to “love the timeline” -(when was the last time you heard that advice?)- I found a lot to takeaway. One thing I didn’t think about was using custom tweens on simpler things and eschewing using a tweening engine (despite that fact that his company wrote one) for every single animation (like I’ve been doing ever since I found out you could abstract that chore to a separate library.) Grant has all of his talks located on one page and they’re kinda interesting to look at, highly recommended.

All in all, a very illuminating way to spend an hour – here is the video followed by my favorite slides:

Playing around with Augmented Reality and the FLARManager…

by paul on October 17, 2009

paul_flar

If you want to see some really well done Augmented Reality (AR) go here – plus – John Mayer explaining AR is probably more interesting than me…

So I’ve seen some AR in the browser for a little while now and have wanted to play around with the FLAR Toolkit for some time but like most things…I just hadn’t gotten around to it. So I finally got some nerve to hop in tonight and thanks to the FLARManager I was able to get stuff going pretty darn quick. I LOVE this community! Right away I was able to get the proverbial earth and moon example going but have a couple of other idea’s I’d love to try out.

Want to see it for yourself? Well, print out the card you find here, make sure you have a webcam hooked up, and then go to here. Flash will ask for your permission to use your webcam and once you do – BLAMMO – hold up your freshly minted card to your camera and start seeing the AR experience for yourself! It’s better than unicorn tears or flowers that taste like cake!

You should be seeing something very much like this…

I’m going to try and do something more interesting but we’ll see how far it goes. It’s incredibly fun to play with…I wonder if I could make a game out of it? Hmmmm……

Did Flex really make (my) life better?

by paul on October 15, 2009

I remember when I first got my hands on Flex (not the dev version of 1.5 that would never be anything that I could deploy to production because of the insane COST) – it was game changing. I could finally stop worrying about all of the annoying things (like laying out controls and giving data to components…and even dealing with components themselves) and could really focus on making truly awesome and polished apps (with all this new time I found!) I remember the absolute joy of coding actionscript in eclipse and what it was like to finally have things like code completion and decent formatting. I thought, “Man, the things I’m going to do with this new found tech…I can finally change the world! Finally!”

But something changed. I don’t know if it was me, I’m not sure if was the tooling or if anyone else even feels this way but…I lost something when I started using flex. I lost something and I want it back.

I was looking through my collection of old fla’s on my hard drive…some of them are quite crude but they have something that it seems that none of my flex apps have. They’re fun. They look nicer, they’re simpler…it’s almost like I’m looking back at a time of creativity and glee. Seriously, “G-L-E-E.” I used to try and design things. I had to, I couldn’t just throw a whole bunch of controls and MovieClips on the stage and leave it as it was. I think the change is that Flex encourages you to look at your code. In the flash IDE, you tried to make the code look “nice” but really, who cared? I wasn’t building enterprise grade apps back in the day…I was building widgets, I was making cool things, I was having fun. I used to think about motion, I used to think about really doing something cool, coming up with things that people hadn’t seen before. Now I think about libraries, and class structure and frameworks. I care about memory optimization and say things like “I wish I could overload methods in actionscript, mang” when I used to say things like “I love Flash, it makes me feel like I can do anything.” I was one of those people that defended the presence of the drawing toolbar in the IDE and I got really good at using my tablet to make all kinds of crazy art with the tool.

But Flex changed that. Yes I could still use Flash and make swc’s and go to “Commands” and “Convert to Flex Component” but in reality…I dunno…it seems to make the magic feel far away. I’m realizing that the last time I made something that I actually wanted to show to people was when I created Dropping Joes which brought me back to the creative suite and closer to “designing an experience” rather than “crafting some code.”

I don’t know where I’m at with it all yet…I do know that I’m probably going to start spending more time in CS4 and less time in Flex (Flash) Builder. I’m trying to find something witty to say to end this post of whinging about Flex but I got nothin. I’m just looking forward to having fun again.