[Pixlib] AbstractLib et libs package, What for ?
Francis Bourre
peterphonix at usa.net
Wed Nov 9 08:06:22 EST 2005
Welcome Thomas!
AbstractLib is an abstract class to handle external data loading.
Generic features available in this class :
- name identifier
- url
- events system built-in (onLoadInitEVENT, onLoadProgressEVENT,
onTimeOutEVENT)
- timeout handling
- errors logging
- content getter.
- Last but not least, you can use directly getPerCent() and getName()
accessors to retrieve infos from LibEvent instances and make your preloader
UIs working easily.
Few concrete implementations are available in the framework:
- GraphicLib. It handles .swf loading.
- XMLToObject. It handles xml files loading and automatical object
deserialization.
- Libstack. Polymorphic stack implementation (FIFO). It means you can
enqueue every class above (:ILib).
Libstack instance will broadcast all AbstractLib events (onLoadInitEVENT,
onLoadProgressEVENT, onTimeOutEVENT) + a new one (onLoadCompleteEVENT) to
notify stack is empty.
I will add SoundLib soon to the list to handle swf loading + SoundFactory
instance feeding.
Here's a basical example to use GraphicLib class:
gl = new GraphicLib( mcTarget, nDepth );
gl.addEventListener( GraphicLib.onLoadInitEVENT, this, showIntro );
gl.load("intro.swf");
All your questions are welcome!
francis.
----- Original Message -----
From: "kiroukou" <kiroukou at gmail.com>
To: <Pixlib at osflash.org>
Sent: Wednesday, November 09, 2005 10:45 AM
Subject: [Pixlib] AbstractLib et libs package, What for ?
> Hi all,
> Well I'm starting with pixlib, and i've to say it's very complete, good
> job!
>
> But there is a lack of documentation i must say, i know how it is boring
> to do that with my sandy project, but I also see how it's important for
> somebody who wants to use your work.
>
> So there are my questions :
> > what is the goal of libs package ? Fro example AbstractLib seems to
> be able to load something like an external library in a swf. But what is
> the application of this class ?
>
> > can i use graphic lib to load basic swf movies? Is it a kind of super
> complete preloader ?
>
> Well, i guess it's a good start :)
> Thanks
> Thomas
>
>
> _______________________________________________
> Pixlib mailing list
> Pixlib at osflash.org
> http://osflash.org/mailman/listinfo/pixlib_osflash.org
>
More information about the Pixlib
mailing list