Re: [AD] Allegro 4.2.0 RC1 timetable

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On Sat, 2005-06-04 at 08:39 -0600, Thomas Fjellstrom wrote:
> On June 4, 2005 01:46 am, Evert Glebbeek wrote:
> > Let's see if I don't forget anything that still needs to be done:
> >
> 
> Someone on #allegro gave entheh and I a brilliant Idea, making it easier for 
> people to chain a builtin datafile object onto a custom one:
> 
> create_myobj(...) {
> 	BITMAP *bmp = load_bitmap_object(...);
> 	/* ...wooo... */
> 	...
> }
> 
> ...
> 
> register_datafile_object(DAT_BITMAP, create_myobj, ...);
> 

So basically, the internal datafile loading functions are made public,
so you can reuse them in your own datafile loader functions. Sounds
quite useful. Only, what speaks against:

dat = load_datafile("my.dat");
while (dat[i].type != DAT_END)
{
   dat[i].dat = create_myobj(dat[i].dat);
}

To me, this seems less confusing than registering your own handlers..
but well, that may just be me.

-- 
Elias Pschernig <elias@xxxxxxxxxx>





Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/