b2dSaveImage

Category: 2D Overlay

Syntax:

b2dSaveImage:Int(imageHandle:Int, filePath:String)


Parameters

Returns

Int



Summary

Saves image to PNG file (reads GPU texture, writes to disk, synchronous operation).

Takes imageHandle (image handle from b2dLoadImage, b2dCreateRenderTarget, or b2dGrabImage, positive integer), filePath (output file path, string, .png extension).

Returns 1 on success, returns 0 on failure (invalid handle, GPU read error, or file write error).

View detailed documentation online



Example

;No example implemented yet


BambooBasic © 2026 Michael Denathorn