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

Disassembly:
sub esp, 0x60
push ebx
push ebp
push esi
push edi
mov edi, ecx
mov ebx, edx
push edi
mov dword [esp + 0x14], ebx
call sym.FreeImage.dll__FreeImage_GetHeight_4
push ebx
mov dword [esp + 0x28], eax
call sym.FreeImage.dll__FreeImage_GetHeight_4
mov ecx, dword [esp + 0x84]
lea edx, [esp + 0x60]
test ecx, ecx
mov ebx, eax
xorps xmm0, xmm0
mov dword [esp + 0x20], ebx
cmovne edx, ecx
push edi
movups xmmword [esp + 0x64], xmm0
mov dword [esp + 0x2c], edx
call sym.FreeImage.dll__FreeImage_GetLine_4
push edi
mov esi, eax
call sym.FreeImage.dll__FreeImage_GetWidth_4
mov ecx, eax
xor edx, edx
mov eax, esi
div ecx
push edi
mov ebp, eax
mov esi, ebp
shr esi, 2
mov dword [esp + 0x20], esi
call sym.FreeImage.dll__FreeImage_GetPitch_4
push dword [esp + 0x10]
mov dword [esp + 0x30], eax
call sym.FreeImage.dll__FreeImage_GetPitch_4
mov dword [esp + 0x14], eax
mov eax, ebp
imul eax, dword [esp + 0x74]
push edi
mov dword [esp + 0x78], eax
call sym.FreeImage.dll__FreeImage_GetBits_4
add eax, dword [esp + 0x74]
push dword [esp + 0x10]
mov dword [esp + 0x1c], eax
call sym.FreeImage.dll__FreeImage_GetBits_4
mov edi, eax
mov eax, dword [esp + 0x84]
add edi, dword [esp + 0x74]
test eax, eax
je 0x1005ad0f
mov ecx, dword [esp + 0x78]
test ecx, ecx
jle 0x1005ad01
mov esi, dword [esp + 0x14]
mov ebx, ecx
nop word [eax + eax]
push ebp
push eax
push edi
call fcn.101df960
mov eax, dword [esp + 0x90]
add esp, 0xc
add edi, esi
sub ebx, 1
jne 0x1005ace0
mov esi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x20]
push ebp
push eax
lea eax, [esp + 0x48]
push eax
call fcn.101df960
jmp 0x1005ad48
mov eax, dword [esp + 0x78]
test eax, eax
jle 0x1005ad3b
mov esi, dword [esp + 0x14]
mov ebx, eax
nop dword [eax]
push ebp
push 0
push edi
call fcn.101dfee0
add esp, 0xc
add edi, esi
sub ebx, 1
jne 0x1005ad20
mov esi, dword [esp + 0x1c]
mov ebx, dword [esp + 0x20]
push ebp
lea eax, [esp + 0x44]
push 0
push eax
call fcn.101dfee0
mov eax, dword [esp + 0x30]
add esp, 0xc
test eax, eax
je 0x1005af4c
mov edi, dword [esp + 0x78]
movsd xmm3, qword [esp + 0x7c]
movsd xmm4, qword [0x1039c168]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x20], edi
push ebp
mov edx, eax
lea ecx, [esp + 0x34]
call fcn.10028bb0
add esp, 4
test esi, esi
je 0x1005add4
mov ecx, dword [esp + 0x28]
lea edx, [esp + 0x30]
sub edx, ecx
lea edi, [esp + 0x50]
mov eax, ecx
sub edi, ecx
mov ecx, esi
nop dword [eax]
movss xmm2, dword [eax]
movss xmm0, dword [eax + edx]
subss xmm0, xmm2
cvtps2pd xmm1, xmm0
cvtps2pd xmm0, xmm2
mulsd xmm1, xmm3
addsd xmm1, xmm0
addsd xmm1, xmm4
cvtpd2ps xmm0, xmm1
movss dword [eax + edi], xmm0
add eax, 4
sub ecx, 1
jne 0x1005ada0
mov edi, dword [esp + 0x20]
test edi, edi
js 0x1005af1f
cmp edi, ebx
jge 0x1005af1f
xor ecx, ecx
test esi, esi
je 0x1005aef1
cmp esi, 8
jb 0x1005ae3b
mov eax, esi
and eax, 0xfffffff8
nop dword [eax + eax]
movups xmm0, xmmword [esp + ecx*4 + 0x40]
movups xmm1, xmmword [esp + ecx*4 + 0x50]
subps xmm1, xmm0
movups xmm0, xmmword [esp + ecx*4 + 0x30]
subps xmm0, xmm1
movups xmm1, xmmword [esp + ecx*4 + 0x60]
movups xmmword [esp + ecx*4 + 0x30], xmm0
movups xmm0, xmmword [esp + ecx*4 + 0x50]
subps xmm1, xmm0
movups xmm0, xmmword [esp + ecx*4 + 0x40]
subps xmm0, xmm1
movups xmmword [esp + ecx*4 + 0x40], xmm0
add ecx, 8
cmp ecx, eax
jb 0x1005ae00
cmp ecx, esi
jae 0x1005aef1
mov eax, esi
sub eax, ecx
cmp eax, 4
jb 0x1005aec7
lea eax, [esi - 3]
nop
movss xmm1, dword [esp + ecx*4 + 0x50]
subss xmm1, dword [esp + ecx*4 + 0x40]
movss xmm0, dword [esp + ecx*4 + 0x30]
subss xmm0, xmm1
movss xmm1, dword [esp + ecx*4 + 0x54]
subss xmm1, dword [esp + ecx*4 + 0x44]
movss dword [esp + ecx*4 + 0x30], xmm0
movss xmm0, dword [esp + ecx*4 + 0x34]
subss xmm0, xmm1
movss xmm1, dword [esp + ecx*4 + 0x58]
subss xmm1, dword [esp + ecx*4 + 0x48]
movss dword [esp + ecx*4 + 0x34], xmm0
movss xmm0, dword [esp + ecx*4 + 0x38]
subss xmm0, xmm1
movss xmm1, dword [esp + ecx*4 + 0x5c]
subss xmm1, dword [esp + ecx*4 + 0x4c]
movss dword [esp + ecx*4 + 0x38], xmm0
movss xmm0, dword [esp + ecx*4 + 0x3c]
subss xmm0, xmm1
movss dword [esp + ecx*4 + 0x3c], xmm0
add ecx, 4
cmp ecx, eax
jb 0x1005ae50
cmp ecx, esi
jae 0x1005aef1
nop dword [eax + eax]
movss xmm1, dword [esp + ecx*4 + 0x50]
subss xmm1, dword [esp + ecx*4 + 0x40]
movss xmm0, dword [esp + ecx*4 + 0x30]
subss xmm0, xmm1
movss dword [esp + ecx*4 + 0x30], xmm0
inc ecx
cmp ecx, esi
jb 0x1005aed0
push ebp
push edi
push dword [esp + 0x18]
call sym.FreeImage.dll__FreeImage_GetScanLine_8
add eax, dword [esp + 0x78]
lea edx, [esp + 0x34]
mov ecx, eax
call fcn.10028bb0
movsd xmm3, qword [esp + 0x80]
add esp, 4
movsd xmm4, qword [0x1039c168]
push ebp
lea edx, [esp + 0x54]
lea ecx, [esp + 0x44]
call fcn.10028bb0
mov eax, dword [esp + 0x1c]
inc edi
add eax, dword [esp + 0x30]
add esp, 4
sub dword [esp + 0x1c], 1
mov dword [esp + 0x18], eax
mov dword [esp + 0x20], edi
jne 0x1005ad75
mov edi, dword [esp + 0x24]
add edi, dword [esp + 0x78]
js 0x1005afd5
cmp edi, ebx
jge 0x1005afd5
push edi
push dword [esp + 0x14]
call sym.FreeImage.dll__FreeImage_GetScanLine_8
mov esi, eax
lea edx, [esp + 0x40]
add esi, dword [esp + 0x74]
push ebp
mov ecx, esi
call fcn.10028bb0
mov eax, dword [esp + 0x88]
add esp, 4
inc edi
test eax, eax
je 0x1005afb5
cmp edi, ebx
jge 0x1005afd5
sub ebx, edi
nop dword [eax + eax]
add esi, dword [esp + 0x14]
mov edx, eax
push ebp
mov ecx, esi
call fcn.10028bb0
mov eax, dword [esp + 0x88]
add esp, 4
sub ebx, 1
jne 0x1005af90
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret
cmp edi, ebx
jge 0x1005afd5
sub ebx, edi
nop dword [eax + eax]
add esi, dword [esp + 0x14]
push ebp
push 0
push esi
call fcn.101dfee0
add esp, 0xc
sub ebx, 1
jne 0x1005afc0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x60
ret