Tuesday, January 25, 2005

WMODE and Flash Video

Now here is one everyone should know: If you use Flash Video, either by using the Flash Communication Server or progressive FLV download, do not use windowless mode. What is windowless mode you ask? This TechNote has more information of what it means. We use this term internally since it best describes what it does. Instead of creating our own drawing surface we use the browser window so that you can overlay Flash content over HTML content.

Windowless mode is a nice feature, but it heavily impacts on performance. More so with video. To the point where your whole browser will eventually freeze because of timing issues during playback. If that happens you either need to kill your browser process or in the worst case reboot your machine.

This is something a lot of customers have trouble with when deploying video and we get quite a few calls on it.

Monday, January 17, 2005

Undiscoverable features in Flash MX 2004

Throughout a release cycle we always stay in contact with users to get feedback. Very often users request new features from us which are already in the product, but were just undiscoverable. This can be due to missing UI, a bad description or wrong location. One of the examples is a basic ActionScript editor formatting feature, the block indent. Very often you just want to indent a whole block of code like this:



Well, as you can see there is no icon you can click for this, the AutoFormat feature will not do exactly what you want either. You have to know the shortcut which is simply TAB for increasing the indent of a selected block and SHIFT-TAB for decreasing the indent of a block.

What makes this even more confusing that it is the same on Windows and Mac. While this is standard in many Windows applications, the Mac editors I know (CodeWarrior, Eddy) usually use APPLE+'[' and APPLE+']' for this. Another reason this is sometimes lost in the appendix of the documentation.

While being at it, did you ever try to hold SHIFT-CTRL while using the scroll wheel? If your mouse is over the stage you might just have found a new feature. ;-) Obviously this does not help the fact that it should actually be just CTRL and that holding SHIFT does not scroll horizontally like it should.


Sunday, January 16, 2005

Microsoft Avalon remarks

I spent some time following what Microsoft and Apple are doing for their new OS versions. The direction is clear: everything is moving from pixel based graphics to vector data and extensive graphics hardware support.

Microsoft file format solution is called XAML, which is a SVG derivation in many points. But where SVG is incredibly complex, still lacking some basic functionality, slow and almost impossible to implement 100% correctly, XAML is simply to the point of what developers and designers need. There are many reasons why XAML is interesting, apart from the technical ones:
  • Totally new user experiences are possible, going away from the classic widget based systems.
  • Reusing content and making changes becomes easier. Maybe this is the perfect blend between skinning and code.
  • Designers can become more part of developing applications than ever before. The key here is that Microsoft has to deliver on the tools side. In the past they haven't shown a particular feel for designers.
Microsoft has acquired CreativeHouse with their application called Expression. It looks like this technology will become the base of their new design tools. While a nice toy application, I hope it'll change enough so it will become practical for everyday use. Or maybe they have those engineers working on something totally new like it is the case so often when small companies are acquired.

Skimming over some of the specs of XAML, everything still looks quite incomplete. If they are at this stage now it looks like another couple of years for this thing is ready though.

Summary of new Macromedia Flash features

'Zeh' has posted a good summary of the information which is out there about the new version of Macromedia Flash, code named '8ball' and 'Maelstrom'.

The information is mostly accurate, if a bit incomplete. While the new features are exciting, I can assure everyone that we also spent time fixing many older graphics related issues. The format itself has limitations and therefore some things will stay as they are, but there is still room for improving some areas which have been the source of frustration for many users.

In the end I hope we'll be able to make this version the most important one ever, maybe since Flash 5. From how it looks we are on track so far with all the excitement we have generated out there.

Tuesday, January 11, 2005

Apple's KeyNote with SWF support

Looks like Apple's KeyNote 2 will have SWF export functionality:

http://www.apple.com/iwork/keynote/compatibility.html

Monday, January 10, 2005

NetStream attached to multiple video objects

Last week I looked at an interesting bug with Flash Video. Let's assume you have two video objects on stage and you attach the same NetStream object to them:

myNetStream = new NetStream(myNetConnection);
myVideo1.attachVideo(myNetStream);
myVideo2.attachVideo(myNetStream);

This code will not do exactly what you'd expect. FLVs are a packet based format and the NetStream object will simply evenly distribute packets between the two video objects. Each video object instance has it's own instance of the video codec. What happens is that the video codec is suddenly missing some frames, including key frames. This will result in corrupted video playback.

So if you want to make this work you have to create another NetStream object which will serve up the video.

Windows XP 64bit Edition RC1

This weekend I installed Microsoft Windows XP 64bit Edition RC1 on my dual Opteron. So far I am impressed. It's extremely stable and runs all my 32bit applications without a problem. Since Microsoft seems to want to price it the same way as the 32bit version it might easily become the default for new AMD and Intel boxes.

Now, as far as 64bit applications, there is not too much out there. Microsoft ships two versions of IE. Obviously this is because most of the plugins are not 64bit ready yet, including the Flash Player.

After some digging I found some interesting info for developers:
  • The Microsoft Windows Sever 2003 Platform SDK has everything required to compile 64bit applications using Visual Studio 2003
  • Switching Visual Studio 2003 to a 64bit environment is a little bit of a pain as it is a global environment variable setting.
  • Inline assembly is not supported. Instead good old .asm files need to be used.
  • In 64bit mode MMX and x87 registers are not saved during a context switch of the kernel. That means that all the MMX code you might have will not run (and not compile that is).
  • Floating point math is done using SSE1/SSE2. This could be a problem if you depended on accuracy of the 80bit floating point values of the x87 instruction set. In SSE it's 64bit only.
  • Custom SSE code needs to be implemented using intrinsics. I still haven't figured out if old MMX code using intrinsics will compile directly to SSE. In theory this should work.
  • The compiler does output useful information about potentially dangerous pointer usage like casting a pointer to a 32bit integer value or backwards.
I see plenty of work ahead...