LOL @ 110 FPS... How on earth can I optimize this:- (other than using MMX)Originally Posted by Alimonster
dwSrcOffset := (ddsdSrc.lPitch shr 1);
dwDestOffset := (ddsdDest.lPitch shr 1);
for iY := 0 to ddsdSrc.dwHeight - 1 do
begin
for iX := 0 to ddsdSrc.dwWidth - 1 do
begin
if SrcBuf[iX + iY * dwSrcOffset] <> $0000 then
begin
DestBuf[iX + iY * dwDestOffset] :=
((SrcBuf[iX + iY * dwSrcOffset] and $F7DE) shr 1) + ((DestBuf[iX + iY * dwDestOffset] and $F7DE) shr 1);
end;
end;
end;
Bookmarks