Home > Software engineering >  In MFC VS how bitmap background transparent
In MFC VS how bitmap background transparent

Time:10-12


As shown, I made a simple MFC project, I want to achieve the bitmap gray background transparent figure in hefei university of technology, what should I do? Please tell me the detailed affinity tutorial? thank you

CodePudding user response:

WINGDIAPI BOOL WINAPI TransparentBlt (HDC, int, int, int, int, HDC, int, int, int, int, UINT);
The TransparentBlt function performs a bit - block transfer of The color data corresponding to a rectangle of pixels from The specified source device context into a destination device context.

BOOL TransparentBlt (
HDC hdcDest,
Int nXOriginDest,
Int nYOriginDest,
Int nWidthDest,
Int hHeightDest,
HDC hdcSrc,
Int nXOriginSrc,
Int nYOriginSrc,
Int nWidthSrc,
Int nHeightSrc,
UINT crTransparent
);

crTransparent
The RGB color in The source bitmap to treat as transparent.

You are a white

CodePudding user response:

Simple method is to use PS images make it transparent PNG transparency, direct mapping,
If use interface library, dazzle colour interface library, for example, through the UI designer can directly,
If it is MFC, need custom painting,

CodePudding user response:

Advice first learn to PS a few basic operations,
  • Related