Not too shy to talk
Joined: 2011/6/3 13:49 Last Login
: Yesterday 7:44
Group:
Registered Users
|
Hello
I have a very simple problem : I want to apply an uniform alpha value to a bitmap that is NOT transparent ( A=255 for all pixels)
Is it not possible ? or am I doing it wrong ? [I am using VertexArray because the "sprite" may be flipped]
Thanks
Alain Thellier
if(DoBlend) {
SrcA=((float)G->Blend.B.RGBA[3])/255.0; SrcAfix=(SrcA*65536.0); DstA=1.0-SrcA; DstAfix=(DstA*65536.0);
CompMode=COMPOSITE_Src_Over_Dest; flags= COMPFLAG_SrcFilter|COMPFLAG_IgnoreDestAlpha; error = CompositeTags(CompMode, srcbm,dstbm, COMPTAG_VertexArray, P, COMPTAG_VertexFormat,COMPVF_STW0_Present, COMPTAG_NumTriangles,2, COMPTAG_DestX,sx, COMPTAG_DestY,sy, COMPTAG_SrcAlpha ,SrcAfix, COMPTAG_DestAlpha ,DstAfix, COMPTAG_DestWidth ,slarge, COMPTAG_DestHeight,shigh, COMPTAG_Flags, flags , TAG_DONE); }
|