Re: [AD] Potential Optimization

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


That does seem like a useful function to have. It's sort of a generalization of `al_draw_glyph`.

Also, we could add a callback to the font itself to cache glyphs on a bitmap of your choosing, so you could e.g. stick it onto an atlas with the rest of your sprites. Then you could really draw everything in a single draw call.

-SL

On 07/14/2016 07:50 PM, trent@xxxxxxxxxx wrote:
That makes sense. What I need then is just al_get_glyph_region that returns
x/y and bitmap of a font glyph so I can draw my own text. I tested this in
my game, with both fonts and graphics drawn using al_draw_prim and I've gone
from ~12 FPS to 60 in the menu...

On Wed, July 13, 2016 10:59 pm, SiegeLord wrote:
I'm confused about this. The reason why transformations are applied as
they are is so that you can change them in the middle of drawing
multiple bitmaps. Does this change essentially remove that feature?

Also, it doesn't seem like this completely fixes mixing primitives and
bitmaps, as if there's overlap, wouldn't bitmaps always be drawn over
the primitives even if they're interleaved?

-SL

_______________________________________________
Allegro-developers mailing list
Allegro-developers@xxxxxxxxxx
https://mail.gna.org/listinfo/allegro-developers







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