You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
JoeStrout edited this page Apr 29, 2026
·
2 revisions
Resize canvas and fill with color NOTE: Resize offset is relative to the top-left corner of the original image
Parameters
Parameter
Default Value
Note
image
offsetX
offsetY
newWidth
newHeight
fill
Return value
None.
Notes
Example
img=raylib.LoadImage("sprite.png")
// Add a 16px border of black around the imageraylib.ImageResizeCanvasimg, img.width+32, img.height+32, 16, 16, raylib.BLACKraylib.ExportImageimg, "sprite_bordered.png"raylib.UnloadImageimg