参数表
$ O5 ?' J& Q, q5 r h* R0 n; darg1:[arg1+10]+[arg1+C]*arg3+arg2*2存放缓冲区(应该就是屏幕显示区在内存的映像)基地址
1 f2 g% q* A& Aarg2:字符串宽度 x" j5 t2 O! c/ E; z" r0 r$ f
arg3:y
! R2 h1 U& ]# Jarg4:颜色( j; u g1 c b. J
arg5:与颜色深度有关% Z4 T* x5 N: B( H7 [( `$ A
arg6:与颜色深度有关$ t' u, s, Z# [: \
ecx:字符的编码基地址
" T8 e5 @! O9 v+ |5 P4 K! m
7 d! S* }8 V' D5 p0071B820 /$ 83EC 54 sub esp,54% `) y% u0 E7 X$ f
0071B823 |. 53 push ebx
- z$ f' ?% q I, a% C+ O H! U0071B824 |. 8B5C24 5C mov ebx,dword ptr ss:[esp+5C]
8 ~( }' Y7 X. ]9 _5 Y n* y9 H0071B828 |. 55 push ebp. D; W3 H, @) \+ O
0071B829 |. 56 push esi. V3 `# O. t7 w
0071B82A |. 8B43 08 mov eax,dword ptr ds:[ebx+8]4 A9 O; ]! d3 v& L
0071B82D |. 8BF1 mov esi,ecx! M, f3 N" g2 f0 m* c% P6 l k# ^
0071B82F |. 8B4B 04 mov ecx,dword ptr ds:[ebx+4]
. n e: H) p1 E, C$ \5 w0071B832 |. 57 push edi
' `) k9 m* E: y; p0071B833 |. 50 push eax" q# ~% ^, v1 k% U, D
0071B834 |. 51 push ecx
' \4 Y7 p" ?1 p- i3 k1 n) Q0071B835 |. 6A 00 push 0) P: R/ A" q j' w( N4 r0 q
0071B837 |. 6A 00 push 01 @. a* ], Q% g* K! \2 `: G6 I
0071B839 |. 8D4C24 54 lea ecx,dword ptr ss:[esp+54]
: S0 d6 r/ g, Y0 Q0071B83D |. 897424 20 mov dword ptr ss:[esp+20],esi4 Z/ j8 K7 Z' y) J, S+ O: K' i
0071B841 |. E8 6ABCCEFF call heroes4.004074B0
' E- E) ^* y! K5 b) A0 @; {0071B846 |. 8B56 08 mov edx,dword ptr ds:[esi+8]
8 l4 r/ Y: R1 ~0071B849 |. 8B46 04 mov eax,dword ptr ds:[esi+4]
8 t- L( D8 E6 L9 L& M0071B84C |. 52 push edx4 A8 R- ]# O) O J8 G3 R: o% x
0071B84D |. 50 push eax
5 T9 s7 s% K% p0071B84E |. 6A 00 push 0; v* w4 N- Y% |5 J& o* G
0071B850 |. 6A 00 push 0& T6 {/ o8 A6 e0 H' ^& g
0071B852 |. 8D4C24 44 lea ecx,dword ptr ss:[esp+44]7 E$ n! C0 r5 w7 i5 q. p
0071B856 |. E8 55BCCEFF call heroes4.004074B01 V: B1 I7 y: Y! b3 r
0071B85B |. 8B4C24 34 mov ecx,dword ptr ss:[esp+34]. x) L7 t, v7 L, Y
0071B85F |. 8B5424 38 mov edx,dword ptr ss:[esp+38]: u+ d9 Q+ |. \0 @( E& e
0071B863 |. 8B4424 3C mov eax,dword ptr ss:[esp+3C]
( f0 v# d H" P: f0071B867 |. 894C24 24 mov dword ptr ss:[esp+24],ecx
+ g v* ~' m# |7 _/ E. ~0071B86B |. 8B4C24 40 mov ecx,dword ptr ss:[esp+40]
5 `5 ^9 c3 m* q" b& X# ?4 E! z0071B86F |. 895424 28 mov dword ptr ss:[esp+28],edx3 _, \+ R; \0 Q
0071B873 |. 8D5424 6C lea edx,dword ptr ss:[esp+6C]
1 V% O; x6 N4 F7 h1 h* l* V& t0071B877 |. 894C24 30 mov dword ptr ss:[esp+30],ecx0 |$ t# l! e! z( J5 y
0071B87B |. 52 push edx" E9 ^5 |- P/ H0 F: j$ j
0071B87C |. 8D4C24 28 lea ecx,dword ptr ss:[esp+28]
2 ?$ q* B+ ~# Z! |& D; N; j, U0071B880 |. 894424 30 mov dword ptr ss:[esp+30],eax l% a5 B" L2 N! r/ f
0071B884 |. E8 47BCCEFF call heroes4.004074D0
% U ^. K( c/ b0 X0071B889 |. 8B4424 30 mov eax,dword ptr ss:[esp+30]
1 T; _6 @, g; |7 c/ ?0071B88D |. 8B4C24 50 mov ecx,dword ptr ss:[esp+50]
( }+ I K+ E8 \2 | L! y4 w0071B891 |. 3BC1 cmp eax,ecx
# N8 q- O' ?2 I+ N: S0071B893 |. 8BF8 mov edi,eax
- M# L/ ]; Z% A# O0071B895 |. 7C 02 jl short heroes4.0071B899! c7 x6 v o& T) _: Y
0071B897 |. 8BF9 mov edi,ecx& N7 x7 d' \' K$ {# X
0071B899 |> 8B4424 2C mov eax,dword ptr ss:[esp+2C]
3 P5 b7 f% S- e+ S7 G6 u3 Y: a$ `0071B89D |. 8B5424 4C mov edx,dword ptr ss:[esp+4C]
2 `) J- _7 `' `3 u3 o0071B8A1 |. 3BC2 cmp eax,edx- \( V8 D8 B8 y: D- }' u6 N
0071B8A3 |. 7D 02 jge short heroes4.0071B8A7 R; e0 M2 L/ f" F6 E, ` Q
0071B8A5 |. 8BD0 mov edx,eax
% n1 v# y: ^8 I9 @7 ` j0071B8A7 |> 8B4424 28 mov eax,dword ptr ss:[esp+28]
' f0 Y; x- X' T" Y! K1 M7 f+ W0071B8AB |. 8B4C24 48 mov ecx,dword ptr ss:[esp+48]" y0 M: x+ @. \& G# f3 m6 [
0071B8AF |. 3BC1 cmp eax,ecx( p8 t9 m) }* f
0071B8B1 |. 7E 02 jle short heroes4.0071B8B5+ U( I1 i2 @8 {$ ]3 E& T. L/ _; ~
0071B8B3 |. 8BC8 mov ecx,eax( @( {7 ]4 m# }- x) x" i
0071B8B5 |> 8B4424 24 mov eax,dword ptr ss:[esp+24]- R" Y$ y# l. \: Y* ^
0071B8B9 |. 8B7424 44 mov esi,dword ptr ss:[esp+44]4 h5 ^% B! n' Y0 V9 x& g
0071B8BD |. 3BC6 cmp eax,esi O: H1 t9 y3 B
0071B8BF |. 7F 02 jg short heroes4.0071B8C3
0 K* x0 B% c6 @. R4 B0071B8C1 |. 8BC6 mov eax,esi6 X9 j9 G9 c2 e( T. y/ `' k8 m
0071B8C3 |> 57 push edi
+ T( _- n! j/ w6 a2 k4 Q; v+ o0071B8C4 |. 52 push edx
* L+ l/ C/ }5 V+ N7 G" \0071B8C5 |. 51 push ecx
U! L6 w2 U. E0071B8C6 |. 50 push eax! @( G b2 G; q9 j) ?' d& e
0071B8C7 |. 8D4C24 64 lea ecx,dword ptr ss:[esp+64]
% D2 _6 O; ~# y# P) V3 n0071B8CB |. E8 E0BBCEFF call heroes4.004074B0% Y+ n+ Y' W* _* h4 b
0071B8D0 |. 8B4424 60 mov eax,dword ptr ss:[esp+60]) Z) w* I. x% J# h8 c5 I+ O
0071B8D4 |. 8B7424 58 mov esi,dword ptr ss:[esp+58]8 }. C% W( ?# m, ^
0071B8D8 |. 2BC6 sub eax,esi( Z% J) }) V3 s
0071B8DA |. 85C0 test eax,eax
" p; q* ~8 D }6 N% }1 J0071B8DC |. 894424 18 mov dword ptr ss:[esp+18],eax
# C3 ^" f: T4 H4 @0 }+ P4 J# O0 w/ V0071B8E0 |. 0F8E B0010000 jle heroes4.0071BA962 Z* N/ i, f- I0 z, U3 s# V( n0 q7 W/ ]
0071B8E6 |. 8B6C24 5C mov ebp,dword ptr ss:[esp+5C]- e& L, _4 d; I6 l U1 B; [" Y2 X# z
0071B8EA |. 8B4C24 54 mov ecx,dword ptr ss:[esp+54] ; 数值上等于arg2
. X# W( Q- [- j7 K0071B8EE |. 2BE9 sub ebp,ecx) f0 w3 r: r& |- {2 k* h0 O3 u
0071B8F0 |. 85ED test ebp,ebp
" [) _; |+ Y1 n" j) B0071B8F2 |. 896C24 1C mov dword ptr ss:[esp+1C],ebp
2 T* {* ^7 {. Q2 q+ G% Q0 M0071B8F6 |. 0F8E 9A010000 jle heroes4.0071BA96" t C, _% u ]- f+ E
0071B8FC |. 8B4424 6C mov eax,dword ptr ss:[esp+6C] ; arg2
# x! H" k1 O7 P0 R- O8 w; x# H0071B900 |. 8BF9 mov edi,ecx g5 }* h6 ~4 f/ j# `; Y& F. f; w8 l
0071B902 |. 2BF8 sub edi,eax/ [, [) v2 p- Z
0071B904 |. 8B4424 70 mov eax,dword ptr ss:[esp+70] ; arg3
- ^ J8 x3 M4 w7 S) H0071B908 |. 8BD6 mov edx,esi- Z2 d1 _. e f+ \) F
0071B90A |. 894C24 24 mov dword ptr ss:[esp+24],ecx
$ p& C3 F6 l9 Z6 c8 y0 h9 q0071B90E |. 2BD0 sub edx,eax4 k7 @) q6 Y% x! T4 i
0071B910 |. 8B43 0C mov eax,dword ptr ds:[ebx+C]
+ F! K V X# e: n- r; N u9 D0071B913 |. 8BD8 mov ebx,eax/ J5 X. x( {/ v
0071B915 |. 0FAFDE imul ebx,esi* D! d6 f2 @; j
0071B918 |. 8D344B lea esi,dword ptr ds:[ebx+ecx*2]/ G) {& J( l: H
0071B91B |. 8B4C24 68 mov ecx,dword ptr ss:[esp+68]
* ~9 b4 O+ f9 J6 T" J- x0071B91F |. 8B59 10 mov ebx,dword ptr ds:[ecx+10]
) e: q( z) d Z6 M( Y- n0 \0071B922 |. 8B4C24 10 mov ecx,dword ptr ss:[esp+10]( V* A& H6 Z! A. L
0071B926 |. 03F3 add esi,ebx
6 S! ~% |5 @% b; l+ p- F0071B928 |. 8B49 0C mov ecx,dword ptr ds:[ecx+C]
* U5 s$ x# [, G; ]* h0071B92B |. 897424 68 mov dword ptr ss:[esp+68],esi; 重点:将缓冲区地址写入栈内(原arg1处)/ M* h5 n) A) S) {1 y
0071B92F |. 8BD9 mov ebx,ecx& W# O6 }! M7 I; O$ L
0071B931 |. 2BCD sub ecx,ebp; t1 u) m9 G3 g$ ]; w2 e8 x
0071B933 |. 0FAFDA imul ebx,edx6 |- s9 B$ ]' Q' P
0071B936 |. 8B5424 10 mov edx,dword ptr ss:[esp+10]
4 j" o3 U; p% q" L0071B93A |. 894C24 20 mov dword ptr ss:[esp+20],ecx& ]& i1 \4 m4 u: _" u! z9 l
0071B93E |. 8D4C2D 00 lea ecx,dword ptr ss:[ebp+ebp]
f& }5 q' a7 k/ a, X; w0071B942 |. 035A 10 add ebx,dword ptr ds:[edx+10]
: a* s* T% H, e- z6 z& [' n' V0071B945 |. 8B5424 18 mov edx,dword ptr ss:[esp+18]
" ?( ^; p! D, |. d. K* P0071B949 |. 2BC1 sub eax,ecx; [! e$ A: C' F' Z# c
0071B94B |. 894424 24 mov dword ptr ss:[esp+24],eax
' J# I5 ?2 V6 T. ]# b4 Q! {0071B94F |. 03DF add ebx,edi3 }) v9 Q" E8 j9 r
0071B951 |. 8BC2 mov eax,edx
9 n( e" y n: I0071B953 |. 4A dec edx3 c1 ?: `! V$ p! W/ n4 s0 X
0071B954 |. 85C0 test eax,eax& X& V7 v% n/ Z/ f+ s
0071B956 |. 0F84 3A010000 je heroes4.0071BA968 z4 Y' @7 q3 j: e. F+ X
0071B95C |. 42 inc edx5 [ |: z1 \5 ]: l7 c& \0 y
0071B95D |. 895424 18 mov dword ptr ss:[esp+18],edx+ ^( O8 _' [0 H) r# p
0071B961 |> 85ED /test ebp,ebp" V- ?; c8 e q% i
0071B963 |. 0F84 0E010000 |je heroes4.0071BA773 ^8 i' j( g7 R6 H! w3 D$ \1 F
0071B969 |. 8B4424 74 |mov eax,dword ptr ss:[esp+74]
6 v Y5 t# ]8 v3 v2 g0071B96D |. 896C24 14 |mov dword ptr ss:[esp+14],ebp
% u" n9 ^9 ?: R# v9 j) y0071B971 |. 25 FFFF0000 |and eax,0FFFF
& W/ O. n' n7 I7 g) n/ b8 N B x0071B976 |. 894424 10 |mov dword ptr ss:[esp+10],eax
! e# G6 g! a8 @0071B97A |> 8A4424 78 |/mov al,byte ptr ss:[esp+78]" j. X) i1 n- y: I. b) T7 u3 |4 m2 E4 p
0071B97E |. 8B2D DCF0AA00 ||mov ebp,dword ptr ds:[AAF0DC]
]& K$ d- [2 H3 `# `8 }$ [- P0071B984 |. 84C0 ||test al,al7 l% p: ^' I6 l
0071B986 |. 74 6A ||je short heroes4.0071B9F2
3 M7 T9 ~2 w! R" W& L9 N y2 |, o+ \' w0071B988 |. 8A0B ||mov cl,byte ptr ds:[ebx] ; 取字模的像素点3 m! g f: F* \1 @- M: o
0071B98A |. 8B4424 7C ||mov eax,dword ptr ss:[esp+7C]* P9 v: @. `6 W/ T
0071B98E |. 83E1 0F ||and ecx,0F ; 取低四位# u1 r D( Q$ F9 o
0071B991 |. 25 FFFF0000 ||and eax,0FFFF
) O& V! ~1 }- K, |6 A0071B996 |. 8BF9 ||mov edi,ecx
' d( M- }# r( ^5 a5 g P; f0071B998 |. 33C9 ||xor ecx,ecx
3 I1 {5 U4 ~/ W0071B99A |. 66:8B0E ||mov cx,word ptr ds:[esi] ; 取缓冲区的原值1 Z& g: _9 r. @& k' |. o/ v3 \
0071B99D |. 85FF ||test edi,edi ; 检查字模的像素点低四位是否为0) ?: U o/ n) |* f# H8 K
0071B99F |. 74 54 ||je short heroes4.0071B9F5 ; 为0则不作处理! d/ z+ s% v* ~3 M) P
0071B9A1 |. 8BD7 ||mov edx,edi3 U0 ]" |( V1 `: @. y! K( k2 S
0071B9A3 |. 8BF1 ||mov esi,ecx0 o* e0 u8 ~: o7 i: q
0071B9A5 |. C1FA 03 ||sar edx,37 f! U! Q$ Y- E& U
0071B9A8 |. 83E2 01 ||and edx,10 `: l& c& n- h
0071B9AB |. 03FA ||add edi,edx
7 U' M6 c2 y1 K' [0071B9AD |. 8BD1 ||mov edx,ecx Z2 e; r1 @0 g* d* r" L
0071B9AF |. 8B0D 04F1AA00 ||mov ecx,dword ptr ds:[AAF104]
* V6 A1 n8 X+ a0 z& }& M0 o0071B9B5 |. 23D5 ||and edx,ebp
6 L3 i4 o' q6 u& s, v0071B9B7 |. 23F1 ||and esi,ecx# m" G! N4 G5 |6 M3 T2 M! J% W
0071B9B9 |. 8BC8 ||mov ecx,eax
4 u! p3 C0 k% s) f2 A0071B9BB |. 230D 04F1AA00 ||and ecx,dword ptr ds:[AAF104]7 d9 p7 |5 `8 n7 [! C& d% d; C
0071B9C1 |. 23C5 ||and eax,ebp9 b* Q( g3 i$ Q8 Y4 {
0071B9C3 |. 2BC2 ||sub eax,edx
$ @2 \0 w+ W. T4 p0071B9C5 |. 2BCE ||sub ecx,esi$ I8 i5 [! G: `5 g3 L) R+ @
0071B9C7 |. 0FAFC7 ||imul eax,edi' V5 Q7 |2 o) q! j' D! G8 v
0071B9CA |. 0FAFCF ||imul ecx,edi7 p4 c$ ?. B/ H) j( H6 P
0071B9CD |. C1E6 04 ||shl esi,4
* L) w5 O- o' g% U& H) C0071B9D0 |. 03CE ||add ecx,esi" a0 z3 H L/ a& ]
0071B9D2 |. 8B35 F4F0AA00 ||mov esi,dword ptr ds:[AAF0F4]
) k8 C; d* h2 B0071B9D8 |. C1E2 04 ||shl edx,45 L9 `/ j' |% Z! o( ~( D
0071B9DB |. 23CE ||and ecx,esi4 E; d. a4 v a* r$ q- {* p ]
0071B9DD |. 8B35 D8F0AA00 ||mov esi,dword ptr ds:[AAF0D8]
: L4 V: W f" d' n7 e0071B9E3 |. 03C2 ||add eax,edx: A# h9 ?! o6 l' ]$ V5 U4 K
0071B9E5 |. 23C6 ||and eax,esi4 b# E( S h/ n) M V! F
0071B9E7 |. 8B7424 68 ||mov esi,dword ptr ss:[esp+68]
2 K s4 V9 y$ ~0071B9EB |. 03C8 ||add ecx,eax) N/ l+ i" A" A4 f7 I
0071B9ED |. C1F9 04 ||sar ecx,4
1 ~. g9 y) B0 Q% @0071B9F0 |. EB 03 ||jmp short heroes4.0071B9F5
8 ~& p7 u" ^# {* J P, P2 h0071B9F2 |> 66:8B0E ||mov cx,word ptr ds:[esi]
6 c' @' z3 a* x, G5 A* |0071B9F5 |> 33D2 ||xor edx,edx3 V; S( N7 ~9 ~: |( c
0071B9F7 |. 81E1 FFFF0000 ||and ecx,0FFFF: M$ j) }8 X' s7 E2 \
0071B9FD |. 8A13 ||mov dl,byte ptr ds:[ebx]
4 B% |5 P$ R' A" p5 R0071B9FF |. 8BC1 ||mov eax,ecx
0 r4 h/ R7 E- K- R3 y0071BA01 |. C1EA 04 ||shr edx,4 ; 取高四位, ~- W# M; T8 ]( R) L9 Z
0071BA04 |. 85D2 ||test edx,edx ; 检查字模的像素点高四位是否为0
1 _- P" c1 @& z8 s6 E* t; E0071BA06 |. 74 51 ||je short heroes4.0071BA59 ; 为0则不作处理
9 K2 D9 ?2 E3 j0 S; i4 ]) [. @0071BA08 |. 8BCA ||mov ecx,edx
; }" x8 ?$ l; Z% C( u( @0071BA0A |. 8BF0 ||mov esi,eax
9 Y* t x! N/ R0071BA0C |. C1F9 03 ||sar ecx,3
4 S/ n, o h4 M z0071BA0F |. 83E1 01 ||and ecx,1
2 O9 W/ Q, J6 x& p0071BA12 |. 23F5 ||and esi,ebp
$ R& |6 P* W; _0 `0071BA14 |. 03D1 ||add edx,ecx
' F6 {/ R( S$ O9 e0071BA16 |. 8BC8 ||mov ecx,eax
8 }! `* g: E9 m2 {0071BA18 |. 8B4424 10 ||mov eax,dword ptr ss:[esp+10]
# E! B0 m+ L5 _1 s- z, o$ J0 Y' J; }0071BA1C |. 8B3D 04F1AA00 ||mov edi,dword ptr ds:[AAF104]
( ~4 _6 w+ Y! P/ }, T' P- T! _0071BA22 |. 23C5 ||and eax,ebp* n) R( _# Y" L) H9 b# t, ~ o
0071BA24 |. 23CF ||and ecx,edi
8 H7 F) q' j) h' y% T% j0071BA26 |. 2BC6 ||sub eax,esi
6 j! t: |, v. ?0071BA28 |. 0FAFC2 ||imul eax,edx
. }, v2 ~3 V( q" s, y! O0071BA2B |. C1E6 04 ||shl esi,4
# z. D! J0 [6 B0071BA2E |. 03C6 ||add eax,esi
# |7 ?1 |. q$ ]* l! `0071BA30 |. 8B35 D8F0AA00 ||mov esi,dword ptr ds:[AAF0D8]
4 l+ {+ b' [1 a% N3 j" A0071BA36 |. 23C6 ||and eax,esi
$ F4 f6 U: e# s1 q8 G, o0071BA38 |. 8B7424 10 ||mov esi,dword ptr ss:[esp+10]8 M1 H- s- T9 x3 P7 o
0071BA3C |. 23F7 ||and esi,edi1 a' n" \. j' t9 x5 k2 Y
0071BA3E |. 8B3D F4F0AA00 ||mov edi,dword ptr ds:[AAF0F4]
5 s& M3 I( L$ z U* r# Y) V0071BA44 |. 2BF1 ||sub esi,ecx
' ^+ `3 g9 M) ~6 { E; v0071BA46 |. 0FAFF2 ||imul esi,edx8 \) T0 d$ }" O% @& _4 I& o7 g
0071BA49 |. C1E1 04 ||shl ecx,4% K" T' Y5 Y9 o" O5 u) u5 ?2 B
0071BA4C |. 03F1 ||add esi,ecx
. D7 E" \% z2 P% w+ D7 m) C+ c4 k8 q0071BA4E |. 23F7 ||and esi,edi
* @4 k/ O* ^% ^0071BA50 |. 03C6 ||add eax,esi
% R6 N" h2 a+ F6 J# Z6 V' `1 F( V0071BA52 |. 8B7424 68 ||mov esi,dword ptr ss:[esp+68]9 @# x* W8 G& N1 U
0071BA56 |. C1F8 04 ||sar eax,42 X- Y" Q0 f' z8 v- [. Z' d9 s7 x
0071BA59 |> 66:8906 ||mov word ptr ds:[esi],ax ; 将经过处理后的缓冲区值放回原处# a* t& G" X+ C
0071BA5C |. 8B4424 14 ||mov eax,dword ptr ss:[esp+14]$ G* |" X( |% O4 {- j3 ]5 E$ G, q
0071BA60 |. 43 ||inc ebx ; 指向字模的下个像素点
1 \6 v9 l1 v6 d5 w/ o0 F c) c0071BA61 |. 83C6 02 ||add esi,2 ; 指向缓冲区的下个点
- N9 _! A9 P. ~) q0071BA64 |. 48 ||dec eax ; 计数值减12 B8 n# @; ^. q5 l0 Y
0071BA65 |. 897424 68 ||mov dword ptr ss:[esp+68],esi2 A, E. i) R) P
0071BA69 |. 894424 14 ||mov dword ptr ss:[esp+14],eax
J6 l# H/ h5 `. N) {0071BA6D |.^ 0F85 07FFFFFF |\jnz heroes4.0071B97A- v/ \& U1 Q( E# Y- [% k) U
0071BA73 |. 8B6C24 1C |mov ebp,dword ptr ss:[esp+1C]3 t; w' {: F( Y2 V" h
0071BA77 |> 8B5424 20 |mov edx,dword ptr ss:[esp+20]
1 Z t# j G0 g: p/ _/ k. ^ L3 D0071BA7B |. 8B4C24 24 |mov ecx,dword ptr ss:[esp+24]1 h R. ~! z, ~: U4 i; v
0071BA7F |. 8B4424 18 |mov eax,dword ptr ss:[esp+18]' A, ~! E" ^/ c; M' V! v- \7 h: e
0071BA83 |. 03DA |add ebx,edx ; 指向字模的下行像素点5 y2 A2 s, L9 v% n# a2 f8 X( Z5 Q
0071BA85 |. 03F1 |add esi,ecx ; 指向缓冲区的下行点
- W- O: } t. Q* X0071BA87 |. 48 |dec eax ; 计数值减1. y! O% Z% }/ G+ z6 f5 E4 M
0071BA88 |. 897424 68 |mov dword ptr ss:[esp+68],esi1 b: `+ K( l6 [0 x5 Q5 a
0071BA8C |. 894424 18 |mov dword ptr ss:[esp+18],eax: h- b* u$ t. w
0071BA90 |.^ 0F85 CBFEFFFF \jnz heroes4.0071B9619 g' J# o2 j" r/ ?1 u7 o
0071BA96 |> 5F pop edi
8 \2 N+ H( f2 m+ Z0071BA97 |. 5E pop esi! a2 R4 Z' p! d; w7 [& L
0071BA98 |. 5D pop ebp5 a! G* P: t& N/ B9 q
0071BA99 |. 5B pop ebx
% S, \7 c: F0 \0 h0071BA9A |. 83C4 54 add esp,540 _7 _' z b) [( [7 e; E2 h
0071BA9D \. C2 1800 retn 181 h" b! Z7 ~" B9 M- f* `' |
本函数的核心是两层循环,从71B9A1开始就是循环体,整个换算过程是一个比较复杂的算法,可以简单表示为:9 k4 i: r g! y4 R; T) I3 w* ^
2 b5 v' l0 r; s) A1 }+ z
buf[x][y]=func(buf[x][y],zm[x/2][y/2])
+ b( c( i, W5 F2 _
' N# s5 t" @ [0 ^$ S7 U5 `buf:缓冲区二维数组,两个字节表示一个点3 A# X$ I; D' @/ _( t8 o* _" Y- A
zm:字模二维数组,一个字节表示一个点 |