Function at 0x408d70
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x58
push ebx
push ebp
push esi
push edi
push 0
push 0
push 0
push 0
mov edi, eax
call dword [sym.imp.GDI32.dll_CreateRectRgn]
push eax
mov dword [esp + 0x38], eax
mov eax, dword [esp + 0x78]
push eax
call dword [sym.imp.USER32.dll_GetWindowRgn]
mov ecx, dword [esp + 0x6c]
movsx eax, byte [ecx + 0x15]
mov esi, dword [edi + 8]
sub esi, dword [edi]
mov ebx, dword [edi + 0xc]
sub ebx, dword [edi + 4]
add eax, eax
lea edx, [eax + esi]
add eax, ebx
cmp ebx, eax
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x50], edx
mov dword [esp + 0x54], eax
jle 0x408dc9
mov edi, ebx
mov dword [esp + 0x30], edi
jmp 0x408dcf
mov edi, eax
mov dword [esp + 0x30], eax
xor ecx, ecx
lea ebp, [edi + 2]
mov eax, ebp
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
xor eax, eax
mov dword [esp + 0x74], eax
mov eax, ecx
mov ecx, 4
mul ecx
mov ecx, dword [esp + 0x74]
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0049abdb
xor ecx, ecx
mov ebp, eax
mov dword [esp + 0x18], eax
mov eax, ebx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
xor eax, eax
mov dword [esp + 0x78], eax
mov eax, ecx
mov ecx, 4
mul ecx
mov ecx, dword [esp + 0x78]
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0049abdb
xor edx, edx
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x74]
mov dword [ebp], esi
mov dword [ebp + 4], edx
mov dword [ebp + edi*8 + 8], esi
mov dword [ebp + edi*8 + 0xc], edx
mov al, byte [eax + 0x15]
add esp, 8
test al, al
jle 0x408ea2
xor edi, edi
test al, al
jle 0x408e92
mov ecx, dword [esp + 0x54]
lea eax, [ebp + 0xc]
lea ecx, [ebp + ecx*8]
jmp 0x408e73
xor edx, edx
mov dword [eax], edx
mov dword [eax - 4], esi
mov dword [ecx + 4], edx
mov edx, dword [esp + 0x6c]
mov dword [ecx], esi
movsx edx, byte [edx + 0x15]
inc edi
add eax, 8
sub ecx, 8
cmp edi, edx
jl 0x408e71
xor edx, edx
mov eax, dword [esp + 0x6c]
movsx ecx, byte [eax + 0x15]
lea ebp, [ebp + ecx*8]
mov dword [esp + 0x14], ebp
cmp ebx, edx
mov dword [esp + 0x1c], edx
jle 0x408f63
mov edx, dword [esp + 0x24]
add edx, 4
mov dword [esp + 0x74], edx
lea ebx, [ebp + 8]
lea esp, [esp]
xor edi, edi
test esi, esi
jle 0x408f01
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x34]
push eax
push edi
push ecx
call dword [sym.imp.GDI32.dll_PtInRegion]
test eax, eax
jne 0x408eea
inc edi
cmp edi, esi
jl 0x408ec6
mov edx, dword [esp + 0x74]
mov dword [ebx], esi
mov dword [edx], eax
jmp 0x408f48
mov edx, dword [esp + 0x6c]
movsx eax, byte [edx + 0x15]
mov ecx, dword [esp + 0x74]
add eax, edi
cmp edi, esi
mov dword [ebx], eax
mov dword [ecx - 4], edi
jl 0x408f0f
mov edx, dword [esp + 0x74]
mov dword [ebx], esi
mov dword [edx], 0
jmp 0x408f48
lea edi, [esi - 1]
cmp edi, dword [ebx]
jl 0x408f48
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x34]
push eax
push edi
push ecx
call dword [sym.imp.GDI32.dll_PtInRegion]
test eax, eax
jne 0x408f32
dec edi
cmp edi, dword [ebx]
jge 0x408f16
jmp 0x408f48
mov edx, dword [esp + 0x6c]
movsx eax, byte [edx + 0x15]
mov edx, dword [esp + 0x74]
lea ecx, [eax + edi + 1]
inc edi
mov dword [ebx + 4], ecx
mov dword [edx], edi
mov eax, dword [esp + 0x1c]
add dword [esp + 0x74], 8
inc eax
add ebx, 8
cmp eax, dword [esp + 0x5c]
mov dword [esp + 0x1c], eax
jl 0x408ec0
mov eax, dword [esp + 0x6c]
mov al, byte [eax + 0x15]
test al, al
jle 0x408f7b
movsx ecx, al
neg ecx
lea ebp, [ebp + ecx*8]
mov dword [esp + 0x14], ebp
mov ebx, dword [esp + 0x30]
xor ecx, ecx
lea edi, [ebx + 2]
mov eax, edi
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
xor eax, eax
mov dword [esp + 0x74], eax
mov eax, ecx
mov ecx, 4
mul ecx
mov ecx, dword [esp + 0x74]
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0049abdb
mov edi, eax
mov dword [esp + 0x48], eax
xor eax, eax
mov dword [edi + 4], eax
mov dword [edi], esi
mov dword [edi + ebx*8 + 0xc], eax
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x70]
mov dword [edi + ebx*8 + 8], esi
movsx edx, byte [eax + 0x15]
movzx eax, byte [eax + 0x14]
sub eax, edx
add esp, 4
test eax, eax
jle 0x409083
lea ecx, [ebx + 1]
mov dword [esp + 0x44], ecx
lea ecx, [ecx]
mov esi, 1
cmp ecx, esi
jle 0x409056
lea eax, [ebp + 0x10]
lea esp, [esp]
mov ecx, dword [eax - 8]
mov edx, dword [eax]
cmp ecx, edx
mov ebp, ecx
jg 0x40900d
mov ebp, edx
mov ebx, dword [eax - 0x10]
cmp ebx, ebp
jle 0x409018
mov ecx, ebx
jmp 0x40901e
cmp ecx, edx
jg 0x40901e
mov ecx, edx
inc ecx
mov dword [edi + esi*8], ecx
mov edx, dword [eax - 4]
mov ecx, dword [eax + 4]
cmp edx, ecx
mov ebp, edx
jl 0x409030
mov ebp, ecx
mov ebx, dword [eax - 0xc]
cmp ebx, ebp
jge 0x40903b
mov ecx, ebx
jmp 0x409041
cmp edx, ecx
jge 0x409041
mov ecx, edx
dec ecx
mov dword [edi + esi*8 + 4], ecx
mov ecx, dword [esp + 0x44]
inc esi
add eax, 8
cmp esi, ecx
jl 0x409000
mov ebp, dword [esp + 0x14]
mov edx, dword [esp + 0x6c]
movsx esi, byte [edx + 0x15]
movzx edx, byte [edx + 0x14]
mov eax, edi
mov edi, ebp
mov ebp, eax
mov eax, dword [esp + 0x74]
inc eax
sub edx, esi
cmp eax, edx
mov dword [esp + 0x14], ebp
mov dword [esp + 0x74], eax
jl 0x408ff0
mov dword [esp + 0x44], edi
mov edx, dword [esp + 0x6c]
mov cl, byte [edx + 0x15]
test cl, cl
jge 0x409095
movsx eax, cl
neg eax
jmp 0x409097
xor eax, eax
lea eax, [ebp + eax*8 + 8]
mov dword [esp + 0x14], eax
movsx eax, cl
movzx ecx, byte [edx + 0x14]
cmp eax, ecx
jle 0x4090b2
mov edx, eax
mov dword [esp + 0x10], edx
jmp 0x4090b8
mov edx, ecx
mov dword [esp + 0x10], ecx
cmp eax, ecx
jle 0x4090c4
sub eax, ecx
mov dword [esp + 0x2c], eax
jmp 0x4090cc
mov dword [esp + 0x2c], 0
lea esi, [edx + edx]
lea eax, [esi + 1]
imul eax, eax
xor ecx, ecx
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0049abdb
add esp, 4
mov dword [esp + 0x30], eax
mov edi, eax
test esi, esi
jl 0x4092cd
mov ecx, dword [esp + 0x10]
mov eax, ecx
neg eax
mov dword [esp + 0x1c], eax
lea eax, [ecx + ecx]
inc eax
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x10]
add eax, eax
js 0x4092ba
mov eax, dword [esp + 0x1c]
mov ebp, dword [esp + 0x6c]
mov ecx, eax
imul ecx, eax
mov dword [esp + 0x74], ecx
mov ecx, dword [esp + 0x10]
mov eax, ecx
fild dword [esp + 0x74]
neg eax
mov dword [esp + 0x20], eax
lea eax, [ecx + ecx]
fstp qword [esp + 0x48]
inc eax
fild dword [esp + 0x2c]
mov dword [esp + 0x28], eax
fstp qword [esp + 0x60]
fild dword [esp + 0x20]
fmul st(0), st(0)
fadd qword [esp + 0x48]
call fcn.00729510
fld qword [esp + 0x60]
fcom st(1)
fnstsw ax
test ah, 0x41
jne 0x4091df
mov ecx, dword [ebp + 0x20]
fstp st(1)
mov bl, byte [ebp + 0x13]
fstp st(0)
mov edx, ecx
shr edx, 0x10
movzx edx, dl
movzx esi, bl
imul edx, esi
mov eax, 0x80808081
mul edx
shr edx, 7
mov eax, edx
movzx edx, bl
shl edx, 8
or eax, edx
mov edx, ecx
shr edx, 8
movzx edx, dl
imul edx, esi
shl eax, 8
mov dword [esp + 0x74], eax
mov eax, 0x80808081
mul edx
mov eax, dword [esp + 0x74]
movzx ecx, cl
shr edx, 7
imul ecx, esi
or eax, edx
shl eax, 8
mov dword [esp + 0x74], eax
mov eax, 0x80808081
mul ecx
mov eax, dword [esp + 0x74]
shr edx, 7
or eax, edx
mov dword [edi], eax
jmp 0x4092a4
fild dword [esp + 0x10]
fcomp st(2)
fnstsw ax
test ah, 1
jne 0x40929a
movzx edx, byte [ebp + 0x14]
fsubp st(1)
inc edx
mov dword [esp + 0x74], edx
movzx eax, byte [ebp + 0x13]
fild dword [esp + 0x74]
mov dword [esp + 0x74], eax
mov ebx, dword [ebp + 0x20]
fdivp st(1)
mov edx, ebx
shr edx, 0x10
movzx edx, dl
fld1
fsubrp st(1)
fild dword [esp + 0x74]
fnstcw word [esp + 0x74]
fmulp st(1)
movzx eax, word [esp + 0x74]
or eax, 0xc00
mov dword [esp + 0x38], eax
mov eax, 0x80808081
fldcw word [esp + 0x38]
fistp qword [esp + 0x38]
mov ecx, dword [esp + 0x38]
movzx esi, cl
shl ecx, 8
imul edx, esi
fldcw word [esp + 0x74]
mul edx
shr edx, 7
mov eax, edx
or eax, ecx
mov ecx, ebx
shr ecx, 8
movzx edx, cl
imul edx, esi
shl eax, 8
mov dword [esp + 0x74], eax
mov eax, 0x80808081
mul edx
mov eax, dword [esp + 0x74]
movzx ecx, bl
shr edx, 7
imul ecx, esi
or eax, edx
shl eax, 8
mov dword [esp + 0x74], eax
mov eax, 0x80808081
mul ecx
mov eax, dword [esp + 0x74]
shr edx, 7
or eax, edx
mov dword [edi], eax
jmp 0x4092a4
fstp st(1)
mov dword [edi], 0
fstp st(0)
mov eax, 1
add dword [esp + 0x20], eax
add edi, 4
sub dword [esp + 0x28], eax
jne 0x409151
mov eax, 1
add dword [esp + 0x1c], eax
sub dword [esp + 0x18], eax
jne 0x409110
mov ebp, dword [esp + 0x54]
mov esi, dword [esp + 0x10]
mov eax, ebp
sub eax, esi
cmp esi, eax
mov dword [esp + 0x48], eax
jge 0x409497
mov edx, dword [esp + 0x14]
lea ecx, [edx + esi*8 - 4]
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0x50]
lea edx, [ebp*4 - 4]
imul edx, ecx
neg ecx
add ecx, ecx
add ecx, ecx
sub eax, esi
mov dword [esp + 0x20], edx
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x38], eax
mov eax, dword [esp + 0x18]
mov edx, dword [eax + 4]
cmp edx, dword [eax + 8]
jge 0x409475
mov edi, eax
mov ebx, dword [edi + 4]
mov eax, ebx
sub eax, dword [esp + 0x10]
mov dword [esp + 0x74], ebx
add eax, eax
add eax, eax
mov dword [esp + 0x28], eax
lea ebx, [ebx]
mov eax, dword [edi - 4]
mov ecx, dword [edi + 0xc]
cmp eax, ecx
mov esi, eax
jg 0x40934e
mov esi, ecx
mov edx, dword [edi + 8]
inc esi
cmp esi, edx
jge 0x40935f
cmp eax, ecx
jg 0x40935c
mov eax, ecx
lea edx, [eax + 1]
cmp ebx, edx
jge 0x4093d4
mov eax, dword [esp + 0x10]
add eax, eax
js 0x4093be
mov edx, dword [esp + 0x28]
mov ebx, dword [esp + 0x30]
lea ecx, [eax*4 + 4]
mov dword [esp + 0x2c], ecx
mov ecx, dword [esp + 0x20]
add ecx, edx
add ecx, dword [esp + 0x70]
lea ebp, [eax + 1]
jmp 0x409390
mov edi, dword [esp + 0x10]
add edi, edi
mov eax, ecx
js 0x4093b1
mov esi, ebx
sub esi, ecx
inc edi
nop
mov edx, dword [esi + eax]
cmp dword [eax], edx
jae 0x4093a9
mov dword [eax], edx
add eax, 4
sub edi, 1
jne 0x4093a0
add ebx, dword [esp + 0x2c]
add ecx, dword [esp + 0x1c]
sub ebp, 1
jne 0x409390
inc dword [esp + 0x74]
add dword [esp + 0x28], 4
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x74]
jmp 0x409340
mov eax, dword [edi]
mov ecx, dword [edi + 0x10]
cmp eax, ecx
mov edx, eax
jl 0x4093e1
mov edx, ecx
dec edx
cmp ebx, edx
jg 0x4093f3
cmp eax, ecx
jl 0x4093ec
mov eax, ecx
lea ebx, [eax - 1]
mov dword [esp + 0x74], ebx
cmp ebx, dword [edi + 8]
jge 0x409475
mov eax, dword [esp + 0x74]
sub eax, dword [esp + 0x10]
add eax, eax
add eax, eax
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x10]
add eax, eax
js 0x40945e
mov ecx, dword [esp + 0x20]
mov ebx, dword [esp + 0x30]
lea edx, [eax*4 + 4]
mov dword [esp + 0x2c], edx
mov edx, dword [esp + 0x28]
add ecx, edx
add ecx, dword [esp + 0x70]
lea ebp, [eax + 1]
mov edi, dword [esp + 0x10]
add edi, edi
mov eax, ecx
js 0x409451
mov esi, ebx
sub esi, ecx
inc edi
nop
mov edx, dword [esi + eax]
cmp dword [eax], edx
jae 0x409449
mov dword [eax], edx
add eax, 4
sub edi, 1
jne 0x409440
add ebx, dword [esp + 0x2c]
add ecx, dword [esp + 0x1c]
sub ebp, 1
jne 0x409430
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x18]
add dword [esp + 0x28], 4
inc eax
cmp eax, dword [ecx + 8]
mov dword [esp + 0x74], eax
jl 0x409408
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
add dword [esp + 0x20], eax
add edx, 8
sub dword [esp + 0x38], 1
mov dword [esp + 0x18], edx
jne 0x409313
mov ebp, dword [esp + 0x54]
mov esi, dword [esp + 0x6c]
mov ecx, dword [esi + 0x20]
mov al, byte [esi + 0x13]
movzx edi, al
mov edx, ecx
shr edx, 0x10
movzx edx, dl
imul edx, edi
mov eax, 0x80808081
mul edx
movzx eax, byte [esi + 0x13]
shr edx, 7
mov ebx, edx
mov edx, ecx
shr edx, 8
movzx edx, dl
imul edx, edi
shl eax, 8
or ebx, eax
mov eax, 0x80808081
mul edx
movzx ecx, cl
imul ecx, edi
shr edx, 7
shl ebx, 8
or ebx, edx
mov eax, 0x80808081
mul ecx
movsx eax, byte [esi + 0x15]
mov ecx, dword [esp + 0x10]
shr edx, 7
shl ebx, 8
or ebx, edx
movsx edx, byte [esi + 0x17]
sub eax, edx
xor edx, edx
test eax, eax
setle dl
mov dword [esp + 0x74], ebx
dec edx
and edx, eax
cmp ecx, edx
jl 0x40951d
xor ecx, ecx
test eax, eax
setle cl
dec ecx
and ecx, eax
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x50]
lea edi, [eax + ecx*8 + 4]
mov eax, edx
neg eax
add eax, eax
sub ebp, ecx
add eax, eax
dec ebp
imul ebp, edx
mov edx, dword [esp + 0x70]
mov dword [esp + 0x1c], eax
lea eax, [edx + ebp*4]
mov dword [esp + 0x70], eax
movsx edx, byte [esi + 0x15]
movsx eax, byte [esi + 0x17]
mov ebp, dword [esp + 0x5c]
mov esi, edx
sub esi, eax
add esi, ebp
lea edx, [ebp + edx*2]
cmp esi, edx
mov edx, dword [esp + 0x6c]
movsx esi, byte [edx + 0x15]
mov dword [esp + 0x2c], edi
jge 0x409574
mov edx, esi
sub edx, eax
add edx, ebp
jmp 0x409578
lea edx, [ebp + esi*2]
mov ebp, dword [esp + 0x48]
cmp ebp, edx
jle 0x409584
mov edx, ebp
jmp 0x4095ac
mov edx, dword [esp + 0x6c]
movsx edx, byte [edx + 0x15]
mov ebx, dword [esp + 0x5c]
mov ebp, edx
sub ebp, eax
add ebp, ebx
lea edx, [ebx + edx*2]
cmp ebp, edx
jge 0x4095a5
mov edx, esi
sub edx, eax
add edx, ebx
jmp 0x4095a8
lea edx, [ebx + esi*2]
mov ebx, dword [esp + 0x74]
cmp ecx, edx
mov ebp, dword [esp + 0x24]
jge 0x409745
sub eax, esi
add eax, ecx
js 0x40971d
cmp eax, dword [esp + 0x5c]
jge 0x40971d
mov eax, dword [edi - 4]
mov dword [esp + 0x38], eax
mov esi, dword [esp + 0x6c]
movsx eax, byte [esi + 0x17]
movsx edx, byte [esi + 0x15]
movsx esi, byte [esi + 0x16]
mov edi, dword [edi]
mov ebx, eax
sub ebx, edx
add ebx, ecx
mov ebx, dword [ebp + ebx*8]
sub ebx, esi
add ebx, edx
cmp ebx, edi
mov ebx, dword [esp + 0x6c]
jge 0x40960d
movsx edx, byte [ebx + 0x15]
sub eax, edx
add eax, ecx
mov eax, dword [ebp + eax*8]
sub eax, esi
add eax, edx
jmp 0x40960f
mov eax, edi
mov edx, dword [esp + 0x38]
cmp edx, eax
jge 0x40962d
mov eax, dword [esp + 0x74]
mov esi, dword [esp + 0x70]
mov edi, dword [esp + 0x2c]
mov dword [esi + edx*4], eax
inc edx
mov dword [esp + 0x38], edx
jmp 0x4095d3
movsx eax, byte [ebx + 0x17]
movsx edx, byte [ebx + 0x15]
movsx esi, byte [ebx + 0x16]
mov edi, eax
sub edi, edx
add edi, ecx
mov edi, dword [ebp + edi*8]
sub edi, esi
add edi, edx
test edi, edi
jle 0x40965d
movsx edx, byte [ebx + 0x15]
sub eax, edx
add eax, ecx
mov edi, dword [ebp + eax*8]
sub edi, esi
add edi, edx
jmp 0x409660
xor edi, edi
nop
movsx eax, byte [ebx + 0x17]
movsx edx, byte [ebx + 0x15]
movsx esi, byte [ebx + 0x16]
mov ebx, eax
sub ebx, edx
add ebx, ecx
mov ebx, dword [ebp + ebx*8 + 4]
sub ebx, esi
add ebx, edx
mov edx, dword [esp + 0x50]
cmp ebx, edx
mov ebx, dword [esp + 0x6c]
jge 0x409698
movsx edx, byte [ebx + 0x15]
sub eax, edx
add eax, ecx
mov eax, dword [ebp + eax*8 + 4]
sub eax, esi
add eax, edx
jmp 0x40969a
mov eax, edx
cmp edi, eax
jge 0x4096b0
mov edx, dword [esp + 0x70]
mov ebx, dword [esp + 0x6c]
mov dword [edx + edi*4], 0
inc edi
jmp 0x409660
movsx esi, byte [ebx + 0x16]
movsx edx, byte [ebx + 0x17]
movsx eax, byte [ebx + 0x15]
mov edi, dword [esp + 0x2c]
mov dword [esp + 0x38], esi
mov esi, edx
sub esi, eax
movsx eax, byte [ebx + 0x15]
add esi, ecx
mov esi, dword [ebp + esi*8 + 4]
sub esi, dword [esp + 0x38]
add esi, eax
mov eax, dword [edi - 4]
cmp esi, eax
jle 0x4096f1
movsx esi, byte [ebx + 0x15]
sub edx, esi
add edx, ecx
mov eax, dword [ebp + edx*8 + 4]
sub eax, dword [esp + 0x38]
add eax, esi
cmp eax, dword [edi]
mov ebx, dword [esp + 0x74]
mov edx, dword [esp + 0x70]
jge 0x409730
lea ecx, [ecx]
mov dword [edx + eax*4], ebx
inc eax
cmp eax, dword [edi]
jl 0x409700
add edx, dword [esp + 0x1c]
mov esi, dword [esp + 0x6c]
inc ecx
mov dword [esp + 0x70], edx
add edi, 8
jmp 0x409546
mov eax, dword [edi - 4]
cmp eax, dword [edi]
mov edx, dword [esp + 0x70]
jge 0x409730
mov dword [edx + eax*4], ebx
inc eax
cmp eax, dword [edi]
jl 0x409728
add edx, dword [esp + 0x1c]
mov esi, dword [esp + 0x6c]
inc ecx
mov dword [esp + 0x70], edx
add edi, 8
jmp 0x409546
mov eax, dword [esp + 0x6c]
mov al, byte [eax + 0x15]
test al, al
jge 0x409757
movsx eax, al
neg eax
jmp 0x409759
xor eax, eax
lea ecx, [eax*8 + 8]
mov eax, dword [esp + 0x14]
sub eax, ecx
push eax
call fcn.00563af8
mov edx, dword [esp + 0x48]
push edx
call fcn.00563af8
push ebp
call fcn.00563af8
mov eax, dword [esp + 0x3c]
push eax
call fcn.00563af8
mov ecx, dword [esp + 0x44]
add esp, 0x10
push ecx
call dword [sym.imp.GDI32.dll_DeleteObject]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x58
ret 0xc