Adobe Camp: 1 Day, 3 Camps: 5280 Reasons to Use the Flash Platform

Rocky Mountain Adobe CampIf you haven’t heard already, the first Rocky Mountain Adobe Camp is open for registration.

The first ever, one of a kind, Rocky Mountain Adobe Camp is right here in Denver on June 22, 2009. Digital professionals at all experience levels are invited to this one-day event to participate in in-depth sessions, and unique hands-on activities taught by some of the most influential speakers in the “Flash-o-sphere”.

Want more information?
Check out http://camp.rmaug.com for event date and location as well as speaker and session info.

Use twitter?
Follow @adobecamp’s updates for more information and news.

There are some interesting sessions that will be divided between 3 different “tracks”:

  • Flash Camp: Get ready to learn best practices, discover hidden features, and extend your abilities
  • Dynamic Media Camp: Developers and content owners alike will expand their current knowledge of the Flash Media Server family
  • eLearning Camp: Trainers, staff development managers, and Human Resource professionals will all gain valuable insight for eLearning development using tools such as Adobe Connect, Adobe Captivate, and Adobe Acrobat

So pick one and register for the First Rocky Mountian Adobe Camp!

Adobe AIR – Issues with Command Line Arguments

After working on a little automation tool for video encoding process we ran into an interesting issue with AIR applications and command line arguments. Here is the scenario:

  1. Encoding process ends.
  2. The encoding process passes a file path to the waiting AIR application via command line.
  3. If the AIR app is not running, it starts up.
  4. The AIR application then checks some data in a database updates some tracking info and possibly grabs the duration out of the file.
  5. The AIR app waits for some more input.

Here is the issue – when the application starts up via the command line call, subsequent calls fail to the AIR application. Our solution, the AIR app has to be running when the OS starts up – that way the initial command line call to start the application doesn’t hold the process.

The command line looks something like in Windows:
[vb]
C:/Program Files/ServerApplication/ServerApplication.exe “D:/my/storagedir/vidfile.f4v”
[/vb]

The command line looks something like on a Mac:
[vb]
/Applications/ServerApplication.app/Contents/MacOS/ServerApplication “D:/my/storagedir/vidfile.f4v”
[/vb]

There has to be some way to start the application via the command line without holding everything up right? What am I missing?

Here is what I’m missing:
The new command line looks something like in Windows (added the /b option):
[vb]
C:/Program Files/ServerApplication/ServerApplication.exe /b “D:/my/storagedir/vidfile.f4v”
[/vb]

The new command line looks something like on a Mac (added the ‘&’ at the end):
[vb]
/Applications/ServerApplication.app/Contents/MacOS/ServerApplication “D:/my/storagedir/vidfile.f4v” &
[/vb]

Now our little automation AIR tool doesn’t need to be running when the first call happens – it will actually start up – and it can stay open and successfully receive new command line arguments.

RMAUG Mini-Max Pixel Bender Presentation Files

Last night I gave an extremely fast run down on Pixel Bender to the Rocky Mountain Adobe User’s Group Mini-Max meeting last night. The presentation was the bare minimum you need to get started playing with Pixel.

I’ve got to give props to Lee Brimelow and his other site gotoandlearn.com for information used in the presentaion as well as the start file for the PixelBender class file in the Flex project.

Resource Links from the preso:

Downloads:
[dm]5[/dm]
[dm]6[/dm]

ANT + Growl notifications = Happy Coder

We have a bunch of projects around here that we build with ANT. One of the biggest gripes with ANT builds and Flex is the amount of time it can take – Flex compiles can be slow. So whilst I’m building a project, I usually end up getting distracted for 10 or 15 minutes by something else, and my newly compiled Flex project sits there waiting for me to return. When I do return I have inevitably forgotten what I was doing.

Enter Growl and ant-growlnotify (thanks Jamie) with the ANT -listener argument. Using it is pretty simple:

  1. Download the ant-growllistener-0.4.jar from google code
  2. Drop the jar into your ant’s lib directory
  3. Run your ANT script with the -library arguement set to com.google.code.ant.growlnotify.GrowlListener
    or add -listener
    com.google.code.ant.growlnotify to ANT_ARGS
  4. Now when you run your ANT script you should get nice Growl notifications.

You’ll need to make sure that you’ve installed growlnotify. growlnotify is in the Extras folder when you install Growl.

In the same notification vein, I also tracked down ImTask last night and got build norifications going with an XMPP server. The project seems a little dated (released in 2003), but still works with OpenFire and Jabber.org.

HOW TO: Delete an XML node using E4X

While creating a sample application for some class content the other day, I ran into an XML/E4X situation that I’d never encountered before. It is pretty basic – deleting a node from XML. How does one do it? With the delete keyword of course!

For example:
[as]var myXML:XML =

Hamburger
Fries
Med. Soda
Lg. Soda
;

