Small change to allow window capture and automatically add a shadow, only inside the editor.

git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@1652 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
RKrom 2012-02-10 16:57:25 +00:00
parent c8fc93ee53
commit 594f8f9a0a
2 changed files with 11 additions and 2 deletions

View file

@ -583,7 +583,7 @@ namespace GreenshotPlugin.Core {
/// <param name="targetPixelformat">What pixel format must the returning bitmap have</param>
/// <param name="offset">How many pixels is the original image moved?</param>
/// <returns>Bitmap with the shadow, is bigger than the sourceBitmap!!</returns>
public static Bitmap CreateShadow(Bitmap sourceBitmap, float darkness, int shadowSize, Point offset, PixelFormat targetPixelformat) {
public static Bitmap CreateShadow(Image sourceBitmap, float darkness, int shadowSize, Point offset, PixelFormat targetPixelformat) {
// Create a new "clean" image
Bitmap newImage = new Bitmap(sourceBitmap.Width + (shadowSize * 2), sourceBitmap.Height + (shadowSize * 2), targetPixelformat);
newImage.SetResolution(sourceBitmap.HorizontalResolution, sourceBitmap.VerticalResolution);