Same card remains selected when reloading templates;

Fixed vertical blends for non-square images

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@459 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-07-01 19:29:06 +00:00
parent 86393f33dc
commit bd18f41075
2 changed files with 13 additions and 1 deletions
+1 -1
View File
@@ -39,7 +39,7 @@ void linear_blend(Image& img1, const Image& img2, double x1,double y1, double x2
double a = fixed / (sqr(width) * sqr(x1-x2) + sqr(height) * sqr(y1-y2));
int xm = to_int( (x2 - x1) * width * a );
int ym = to_int( (y2 - y1) * height * a );
int d = to_int( - (x1 * width * xm + y1 * width * ym) );
int d = to_int( - (x1 * width * xm + y1 * height * ym) );
Byte *data1 = img1.GetData(), *data2 = img2.GetData();
// blend pixels