Digital Dictionary with Adobe AIR

I am using Adobe AIR since beta testing process. For me AIR is midpoint of desktop and web programming, which is one of the basic idea of Adobe AIR. I want to use soon as AIR 1.0 released and last week give it my first official AIR application to one of the software company’s that I am working with.

Digital Dictionary

We design a dictionary (Metallurgy Technical Terms Dictionary) application with AIR, the offer came to me at the first week of march. Same week I designed the working system and functionality. It is a Turkish-English Technical Terms Dictionary which has more than 98.000 terms and 125.000 explanations. Each explanation has it own field, formulas, signs some other explanation part. Of course the numbers of terms are total number of both languages. I use is SQLLite database system which is with all data is 6.34 MB.

The Dictionary has a live searching feature. When a user starts to type a term number of matching terms come up automatically, and this is a great feature of dictionary.


Read rest of this article »

Reflection Class

Reflection effect is not something new but I accept that is effective and cool. For my current project I need it a Reflection effect. I found two on internet, but I had problems while I am trying them. One of them made problem for dynamic creation, and other one had problem with size of effect when were scaled down. If movie clip was 400×300 and scaled down to 200×150 it was creating normal size of effect and that was a huge problem. Because of those two problems I write my own Reflection class. It works fine for now but I may add some more functionality in future. If you need or just want to try you can download source code and you can use it for free. You can use example or read the below for detail and usage;


Read rest of this article »

Security Violation of Swf Files

Loading external files in Flash is simple process. First you need to create a Loader object and than give address of material which is have to be loaded to Loader object. This is simple process which supposes to be work fine but there is a high chance that you may get in error. Especially when you try to reach the files under different domain names or same domain name but when you don’t type www to beginning of the domain name. For example lets say we have two different domain name and we want to keep common files in one server.

Farklı sunuculardan dosya yüklemek

The swf file under Server A is tyring to get images from server B. For server A to reach server B there muse be an crossdomain.xml file under Server B. When swf file works in Flash Player, swf file will try to get images from server B. Flash Player will check the crossdomain.xml file for which domain name is allow and which is not. Basically this xml file allows different domains to access to files. Xml file is look like this;


Read rest of this article »

Using The Pixel Bender Filters in Actionscript 3.0

The best thing about Pixel Bender filters is soon we will have more amazing effects. I am not a person which is has a great background of math and I never work with image processing or with C. But the great part of Pixel Bender is you can use filters which is been created from someone else. This is similar like using classes in action script. Someone wrote good class and opens for public and everybody is using. So even if you are not the one who wrote filter still is good to know how to use them.

In this article I will explain how to use Pixel Bender Filters in Flash Player. Well probably you know that Pixel Bender filters can be use in Flash and After Effects. But if you want to use in flash you have to export the Pixel Bender file for flash. For exporting .pbj file you have to select “Export Kernel Filter For Flash Player” in File menu. I assume you all ready did that and I am passing the code which will be use in Flash.


Read rest of this article »

Beginning To Pixel Bender - 2

This is a second part of “Beginning To Pixel Bender” article. If you didn’t read first one you can reach form the link at below.
http://enginyoyen.com/blog/eng/index.php/beginning-to-pixel-bender-1/

Colour Channels

32-Bit of image is have 4 color channels (A:alpha, R:red, G:Greeen, B:blue). Getting color channels in Pixel Bender is really easy. For reaching the channel color of pixel first you have to reach to pixel. For getting the pixel we can use sampleNearest() function. All we have to do is create a new variable and set data type as a pixel4. For assigning value to variable we will use the sampleNearest() function.

pixel4 channels= sampleNearest(src,outCoord());


Read rest of this article »

Beginning To Pixel Bender - 1

I cover topics such as; how pixel bender works, pbj file format, language in pixel bender, platform and couple more topics in “First Look To Pixel Bender” article. And now I will consider this article as a part of the old one. That’s why I recommend you to reading the first one before starting this one.

http://enginyoyen.com/blog/eng/index.php/first-look-to-pixel-bender/

In this article I will explain how you can code with Pixel Bender and create a filter file. The language in Pixel Bender is C based language, so that’s why it might be hard at the beginning. But I will try to make easy as possible, and explain each code with detail.

