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

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x48
mov eax, dword [esp + 0x5c]
sub eax, 1
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x60]
sub eax, 1
mov dword [esp + 0x44], eax
je 0x6ca2f6ac
mov ebx, dword [esp + 0x64]
mov eax, dword [esp + 0x78]
mov dword [esp + 0x34], 0
mov edi, dword [esp + 0x80]
lea edi, [edi + edi*2]
mov dword [esp + 0x40], edi
lea esi, [esi]
mov edx, dword [esp + 0x34]
mov edi, ebx
add edi, dword [esp + 0x70]
mov dword [esp + 4], ebx
mov ebx, dword [esp + 0x68]
mov dword [esp + 0xc], eax
shr edx, 1
imul edx, dword [esp + 0x74]
add eax, dword [esp + 0x7c]
mov dword [esp + 0x38], edi
mov dword [esp + 8], edi
mov dword [esp + 0x3c], eax
add ebx, edx
add edx, dword [esp + 0x6c]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x20]
mov dword [esp + 0x14], ebx
test edx, edx
je 0x6ca2f568
mov ebx, dword [esp + 0x40]
mov dword [esp + 0x10], 0
lea eax, [ebx*4 + 0x6ca94f20]
movzx ebp, byte [ebx*4 + 0x6ca94f20]
movsx edi, word [eax + 4]
mov dword [esp + 0x24], edi
movsx edi, word [eax + 6]
mov dword [esp + 0x28], edi
movsx edi, word [eax + 8]
mov dword [esp + 0x2c], edi
movsx edi, word [eax + 0xa]
movsx eax, word [eax + 2]
mov dword [esp + 0x30], edi
mov dword [esp], eax
lea esi, [esi]
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x24]
mov eax, dword [esp + 0x14]
mov esi, dword [esp + 4]
movzx edx, byte [edi]
movzx eax, byte [eax]
movzx ecx, byte [esi]
add edx, 0xffffff80
imul ebx, edx
add eax, 0xffffff80
sub ecx, ebp
imul edx, dword [esp + 0x2c]
imul ecx, dword [esp]
mov edi, ebx
mov ebx, dword [esp + 0x28]
imul ebx, eax
imul eax, dword [esp + 0x30]
add ebx, edx
lea edx, [edi + ecx + 0x2000]
sar edx, 6
movzx esi, byte [edx + 0x6ca94ce0]
lea edx, [eax + ecx + 0x2000]
lea ecx, [ebx + ecx + 0x2000]
sar edx, 6
sar ecx, 6
movzx edx, byte [edx + 0x6ca94ce0]
movzx ecx, byte [ecx + 0x6ca94ce0]
shl esi, 8
and si, 0xf800
shr dl, 3
shl ecx, 3
movzx edx, dl
and cx, 0x7e0
or edx, esi
mov esi, dword [esp + 4]
or edx, ecx
mov ecx, dword [esp + 0xc]
mov word [ecx], dx
movzx ecx, byte [esi + 1]
sub ecx, ebp
imul ecx, dword [esp]
lea edx, [edi + ecx + 0x2000]
sar edx, 6
movzx esi, byte [edx + 0x6ca94ce0]
lea edx, [eax + ecx + 0x2000]
lea ecx, [ebx + ecx + 0x2000]
sar edx, 6
sar ecx, 6
movzx edx, byte [edx + 0x6ca94ce0]
movzx ecx, byte [ecx + 0x6ca94ce0]
shl esi, 8
and si, 0xf800
shr dl, 3
shl ecx, 3
movzx edx, dl
and cx, 0x7e0
or edx, esi
or edx, ecx
mov ecx, dword [esp + 0xc]
mov word [ecx + 2], dx
add ecx, 4
mov dword [esp + 0xc], ecx
mov ecx, dword [esp + 8]
movzx ecx, byte [ecx]
sub ecx, ebp
imul ecx, dword [esp]
lea edx, [edi + ecx + 0x2000]
sar edx, 6
movzx esi, byte [edx + 0x6ca94ce0]
lea edx, [eax + ecx + 0x2000]
lea ecx, [ebx + ecx + 0x2000]
sar edx, 6
sar ecx, 6
movzx edx, byte [edx + 0x6ca94ce0]
movzx ecx, byte [ecx + 0x6ca94ce0]
shl esi, 8
and si, 0xf800
shr dl, 3
shl ecx, 3
movzx edx, dl
and cx, 0x7e0
or edx, esi
mov esi, dword [esp + 0x1c]
or edx, ecx
mov word [esi], dx
mov ecx, dword [esp + 8]
add dword [esp + 0x10], 2
movzx edx, byte [ecx + 1]
add dword [esp + 4], 2
add dword [esp + 8], 2
sub edx, ebp
imul edx, dword [esp]
add dword [esp + 0x14], 2
add dword [esp + 0x18], 2
lea ecx, [edi + edx + 0x2000]
lea eax, [eax + edx + 0x2000]
sar ecx, 6
sar eax, 6
movzx ecx, byte [ecx + 0x6ca94ce0]
movzx eax, byte [eax + 0x6ca94ce0]
shl ecx, 8
shr al, 3
movzx eax, al
and cx, 0xf800
or ecx, eax
lea eax, [ebx + edx + 0x2000]
sar eax, 6
movzx eax, byte [eax + 0x6ca94ce0]
shl eax, 3
and ax, 0x7e0
or ecx, eax
mov eax, esi
add eax, 4
mov word [esi + 2], cx
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x10]
cmp eax, dword [esp + 0x20]
jb 0x6ca2f348
je 0x6ca2f568
add dword [esp + 0x34], 2
mov ebx, dword [esp + 0x38]
mov eax, dword [esp + 0x3c]
mov edi, dword [esp + 0x34]
add ebx, dword [esp + 0x70]
add eax, dword [esp + 0x7c]
cmp dword [esp + 0x44], edi
ja 0x6ca2f2b8
je 0x6ca2f683
add esp, 0x48
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [esp + 0x14]
mov ebp, dword [esp + 0x40]
movzx eax, byte [eax]
lea esi, [eax - 0x80]
mov eax, dword [esp + 0x18]
movzx eax, byte [eax]
lea ebx, [eax - 0x80]
lea eax, [ebp*4 + 0x6ca94f20]
movsx edx, word [eax + 4]
movsx ecx, word [eax + 6]
mov edi, edx
movsx edx, word [eax + 8]
imul ecx, esi
imul edi, ebx
imul edx, ebx
lea ebx, [ecx + edx]
movzx ecx, byte [ebp*4 + 0x6ca94f20]
movsx edx, word [eax + 0xa]
movsx ebp, word [eax + 2]
mov eax, dword [esp + 4]
mov dword [esp], ebx
imul esi, edx
mov ebx, ecx
movzx edx, byte [eax]
sub edx, ecx
imul edx, ebp
lea eax, [edi + edx + 0x2000]
sar eax, 6
movzx ecx, byte [eax + 0x6ca94ce0]
lea eax, [esi + edx + 0x2000]
sar eax, 6
movzx eax, byte [eax + 0x6ca94ce0]
shl ecx, 8
and cx, 0xf800
shr al, 3
movzx eax, al
or eax, ecx
mov ecx, dword [esp]
lea edx, [ecx + edx + 0x2000]
sar edx, 6
movzx edx, byte [edx + 0x6ca94ce0]
shl edx, 3
and dx, 0x7e0
or eax, edx
mov edx, dword [esp + 0xc]
mov word [edx], ax
mov eax, dword [esp + 8]
movzx eax, byte [eax]
sub eax, ebx
imul eax, ebp
lea edx, [edi + eax + 0x2000]
lea ecx, [esi + eax + 0x2000]
sar edx, 6
sar ecx, 6
movzx edx, byte [edx + 0x6ca94ce0]
movzx ecx, byte [ecx + 0x6ca94ce0]
shl edx, 8
shr cl, 3
movzx ecx, cl
and dx, 0xf800
or edx, ecx
mov ecx, dword [esp]
lea eax, [ecx + eax + 0x2000]
sar eax, 6
movzx eax, byte [eax + 0x6ca94ce0]
shl eax, 3
and ax, 0x7e0
or edx, eax
mov eax, dword [esp + 0x1c]
mov word [eax], dx
jmp 0x6ca2f534
mov edi, dword [esp + 0x44]
mov edx, dword [esp + 0x70]
mov eax, edi
imul edx, edi
add dword [esp + 0x64], edx
imul edi, dword [esp + 0x7c]
shr eax, 1
add dword [esp + 0x78], edi
imul eax, dword [esp + 0x74]
add dword [esp + 0x68], eax
add dword [esp + 0x6c], eax
mov eax, dword [esp + 0x80]
lea eax, [eax + eax*2]
shl eax, 2
movsx edi, word [eax + 0x6ca94f24]
mov dword [esp + 0x10], edi
movsx edi, word [eax + 0x6ca94f26]
mov dword [esp + 0x14], edi
movsx edi, word [eax + 0x6ca94f28]
mov dword [esp + 0x18], edi
movsx edi, word [eax + 0x6ca94f2a]
mov dword [esp + 0x1c], edi
movzx edi, byte [eax + 0x6ca94f20]
movsx eax, word [eax + 0x6ca94f22]
mov dword [esp + 4], edi
mov dword [esp + 8], eax
mov eax, dword [esp + 0x20]
test eax, eax
je 0x6ca2f838
xor ebp, ebp
mov edi, dword [esp + 0x78]
mov dword [esp], ebp
mov ebp, dword [esp + 0x64]
lea esi, [esi]
mov eax, dword [esp + 0x68]
mov ebx, dword [esp + 0x10]
add edi, 4
mov esi, dword [esp + 0x14]
movzx ecx, byte [ebp]
movzx edx, byte [eax]
mov eax, dword [esp + 0x6c]
sub ecx, dword [esp + 4]
imul ecx, dword [esp + 8]
movzx eax, byte [eax]
add edx, 0xffffff80
imul esi, edx
add eax, 0xffffff80
imul edx, dword [esp + 0x1c]
imul ebx, eax
imul eax, dword [esp + 0x18]
mov dword [esp + 0xc], ebx
add esi, eax
lea eax, [ebx + ecx + 0x2000]
sar eax, 6
movzx ebx, byte [eax + 0x6ca94ce0]
lea eax, [edx + ecx + 0x2000]
lea ecx, [esi + ecx + 0x2000]
sar eax, 6
sar ecx, 6
movzx eax, byte [eax + 0x6ca94ce0]
movzx ecx, byte [ecx + 0x6ca94ce0]
shl ebx, 8
and bx, 0xf800
shr al, 3
shl ecx, 3
movzx eax, al
and cx, 0x7e0
or eax, ebx
mov ebx, dword [esp + 0xc]
or eax, ecx
mov word [edi - 4], ax
movzx eax, byte [ebp + 1]
sub eax, dword [esp + 4]
imul eax, dword [esp + 8]
lea ecx, [ebx + eax + 0x2000]
lea edx, [edx + eax + 0x2000]
sar ecx, 6
sar edx, 6
lea eax, [esi + eax + 0x2000]
sar eax, 6
movzx ecx, byte [ecx + 0x6ca94ce0]
movzx edx, byte [edx + 0x6ca94ce0]
movzx eax, byte [eax + 0x6ca94ce0]
shl ecx, 8
shr dl, 3
and cx, 0xf800
shl eax, 3
movzx edx, dl
and ax, 0x7e0
or ecx, edx
or ecx, eax
mov word [edi - 2], cx
add ebp, 2
add dword [esp], 2
mov eax, dword [esp]
add dword [esp + 0x68], 2
add dword [esp + 0x6c], 2
cmp eax, dword [esp + 0x20]
jb 0x6ca2f718
mov dword [esp + 0x64], ebp
mov dword [esp + 0x78], edi
jne 0x6ca2f55d
mov eax, dword [esp + 0x68]
mov ecx, dword [esp + 0x10]
movzx eax, byte [eax]
lea edx, [eax - 0x80]
mov eax, dword [esp + 0x6c]
movzx eax, byte [eax]
lea ebx, [eax - 0x80]
mov eax, dword [esp + 0x64]
imul ecx, ebx
movzx eax, byte [eax]
sub eax, dword [esp + 4]
imul eax, dword [esp + 8]
imul ebx, dword [esp + 0x18]
lea ecx, [eax + ecx + 0x2000]
sar ecx, 6
movzx ecx, byte [ecx + 0x6ca94ce0]
shl ecx, 8
mov esi, ecx
mov ecx, dword [esp + 0x1c]
and si, 0xf800
imul ecx, edx
imul edx, dword [esp + 0x14]
lea ecx, [eax + ecx + 0x2000]
add edx, ebx
sar ecx, 6
lea eax, [eax + edx + 0x2000]
movzx ecx, byte [ecx + 0x6ca94ce0]
sar eax, 6
movzx eax, byte [eax + 0x6ca94ce0]
shr cl, 3
movzx ecx, cl
shl eax, 3
or ecx, esi
and ax, 0x7e0
or ecx, eax
mov eax, dword [esp + 0x78]
mov word [eax], cx
add esp, 0x48
pop ebx
pop esi
pop edi
pop ebp
ret