equal
deleted
inserted
replaced
657 for x:= leftX div 2 to rightX div 2 do |
657 for x:= leftX div 2 to rightX div 2 do |
658 for y:= topY div 2 to LAND_HEIGHT-1 div 2 do |
658 for y:= topY div 2 to LAND_HEIGHT-1 div 2 do |
659 begin |
659 begin |
660 w:= LandPixels[y div 2,x div 2]; |
660 w:= LandPixels[y div 2,x div 2]; |
661 w:= ((w shr RShift and $FF) + (w shr BShift and $FF) + (w shr GShift and $FF)) div 3; |
661 w:= ((w shr RShift and $FF) + (w shr BShift and $FF) + (w shr GShift and $FF)) div 3; |
662 if w > 255 then |
|
663 w:= 255; |
|
664 w:= (w and $FF shl RShift) or (w and $FF shl BShift) or (w and $FF shl GShift) or (LandPixels[y div 2,x div 2] and AMask); |
662 w:= (w and $FF shl RShift) or (w and $FF shl BShift) or (w and $FF shl GShift) or (LandPixels[y div 2,x div 2] and AMask); |
665 LandPixels[y,x]:= w or (LandPixels[y div 2, x div 2] and AMask) |
663 LandPixels[y,x]:= w or (LandPixels[y div 2, x div 2] and AMask) |
666 end |
664 end |
667 end; |
665 end; |
668 |
666 |