// Delete the Med. Soda node

// Output the XML
trace( myXML.toXMLString() );

// Result
//
// Hamburger
// Fries
// Med. Soda
// Lg. Soda
//

delete myXML.item[2];

// Output the edited XML
trace( myXML.toXMLString() );

// Result
//
// Hamburger
// Fries
// Lg. Soda
//[/as]
Man, E4X is so simple!
[dm]1[/dm]

E4X XML Namespaces

For XML that looks like the following response from Yahoo’s weather service:
[xml]
< ?xml version=’1.0′ encoding=’UTF-8′?>
http://us.rd.yahoo.com/dailynews/rss/weather/Sunnyvale__CA/*
http://weather.yahoo.com/forecast/94089_f.html Yahoo! Weather for Sunnyvale, CA
en-us
Tue, 06 Nov 2007 6:56 pm PST
60

142
18

http://weather.yahoo.com/ http://l.yimg.com/us.yimg.com/i/us/nws/th/main_142b.gif
37.39
-122.03

http://us.rd.yahoo.com/dailynews/rss/weather/Sunnyvale__CA/*http://weather.yahoo.com/forecast/94089_f.html Tue, 06 Nov 2007 6:56 pm PST

< ![CDATA[

Current Conditions:
Fair, 55 F

Forecast:
Tue – Mostly Clear. High: 67 Low: 49
Wed – Partly Cloudy. High: 71 Low: 49

Full Forecast at Yahoo! Weather
(provided by The Weather Channel)
]]>

94089_2007_11_06_18_56_PST

[/xml]

When you need to access the nodes with complex node names such as yweather:location think XML namespaces.
In the above example, look for the xmlns declaration in the rss node
xmlns:yweather='http://xml.weather.yahoo.com/ns/rss/1.0'.
Creating a Namespace object using the declaration will allow us to access the nodes with complex names.
Creating a Namespace object is a pretty simple process:

[as]
var yweatherNS:Namespace = new Namespace( http://xml.weather.yahoo.com/ns/rss/1.0 );
[/as]

Now we can access the node with the following code:

[as]
yahooWeaterXML.channel.yweatherNS::location

trace( yahooWeaterXML.channel.yweatherNS::location.@city ); // outputs ‘Sunnyvale’
trace( yahooWeaterXML.channel.yweatherNS::location.@region); // outputs ‘CA’
trace( yahooWeaterXML.channel.yweatherNS::location.@country ); // outputs ‘US’
[/as]

With the preceding example we need to know the namespace url ahead of time. E4X gives us the namespaceDeclarations() method that will return an array that contains the namespace declarations associated with the XML document

Using the namespaceDeclarations() method from the XML object:

[as]
var namespaces:Array = myXML.namespaceDeclarations();
[/as]

Now we have an array of namespace declarations that we can use to dynamically declare Namespace objects and access our complex node names:

[as]
var yweatherNS:Namespace
var geoNS:Namespace
var nsLen:uint = nameSpaces.length;
for(var i:uint = 0; i < nsLen; i++)
{
var newNamespace:Namespace = new Namespace( nameSpaces[i] );
if( String( nameSpaces[i].prefix ).toLowerCase() == “yweather” )
{
yweatherNS = newNamespace;
}
else
{
geoNS = newNamespace;
}
}
[/as]

So we can access the geo and yweather nodes without any problems now.

ApolloRanch in Boulder CO

ApolloRanch is a mini-conference similar to ApolloCamp. Thanks to Xylem CCI (Xlyem and Creation Chamber merged on April 30th) for putting together and hosting the ApolloRanch, they’ve done a great job so far! ApolloRanch is at the Fisk Planetarium (shoot for the starts Apollo!) on the CU campus in Bolder.

Mike Chambers gave the keynote as well as a “creating your first Apollo application” presentation.

Here is a frew of the highlights:

  • Apollo Beta to be released on Labs around mid June (keep an eye on Labs)
  • Many of the missing APIs will be in the beta; drag-and-drop, clipboard
  • Philo (Adobe Media Player) Preview: Very interesting media player. RSS feed based “channels” for video contnet delivery (FLV).

Some more of the release timeline:

  • Apollo 1.0, Moxie (Flex 3.0), Philo 1.0 – late Fall early Winter
  • Apollo dot releases – first quarter 2008

Links for the sample apps

Cairngen 1.0 – Now with ANT

Eric Feminella created Cairngen as a code generation tool for Adobe Cairngorm. he developed it to do away with the redundant copy/paste work needed to create Flex applicatoins with Cairngorm and is released under the MIT license.

Cairngen 1.0 is built entirely in Ant and provides a solution for one-shot code generation of Adobe Cairngorm 2.2 classes.

I haven’t had a chance to play with Caringen 1.0, but can’t wait (I love ANT!).

Thanks Eric!