Re: [AD] clipping, sub bitmaps |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
- To: "Coordination of admins/developers of the game programming library Allegro" <alleg-developers@xxxxxxxxxx>
- Subject: Re: [AD] clipping, sub bitmaps
- From: Matthew Leverton <meffer@xxxxxxxxxx>
- Date: Tue, 18 Aug 2009 12:52:11 -0500
On Tue, Aug 18, 2009 at 11:23 AM, Elias
Pschernig<elias.pschernig@xxxxxxxxxx> wrote:
> But yes, the origin as well as the offset can both easily be done in
> user code by simply changing the parameters passed to drawing functions.
>
I don't really like setting the offset... it seems like approaching
the problem from the wrong side. E.g., the smaller entity (the
"sprite") is telling the larger entity (the "canvas") what to do. I
think conceptually it's better to make the user specify additional
offsets when blitting. To me, you're almost moving Allegro into a
higher level sprite-management role with supporting offsets.
On the flip side, specifying the origin is just a natural extension of
clipping and another way to do sub-bitmaps. It almost always would be
used with the parent object telling the child object where to draw
itself, which makes sense from an OOP standpoint--especially with
Allegro 5's implicit target bitmap. Those types of transformations are
easy to understand.
But I'm not opposed to adding offsets. I just wouldn't use it, and I
think it gives a confusing and false impression of what Allegro is. (I
can just imagine people always blitting to 0,0 and using bitmap
offsets exclusively to control things...)
--
Matthew Leverton
- References:
- [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps
- Re: [AD] clipping, sub bitmaps