mirror of
https://github.com/luanti-org/luanti.git
synced 2025-08-26 18:21:04 +00:00
Add support for 9-sliced backgrounds (#8600)
9-slice textures are commonly used in GUIs to allow scaling them to match any resolution without distortion. https://en.wikipedia.org/wiki/9-slice_scaling
This commit is contained in:
parent
4e3c1916f7
commit
429a989648
5 changed files with 137 additions and 13 deletions
|
@ -48,3 +48,9 @@ void draw2DImageFilterScaled(video::IVideoDriver *driver, video::ITexture *txr,
|
|||
const core::rect<s32> &destrect, const core::rect<s32> &srcrect,
|
||||
const core::rect<s32> *cliprect = 0, const video::SColor *const colors = 0,
|
||||
bool usealpha = false);
|
||||
|
||||
/*
|
||||
* 9-slice / segment drawing
|
||||
*/
|
||||
void draw2DImage9Slice(video::IVideoDriver *driver, video::ITexture *texture,
|
||||
const core::rect<s32> &rect, const core::rect<s32> &middle);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue