Filt3rek's home

Go to the content | Go to menu | Go to search

haXe, actionscript, open source flash, SWF experimentations.
Note : Most posts are experiments, so some tricks are fixed in new versions of haXe.

friday 18 april 2008

Same source code for different plateforms using haXe - Flash / JavaScript component sample

You can find many frameworks or libraries, plateform dependant, that help you writing your applications. You can, for exemple, find UI components, motion tweens libraries for flash (like caurinaTweener) and for JavaScript (like JavaScript Motion Tween). Each plateform is different and each library has its own API, that you have to learn and sometimes it's the best way to give you reason for hanging LOL .
Of course you can write your own libraries that use the same API for the different plateforms you target, but as everyone should know, coders are lazy.
haXe targets Flash and JavaScript, and thanks to the conditional compilation, you can easily build libraries having the same API and behaviour on different plateforms and sharing same, common source code.
Here comes an little example of a Button component having the same appearence and behaviour on Flash9 and JavaScript. 70% of the source code is common for both plateforms... Less time spent on building and debugging our library. It's a great news since time is money, and we don't want to loose money, right? ;-)

Read next

saturday 12 april 2008

FEffects 0.1.0 for haXe (Tween for Flash8, Flash9 and JS)

This is a little package that I wanted to create including some tweens, sine loops effects (will come soon) and others effects that change values in time.
For now, a Tween class and easing equations (ported to haXe), are available for flash8, Flash9 and JavaScript.
Here is a sample :
Chips :

Read next

friday 11 april 2008

haXe/PHP : Nouvelle plateforme pour haXe

Aujourd'hui, a été publié ce post, par Franco Ponticelli, annonçant la sortie de la version alpha 1 de ce projet; haXe cible désormais le PHP...en gros : t'écris en haXe et ça te pond du php nickel derrière.
J'ai craqué. J'ai fais le petit "Hello World" qui suit.
C'était dans l'ordre des choses... LOL

Read next

sunday 6 april 2008

Collections access time : haXe Flash8 - Flash9 bench

Here's a basic test that shows times for differents ways to store and iterate through a set of collection as List, Hash, Array.
flash8 & flash9.

Read next

wednesday 2 april 2008

Data access time : haXe Flash8 - Flash9 bench

Here's a basic test that shows times for differents ways to get a value.
flash8 & flash9, 8 tests, it can take time :-)

Read next