mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-08-30 23:02:39 -06:00
Draw: New Copy(Image, Rect) variant
git-svn-id: svn://ultimatepp.org/upp/trunk@11894 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
64dbf66224
commit
ecf64bd572
3 changed files with 16 additions and 1 deletions
|
|
@ -75,6 +75,13 @@ Image GetOver(const Image& dest, const Image& src)
|
|||
return r;
|
||||
}
|
||||
|
||||
Image Copy(const Image& src, const Rect& srect)
|
||||
{
|
||||
ImageBuffer ib(srect.GetSize());
|
||||
Copy(ib, Point(0, 0), src, srect);
|
||||
return ib;
|
||||
}
|
||||
|
||||
void Fill(ImageBuffer& dest, const Rect& rect, RGBA color)
|
||||
{
|
||||
Rect r = dest.GetSize() & rect;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue