Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21100

alpha blending 2 pixels together

$
0
0
i want to alpha blend 2 pixels together by an alpha value between range 0-255 and i found this formula so far:
dest = alpha * (source - dest) / 255 + dest
the above formula works fine except on lower alpha value generates black artifact instead of transparency.(e.g:instead of transparency over back image generates black color).
so i'm wondering is there any other fast and optimized and of course with no artifacts formula for this?

Viewing all articles
Browse latest Browse all 21100

Trending Articles