Flash Penetration!

Since the realease of Flash Player 9 the penetration that the player has gotten is fantastic. Flash Player 9 alone has gone up to 97% and Flash Player 9 with update 3 is up to 82%. It shows that the Flash Player and it’s content is still strong and there is no sign of it dying off. (Yippeee)

The thing to wait for now is when Flash Player 10 comes out. What will be the stats for that? Will it have the same impact as Flash Player 9? (I’m thinking hell yes!) With the capabilites of Flash Player 10 it will mean that Flash Player 10 will penetrate even more then Flash Player 9. I even suspect that whole pages will be created out of Flash that look like an XHTML site. Why not? Flash content is now searchable with Google and Yahoo!.

 


Flash Searchable

On the 30th of June 2008 (Monday) Adobe anounced they will be working with Yahoo! and Google to enable search on Flash content.

Both Yahoo! and Google will be given a special version of the Flash player that will be able to open up SWF content and search through it. The Flash player will also be able to perform user actions so the content can be crawled.

Adobe explains why they have chosen to do this:

“Until now it has been extremely challenging to search the millions of RIAs and dynamic content on the web, so we are leading the charge in improving search of content that runs in Adobe Flash Player. We are initially working with Google and Yahoo! to significantly improve search of this rich content on the web, and we intend to broaden the availability of this capability to benefit all content publishers, developers, and end users”

Having Flash content searchable is going to open up the doors (or should a I say flood gates) for even more Flash content. I can tell you this, when I heard this a little bit of wee come out! It will be spectacular as all the RIAs and Flash content that I develop will be searchable which will lead to the content being listed on Yahoo! and Google.

When will this new searching begin though? Well Adobe has anounced that the new SWF searching has already been implmented in with Google and that you should be seeing better results already.

Excuse me, but now I have to go and clean my self.

 


3D in flash the old way

As the new Flash player 10 is arriving in 2009 is there a need to write code to simulate 3D code. I suppose it depends on what you want to achieve in your Flash project.

The way I do it now is by perspective. I use perspective to manipulate the x, y and scaling values of the objects that I want to be in 3D space.

Perspective is pretty easy to understand as you see it all the time. The further you are away from an object the smaller the object becomes.

On a screen though, you have a focal distance and then the z index, which determines your perspective of an object. Below is a diagram demonstrating this:

Example of 3D perspective

Now to determine your z index you have to do a little bit of simple maths.

Scale ratio = fd / (fd + z)

Where fd is your focal distance (the distance away from your screen) and the z is the z distance on your screen. fd is static it doesn’t change, I usually do 300. The reason why I choose 300 is because it gives a good virtual distance between the screen and the eye.

As an objects z index gets bigger this ratio becomes smaller, and so does the objects size. To apply the scale ratio to the objects scale just add the scale ratio as the new scale for the object.

You also have to apply this ratio to the x and y positions of the object other wise it wont scale properly. You have to set a vanishing point as well. You can use the center of the stage for this. You can see how this is applied in the example below.

Below i have done a quick sample. If you want, try the code out and try it for your self.
 

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package {
	import flash.display.Sprite;
	import flash.events.Event;
 
	public class basic3d extends Sprite {
		private var ball:Sprite = new Sprite();
		private const fd:Number = 300;
		private var bx:Number = stage.stageWidth/2;
		private var by:Number = stage.stageHeight/2;
		private var z:Number = -100;
		private var vx:Number = stage.stageWidth/2;
		private var vy:Number = stage.stageHeight/2;
 
		public function basic3d():void {
 
			ball.graphics.beginFill(0x000000);
			ball.graphics.drawCircle(0, 0, 40);
			ball.graphics.endFill();
			ball.x = bx
			ball.y = by
			addChild(ball);
 
			ball.addEventListener(Event.ENTER_FRAME, scale);
		}
 
		private function scale(e:Event):void {
			z += 10;
			var scale:Number = fd/(fd+z);
			ball.scaleX = ball.scaleY = scale;
			ball.x = bx + vx * scale;
			ball.y = by + vy * scale;
 
			if(z == 2000) {
				z = -100;
			}			
		}	
	}	
}

You can download the end result of this code here

This is the complete basics of 3D in flash and the new Flash player 10 will incorporate a z index so you don’t have to do this ratio every time you want to achieve basic 3D. Having this in the Flash player will lead to some exciting developments in user interface design, but if you want real powerful 3D capabilities I recommend the Papervision3D framework (Now that is some cool stuff).


Diesel - Flash CS4

The Flash CS3 LogoIt looks like Flash CS4 will arrive in 2009. My last post I was talking about the Flash player 10 and the features that we’ll see in the player. Today though I have read over some interesting blog articles about Flash CS4 and what they have planned for it.

It looks like the Flash CS4 environment is going though a major overhall. Instead of the main time line you will be able to place objects on the stage, right click them, click add motion Tween and then move your object to the end location, and whala all done. By the sounds of it Flash CS4 is going to be even easier for the end-user who is design oriented to perform even more actions with out having to code a line. 

Some of the features that look like there on the agenda for Flash CS4 are:

  • inverse kinematics (Things like capturing the movement of a human arm)
  • A new Tweening model. (Which should make it even easier to make animation)
  • 3D capabilities (Like I said in my last post about 3D in Flash 10)
  • Advance text components
  • XFL a new source format

These features alone are going to take the new Flash authoring environment a hell of a lot easier to use. 

Out of the features above the one that catches my eye is the new XFL source format. The reason for this is the *.fla format can only be used by the Flash authoring environment. This new source format, which is a XML document, will be contained in a zip archive with all the assets of the Flash project. Having the source format like this will lead to other applications being able to open up the Flash project for editing. For example say Photoshop could open the source format and inspect each component in the Flash project. You can then edit each image asset in Photoshop and when you open it back up in Flash CS4 you would see the changes made.

This makes Flash framework more flexible for the community. If a bunch or even a developer got cracking they would be able to create a Flash authoring environment that could be made out of Adobe AIR and coded in ActionScript 3.0. So you would be developing content that was created in the content that you are creating in. (That sounds right….. yeah I think so. [Brain freeze])


Flash player 9 to 10

Flash Player 10 code name: AstroFlash over the years has had some drastic changes, and Flash player 10 shows that there are still a lot more to come. With the release of Flash player 10 (codename: Astro) it will see the Flash content and RIAs propel to new dimensions.

Flash player 10 I think is planned to take Flash content and throw it into the deep end of development. Turning it not merely into a design and animation tool, but a full blown out development environment that rivals the .NET framework.

With Adobe AIR I can also see that it will be a fierce competitor when building not only online applications but offline applications; especially when the AIR run time will be based off Flash 10.

You can get a feel of what is coming for the new Flash player 10 at the Adobe labs.

There are some cool videos that Justin Everett-Church has made to demonstrate the new features of the new player. It got me thinking on how I could use some of these new features and effects on various projects to make them more visually stunning.

The links to the videos are below:

I Love ActionScript 3.0 and the whole Flash sha-bang. I can’t wait for what the Adobe gang will come up with next.