Sunday, September 25, 2011

Delphi XE2 learning curve

Prefix
If you are an Embarcadero (ex codegear [ex Borland]) Delphi programmer -- and started programming with the latest Delphi xe2 release, you must have asked yourself a couple of questions regarding it.

Delphi xe2 has introduced a bunch of new technology programming abilities -- which make the learning curve a little bit slower -- yet on the long run will produce excellent products.

First of all -- cross platform --
Delphi now can produce applications for a couple of platforms:
Microsofts Windows - win 32bit, win 64bit
Apple - OSX (desktop devices) and iOS (portable devices iPad, iPod, iPhone)
In the for coming future also:
Google - mobile android os
Microsoft - windows 8 metro style os

To make these cross compilation, Delphi's developers added to the compilation environment - FPC (free pascal) which is deployed on the Mac OSX. In order to develop on a Mac one should be register to Apple, and have a Mac computer. After preforming that you should download the Xcode and OSX, iOS sdk. The compilation of your Mac application will be done from Xcode which would use the FPC and the FMX (firemonkey platform) libraries. Both the FPC and FMX are supplied in the installation of the delphi XE2 - copied to the Mac computer and installed on it.

The FMX is a set of development objects code that enable you to compiled on the Mac after preforming the short guide lines I gave on the previous paragraph.

2d & 3d graphics
The FMX enables you to create impressive 2d and 3d applications. The use of the CPU and GPU are taken into effect when running the code you write.

Although I am not a stranger to the 3d models design. I never designed anything nor used a designer tool for that matter... Yet, when starting with the FMX one of its great abilities the the tight code written to 3d design. FMX contains components of 3d design that would be familiar to designers such as standard 3d objects, camera object, light and so on.

Delphi programmers could find on the web a set of tools such as DXScene that contains the same abilities of the FMX -- however, when purchasing the delphi xe2, you get all these abilities "built in" the environment.

Some slow downs
Unfortunately developing on this stage on Delphi XE2, would be a tricky thing. Due to lack of information on the help files. I find it useful drilling down the code of delphi in order to see what an object could do, or what is its properties and API.

If you are developing for the Mac OSX/iOS you'd find it usefull to know the Free Pascal. For example Embarcadero developers didn't map all the api that can be supplied from the various iOS devices -- and using for example GPS or sound and much more, can be done though one should know that it'll require a bit of objective-pascal code (which are the objective-c api to the iOS devices written for object pascal).

The FireMonkey was originated from a third party tool called VGScene -- which initially had the abilities of the linkage between the Delphi and the FPC. I was registered to the VGScene thus I had to use for my project an interface that was totally mapped back then on the VGScene, same goes on the FireMonkey platform.

Mid-conclusion
If you are planning a project that should be ported to Mac OSX, iOS and win32, win64.. the RAD studio is for you. If you would like to use high 3d manipulations or 2d graphics manipulation on your app -- I would give you the same conclusion.
It would be a good time to get into the programming of apps using the RAD Studio. For number of reasons:
1. DB support. Although modified from the other versions of the Rad.
2. FireMonkey support for cross platform compilation on Mac and Windows.
3. FireMonkey 3d and 2d programming.
4. Modified programming features such as LiveBinding of components.
5. Vast historical expertize on the programming environment tools in the market. Starting back from the Turbo Pascal -- which was for DOS environment -- downto the Current Delphi XE2 release