Skip to content

Commit

Permalink
Add a draw_raw() function for BitmapObject
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkOates committed Jan 1, 2017
1 parent 14949c4 commit a5ab79c
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions include/allegro_flare/objects/bitmap_object.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,14 +71,19 @@ class BitmapObject : public object2d
}
return *this;
}
inline BitmapObject &draw()
inline BitmapObject &draw_raw()
{
if (_placement) _placement->start_transform();
if (_bitmap)
{
if (_appearance) al_draw_tinted_bitmap(_bitmap, color::color(_appearance->color, _appearance->opacity), 0, 0, _flags);
else al_draw_bitmap(_bitmap, 0, 0, _flags);
}
return *this;
}
inline BitmapObject &draw()
{
if (_placement) _placement->start_transform();
draw_raw();
if (_placement) _placement->restore_transform();
return *this;
}
Expand Down

0 comments on commit a5ab79c

Please sign in to comment.