Pixel Bender Toolkit

First you do need a Pixel Bender off course. You can download to Pixel Bender Toolkit address at below;

http://labs.adobe.com/wiki/index.php/Pixel_Bender_Toolkit

If you all ready start to use Flash CS4 it’s coming with installation package. You can check your programs folders it might all ready be loaded. Of course if is not you can get IDE from labs.adobe for free.

I assume you all ready download or have it Pixel Bender for rest of article. Pixel Bender Toolkit has three basic areas;


Read rest of this article »

Actionscript 3.0 Book is Out!

Actionscript 3.0 Kitabı Çıktı!

After long nights of work finally the Actionscript 3.0 book is from now on available in any book store in country. The book covers basic elements of Actionscript 3.0. Those I tried to explain by also paying a lot of attention to of only giving explanations how methods functions, I preferred to figuratively show how the system of codes works.

I finished the book at the end of April. But because of the usual summer break the publisher decided to wait a bit longer. The book is written in Turkish and I truly hope it will find great respond among the Turkish readership as it is the only source on Actionscript 3.0 in Turkey so far.


Read rest of this article »

First Look To Pixel Bender

What is Pixel Bender?

Shortly Pixel Bender Toolkit is small IDE which allow you to create your own Bitmap Filter. With Flash 8 we start to use to filters for display objects. But those filters were basic filters (Glow, Blur, DropShadow etc). If you want to go one step further with filters than you need it to use matrix and color channels. But of course they were all somehow limited.

With Pixel Bender instead of basic filters you can create your own filters or visual effect that you want.

Ps: Click the link at below for basic usage of filters;
http://enginyoyen.com/blog/eng/index.php/using-filters-with-actionscript-30/


Read rest of this article »

Using Filters With Actionscript 3.0

You can use some of the filters which is being use in image programs such a Photoshop in Flash. Of course you can do this in IDE or you can do this by Actionscript. I will only mention how you can do it in Actionscript. The numbers of filters you an use in Actionscript is not just 7 or 8. Actually I can say this number is been decided by the user. This is more like up to your creativity and curiosity. You can also create new filters and manipulate them way you want. The other point I want to touch is new version of Flash Player (Code Name: Astro) has a special way to make your own filters. The filter made by a small program called Pixel Bender. But I explain and cover that with more detail in next articles.

Creating and Applying New Filter

Creating new filter is easy. Creating new filter is not different than a creating object. All you have to do create new Filter object with new statement than pass the parameters which is required. Most simple and most used one is Blur Filter;

var blurFilt:BlurFilter = new BlurFilter (10, 10, BitmapFilterQuality.HIGH);

The blur filter takes 3 parameter. First one is blur amount that you want to apply x coordinate. Second one is amount of blut that you want to apply to y coordinate. The third parameter is the quality of blur which will be applied to display object. We can also show the code like this;


Read rest of this article »

Beginning Of Event and EventListeners With Actionscript 3.0

Event class had a big change with Actionscript 3.0. Those changes effect and make thins much easier for developers. The main idea behind that is having better controls on objects. Better control on codes it will decrease number of the errors. Also will help you too manipulate your code after while.

For example: You have made a project with Actionscript 3.0. Couple months after you finish project your costumer or employee wants to add a new functionality. Main problem over here will be adding code on a working system with out breaking functionality that is exist. Usually is hard to add some code on a system that is working. In this point is matter how good you can control your objects. If you can control your objects easily adding new codes will be easy. If is not you will have more serious problems about adding new functionality. And for more control you should definitely use the event class good.

What is Event?
Event is respond of an object to the other objects in Actionscript when some action happen. Best and easiest example is actions that happen when you click a button in Actionscript. But do not think of that only for buttons. Events can be in lots of types. Beginning of an animation, ending of animation, image that start to be load or anything like this can be an event. Any action that happens is beginning or ending of an event.

Event Listeners
Event listeners check or listen to object for any change or action. Event listeners give us information of did animation start, did some click button, did image loaded, did connect to server or any information like this. When expecting event occur event listeners run block of code which had been specified before.


Read rest of this article »

PHVsPjwvdWw+