DrawBitmapOverFrame
function DrawBitmapOverFrame (Bitmap: VCL.Graphics.TBitmap; Stretched: Boolean; LeftLocation: LongInt; TopLocation: LongInt; bmWidth: LongInt; bmHeight: LongInt; Transparent_Enabled: Boolean; UseTransparentColor: Boolean; Transparent_ColorValue: TColor; AlphaBlend_Enabled: Boolean; AlphaBlend_Value: LongInt; ChromaKey: Boolean; ChromaKeyRGBColor: LongInt; ChromaKeyLeewayPercent: LongInt): Boolean;
bool __fastcall DrawBitmapOverFrame(Vcl::Graphics::TBitmap* Bitmap, bool Stretched, System::LongInt LeftLocation, System::LongInt TopLocation, System::LongInt bmWidth, System::LongInt bmHeight, bool Transparent_Enabled, bool UseTransparentColor, System::Uitypes::TColor Transparent_ColorValue, bool AlphaBlend_Enabled, System::LongInt AlphaBlend_Value, bool ChromaKey, System::LongInt ChromaKeyRGBColor, System::LongInt ChromaKeyLeewayPercent);
public bool DrawBitmapOverFrame(IntPtr BitmapHandle, bool Stretched, int LeftLocation, int TopLocation, int bmWidth, int bmHeight, bool Transparent_Enabled, bool UseTransparentColor, int Transparent_ColorValue, bool AlphaBlend_Enabled, int AlphaBlend_Value, bool ChromaKey, int ChromaKeyRGBColor, int ChromaKeyLeewayPercent);
Public Function DrawBitmapOverFrame(BitmapHandle As IntPtr, Stretched As Boolean, LeftLocation As Integer, TopLocation As Integer, bmWidth As Integer, bmHeight As Integer, Transparent_Enabled As Boolean, UseTransparentColor As Boolean, Transparent_ColorValue As Integer, AlphaBlend_Enabled As Boolean, AlphaBlend_Value As Integer, ChromaKey As Boolean, ChromaKeyRGBColor As Integer, ChromaKeyLeewayPercent As Integer) As Boolean
BOOL DrawBitmapOverFrame (HBITMAP BitmapHandle, BOOL Stretched, int LeftLocation, int TopLocation, int bmWidth, int bmHeight, BOOL Transparent_Enabled, BOOL UseTransparentColor, int Transparent_ColorValue, BOOL AlphaBlend_Enabled, int AlphaBlend_Value, BOOL ChromaKey, int ChromaKeyRGBColor, int ChromaKeyLeewayPercent);
Draws the bitmap passed as parameter over video frames.
Location: the bitmap is drawn at the LeftLocation, TopLocation position over the video frame (expressed in pixels).
Size: if the bmWidth or bmHeight parameter differs from the width or height of the bitmap, the bitmap is stretched to bmWidth and bmHeight.
Transparency: if the Transparent_Enabled parameter is true, the image background is not drawn. If the Transparent_Enabled and UseTransparentColor parameters are both true, the Transparent_ColorValue value is used for transparency.
Alpha blending: if the AlphaBlend_Enabled parameter is true, a progressive bitmap transparency is applied, depending on the AlphaBlend_Value parameter, in the 0..255 range. Alpha blending cannot be performed when the Transparent_Enabled parameter is true.
Important: if the bitmap color format is not 32 bits, the bitmap is converted to a 32-bit format. For better performance, pass a bitmap already in 32-bit color format.
The DrawBitmapOverFrame function can be called only from the OnFrameOverlayUsingDC event. See the MainDemo project for sample code.