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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x410abb
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x49c
push ebx
push esi
push edi
lea ecx, [ebp + 0xc]
call sub.MFC42.DLL_CRect::NormalizeRect
lea ecx, [esp + 0x54]
call sym.Player.exe_public:_void___thiscall_CTPImage::constructor_void_
mov eax, dword [ebp + 0x18]
mov ebx, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x14]
mov esi, dword [ebp + 0xc]
sub eax, ebx
sub ecx, esi
push eax
push ecx
lea ecx, [esp + 0x5c]
mov dword [esp + 0x4b8], 0
call sym.Player.exe_public:_long_int___thiscall_CTPImage::Create_unsigned_int__unsigned_int_
test eax, eax
jne 0x401897
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 0x1c]
mov ebx, dword [ebp + 0x24]
mov eax, dword [ebp + 0x10]
mov esi, dword [ebp + 0x20]
mov edi, dword [ebp + 0x34]
neg ecx
add edx, ecx
add ebx, ecx
mov ecx, dword [ebp + 0x28]
mov dword [ebp + 0x1c], edx
neg eax
add ecx, eax
add esi, eax
mov dword [ebp + 0x28], ecx
mov ecx, dword [ebp + 0x30]
mov eax, ecx
mov dword [ebp + 0x20], esi
shr eax, 8
mov byte [esp + 0x1d], al
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x1c], al
mov eax, edi
shr eax, 8
mov byte [esp + 0x15], al
mov eax, edi
shr eax, 0x10
mov byte [esp + 0x14], al
mov eax, esi
mov esi, dword [ebp + 0x28]
sub edx, ebx
sub eax, esi
mov esi, edx
imul esi, edx
mov edx, eax
mov dword [ebp + 0x24], ebx
imul edx, eax
add esi, edx
mov dword [esp + 0x34], esi
fild dword [esp + 0x34]
fsqrt
fst qword [esp + 0x24]
fabs
fcomp qword [0x412340]
fnstsw ax
test ah, 1
je 0x401579
mov dword [esp + 0x24], 0x88e368f1
mov dword [esp + 0x28], 0x3ee4f8b5
mov eax, edi
mov edi, dword [esp + 0x14]
mov edx, dword [esp + 0x15]
and edi, 0xff
mov dword [esp + 0x3c], edi
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x5c]
and edi, 0xff
mov dword [esp + 0x14], edi
mov edi, dword [esp + 0x1d]
xor ebx, ebx
and eax, 0xff
and edx, 0xff
and edi, 0xff
and ecx, 0xff
mov dword [esp + 0x10], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0xc], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x6c], eax
mov dword [esp + 0x4c], edx
mov dword [esp + 0x1c], edi
mov dword [esp + 0x44], ecx
lea ebx, [esp + 0xa5]
jmp 0x4015ed
mov eax, dword [esp + 0x6c]
mov edx, dword [esp + 0x4c]
mov ecx, dword [esp + 0x10]
mov edi, pe_nt_image_headers32
sub edi, ecx
mov ecx, dword [esp + 0x30]
imul eax, edi
imul edx, edi
add eax, ecx
mov ecx, dword [esp + 0xc]
add edx, ecx
mov ecx, dword [esp + 0x3c]
imul ecx, edi
mov edi, dword [esp + 0x34]
add ecx, edi
shr eax, 8
shr edx, 8
shr ecx, 8
cmp eax, 0xfd
jle 0x40162c
mov eax, 0xfd
cmp edx, 0xfd
jle 0x401639
mov edx, 0xfd
cmp ecx, 0xfd
jle 0x401646
mov ecx, 0xfd
cmp eax, 2
jge 0x401650
mov eax, 2
cmp edx, 2
jge 0x40165a
mov edx, 2
cmp ecx, 2
jge 0x401664
mov ecx, 2
mov byte [ebx + 1], al
mov byte [ebx], dl
mov edx, dword [esp + 0x30]
mov byte [ebx - 1], cl
mov ecx, dword [esp + 0x44]
mov eax, dword [esp + 0x10]
add edx, ecx
mov ecx, dword [esp + 0xc]
mov dword [esp + 0x30], edx
mov edx, dword [esp + 0x1c]
add ecx, edx
inc eax
mov dword [esp + 0xc], ecx
mov ecx, dword [esp + 0x14]
add edi, ecx
add ebx, 4
cmp eax, 0x101
mov dword [esp + 0x10], eax
mov dword [esp + 0x34], edi
jb 0x4015e5
mov ebx, dword [esp + 0x64]
mov edx, dword [esp + 0x60]
xor eax, eax
test ebx, ebx
mov dword [esp + 0x10], eax
jbe 0x40180a
xor edi, edi
test edx, edx
mov dword [esp + 0xc], edi
jbe 0x4017fd
mov edx, dword [ebp + 0x20]
mov ecx, eax
fld qword [esp + 0x24]
fmul qword [esp + 0x24]
sub ecx, edx
mov edx, eax
mov eax, dword [ebp + 0x28]
imul ecx, ecx
fstp qword [esp + 0x6c]
fld qword [esp + 0x24]
fadd st(0), st(0)
fstp qword [esp + 0x34]
sub edx, eax
mov dword [esp + 0x1c], ecx
imul edx, edx
mov dword [esp + 0x14], edx
jmp 0x40170d
mov edx, dword [esp + 0x14]
mov edi, dword [esp + 0xc]
mov ecx, dword [esp + 0x1c]
mov ebx, dword [ebp + 0x1c]
mov eax, edi
sub eax, ebx
mov ebx, eax
imul ebx, eax
add ebx, ecx
mov ecx, dword [ebp + 0x24]
mov eax, edi
mov dword [esp + 0x44], ebx
sub eax, ecx
xor ebx, ebx
mov ecx, eax
mov dword [esp + 0x48], ebx
imul ecx, eax
fild qword [esp + 0x44]
add ecx, edx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x3c], ecx
mov eax, dword [ebp + 0x2c]
fild qword [esp + 0x3c]
fld qword [esp + 0x6c]
fadd st(2)
cmp eax, ebx
fsub st(1)
fdiv qword [esp + 0x34]
fstp qword [esp + 0x4c]
fstp st(0)
je 0x40177c
fstp st(0)
fld qword [esp + 0x4c]
fcomp qword [0x412338]
fnstsw ax
test ah, 0x41
jne 0x401775
fld qword [esp + 0x4c]
jmp 0x40177e
mov edi, 0xff
jmp 0x40179b
fsqrt
fmul qword [0x412330]
fdiv qword [esp + 0x24]
fsubr qword [0x412330]
call sub.MSVCRT.dll__ftol
mov edi, eax
cmp edi, ebx
jge 0x40179b
xor edi, edi
call dword [sym.imp.MSVCRT.dll_rand]
and eax, 0x80000003
jns 0x4017ad
dec eax
or eax, 0xfffffffc
inc eax
xor ecx, ecx
xor edx, edx
mov cl, byte [esp + edi*4 + 0xa6]
mov dl, byte [esp + edi*4 + 0xa5]
xor ebx, ebx
sub eax, 2
mov bl, byte [esp + edi*4 + 0xa4]
add ecx, eax
add edx, eax
add ebx, eax
mov eax, dword [esp + 0xc]
mov byte [esi + 2], cl
mov byte [esi + 1], dl
mov byte [esi], bl
mov byte [esi + 3], 0xff
mov edx, dword [esp + 0x60]
add esi, 4
inc eax
cmp eax, edx
mov dword [esp + 0xc], eax
jb 0x401701
mov ebx, dword [esp + 0x64]
mov eax, dword [esp + 0x10]
inc eax
cmp eax, ebx
mov dword [esp + 0x10], eax
jb 0x4016bf
mov esi, dword [ebp + 8]
mov ecx, 0xb
xor eax, eax
lea edi, [esp + 0x78]
rep stosd dword es:[edi], eax
neg ebx
push 2
mov ecx, esi
mov word [esp + 0x8a], 0x20
mov dword [esp + 0x84], ebx
mov dword [esp + 0x80], edx
mov dword [esp + 0x7c], 0x28
mov word [esp + 0x88], 1
mov dword [esp + 0x8c], eax
call sub.MFC42.DLL_CDC::SetStretchBltMode
test esi, esi
je 0x40185d
mov esi, dword [esi + 4]
mov eax, dword [esp + 0x5c]
mov ecx, dword [esp + 0x64]
push 0xcc0020
lea edx, [esp + 0x7c]
push 0
push edx
mov edx, dword [esp + 0x6c]
push eax
mov eax, dword [ebp + 0x10]
push ecx
mov ecx, dword [ebp + 0x18]
push edx
mov edx, dword [ebp + 0x14]
push 0
sub ecx, eax
push 0
push ecx
mov ecx, dword [ebp + 0xc]
sub edx, ecx
push edx
push eax
push ecx
push esi
call dword [sym.imp.GDI32.dll_StretchDIBits]
lea ecx, [esp + 0x54]
mov dword [esp + 0x4b0], 0xffffffff
call sym.Player.exe_public_virtual:_void___thiscall_CTPImage::destructor_void_
mov ecx, dword [esp + 0x4a8]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret