Skip to content

DrawBlock

Narta Xaymar Dirks edited this page Oct 28, 2026 · 5 revisions

Blitz3DBlitzPlusBlitzBasic

DrawBlock

DrawBlock:Void image:Int32, x:Int32, y:Int32, frame:Int32=0
Parameter Mode Type Default Description
image In Int32 required The image to draw.
x In Int32 required Horizontal position of the handle of the image.
y In Int32 required Vertical position of the handle of the image.
frame In Int32 0 Which frame to draw. Defaults to 0.

Description

Draws a frame of an image without any transparency, so the mask color is drawn like any other. It is faster than DrawImage for pictures that fill a rectangle completely, such as backgrounds.

Examples

Graphics 320, 240, 0, 2
SetBuffer BackBuffer()
Local img = CreateImage(100, 100)
SetBuffer ImageBuffer(img)
Color 255, 160, 0
Oval 5, 5, 90, 90, 1
SetBuffer BackBuffer()
Cls
Color 40, 90, 160
Rect 0, 0, 320, 240, 1
DrawImage img, 30, 70
DrawBlock img, 190, 70
Color 255, 255, 255
Text 80, 200, "DrawImage", 1, 1
Text 240, 200, "DrawBlock", 1, 1
Flip
WaitKey

Media

DrawBlock

Related Commands

DrawBlockRect, DrawImage, DrawImageRect, TileBlock

Home · Command Index



Differences
Language Features
BlitzBasic
Blitz3D
BlitzPlus

Clone this wiki locally