Re: [AD] v/h flip for draw_lit/trans

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


On Mon, 2007-03-05 at 19:47 -0500, Jon Rafkind wrote:
> I wanted to use draw_lit_h_flip_sprite today but realized it doesn't 
> exist. I suppose in the mean time I can make a new bitmap, 
> draw_sprite_h_flip and draw_lit that but I would rather have a native 
> draw_lit_h_flip_sprite or something similar.

I believe that's the usual answer we had when someone wanted to do this,
in the past.

> Actually its probably not worth adding *_h/f/rotate_sprite for lit and 
> trans routines but rather make draw_sprite respect drawing_mode. I 
> wondered why this is not the case anyway, anyone know why?

Well, the documentation of drawing_mode says: "Sets the graphics drawing
mode. This only affects the geometric routines like putpixel, lines,
rectangles, circles, polygons, floodfill, etc, not the text output,
blitting, or sprite drawing functions."

So, it simply never was meant to do anything to blitting/sprite
functions.. which doesn't mean we can't change the docs. (And deprecate
draw_trans_sprite and draw_lit_sprite then? I always found them
confusing anyway.. but would need to think more if this really would
work out.)

>  Looking 
> through cspr.c it might be tricky to make fast, non-sucky code that can 
> do normal/lit/trans mode's for all the drawing routines but I'm sure 
> something can be arranged. Perhaps the code could be auto-generated or 
> something. Just wanted to bring it up before I submit a patch of sorts.
> 

Not sure if it's better to fill in extra functions, use drawing_mode, or
do something else. If your patch fits properly into the API (not hard
with 4.2 :P), I don't see why it shouldn't be applied.

-- 
Elias Pschernig





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