there's the rect grad. now stop bugging me :(

This commit is contained in:
Derek Foreman 2003-05-18 23:27:31 +00:00
parent e328dc2f60
commit b24e6fbfa1

View file

@ -397,7 +397,7 @@ void gradient_rectangle(Surface *sf, int inw, int inh)
dby = dbx/(float)h; dby = dbx/(float)h;
dbx/= (float)w; dbx/= (float)w;
for (x = 0; x < w; ++x, data) { for (x = 0; x < w; ++x, data) {
if (drx * x < dry * y) val = (int)(drx * x); if ((float)x/(float)w < (float)y/(float)h) val = (int)(drx * x);
else val = (int)(dry * y); else val = (int)(dry * y);
r = sf->data.planar.primary->r + val; r = sf->data.planar.primary->r + val;