b2dFadePalette

Blends an indexed image's palette toward a target colour by amount (0..1).

2D Overlay

Parameters & Returns

Parameters

imageHandle Int
toR Int
toG Int
toB Int
amount Double

Returns

Void

Quick Summary

Blends an indexed image's palette toward a target colour by amount (0..1).

Technical Exegesis...

Interpolates every palette entry toward (toR, toG, toB) by amount (0 = unchanged, 1 = fully the target colour) - a cheap tint/dim/fade-to-colour that affects the whole image at once. Combine with cycling for embers/fog effects.

Example

Example.bam
; No example implemented yet