TftBmpMemIndRotate()

Library Description ›› Memory ››
 visits
Parent Previous Next

Syntax

TftBmpMemIndRotate(wFileIndex As wTftLibParameter1, wX_Pos As wTftLibParameter2, wY_Pos As wTftLibParameter3, wAngleDeg As wTftLibParameter4, wBackground As wTftLibParameter5, bTransparent As bTftLibParameter1, wAlphaColor As wTftLibParameter6, bInvert As bTftLibParameter2, bOverlay As bTftLibParameter3), Byte

Overview

Renders a BMP by index stored in FLASH memory, rotates it counter-clockwise by a specified angle, and applies optional transparency, inversion, and pixel-overlay effects.

Parameters

Parameter

Description

wFileIndex

Zero-based BMP file index in FLASH memory.

wX_Pos

X-coordinate of the rotated image’s lower-left corner.

wY_Pos

Y-coordinate of the rotated image’s lower-left corner.

wAngleDeg

Rotation angle in degrees (CCW).

wBackground

Fill color for exposed areas created by rotation.

bTransparent

Transparency mode:
0 – Normal rendering (no transparency)
1 – Skip any pixel matching the alpha-key color

wAlphaColor

Alpha-key color used when transparency is enabled.

bInvert

Color inversion:
0 – Normal colors
1 – Invert all colors

bOverlay

Pixel overlay/blending mode:
0 = NONE – Direct pixel write
1 = OR – Lightens by setting bits
2 = AND – Keeps intersecting bits
3 = XOR – Highlights differences
4 = NAND – Inverted AND; bright overlaps
5 = NOR – Inverted OR; darker result
6 = XNOR – Keeps matching pixels
7 = ADD – Add RGB values; brighter blend
8 = SUB – Subtract RGB values; darker blend
9 = AVG – Average RGB; soft mix
10 = SCR – Screen blend; bright highlights
11 = MUL – Multiply blend; darker result (Photoshop-style Multiply)
12 = CON – Contrast-boost mix; non-linear

Return value

Value

Meaning

0

Success

1

Origin outside visible area

2

BMP width or height is zero

4

BMP partially printed outside the visible area

Notes

Processing order: transparency → inversion → overlay → draw.

Transparency is slower because each pixel must be evaluated individually.

Overlay effects are slower due to pixel read-modify-write behavior.

When global TftPixelCheck is enabled:

Images fully outside the visible area are skipped.

Images partially outside are clipped to screen boundaries.

Created with the Personal Edition of HelpNDoc: Free help authoring tool