Skip to content

Can blend either 2 colors or more than 2 together with a certain amount of each first one left over.

Notifications You must be signed in to change notification settings

Lexz-08/SharpBlend

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SharpBlend

Description

Can blend either 2 colors or more than 2 together with a certain amount of each first one left over.

How To Use

// Assuming you have the System.Drawing namespace referenced.
// Change the colors passed into the function's parameters to whatever colors you'd like, unless you want those.
Color BlendedColor = Blender.BlendColors(Color.Orange, Color.Magenta, 0.5);

// For Console Application users...
IntPtr DesktopHandle = IntPtr.Zero;
using (Graphics GFX = Graphics.FromHwnd(DesktopHandle)
{
    GFX.FillRectangle(new SolidBrush(BlendedColor), new Rectangle(10, 10, 10, 10));
}

// For Windows Forms Application users...
// The BackColor represents the BackColor property of the Form window.
BackColor = BlendedColor;

Download

SharpBlend.dll

About

Can blend either 2 colors or more than 2 together with a certain amount of each first one left over.

Topics

Resources

Stars

Watchers

Forks

Languages