I know what the following does and if you've used the Avatar Sizer program you've used it!
procedure (Src, Dst: TBitmap);
var
x, y: Integer;
xP, yP: Integer;
xP2, yP2: Integer;
SrcLine1, SrcLine2: pRGBArray;
t3: Integer;
z, z2, iz2: Integer;
DstLine: pRGBArray;
DstGap: Integer;
w1, w2, w3, w4: Integer;
begin
:= 0;
:= pred( );
;
:= pf24Bit;
:= pf24Bit;
if ( = ) and ( = ) then
(Src)
else
begin
DstLine := [0];
DstGap := Integer( [1]) - Integer(DstLine);
xP2 := MulDiv(pred( ), $10000, );
yP2 := MulDiv(pred( ), $10000, );
yP := 0;
for y := 0 to pred( ) do
begin
:= y;
xP := 0;
SrcLine1 := [yP shr 16];
if (yP shr 16 < pred( )) then
SrcLine2 := [succ(yP shr 16)]
else
SrcLine2 := [yP shr 16];
z2 := succ(yP and $FFFF);
iz2 := succ((not yp) and $FFFF);
for x := 0 to pred( ) do
begin
t3 := xP shr 16;
z := xP and $FFFF;
w2 := MulDiv(z, iz2, $10000);
w1 := iz2 - w2;
w4 := MulDiv(z, z2, $10000);
w3 := z2 - w4;
DstLine[x].rgbtRed := (SrcLine1[t3].rgbtRed * w1 +
SrcLine1[t3 + 1].rgbtRed * w2 +
SrcLine2[t3].rgbtRed * w3 + SrcLine2[t3 + 1].rgbtRed * w4) shr 16;
DstLine[x].rgbtGreen :=
(SrcLine1[t3].rgbtGreen * w1 + SrcLine1[t3 + 1].rgbtGreen * w2 +
SrcLine2[t3].rgbtGreen * w3 + SrcLine2[t3 + 1].rgbtGreen * w4) shr 16;
DstLine[x].rgbtBlue := (SrcLine1[t3].rgbtBlue * w1 +
SrcLine1[t3 + 1].rgbtBlue * w2 +
SrcLine2[t3].rgbtBlue * w3 +
SrcLine2[t3 + 1].rgbtBlue * w4) shr 16;
Inc(xP, xP2);
end; {for}
;
Inc(yP, yP2);
DstLine := pRGBArray(Integer(DstLine) + DstGap);
end; {for}
end; {if}
end; {SmoothResize}
Does that make me a real geek?
Ok, it kind of looks like Pascal - or er.. (no experience at all with it but I'd guess..) Delphi - what with it being Windows-ey. Actually the first thing that sprung to mind was Modula-2/3 (taught at colleg/uni respectively to start with, by chance), being the only ":=" language I've programmed in for any length of time.
Was any of this started off by the Sci-Fi channel's survey about how many of us are geeks - I read an article in the free London Underground paper Metro today about geek-ness referring to it.
I only got on the geek test :cry: I thought I was more geeky than that, at school I'd memorised pi to over 20 decimal places :!:
Great post flapjackboy, well done.
Do geeks exist yes and im dam glad .
So far my friend the geek has .taught me all i know about pcs before that i knew nothing .
Ifind it fasinating honest i do just to watch him fiddle and mess its great .
Then fiddle and mess with me mmmmm later .
dont know he sees himself as as geek but hope he dosant read this post so shhhhshhh :shock:
At just under 50% I am only a super geek, but tehn that might have something to do with my dislike of computers.
Well I just took the test and am disappointed to find out I only got % (which I copied and pasted instead of typing out); some areas I ticked tonnes, several others I didn't tick so many. I so wanted to add another couple of boxes though; the button to get to the test itself doesn't work on my Opera and I was seriously thinking about writing some user javascript to fix it or fixing the code on the page and emailing the author about it. In the "I Know" section near the bottom I ticked nearly every box (C++, Unix,...). But what is a THAC0? A computer?
So I run a web browser that's too geeky to do the test... (come on, if you use it you gotta agree - great web browser but definitely a bit geeky with the level of what it can do - customising etc.)