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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xffffffc0
sub esp, 0x2f4
mov eax, dword [0x4596ac]
xor eax, esp
mov dword [esp + 0x2f0], eax
cmp dword [0x464a9c], 0
fldz
push ebx
fstp dword [esp + 0x30]
push esi
push edi
mov dword [esp + 0x54], 0
je 0x40d5fa
push str.Foveon_interpolation..._n
call fcn.00434a96
add eax, 0x40
push eax
call fcn.00435780
add esp, 8
lea eax, [esp + 0x14c]
push str.DarkShieldColRange
push eax
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d643
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0xd8], ecx
mov ecx, dword [eax + 8]
mov dword [esp + 0xdc], edx
mov edx, dword [eax + 0xc]
push eax
mov dword [esp + 0xe4], ecx
mov dword [esp + 0xe8], edx
call fcn.0043481f
add esp, 4
lea eax, [esp + 0x14c]
push str.PostPolyMatrix
push eax
call fcn.0040cdb0
mov esi, eax
add esp, 8
test esi, esi
je 0x40d67a
push 0x6c
lea ecx, [esp + 0x204]
push esi
push ecx
call fcn.00436980
add esp, 0xc
push esi
call fcn.0043481f
add esp, 4
lea edx, [esp + 0x14c]
push str.SaturationLevel
push edx
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d6b9
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0x14c], ecx
mov ecx, dword [eax + 8]
push eax
mov dword [esp + 0x154], edx
mov dword [esp + 0x158], ecx
call fcn.0043481f
add esp, 4
lea edx, [esp + 0xfc]
push str.KeepImageArea
push edx
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d702
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0x174], ecx
mov ecx, dword [eax + 8]
mov dword [esp + 0x178], edx
mov edx, dword [eax + 0xc]
push eax
mov dword [esp + 0x180], ecx
mov dword [esp + 0x184], edx
call fcn.0043481f
add esp, 4
lea eax, [esp + 0xfc]
push str.ActiveImageArea
push eax
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d74b
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0x158], ecx
mov ecx, dword [eax + 8]
mov dword [esp + 0x15c], edx
mov edx, dword [eax + 0xc]
push eax
mov dword [esp + 0x164], ecx
mov dword [esp + 0x168], edx
call fcn.0043481f
add esp, 4
lea eax, [esp + 0xfc]
push str.ChromaDQ
push eax
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d781
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0x70], ecx
mov ecx, dword [eax + 8]
push eax
mov dword [esp + 0x78], edx
mov dword [esp + 0x7c], ecx
call fcn.0043481f
add esp, 4
push 0x45aab8
push 0x45aac0
call fcn.0040cb20
add esp, 8
test eax, eax
mov eax, str.ColorDQ
jne 0x40d7a1
mov eax, str.ColorDQCamRGB
push eax
lea edx, [esp + 0x100]
push edx
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d7dc
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov dword [esp + 0xfc], ecx
mov ecx, dword [eax + 8]
push eax
mov dword [esp + 0x104], edx
mov dword [esp + 0x108], ecx
call fcn.0043481f
add esp, 4
push 0x45aae8
push 0x45aaf8
call fcn.0040cb20
add esp, 8
test eax, eax
je 0x40d81a
lea edx, [esp + 0x8c]
push str.ColumnFilter
push edx
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d81a
mov ecx, dword [eax]
push eax
mov dword [esp + 0x3c], ecx
call fcn.0043481f
add esp, 4
push 0x48
lea edx, [esp + 0x1ac]
push 0
push edx
call fcn.00436440
add esp, 0xc
push 0x45ab18
push 0x45ab24
call fcn.0040cb20
add esp, 8
test eax, eax
je 0x40d880
lea eax, [esp + 0x8c]
push str.DarkDrift
push eax
call fcn.0040cdb0
mov esi, eax
add esp, 8
test esi, esi
je 0x40d880
push 0x30
lea ecx, [esp + 0x1c4]
push esi
push ecx
call fcn.00436980
add esp, 0xc
push esi
call fcn.0043481f
add esp, 4
jmp 0x40da17
mov ebx, dword [esp + 0x98]
xor esi, esi
mov dword [esp + 0x28], esi
lea ecx, [ecx]
mov edi, dword [esp + 0xa4]
mov eax, str.DarkShieldBottom
test esi, esi
jne 0x40d8a5
mov eax, str.DarkShieldTop
push eax
lea edx, [esp + 0x90]
push edx
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40d8ea
mov ebx, dword [eax]
mov ecx, dword [eax + 4]
mov edx, dword [eax + 8]
mov edi, dword [eax + 0xc]
push eax
mov dword [esp + 0x9c], ebx
mov dword [esp + 0xa0], ecx
mov dword [esp + 0xa4], edx
mov dword [esp + 0xa8], edi
call fcn.0043481f
add esp, 4
mov ecx, dword [esp + 0x9c]
cmp ecx, edi
mov dword [esp + 0x34], ecx
jg 0x40d9b1
lea ecx, [ecx]
cmp ebx, dword [esp + 0xa0]
jg 0x40d99d
lea eax, [esi + esi*2]
add eax, eax
add eax, eax
add eax, eax
lea edx, [esp + eax + 0x1c4]
lea esi, [esp + eax + 0x1cc]
lea edi, [esp + eax + 0x1d4]
movzx eax, word [0x466040]
imul eax, ecx
mov ecx, dword [0x4ac418]
add eax, ebx
lea eax, [ecx + eax*8 + 4]
mov ecx, dword [esp + 0xa0]
sub ecx, ebx
inc ecx
jmp 0x40d950
movsx ebx, word [eax - 4]
mov dword [esp + 0x24], ebx
movsx ebx, word [eax - 2]
fild dword [esp + 0x24]
mov dword [esp + 0x24], ebx
movsx ebx, word [eax]
fadd dword [edx]
add eax, 8
sub ecx, 1
fstp dword [edx]
fild dword [esp + 0x24]
mov dword [esp + 0x24], ebx
fadd dword [esi]
fstp dword [esi]
fild dword [esp + 0x24]
fadd dword [edi]
fstp dword [edi]
jne 0x40d950
mov ebx, dword [esp + 0x98]
mov edi, dword [esp + 0xa4]
mov ecx, dword [esp + 0x34]
mov esi, dword [esp + 0x28]
inc ecx
cmp ecx, edi
mov dword [esp + 0x34], ecx
jle 0x40d900
mov ecx, dword [esp + 0x9c]
mov edx, dword [esp + 0xa0]
sub edx, ebx
sub edi, ecx
inc edx
inc edi
imul edx, edi
lea eax, [esi + esi*2]
add eax, eax
mov dword [esp + 0x24], edx
add eax, eax
add eax, eax
fild dword [esp + 0x24]
inc esi
cmp esi, 2
mov dword [esp + 0x28], esi
fstp dword [esp + 0x24]
fld dword [esp + eax + 0x1c4]
fld dword [esp + 0x24]
fld st(0)
fdivp st(2)
fxch st(1)
fstp dword [esp + eax + 0x1c4]
fld dword [esp + eax + 0x1cc]
fdiv st(1)
fstp dword [esp + eax + 0x1cc]
lea eax, [esp + eax + 0x1d4]
fdivr dword [eax]
fstp dword [eax]
jl 0x40d890
push 0x4ac440
push str.WhiteBalanceIlluminants
call fcn.0040cb20
add esp, 8
test eax, eax
jne 0x40da63
mov eax, dword [0x4ac404]
push 0x4ac440
push eax
push str._s:_Invalid_white_balance___s__n
call fcn.00434a96
add eax, 0x40
push eax
call fcn.00435780
add esp, 0x10
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x2f0]
xor ecx, esp
call fcn.004334ab
mov esp, ebp
pop ebp
ret
push eax
lea ecx, [esp + 0x90]
push ecx
call fcn.0040cdb0
mov esi, eax
add esp, 8
test esi, esi
je 0x40da96
push 0x24
lea edx, [esp + 0x188]
push esi
push edx
call fcn.00436980
add esp, 0xc
push esi
call fcn.0043481f
add esp, 4
push 0x4ac440
push str.WhiteBalanceCorrections
call fcn.0040cb20
push eax
lea eax, [esp + 0x98]
push eax
call fcn.0040cdb0
mov esi, eax
add esp, 0x10
test esi, esi
je 0x40dad8
push 0x24
lea ecx, [esp + 0x10c]
push esi
push ecx
call fcn.00436980
add esp, 0xc
push esi
call fcn.0043481f
add esp, 4
xor eax, eax
mov dword [esp + 0xb4], eax
mov dword [esp + 0xb8], eax
mov dword [esp + 0xbc], eax
mov dword [esp + 0xc0], eax
mov dword [esp + 0xc4], eax
mov dword [esp + 0xc8], eax
mov dword [esp + 0xcc], eax
mov dword [esp + 0xd0], eax
mov dword [esp + 0xd4], eax
lea ecx, [esp + 0xb4]
lea edx, [esp + 0x10c]
lea esi, [eax + 3]
lea ebx, [ebx]
xor eax, eax
fld dword [esp + eax*4 + 0x184]
inc eax
fmul dword [edx - 4]
add ecx, 4
cmp eax, 3
fadd dword [ecx - 4]
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
fld dword [esp + eax*4 + 0x18c]
fmul dword [edx]
faddp st(1)
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
fld dword [esp + eax*4 + 0x198]
fmul dword [edx + 4]
faddp st(1)
fstp dword [ecx - 4]
jl 0x40db32
add edx, 0xc
sub esi, 1
jne 0x40db30
mov edi, 2
lea ecx, [esp + 0x114]
mov dword [esp + 0x4c], 3
mov eax, edi
cdq
mov esi, 3
idiv esi
lea eax, [edi - 1]
mov ebx, 3
inc edi
add ecx, 4
lea esi, [edx + edx*2]
cdq
fld dword [esp + esi*4 + 0xbc]
idiv ebx
sub dword [esp + 0x4c], 1
lea eax, [edx + edx*2]
fmul dword [esp + eax*4 + 0xb8]
lea edx, [esp + eax*4 + 0xbc]
mov dword [esp + 0x48], edx
lea edx, [esp + esi*4 + 0xbc]
lea ebx, [esp + eax*4 + 0xb8]
mov dword [esp + 0x2c], ebx
mov ebx, dword [esp + 0x48]
fld dword [ebx]
lea ebx, [esp + esi*4 + 0xb8]
fmul dword [ebx]
mov dword [esp + 0x24], ebx
mov ebx, dword [esp + 0x48]
lea esi, [esp + esi*4 + 0xb4]
fsubp st(1)
lea eax, [esp + eax*4 + 0xb4]
fstp dword [ecx - 0x10]
fld dword [ebx]
fmul dword [esi]
fld dword [edx]
mov edx, dword [esp + 0x24]
fmul dword [eax]
fsubp st(1)
fstp dword [ecx - 4]
fld dword [edx]
fmul dword [eax]
mov eax, dword [esp + 0x2c]
fld dword [eax]
fmul dword [esi]
fsubp st(1)
fstp dword [ecx + 8]
jne 0x40db8e
fld dword [esp + 0x108]
push 0x4ac440
fld qword [0x451960]
lea ecx, [esp + 0x27c]
fmul st(1), st(0)
push str._sRGBNeutral
fld dword [esp + 0x114]
push ecx
fld qword [0x451958]
fmul st(1), st(0)
fxch st(3)
faddp st(1)
fld dword [esp + 0x11c]
fld qword [0x451950]
fmul st(1), st(0)
fxch st(2)
faddp st(1)
fstp dword [esp + 0x98]
fld dword [esp + 0x120]
fmul st(2)
fld dword [esp + 0x124]
fmul st(4)
faddp st(1)
fld dword [esp + 0x128]
fmul st(2)
faddp st(1)
fstp dword [esp + 0x9c]
fld dword [esp + 0x12c]
fmulp st(2)
fld dword [esp + 0x130]
fmulp st(3)
fxch st(1)
faddp st(2)
fmul dword [esp + 0x134]
faddp st(1)
fstp dword [esp + 0xa0]
call fcn.004339dc
add esp, 0xc
lea edx, [esp + 0x278]
push edx
push str.IncludeBlocks
call fcn.0040cb20
add esp, 8
test eax, eax
je 0x40dd2c
lea eax, [esp + 0x278]
push eax
lea ecx, [esp + 0x84]
push ecx
call fcn.0040cdb0
add esp, 8
test eax, eax
je 0x40dd2c
mov edx, dword [eax]
mov ecx, dword [eax + 4]
mov dword [esp + 0x8c], edx
mov edx, dword [eax + 8]
push eax
mov dword [esp + 0x94], ecx
mov dword [esp + 0x98], edx
call fcn.0043481f
add esp, 4
fldz
fstp dword [esp + 0x30]
fld dword [esp + 0x8c]
fcom qword [0x4517a8]
fnstsw ax
test ah, 0x41
jne 0x40dd4a
fst dword [esp + 0x30]
fld dword [esp + 0x30]
fld dword [esp + 0x90]
fcom st(1)
fnstsw ax
test ah, 0x41
jne 0x40dd6a
fstp st(1)
fst dword [esp + 0x30]
fld dword [esp + 0x30]
fxch st(1)
fld dword [esp + 0x94]
fcom st(2)
fnstsw ax
test ah, 0x41
jne 0x40dd8a
fstp st(2)
fxch st(1)
fst dword [esp + 0x30]
fld dword [esp + 0x30]
fxch st(2)
fxch st(1)
fld st(2)
xor eax, eax
fdivp st(4)
mov dword [esp + 0x108], eax
mov dword [esp + 0x10c], eax
mov dword [esp + 0x110], eax
mov dword [esp + 0x114], eax
mov dword [esp + 0x118], eax
mov dword [esp + 0x11c], eax
mov dword [esp + 0x120], eax
mov dword [esp + 0x124], eax
mov dword [esp + 0x128], eax
lea edx, [esp + 0x108]
mov ecx, 0x4ac364
fxch st(3)
fstp dword [esp + 0x8c]
fdiv st(1)
fstp dword [esp + 0x90]
fdivp st(1)
fstp dword [esp + 0x94]
jmp 0x40de00
xor eax, eax
fld dword [esp + eax + 0xb4]
add eax, 4
fmul dword [ecx - 4]
add edx, 4
cmp eax, 0xc
fmul dword [esp + eax + 0x88]
fadd dword [edx - 4]
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
fld dword [ecx]
fmul dword [esp + eax + 0xbc]
fmul dword [esp + eax + 0x88]
faddp st(1)
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
fld dword [esp + eax + 0xc8]
fmul dword [ecx + 4]
fmul dword [esp + eax + 0x88]
faddp st(1)
fstp dword [edx - 4]
jl 0x40de02
add ecx, 0x10
cmp ecx, 0x4ac394
jl 0x40de00
fld dword [esp + 0x108]
lea ecx, [esp + 0x98]
fadd dword [esp + 0x10c]
xor eax, eax
fadd dword [esp + 0x110]
fst qword [esp + 0x98]
fld dword [esp + 0x118]
fadd dword [esp + 0x114]
fadd dword [esp + 0x11c]
fst qword [esp + 0xa0]
fld dword [esp + 0x124]
fadd dword [esp + 0x120]
fadd dword [esp + 0x128]
fst qword [esp + 0xa8]
fxch st(1)
fmul qword [0x451948]
fxch st(2)
fmul qword [0x451940]
faddp st(2)
fmul qword [0x451938]
faddp st(1)
fdiv qword [0x451930]
fst qword [esp + 0x270]
fld dword [esp + eax + 0x108]
add eax, 0xc
fmul st(1)
add ecx, 8
cmp eax, 0x24
fdiv qword [ecx - 8]
fstp dword [esp + eax + 0xa8]
fld dword [esp + eax + 0x100]
fmul st(1)
fdiv qword [ecx - 8]
fstp dword [esp + eax + 0xac]
fld dword [esp + eax + 0x104]
fmul st(1)
fdiv qword [ecx - 8]
fstp dword [esp + eax + 0xb0]
jl 0x40dee8
xor eax, eax
fstp st(0)
fld qword [0x451928]
mov dword [esp + 0x108], eax
mov dword [esp + 0x10c], eax
mov dword [esp + 0x110], eax
mov dword [esp + 0x114], eax
mov dword [esp + 0x118], eax
mov dword [esp + 0x11c], eax
mov dword [esp + 0x120], eax
mov dword [esp + 0x124], eax
mov dword [esp + 0x128], eax
xor edx, edx
lea ecx, [esp + 0x108]
xor eax, eax
mov esi, edx
neg esi
sbb esi, esi
and esi, 0xffffffdf
add esi, 0x20
mov dword [esp + 0x24], esi
fild dword [esp + 0x24]
mov esi, edx
dec esi
neg esi
sbb esi, esi
fstp dword [esp + 0x2c]
and esi, 0xffffffdf
add esi, 0x20
mov dword [esp + 0x24], esi
fild dword [esp + 0x24]
mov esi, edx
sub esi, 2
neg esi
sbb esi, esi
fstp dword [esp + 0x64]
and esi, 0xffffffdf
add esi, 0x20
mov dword [esp + 0x24], esi
fild dword [esp + 0x24]
fstp dword [esp + 0x24]
fld dword [esp + 0x2c]
fld dword [esp + 0x64]
fld dword [esp + 0x24]
fld dword [esp + eax*4 + 0xb4]
inc eax
fmul st(3)
add ecx, 4
cmp eax, 3
fdiv st(4)
fadd dword [ecx - 4]
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
fld dword [esp + eax*4 + 0xbc]
fmul st(3)
fdiv st(5)
faddp st(1)
fstp dword [esp + 0x24]
fld dword [esp + 0x24]
fld dword [esp + eax*4 + 0xc8]
fmul st(2)
fdiv st(5)
faddp st(1)
fstp dword [ecx - 4]
jl 0x40dfd8
fstp st(2)
inc edx
cmp edx, 3
fstp st(0)
fstp st(0)
jl 0x40df7e
fstp st(0)
push ecx
fld dword [esp + 0x3c]
lea eax, [esp + 0x90]
lea ecx, [esp + 0x100]
fstp dword [esp]
lea edi, [esp + 0x130]
call fcn.0040d510
fld dword [esp + 0x74]
fld qword [0x451938]
lea eax, [esp + 0x90]
fdiv st(1), st(0)
lea ecx, [esp + 0x74]
lea edi, [esp + 0x13c]
fxch st(1)
fstp dword [esp + 0x74]
fld dword [esp + 0x78]
fdiv st(1)
fstp dword [esp + 0x78]
fdivr dword [esp + 0x7c]
fstp dword [esp + 0x7c]
fld dword [esp + 0x3c]
fstp dword [esp]
call fcn.0040d510
fld dword [esp + 0x74]
fdiv dword [esp + 0x90]
sub esp, 0x14
fadd qword [esp + 0x288]
fld dword [esp + 0x8c]
fdiv dword [esp + 0xa8]
faddp st(1)
fld dword [esp + 0x90]
fdiv dword [esp + 0xac]
faddp st(1)
fst qword [esp + 0x288]
fld dword [esp + 0x50]
fstp qword [esp + 0x10]
fst qword [esp + 8]
fstp qword [esp]
call fcn.0040d3f0
fld qword [esp + 0x288]
mov dword [esp + 0x15c], eax
fadd st(0), st(0)
fld dword [esp + 0x50]
fstp qword [esp + 0x10]
fst qword [esp + 8]
fstp qword [esp]
call fcn.0040d3f0
mov dword [esp + 0x160], eax
lea eax, [esp + 0x114]
push str.SpatialGain
push eax
call fcn.0040cdb0
add esp, 0x20
mov dword [esp + 0x24], eax
test eax, eax
je 0x40da4e
mov esi, dword [esp + 0x100]
push 0xc
push esi
call fcn.004348ad
movzx ebx, word [0x466040]
mov dword [esp + 0x50], eax
lea eax, [ebx + esi - 2]
dec esi
xor edx, edx
div esi
movzx esi, word [0x4ac486]
push 0xc
push esi
mov dword [esp + 0x38], esi
mov dword [esp + 0x74], eax
call fcn.004348ad
add esp, 0x10
mov dword [esp + 0x60], eax
mov dword [esp + 0x34], 0
test esi, esi
jle 0x40e262
fild dword [esp + 0x28]
mov edx, dword [0x4ac418]
lea ecx, [ebx*8]
mov edi, eax
fsub qword [0x4517d8]
mov dword [esp + 0x30], ecx
mov dword [esp + 0x50], edx
fstp qword [esp + 0x168]
fild dword [esp + 0x34]
xor eax, eax
fdiv qword [esp + 0x168]
fld dword [esp + eax*4 + 0x1d8]
inc eax
cmp eax, 6
fsub dword [esp + eax*4 + 0x1bc]
fmul st(1)
fadd dword [esp + eax*4 + 0x1bc]
fstp dword [esp + eax*4 + 0x1a4]
jl 0x40e1b4
mov ebx, dword [esp + 0x50]
fstp st(0)
xor esi, esi
fld dword [esp + 0x38]
push ecx
lea eax, [esp + 0xe4]
fstp dword [esp]
call fcn.0040d1a0
fmul qword [0x451938]
lea eax, [esp + 0xdc]
fstp qword [esp + 0x274]
fld dword [esp + 0x3c]
fstp dword [esp]
call fcn.0040d1a0
fadd qword [esp + 0x274]
inc esi
add esp, 4
add ebx, 2
fsub dword [esp + esi*8 + 0x1a0]
add edi, 4
cmp esi, 3
fmul qword [0x451840]
fsub dword [esp + esi*8 + 0x1a4]
fstp dword [edi - 4]
jl 0x40e1e0
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x30]
add dword [esp + 0x50], ecx
inc eax
cmp eax, dword [esp + 0x28]
mov dword [esp + 0x34], eax
jl 0x40e1a7
mov eax, dword [esp + 0x28]
jmp 0x40e264
mov eax, esi
mov ebx, dword [esp + 0x60]
lea esi, [ebx + 0x60]
mov ecx, 0x18
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
lea ecx, [eax + eax*2 - 0x21]
lea edi, [ebx + ecx*4]
lea edx, [eax + eax*2 - 0x42]
lea esi, [ebx + edx*4]
mov ecx, 0x21
rep movsd dword es:[edi], dword [esi]
mov ecx, 9
mov esi, ebx
lea edi, [esp + 0xb4]
rep movsd dword es:[edi], dword [esi]
mov edi, 1
dec eax
cmp eax, edi
jle 0x40e483
lea ecx, [ebx + 0x14]
lea esi, [ebx + 0x18]
mov dword [esp + 0x50], ecx
jmp 0x40e2b7
mov ecx, dword [esp + 0x50]
fld dword [esp + 0xc0]
fld dword [esp + 0xb4]
fcom st(1)
fnstsw ax
fld dword [esp + 0xcc]
fcom st(2)
test ah, 5
fnstsw ax
fstp st(2)
jp 0x40e307
test ah, 5
jp 0x40e333
fcom st(1)
fnstsw ax
test ah, 0x41
jne 0x40e2f8
fstp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 8]
jmp 0x40e337
fstp st(0)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 8]
jmp 0x40e337
test ah, 0x41
jne 0x40e333
fcom st(1)
fnstsw ax
test ah, 5
jp 0x40e324
fstp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 8]
jmp 0x40e337
fstp st(0)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 8]
jmp 0x40e337
fstp st(1)
fstp st(0)
fld dword [esp + 0xc4]
fld dword [esp + 0xb8]
fcom st(1)
fnstsw ax
fld dword [esp + 0xd0]
fcom st(2)
test ah, 5
fnstsw ax
fstp st(2)
jp 0x40e387
test ah, 5
jp 0x40e3b3
fcom st(1)
fnstsw ax
test ah, 0x41
jne 0x40e378
fstp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 4]
jmp 0x40e3b7
fstp st(0)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 4]
jmp 0x40e3b7
test ah, 0x41
jne 0x40e3b3
fcom st(1)
fnstsw ax
test ah, 5
jp 0x40e3a4
fstp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 4]
jmp 0x40e3b7
fstp st(0)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx - 4]
jmp 0x40e3b7
fstp st(1)
fstp st(0)
fld dword [esp + 0xc8]
fld dword [esp + 0xbc]
fcom st(1)
fnstsw ax
fld dword [esp + 0xd4]
fcom st(2)
test ah, 5
fnstsw ax
fstp st(2)
jp 0x40e405
test ah, 5
jp 0x40e42f
fcom st(1)
fnstsw ax
test ah, 0x41
jne 0x40e3f7
fstp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx]
jmp 0x40e433
fstp st(0)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx]
jmp 0x40e433
test ah, 0x41
jne 0x40e42f
fcom st(1)
fnstsw ax
test ah, 5
jp 0x40e421
fstp st(1)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx]
jmp 0x40e433
fstp st(0)
fstp dword [esp + 0x28]
fld dword [esp + 0x28]
fstp dword [ecx]
jmp 0x40e433
fstp st(1)
fstp st(0)
push 0x18
lea edx, [esp + 0xc4]
push edx
lea eax, [esp + 0xbc]
push eax
call fcn.00434170
mov ecx, dword [esi]
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
add dword [esp + 0x5c], 0xc
mov dword [esp + 0xd8], ecx
movzx ecx, word [0x4ac486]
inc edi
dec ecx
add esp, 0xc
add esi, 0xc
cmp edi, ecx
mov dword [esp + 0xd0], edx
mov dword [esp + 0xd4], eax
jl 0x40e2b3
fld dword [esp + 0xb4]
lea edi, [edi + edi*2]
fadd dword [esp + 0xc0]
lea esi, [ebx + 4]
fld qword [0x4517d0]
lea eax, [ebx + 8]
fmul st(1), st(0)
mov dword [esp + 0x58], eax
fxch st(1)
fstp dword [ebx + edi*4]
fld dword [esp + 0xb8]
fadd dword [esp + 0xc4]
fmul st(1)
fstp dword [ebx + edi*4 + 4]
fld dword [esp + 0xbc]
fadd dword [esp + 0xc8]
fmul st(1)
fstp dword [ebx + edi*4 + 8]
fld dword [ebx + 0x24]
fadd dword [ebx + 0xc]
fmul st(1)
fstp dword [ebx]
fld dword [ebx + 0x28]
fadd dword [ebx + 0x10]
fmul st(1)
fstp dword [esi]
fld dword [ebx + 0x2c]
fadd dword [ebx + 0x14]
fmulp st(1)
fstp dword [eax]
fld qword [0x451920]
call fcn.00447aac
fld1
movzx edi, word [0x4ac486]
fsubrp st(1)
cmp edi, 1
mov edx, dword [ebx]
mov eax, dword [ebx + 4]
mov ecx, dword [ebx + 8]
fstp dword [esp + 0x3c]
fld dword [esp + 0x3c]
mov dword [esp + 0x80], edx
mov dword [esp + 0x84], eax
mov dword [esp + 0x88], ecx
mov dword [esp + 0x28], edi
jle 0x40e5ac
mov eax, esi
lea ecx, [edi - 1]
fld dword [eax + 8]
add eax, 0xc
sub ecx, 1
fsub dword [eax - 0x10]
fmul st(1)
fadd dword [eax - 0x10]
fstp dword [esp + 0x2c]
fld dword [esp + 0x2c]
fst dword [eax - 4]
fadd dword [esp + 0x80]
fstp dword [esp + 0x80]
fld dword [eax]
fsub dword [eax - 0xc]
fmul st(1)
fadd dword [eax - 0xc]
fstp dword [esp + 0x2c]
fld dword [esp + 0x2c]
fst dword [eax]
fadd dword [esp + 0x84]
fstp dword [esp + 0x84]
fld dword [eax + 4]
fsub dword [eax - 8]
fmul st(1)
fadd dword [eax - 8]
fstp dword [esp + 0x2c]
fld dword [esp + 0x2c]
fst dword [eax + 4]
fadd dword [esp + 0x88]
fstp dword [esp + 0x88]
jne 0x40e53a
fild dword [esp + 0x28]
lea edx, [edi + edi*2]
fld dword [esp + 0x80]
mov ecx, dword [ebx + edx*4 - 0xc]
lea eax, [ebx + edx*4 - 0xc]
fdiv st(1)
mov edx, dword [eax + 4]
mov eax, dword [eax + 8]
mov dword [esp + 0xbc], eax
mov eax, edi
mov dword [esp + 0xb4], ecx
mov dword [esp + 0xb8], edx
fstp dword [esp + 0x80]
fld dword [esp + 0x84]
fdiv st(1)
fstp dword [esp + 0x84]
fld dword [esp + 0x88]
fdiv st(1)
fstp dword [esp + 0x88]
fld dword [esp + 0x88]
fld dword [esp + 0x84]
fld dword [esp + 0x80]
test eax, eax
je 0x40e6aa
lea ecx, [eax + eax*2]
lea ebx, [ebx + ecx*4 + 8]
fld dword [ebx - 0x14]
sub ebx, 0xc
fsub st(1)
dec eax
fld dword [esp + 0xb4]
fld st(0)
fsubp st(2)
fld st(6)
fmulp st(2)
faddp st(1)
fstp dword [esp + 0x2c]
fld dword [esp + 0x2c]
fst dword [ebx - 8]
fstp dword [esp + 0xb4]
fld dword [ebx - 4]
fsub st(2)
fld dword [esp + 0xb8]
fld st(0)
fsubp st(2)
fld st(6)
fmulp st(2)
faddp st(1)
fstp dword [esp + 0x2c]
fld dword [esp + 0x2c]
fst dword [ebx - 4]
fstp dword [esp + 0xb8]
fld dword [ebx]
fsub st(3)
fld dword [esp + 0xbc]
fld st(0)
fsubp st(2)
fld st(6)
fmulp st(2)
faddp st(1)
fstp dword [esp + 0x2c]
fld dword [esp + 0x2c]
fst dword [ebx]
fstp dword [esp + 0xbc]
test eax, eax
jne 0x40e62c
xor eax, eax
fstp st(4)
cmp edi, 2
mov edx, eax
mov esi, eax
mov dword [esp + 0x98], edx
mov dword [esp + 0x9c], esi
mov dword [esp + 0xa0], eax
mov dword [esp + 0xa4], eax
jle 0x40e76f
movzx eax, word [0x466040]
mov ebx, dword [0x4ac418]
mov ecx, eax
shl eax, 4
lea eax, [eax + ebx + 0x14]
mov dword [esp + 0x50], eax
lea eax, [edi - 3]
shl ecx, 5
shr eax, 2
inc eax
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x4c], eax
movzx ebx, word [0x466040]
cmp ebx, 2
jle 0x40e754
mov eax, dword [esp + 0x50]
mov edi, dword [esp + 0xa0]
lea ecx, [ebx - 3]
shr ecx, 2
inc ecx
movsx ebx, word [eax - 4]
inc dword [esp + 0xa4]
add edx, ebx
movsx ebx, word [eax - 2]
add esi, ebx
movsx ebx, word [eax]
add edi, ebx
add eax, 0x20
sub ecx, 1
jne 0x40e721
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x4c]
mov dword [esp + 0xa0], edi
mov edi, dword [esp + 0x28]
add dword [esp + 0x50], ecx
sub eax, 1
mov dword [esp + 0x4c], eax
jne 0x40e703
mov dword [esp + 0x9c], esi
mov dword [esp + 0x98], edx
test edi, edi
jle 0x40e7dd
fild dword [esp + 0xa4]
mov eax, dword [esp + 0x58]
mov ecx, edi
fmul qword [0x451908]
fild dword [esp + 0x98]
fdiv st(1)
fld qword [0x4517d0]
fmul st(6), st(0)
fxch st(1)
faddp st(6)
fild dword [esp + 0x9c]
fdiv st(2)
fxch st(3)
fmul st(1)
faddp st(3)
fild dword [esp + 0xa0]
fdivrp st(2)
fmulp st(3)
faddp st(2)
fld dword [eax - 8]
add eax, 0xc
sub ecx, 1
fadd st(4)
fstp dword [eax - 0x14]
fld dword [eax - 0x10]
fadd st(1)
fstp dword [eax - 0x10]
fld dword [eax - 0xc]
fadd st(2)
fstp dword [eax - 0xc]
jne 0x40e7b7
fstp st(1)
fstp st(2)
jmp 0x40e7e1
fstp st(1)
fstp st(0)
fstp st(1)
mov dword [esp + 0x34], 0
test edi, edi
jle 0x40ebda
fsub qword [0x4517d8]
mov eax, dword [esp + 0x104]
dec eax
mov dword [esp + 0x68], eax
fstp qword [esp + 0x168]
mov dword [esp + 0x7c], eax
fild dword [esp + 0x68]
test eax, eax
jge 0x40e81e
fadd qword [0x451828]
movzx ecx, word [0x466040]
fstp qword [esp + 0x1f0]
mov edx, dword [esp + 0x60]
mov eax, dword [0x4ac418]
mov dword [esp + 0x40], ecx
mov dword [esp + 0x4c], edx
mov dword [esp + 0x50], eax
fild dword [esp + 0x34]
xor eax, eax
fdiv qword [esp + 0x168]
fld dword [esp + eax*4 + 0x1d8]
inc eax
cmp eax, 6
fsub dword [esp + eax*4 + 0x1bc]
fmul st(1)
fadd dword [esp + eax*4 + 0x1bc]
fstp dword [esp + eax*4 + 0x1a4]
jl 0x40e84e
fmul qword [esp + 0x1f0]
mov eax, dword [esp + 0x50]
mov ecx, dword [eax]
mov dx, word [eax + 4]
fstp dword [esp + 0x58]
mov dword [esp + 0x30], eax
fld dword [esp + 0x58]
mov dword [esp + 0x270], ecx
fld st(0)
mov word [esp + 0x274], dx
call fcn.00436cf0
mov dword [esp + 0x58], eax
cmp eax, dword [esp + 0x7c]
jne 0x40e8b4
dec eax
mov dword [esp + 0x58], eax
fisub dword [esp + 0x58]
mov esi, dword [esp + 0x100]
fstp dword [esp + 0x58]
test esi, esi
jbe 0x40e932
mov edx, dword [esp + 0x48]
fld dword [esp + 0x58]
mov edi, dword [esp + 0x24]
fld st(0)
fld1
lea ecx, [eax + 1]
imul ecx, esi
fsubrp st(1)
add edx, 8
imul eax, esi
lea ecx, [ecx + ecx*2]
lea eax, [eax + eax*2]
lea ecx, [edi + ecx*4 + 8]
lea eax, [edi + eax*4 + 8]
fld dword [ecx - 8]
add eax, 0xc
fmul st(2)
add ecx, 0xc
fld dword [eax - 0x14]
add edx, 0xc
sub esi, 1
fmul st(2)
faddp st(1)
fstp dword [edx - 0x14]
fld dword [ecx - 0x10]
fmul st(2)
fld dword [eax - 0x10]
fmul st(2)
faddp st(1)
fstp dword [edx - 0x10]
fld dword [ecx - 0xc]
fmul st(2)
fld dword [eax - 0xc]
fmul st(2)
faddp st(1)
fstp dword [edx - 0xc]
jne 0x40e8f3
fstp st(1)
fstp st(0)
cmp dword [esp + 0x40], 0
mov dword [esp + 0x44], 0
jle 0x40ebb2
fild dword [esp + 0x40]
lea eax, [esp + 0x270]
sub eax, dword [esp + 0x50]
fstp qword [esp + 0x1f8]
mov dword [esp + 0x58], eax
fild dword [esp + 0x64]
fstp qword [esp + 0xd8]
fild dword [esp + 0x44]
mov edi, dword [esp + 0x30]
mov ebx, dword [esp + 0x4c]
xor esi, esi
fdiv qword [esp + 0x1f8]
fsub qword [0x4517d0]
fstp qword [esp + 0x68]
movzx ecx, word [edi]
mov edx, dword [esp + 0x58]
movsx edx, word [edi + edx]
movsx eax, cx
mov dword [esp + 0x3c], eax
sub eax, edx
mov edx, dword [esp + 0x58]
mov word [edi + edx], cx
mov ecx, eax
imul ecx, eax
sar ecx, 0xe
add ecx, eax
mov dword [esp + 0x2c], ecx
sub esp, 8
fild dword [esp + 0x34]
fmul dword [esp + 0x40]
fsub dword [esp + esi*8 + 0x1b4]
fld dword [esp + esi*8 + 0x1b0]
fmul qword [esp + 0x70]
fsubp st(1)
fsub dword [ebx]
fstp qword [esp]
call fcn.00447f40
fiadd dword [esp + 0x44]
add esp, 8
call fcn.00436cf0
mov dword [esp + esi*4 + 0x70], eax
inc esi
add edi, 2
add ebx, 4
cmp esi, 3
jl 0x40e989
mov eax, dword [esp + 0x70]
mov esi, dword [esp + 0x74]
mov ecx, eax
imul ecx, eax
sar ecx, 0xe
mov edx, eax
imul edx, ecx
sar edx, 0xe
mov dword [esp + 0x19c], edx
mov dword [esp + 0x184], ecx
mov ecx, dword [esp + 0x78]
mov edx, esi
imul edx, ecx
sar edx, 0xe
mov dword [esp + 0x198], edx
mov edx, esi
imul edx, esi
sar edx, 0xe
mov dword [esp + 0x188], edx
mov edi, esi
imul edi, edx
mov edx, eax
imul eax, esi
imul edx, ecx
sar edx, 0xe
mov dword [esp + 0x194], edx
mov edx, ecx
imul edx, ecx
sar edx, 0xe
imul ecx, edx
sar eax, 0xe
sar ecx, 0xe
mov dword [esp + 0x190], eax
mov eax, dword [esp + 0x44]
mov dword [esp + 0x18c], edx
mov dword [esp + 0x1a4], ecx
mov ecx, dword [esp + 0x64]
cdq
idiv ecx
sar edi, 0xe
mov dword [esp + 0x1a0], edi
lea esi, [esp + 0x204]
sub ecx, edx
mov dword [esp + 0x2c], ecx
fild dword [esp + 0x2c]
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x3c], edx
lea edx, [eax + eax*2 + 3]
mov eax, dword [esp + 0x48]
fstp dword [esp + 0x5c]
fild dword [esp + 0x3c]
mov dword [esp + 0x2c], ecx
lea ebx, [eax + edx*4]
xor edi, edi
fstp dword [esp + 0x68]
jmp 0x40ead0
fldz
lea eax, [esp + 0x188]
fstp dword [esp + 0x3c]
mov ecx, 3
fild dword [eax - 4]
add eax, 0xc
add esi, 0xc
sub ecx, 1
fmul dword [esi - 0x10]
fadd dword [esp + 0x3c]
fstp dword [esp + 0x3c]
fld dword [esp + 0x3c]
fild dword [eax - 0xc]
fmul dword [esi - 0xc]
faddp st(1)
fstp dword [esp + 0x3c]
fld dword [esp + 0x3c]
fild dword [eax - 8]
fmul dword [esi - 8]
faddp st(1)
fstp dword [esp + 0x3c]
jne 0x40eae2
fld dword [esp + 0x3c]
sub esp, 8
fstp qword [esp]
call fcn.00447f40
fiadd dword [esp + edi + 0x78]
fld dword [ebx - 0xc]
fmul dword [esp + 0x64]
fld dword [esp + 0x70]
fmul dword [ebx]
faddp st(1)
fmulp st(1)
fdiv qword [esp + 0xe0]
fdiv dword [esp + edi + 0x94]
fstp qword [esp]
call fcn.00447f40
add esp, 8
call fcn.00436cf0
cmp eax, 0x7d00
mov dword [esp + edi + 0x70], eax
jle 0x40eb70
mov dword [esp + edi + 0x70], 0x7d00
mov eax, dword [esp + 0x2c]
mov cx, word [esp + edi + 0x70]
mov word [eax], cx
add edi, 4
add eax, 2
add ebx, 4
cmp edi, 0xc
mov dword [esp + 0x2c], eax
jl 0x40ead0
mov eax, 8
add dword [esp + 0x30], eax
sub dword [esp + 0x58], eax
mov eax, dword [esp + 0x44]
inc eax
cmp eax, dword [esp + 0x40]
mov dword [esp + 0x44], eax
jl 0x40e96a
mov ecx, dword [esp + 0x40]
mov eax, dword [esp + 0x34]
add dword [esp + 0x4c], 0xc
add ecx, ecx
add ecx, ecx
add ecx, ecx
add dword [esp + 0x50], ecx
inc eax
cmp eax, dword [esp + 0x28]
mov dword [esp + 0x34], eax
jl 0x40e841
jmp 0x40ebdc
fstp st(0)
mov edx, dword [esp + 0x60]
push edx
call fcn.0043481f
mov eax, dword [esp + 0x4c]
add esp, 4
push eax
call fcn.0043481f
mov ecx, dword [esp + 0x28]
add esp, 4
push ecx
call fcn.0043481f
add esp, 4
lea edx, [esp + 0xfc]
push str.BadPixels
push edx
call fcn.0040cdb0
mov edx, eax
add esp, 8
mov dword [esp + 0x24], edx
test edx, edx
je 0x40edb4
xor ecx, ecx
mov dword [esp + 0x28], ecx
cmp dword [esp + 0xfc], ecx
jbe 0x40edab
movzx eax, word [0x4ac486]
add eax, 0xfffffffd
mov dword [esp + 0x68], eax
mov eax, dword [edx + ecx*4]
mov esi, eax
shr esi, 0x14
sub esi, dword [esp + 0x178]
mov edx, eax
shr edx, 8
and edx, 0xfff
sub edx, dword [esp + 0x174]
lea ecx, [esi - 1]
mov dword [esp + 0x7c], eax
cmp ecx, dword [esp + 0x68]
ja 0x40ed91
movzx edi, word [0x466040]
lea ecx, [edi - 3]
lea ebx, [edx - 1]
cmp ebx, ecx
ja 0x40ed91
xor ecx, ecx
mov dword [esp + 0x80], ecx
mov dword [esp + 0x84], ecx
mov dword [esp + 0x88], ecx
mov dword [esp + 0x44], ecx
lea esp, [esp]
mov ebx, 1
shl ebx, cl
test eax, ebx
je 0x40ed48
movsx ebx, word [ecx*4 + 0x44eb00]
fld dword [esp + 0x80]
movsx eax, word [ecx*4 + 0x44eb02]
add ebx, esi
imul ebx, edi
add ebx, edx
add eax, ebx
mov ebx, dword [0x4ac418]
add eax, eax
add eax, eax
movsx ebx, word [ebx + eax*2]
mov dword [esp + 0x5c], ebx
mov ebx, dword [0x4ac418]
movsx ebx, word [ebx + eax*2 + 2]
fild dword [esp + 0x5c]
inc dword [esp + 0x44]
faddp st(1)
mov dword [esp + 0x5c], ebx
mov ebx, dword [0x4ac418]
movsx eax, word [ebx + eax*2 + 4]
fstp dword [esp + 0x80]
fild dword [esp + 0x5c]
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x7c]
fadd dword [esp + 0x84]
fstp dword [esp + 0x84]
fild dword [esp + 0x5c]
fadd dword [esp + 0x88]
fstp dword [esp + 0x88]
inc ecx
cmp ecx, 8
jl 0x40ecb0
cmp dword [esp + 0x44], 0
je 0x40ed91
fild dword [esp + 0x44]
mov ecx, dword [0x4ac418]
imul edi, esi
fstp dword [esp + 0x5c]
fld dword [esp + 0x5c]
xor ebx, ebx
add edi, edx
lea edi, [ecx + edi*8]
fld dword [esp + ebx*4 + 0x80]
fdiv st(1)
call fcn.00436cf0
mov word [edi], ax
inc ebx
add edi, 2
cmp ebx, 3
jl 0x40ed75
fstp st(0)
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x24]
inc ecx
mov dword [esp + 0x28], ecx
cmp ecx, dword [esp + 0xfc]
jb 0x40ec47
push edx
call fcn.0043481f
add esp, 4
movzx esi, word [0x466040]
lea edx, [esi + esi*4]
push 0xc
push edx
mov dword [esp + 0x48], esi
call fcn.004348ad
add esp, 8
mov dword [esp + 0xf0], eax
test eax, eax
je 0x410064
lea esi, [esi + esi*2]
add esi, esi
xor ecx, ecx
xor edx, edx
add esi, esi
mov dword [esp + 0x50], esi
jmp 0x40edf7
mov eax, dword [esp + 0xf0]
add eax, edx
mov dword [esp + ecx*4 + 0xd8], eax
inc ecx
add edx, esi
cmp ecx, 5
jl 0x40edf0
movzx ecx, word [0x4ac486]
mov dword [esp + 0x28], ecx
or edx, 0xffffffff
add ecx, 0xfffffffe
cmp ecx, 2
mov dword [esp + 0x38], edx
jle 0x40efcd
mov eax, dword [esp + 0x40]
lea ebx, [eax - 2]
lea esi, [eax*8]
inc eax
shl eax, 4
add eax, dword [0x4ac418]
mov edi, 4
add ecx, 0xfffffffe
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x48], edi
mov dword [esp + 0x30], esi
mov dword [esp + 0x4c], eax
mov dword [esp + 0x2c], ecx
jmp 0x40ee68
mov edx, dword [esp + 0x38]
mov edi, dword [esp + 0x48]
cmp edx, edi
jge 0x40ef11
mov ecx, dword [0x4ac418]
mov eax, edx
imul eax, dword [esp + 0x40]
lea esi, [ecx + eax*8 + 0x10]
mov eax, edi
sub eax, edx
add edx, eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x38], edx
nop
xor ecx, ecx
lea eax, [ecx + 5]
cdq
mov edi, 6
idiv edi
mov eax, dword [esp + ecx*4 + 0xd8]
inc ecx
cmp ecx, edi
mov dword [esp + edx*4 + 0xd8], eax
jl 0x40ee92
add esi, dword [esp + 0x30]
cmp ebx, 2
mov dword [esp + 0x68], esi
mov eax, esi
jle 0x40ef06
mov edx, dword [esp + 0xe8]
add edx, 0x18
lea esi, [ebx - 2]
lea esp, [esp]
movsx ecx, word [eax + 8]
movsx edi, word [eax - 8]
add edi, ecx
movsx ecx, word [eax]
lea ecx, [ecx + ecx*2]
add ecx, ecx
lea ecx, [ecx + edi*4 + 8]
movsx edi, word [eax - 0x10]
add ecx, edi
movsx edi, word [eax + 0x10]
add ecx, edi
sar ecx, 4
mov dword [edx], ecx
add eax, 8
add edx, 0xc
sub esi, 1
jne 0x40eed0
mov esi, dword [esp + 0x68]
sub dword [esp + 0x24], 1
jne 0x40ee90
mov eax, dword [esp + 0x4c]
mov edx, 2
cmp ebx, edx
mov edi, eax
jle 0x40efae
mov eax, dword [esp + 0xe4]
lea ecx, [edx + edx*2]
add ecx, ecx
add ecx, ecx
mov esi, dword [ecx + eax]
mov eax, dword [esp + 0xdc]
add esi, dword [ecx + eax]
mov eax, dword [esp + 0xe0]
mov eax, dword [ecx + eax]
lea eax, [eax + eax*2]
add eax, eax
lea eax, [eax + esi*4 + 8]
mov esi, dword [esp + 0xd8]
add eax, dword [ecx + esi]
mov esi, dword [esp + 0xe8]
add eax, dword [ecx + esi]
sar eax, 4
cmp edx, 2
jne 0x40ef6e
mov dword [esp + 0x54], eax
movsx esi, word [edi]
lea ebx, [eax*8]
sub ebx, eax
add ebx, dword [esp + 0x54]
mov ecx, esi
sar ebx, 3
sub ecx, ebx
sar ecx, 3
add ecx, esi
cmp ecx, 0x7d00
jle 0x40ef97
mov ecx, 0x7d00
mov ebx, dword [esp + 0x5c]
mov word [edi], cx
inc edx
add edi, 8
cmp edx, ebx
mov dword [esp + 0x54], eax
jl 0x40ef20
mov eax, dword [esp + 0x4c]
add eax, dword [esp + 0x30]
mov ecx, 1
add dword [esp + 0x48], ecx
sub dword [esp + 0x2c], ecx
mov dword [esp + 0x4c], eax
jne 0x40ee60
mov edi, 0xffff
xor esi, esi
jmp 0x40efe0
fild dword [esp + esi + 0x14c]
fdiv dword [esp + esi + 0x8c]
call fcn.00436cf0
cmp edi, eax
jle 0x40eff9
mov edi, eax
add esi, 4
cmp esi, 0xc
jl 0x40efe0
mov ecx, dword [esp + 0x28]
imul ecx, dword [esp + 0x40]
mov esi, dword [0x4ac418]
lea edi, [edi + edi*8]
lea ebx, [esi + ecx*8]
sar edi, 4
mov dword [esp + 0x68], edi
mov dword [esp + 0x60], ebx
cmp esi, ebx
jae 0x40f0fb
lea esp, [esp]
movsx ecx, word [esi]
cmp ecx, edi
jle 0x40f0f0
movsx edx, word [esi + 2]
cmp edx, edi
jle 0x40f0f0
movsx eax, word [esi + 4]
cmp eax, edi
jle 0x40f0f0
movsx eax, word [esi + 2]
cmp ecx, eax
mov edx, ecx
jle 0x40f05f
mov edx, eax
jge 0x40f063
mov ecx, eax
movsx eax, word [esi + 4]
cmp edx, eax
jle 0x40f06d
mov edx, eax
cmp ecx, eax
jge 0x40f073
mov ecx, eax
lea eax, [edi + edi]
cmp edx, eax
jl 0x40f083
mov word [esi + 2], cx
mov word [esi], cx
jmp 0x40f0ec
mov eax, edi
sub eax, edx
shl eax, 0xe
cdq
idiv edi
mov ebx, ecx
add eax, 0x4000
mov edx, eax
imul edx, eax
sar edx, 0xe
mov eax, 0x4000
sub eax, edx
movzx edx, word [esi]
imul eax, eax
movsx edi, dx
sub ebx, edi
sar eax, 0xe
imul ebx, eax
sar ebx, 0xe
add ebx, edx
movzx edx, word [esi + 2]
mov word [esi], bx
movsx edi, dx
mov ebx, ecx
sub ebx, edi
imul ebx, eax
sar ebx, 0xe
add ebx, edx
movzx edx, word [esi + 4]
movsx edi, dx
sub ecx, edi
mov edi, dword [esp + 0x68]
imul ecx, eax
sar ecx, 0xe
mov word [esi + 2], bx
mov ebx, dword [esp + 0x60]
add ecx, edx
mov word [esi + 4], cx
add esi, 8
cmp esi, ebx
jb 0x40f030
mov eax, dword [esp + 0x28]
add eax, 0xfffffffe
cmp eax, 2
mov dword [esp + 0x38], 0xffffffff
jle 0x40f3e4
mov eax, dword [esp + 0x40]
inc eax
shl eax, 4
add eax, dword [0x4ac418]
mov dword [esp + 0x48], 4
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x28]
add eax, 0xfffffffc
mov dword [esp + 0x2c], eax
jmp 0x40f140
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x48]
cmp eax, ecx
mov esi, dword [esp + 0x40]
jge 0x40f214
mov edi, dword [0x4ac418]
mov edx, eax
imul edx, esi
sub ecx, eax
add eax, ecx
lea edi, [edi + edx*8 + 0x10]
mov dword [esp + 0x24], ecx
mov dword [esp + 0x38], eax
nop
xor ecx, ecx
lea eax, [ecx + 5]
cdq
mov ebx, 6
idiv ebx
mov eax, dword [esp + ecx*4 + 0xd8]
inc ecx
cmp ecx, ebx
mov dword [esp + edx*4 + 0xd8], eax
jl 0x40f172
lea eax, [esi*8]
add edi, eax
lea edx, [esi - 2]
cmp edx, 2
mov dword [esp + 0x68], edi
mov eax, edi
jle 0x40f209
mov ecx, dword [esp + 0xe8]
add ecx, 0x20
add edx, 0xfffffffe
movsx ebx, word [eax - 8]
movsx edi, word [eax]
lea edi, [ebx + edi*2 + 2]
movsx ebx, word [eax + 8]
add edi, ebx
sar edi, 2
mov dword [ecx - 8], edi
movsx ebx, word [eax + 0xa]
movsx edi, word [eax + 2]
lea edi, [ebx + edi*2 + 2]
movsx ebx, word [eax - 6]
add edi, ebx
sar edi, 2
mov dword [ecx - 4], edi
movsx ebx, word [eax + 0xc]
movsx edi, word [eax + 4]
lea edi, [ebx + edi*2 + 2]
movsx ebx, word [eax - 4]
add edi, ebx
sar edi, 2
mov dword [ecx], edi
add eax, 8
add ecx, 0xc
sub edx, 1
jne 0x40f1b4
mov edi, dword [esp + 0x68]
sub dword [esp + 0x24], 1
jne 0x40f170
mov ecx, dword [esp + 0x4c]
lea eax, [esi - 2]
cmp eax, 2
jle 0x40f3c3
mov eax, dword [esp + 0xe0]
lea edx, [eax + 0x18]
mov dword [esp + 0x54], edx
mov edx, dword [esp + 0xdc]
lea esi, [edx + 0x20]
mov edi, eax
mov dword [esp + 0x3c], esi
mov esi, dword [esp + 0xe4]
sub edi, esi
sub eax, edx
mov dword [esp + 0x68], edi
mov dword [esp + 0x64], eax
mov eax, dword [esp + 0x40]
mov edi, edx
sub edi, esi
add eax, 0xfffffffc
lea ebx, [esi + 0x1c]
mov dword [esp + 0x5c], edi
mov dword [esp + 0x24], eax
mov edx, dword [esp + 0x3c]
mov eax, dword [ebx - 4]
add eax, dword [edx - 8]
mov edx, dword [esp + 0x54]
mov edx, dword [edx]
movsx esi, word [ecx]
lea eax, [eax + edx*2]
mov edx, dword [esp + 0x148]
movsx edi, word [edx]
sar eax, 2
sub esi, eax
mov eax, esi
cdq
xor eax, edx
sub eax, edx
cmp eax, edi
jl 0x40f29f
xor edi, edi
jmp 0x40f2c3
test esi, esi
jge 0x40f2b7
mov edx, dword [esp + 0x148]
lea eax, [esi + esi]
sub edx, eax
movsx edi, word [edx + 2]
neg edi
jmp 0x40f2c3
mov eax, dword [esp + 0x148]
movsx edi, word [eax + esi*2 + 2]
mov edx, dword [esp + 0x68]
mov eax, dword [edx + ebx]
mov edx, dword [esp + 0x5c]
mov edx, dword [edx + ebx]
movsx esi, word [ecx + 2]
lea eax, [edx + eax*2]
add eax, dword [ebx]
neg edi
sar eax, 2
sub esi, eax
mov eax, esi
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x148]
mov dword [esp + 0x7c], eax
movsx eax, word [edx]
mov edx, dword [esp + 0x7c]
cmp edx, eax
jl 0x40f302
xor esi, esi
jmp 0x40f326
test esi, esi
jge 0x40f31a
mov edx, dword [esp + 0x148]
lea eax, [esi + esi]
sub edx, eax
movsx esi, word [edx + 2]
neg esi
jmp 0x40f326
mov eax, dword [esp + 0x148]
movsx esi, word [eax + esi*2 + 2]
mov eax, dword [esp + 0x3c]
mov edx, dword [esp + 0x64]
mov edx, dword [edx + eax]
mov eax, dword [ebx + 4]
lea edx, [eax + edx*2]
mov eax, dword [esp + 0x3c]
add edx, dword [eax]
movsx eax, word [ecx + 4]
sar edx, 2
sub eax, edx
mov dword [esp + 0x58], eax
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x148]
mov dword [esp + 0x7c], eax
movsx eax, word [edx]
mov edx, dword [esp + 0x7c]
neg esi
cmp edx, eax
jl 0x40f36b
xor edx, edx
jmp 0x40f38b
mov eax, dword [esp + 0x58]
mov edx, dword [esp + 0x148]
test eax, eax
jge 0x40f386
add eax, eax
sub edx, eax
movsx edx, word [edx + 2]
neg edx
jmp 0x40f38b
movsx edx, word [edx + eax*2 + 2]
neg edx
lea eax, [edx + esi]
add eax, edi
sar eax, 3
sub edi, eax
add word [ecx], di
sub esi, eax
add word [ecx + 2], si
sub edx, eax
add word [ecx + 4], dx
mov eax, 0xc
add dword [esp + 0x54], eax
add dword [esp + 0x3c], eax
add ecx, 8
add ebx, eax
sub dword [esp + 0x24], 1
jne 0x40f26b
mov eax, dword [esp + 0x40]
add eax, eax
add eax, eax
mov ecx, 1
add dword [esp + 0x48], ecx
add eax, eax
add dword [esp + 0x4c], eax
sub dword [esp + 0x2c], ecx
jne 0x40f140
mov eax, dword [esp + 0x28]
or ecx, 0xffffffff
add eax, 0xfffffffe
cmp eax, 2
mov dword [esp + 0x38], ecx
jle 0x40f706
mov edx, dword [esp + 0x40]
inc edx
shl edx, 4
add edx, dword [0x4ac418]
mov ebx, 4
add eax, 0xfffffffe
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x48], edx
mov dword [esp + 0x64], eax
jmp 0x40f424
mov ecx, dword [esp + 0x38]
cmp ecx, ebx
mov esi, dword [esp + 0x40]
jge 0x40f528
mov edx, dword [0x4ac418]
mov eax, ecx
imul eax, esi
lea edi, [edx + eax*8 + 0x10]
mov eax, ebx
sub eax, ecx
add ecx, eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x38], ecx
lea ecx, [ecx]
xor ecx, ecx
lea eax, [ecx + 5]
cdq
mov ebx, 6
idiv ebx
mov eax, dword [esp + ecx*4 + 0xd8]
inc ecx
cmp ecx, ebx
mov dword [esp + edx*4 + 0xd8], eax
jl 0x40f452
lea eax, [esi*8]
add edi, eax
lea edx, [esi - 2]
cmp edx, 2
mov dword [esp + 0x68], edi
mov eax, edi
jle 0x40f519
mov ecx, dword [esp + 0xe8]
add ecx, 0x20
add edx, 0xfffffffe
jmp 0x40f4a0
movsx ebx, word [eax + 0x10]
movsx edi, word [eax - 0x10]
add edi, ebx
movsx ebx, word [eax - 8]
add edi, ebx
movsx ebx, word [eax]
add edi, ebx
movsx ebx, word [eax + 8]
lea edi, [edi + ebx + 2]
sar edi, 2
mov dword [ecx - 8], edi
movsx ebx, word [eax - 0xe]
movsx edi, word [eax + 0x12]
add edi, ebx
movsx ebx, word [eax + 0xa]
add edi, ebx
movsx ebx, word [eax - 6]
add edi, ebx
movsx ebx, word [eax + 2]
lea edi, [edi + ebx + 2]
sar edi, 2
mov dword [ecx - 4], edi
movsx ebx, word [eax - 0xc]
movsx edi, word [eax + 0x14]
add edi, ebx
movsx ebx, word [eax + 0xc]
add edi, ebx
movsx ebx, word [eax - 4]
add edi, ebx
movsx ebx, word [eax + 4]
lea edi, [edi + ebx + 2]
sar edi, 2
mov dword [ecx], edi
add eax, 8
add ecx, 0xc
sub edx, 1
jne 0x40f4a0
mov edi, dword [esp + 0x68]
sub dword [esp + 0x24], 1
jne 0x40f450
mov edx, dword [esp + 0x48]
lea ecx, [esi - 2]
cmp ecx, 2
mov dword [esp + 0x30], edx
jle 0x40f6de
add ecx, 0xfffffffe
mov eax, 0x18
mov dword [esp + 0x24], ecx
mov dword [esp + 0xa4], 0x177
mov dword [esp + 0x44], 0x3c
xor esi, esi
lea edi, [esp + 0x98]
mov dword [esp + 0x54], eax
xor edx, edx
mov dword [edi], edx
xor ecx, ecx
lea ebx, [ebx]
mov ebx, dword [esp + edx*4 + 0xd8]
add ecx, dword [ebx + eax]
inc edx
cmp edx, 5
jl 0x40f570
mov ebx, dword [esp + 0x30]
movsx edx, word [ebx + esi*2]
mov dword [edi], ecx
add dword [esp + 0xa4], ecx
mov ecx, dword [esp + 0x44]
add ecx, edx
inc esi
add eax, 4
add edi, 4
cmp esi, 3
mov dword [esp + 0x44], ecx
jl 0x40f564
mov dword [esp + 0x54], eax
test ecx, ecx
jge 0x40f5b1
xor ecx, ecx
cmp dword [esp + 0xa4], 0x177
jle 0x40f5d1
mov eax, ecx
shl eax, 0x10
cdq
idiv dword [esp + 0xa4]
mov dword [esp + 0x30], eax
jmp 0x40f5db
imul ecx, ecx, 0xae
mov dword [esp + 0x30], ecx
mov ecx, dword [esp + 0x98]
imul ecx, dword [esp + 0x30]
movzx edi, word [ebx]
mov esi, dword [esp + 0x144]
add ecx, 0x8000
movsx eax, di
sar ecx, 0x10
sub ecx, eax
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
movsx edx, word [esi]
cmp eax, edx
jl 0x40f611
xor eax, eax
jmp 0x40f629
test ecx, ecx
jge 0x40f624
lea eax, [ecx + ecx]
mov ecx, esi
sub ecx, eax
movsx eax, word [ecx + 2]
neg eax
jmp 0x40f629
movsx eax, word [esi + ecx*2 + 2]
mov ecx, dword [esp + 0x9c]
imul ecx, dword [esp + 0x30]
add eax, edi
movzx edi, word [ebx + 2]
add ecx, 0x8000
movsx edx, di
mov word [ebx], ax
sar ecx, 0x10
sub ecx, edx
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
movsx edx, word [esi]
cmp eax, edx
jl 0x40f65e
xor eax, eax
jmp 0x40f676
test ecx, ecx
jge 0x40f671
lea eax, [ecx + ecx]
mov ecx, esi
sub ecx, eax
movsx eax, word [ecx + 2]
neg eax
jmp 0x40f676
movsx eax, word [esi + ecx*2 + 2]
mov ecx, dword [esp + 0xa0]
imul ecx, dword [esp + 0x30]
add eax, edi
movzx edi, word [ebx + 4]
add ecx, 0x8000
movsx edx, di
mov word [ebx + 2], ax
sar ecx, 0x10
sub ecx, edx
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
movsx edx, word [esi]
cmp eax, edx
jl 0x40f6ac
xor eax, eax
jmp 0x40f6c2
test ecx, ecx
jge 0x40f6bd
lea eax, [ecx + ecx]
sub esi, eax
movsx eax, word [esi + 2]
neg eax
jmp 0x40f6c2
movsx eax, word [esi + ecx*2 + 2]
add eax, edi
mov word [ebx + 4], ax
mov eax, dword [esp + 0x54]
add ebx, 8
sub dword [esp + 0x24], 1
mov dword [esp + 0x30], ebx
jne 0x40f544
mov eax, dword [esp + 0x40]
mov ebx, dword [esp + 0x2c]
mov edx, dword [esp + 0x48]
add eax, eax
add eax, eax
add eax, eax
inc ebx
add edx, eax
sub dword [esp + 0x64], 1
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x48], edx
jne 0x40f420
mov esi, dword [0x4ac418]
cmp esi, dword [esp + 0x60]
jae 0x40f951
fld qword [0x451918]
fld qword [0x4517d0]
fldz
movzx ecx, word [esi]
movsx edi, cx
mov eax, edi
cdq
mov ebx, eax
mov eax, dword [esp + 0x12c]
xor ebx, edx
sub ebx, edx
movsx edx, word [eax]
cmp ebx, edx
jl 0x40f745
xor eax, eax
jmp 0x40f75b
test edi, edi
jge 0x40f756
lea edx, [edi + edi]
sub eax, edx
movsx eax, word [eax + 2]
neg eax
jmp 0x40f75b
movsx eax, word [eax + edi*2 + 2]
sub ecx, eax
mov word [esi], cx
movzx ecx, word [esi + 2]
movsx edi, cx
mov eax, edi
cdq
mov ebx, eax
mov eax, dword [esp + 0x130]
xor ebx, edx
sub ebx, edx
movsx edx, word [eax]
cmp ebx, edx
jl 0x40f782
xor eax, eax
jmp 0x40f798
test edi, edi
jge 0x40f793
lea edx, [edi + edi]
sub eax, edx
movsx eax, word [eax + 2]
neg eax
jmp 0x40f798
movsx eax, word [eax + edi*2 + 2]
sub ecx, eax
mov word [esi + 2], cx
movzx ecx, word [esi + 4]
movsx edi, cx
mov eax, edi
cdq
mov ebx, eax
mov eax, dword [esp + 0x134]
xor ebx, edx
sub ebx, edx
movsx edx, word [eax]
cmp ebx, edx
jl 0x40f7c0
xor eax, eax
jmp 0x40f7d6
test edi, edi
jge 0x40f7d1
lea edx, [edi + edi]
sub eax, edx
movsx eax, word [eax + 2]
neg eax
jmp 0x40f7d6
movsx eax, word [eax + edi*2 + 2]
sub ecx, eax
mov word [esi + 4], cx
movsx eax, word [esi + 2]
movsx edx, word [esi]
movzx ebx, word [esi]
movsx ecx, cx
lea ecx, [ecx + eax*2]
add ecx, edx
movsx edi, bx
sar ecx, 2
sub edi, ecx
mov eax, edi
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x12c]
movsx edx, word [edx]
cmp eax, edx
jl 0x40f80f
xor eax, eax
jmp 0x40f833
test edi, edi
jge 0x40f827
mov edx, dword [esp + 0x12c]
lea eax, [edi + edi]
sub edx, eax
movsx eax, word [edx + 2]
neg eax
jmp 0x40f833
mov eax, dword [esp + 0x12c]
movsx eax, word [eax + edi*2 + 2]
sub ebx, eax
mov word [esi], bx
movzx ebx, word [esi + 2]
movsx edi, bx
sub edi, ecx
mov eax, edi
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x130]
movsx edx, word [edx]
cmp eax, edx
jl 0x40f85a
xor eax, eax
jmp 0x40f87e
test edi, edi
jge 0x40f872
mov edx, dword [esp + 0x130]
lea eax, [edi + edi]
sub edx, eax
movsx eax, word [edx + 2]
neg eax
jmp 0x40f87e
mov eax, dword [esp + 0x130]
movsx eax, word [eax + edi*2 + 2]
sub ebx, eax
mov word [esi + 2], bx
movzx ebx, word [esi + 4]
movsx edi, bx
sub edi, ecx
mov ecx, dword [esp + 0x134]
mov eax, edi
cdq
xor eax, edx
sub eax, edx
movsx edx, word [ecx]
cmp eax, edx
jl 0x40f8a6
xor eax, eax
jmp 0x40f8ca
test edi, edi
jge 0x40f8be
mov ecx, dword [esp + 0x134]
lea eax, [edi + edi]
sub ecx, eax
movsx eax, word [ecx + 2]
neg eax
jmp 0x40f8ca
mov edx, dword [esp + 0x134]
movsx eax, word [edx + edi*2 + 2]
sub ebx, eax
mov word [esi + 4], bx
xor ebx, ebx
lea edi, [esp + 0x108]
xor eax, eax
fld st(0)
movsx ecx, word [esi + eax*2]
mov dword [esp + 0x68], ecx
inc eax
add edi, 4
cmp eax, 3
fild dword [esp + 0x68]
fmul dword [edi - 4]
faddp st(1)
jl 0x40f8dd
fcom st(1)
fnstsw ax
test ah, 5
jp 0x40f906
fstp st(0)
fld st(0)
jmp 0x40f913
fcom st(3)
fnstsw ax
test ah, 0x41
jne 0x40f913
fstp st(0)
fld st(2)
fadd st(2)
call fcn.00436cf0
mov dword [esp + ebx*4 + 0x70], eax
inc ebx
cmp ebx, 3
jl 0x40f8d9
mov dx, word [esp + 0x70]
mov ax, word [esp + 0x74]
mov cx, word [esp + 0x78]
mov word [esi], dx
mov word [esi + 2], ax
mov word [esi + 4], cx
add esi, 8
cmp esi, dword [esp + 0x60]
jb 0x40f724
fstp st(0)
fstp st(1)
fstp st(0)
mov esi, dword [esp + 0x40]
mov ebx, dword [esp + 0x28]
shr esi, 2
shr ebx, 2
mov edx, esi
imul edx, ebx
push 6
push edx
mov dword [esp + 0x50], ebx
mov dword [esp + 0x6c], esi
call fcn.004348ad
add esp, 8
mov dword [esp + 0x38], eax
test eax, eax
je 0x410036
mov dword [esp + 0x34], ebx
test ebx, ebx
je 0x40fb6f
mov ecx, dword [esp + 0x40]
mov edx, esi
imul edx, ebx
lea eax, [ebx + 1]
mov ebx, dword [esp + 0x38]
imul eax, esi
lea edx, [edx + edx*2]
lea edx, [ebx + edx*2 + 4]
mov ebx, dword [0x4ac418]
mov dword [esp + 0x54], edx
mov edx, dword [esp + 0x40]
imul edx, dword [esp + 0x34]
mov dword [esp + 0x3c], eax
lea eax, [esi*4]
sub eax, esi
neg eax
neg ecx
mov edi, esi
neg edi
add eax, eax
shl ecx, 5
shl edx, 5
mov dword [esp + 0x58], edi
mov dword [esp + 0x7c], eax
mov dword [esp + 0x5c], ecx
lea edx, [edx + ebx + 4]
lea esp, [esp]
dec dword [esp + 0x34]
add dword [esp + 0x54], eax
add dword [esp + 0x3c], edi
add edx, ecx
mov dword [esp + 0x68], edx
mov dword [esp + 0x44], 0
test esi, esi
jle 0x40fb64
mov eax, dword [esp + 0x54]
mov dword [esp + 0x4c], edx
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x4c]
xor esi, esi
xor edx, edx
xor ecx, ecx
mov dword [esp + 0x24], eax
mov dword [esp + 0x2c], 4
mov edi, 4
lea esp, [esp]
movsx ebx, word [eax - 4]
add ecx, ebx
movsx ebx, word [eax - 2]
add edx, ebx
movsx ebx, word [eax]
add esi, ebx
add eax, 8
sub edi, 1
jne 0x40fa40
mov edi, dword [esp + 0x40]
mov eax, dword [esp + 0x24]
add edi, edi
add edi, edi
add edi, edi
add eax, edi
sub dword [esp + 0x2c], 1
mov dword [esp + 0x24], eax
jne 0x40fa34
mov eax, dword [esp + 0x34]
add eax, 2
cmp eax, dword [esp + 0x48]
mov eax, dword [esp + 0x44]
jle 0x40fa8a
sar ecx, 4
jmp 0x40fab1
mov edi, dword [esp + 0x3c]
imul ecx, ecx, 0x8d
mov ebx, dword [esp + 0x38]
add edi, eax
lea edi, [edi + edi*2]
movsx edi, word [ebx + edi*2]
imul edi, edi, 0x730
lea ecx, [edi + ecx + 0x800]
sar ecx, 0xc
mov edi, dword [esp + 0x60]
mov word [edi - 4], cx
mov ecx, dword [esp + 0x34]
add ecx, 2
cmp ecx, dword [esp + 0x48]
jle 0x40facb
sar edx, 4
jmp 0x40faf3
mov ecx, dword [esp + 0x3c]
imul edx, edx, 0x8d
mov ebx, dword [esp + 0x38]
add ecx, eax
lea ecx, [ecx + ecx*2]
movsx ecx, word [ebx + ecx*2 + 2]
imul ecx, ecx, 0x730
lea edx, [ecx + edx + 0x800]
sar edx, 0xc
mov ecx, dword [esp + 0x34]
add ecx, 2
cmp ecx, dword [esp + 0x48]
mov word [edi - 2], dx
jle 0x40fb0c
sar esi, 4
mov word [edi], si
jmp 0x40fb37
mov ecx, dword [esp + 0x3c]
imul esi, esi, 0x8d
add ecx, eax
lea edx, [ecx + ecx*2]
mov ecx, dword [esp + 0x38]
movsx edx, word [ecx + edx*2 + 4]
imul edx, edx, 0x730
lea ecx, [edx + esi + 0x800]
sar ecx, 0xc
mov word [edi], cx
mov esi, dword [esp + 0x64]
add dword [esp + 0x4c], 0x20
inc eax
add edi, 6
cmp eax, esi
mov dword [esp + 0x44], eax
mov dword [esp + 0x60], edi
jl 0x40fa1e
mov edx, dword [esp + 0x68]
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x7c]
mov edi, dword [esp + 0x58]
cmp dword [esp + 0x34], 0
jne 0x40f9f0
mov eax, dword [esp + 0x28]
xor ecx, ecx
and eax, 0xfffffffc
mov dword [esp + 0x34], ecx
mov dword [esp + 0x5c], eax
jle 0x40ff53
mov eax, dword [esp + 0x40]
and eax, 0xfffffffc
mov dword [esp + 0x44], eax
xor edi, edi
xor ebx, ebx
mov dword [esp + 0x78], edi
test cl, 3
jne 0x40fc5a
mov esi, dword [esp + 0x44]
cmp esi, edi
je 0x40fc5a
mov eax, ecx
cdq
and edx, 3
add eax, edx
sar eax, 2
imul eax, dword [esp + 0x64]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0xd8]
lea edx, [esi + esi*2]
lea ecx, [eax + edx*4 + 8]
dec esi
imul edi, edi, 0x1a33
imul ebx, ebx, 0x1a33
mov eax, esi
cdq
and edx, 3
add eax, edx
mov edx, dword [esp + 0x38]
sar eax, 2
add eax, dword [esp + 0x68]
sub ecx, 0xc
lea eax, [eax + eax*2]
movsx edx, word [edx + eax*2]
imul edx, edx, 0x5cd
lea edi, [edx + edi + 0x1000]
mov edx, dword [esp + 0x38]
sar edi, 0xd
mov dword [ecx - 8], edi
movsx edx, word [edx + eax*2 + 2]
imul edx, edx, 0x5cd
lea ebx, [edx + ebx + 0x1000]
mov edx, dword [esp + 0x38]
sar ebx, 0xd
mov dword [ecx - 4], ebx
movsx eax, word [edx + eax*2 + 4]
mov edx, dword [esp + 0x78]
imul eax, eax, 0x5cd
imul edx, edx, 0x1a33
lea eax, [eax + edx + 0x1000]
sar eax, 0xd
mov dword [esp + 0x78], eax
mov dword [ecx], eax
test esi, esi
jne 0x40fbd0
xor edi, edi
xor ebx, ebx
cmp dword [esp + 0x44], edi
mov dword [esp + 0x78], edi
jle 0x40fcf2
mov ecx, dword [esp + 0xd8]
mov esi, dword [esp + 0xdc]
mov edx, ecx
sub edx, esi
mov dword [esp + 0x68], edx
mov edx, dword [esp + 0x44]
mov dword [esp + 0x24], edx
lea eax, [esi + 4]
mov edx, edi
mov esi, dword [ecx]
imul edi, edi, 0x1a33
imul ebx, ebx, 0x1a33
imul esi, esi, 0x5cd
imul edx, edx, 0x1a33
lea edi, [edi + esi + 0x1000]
mov esi, dword [esp + 0x68]
sar edi, 0xd
mov dword [eax - 4], edi
mov esi, dword [esi + eax]
imul esi, esi, 0x5cd
lea ebx, [esi + ebx + 0x1000]
sar ebx, 0xd
mov dword [eax], ebx
mov esi, dword [ecx + 8]
imul esi, esi, 0x5cd
lea edx, [esi + edx + 0x1000]
sar edx, 0xd
mov dword [eax + 4], edx
add ecx, 0xc
add eax, 0xc
sub dword [esp + 0x24], 1
jne 0x40fc8f
cmp dword [esp + 0x34], 0
mov ecx, dword [esp + 0xdc]
jne 0x40fd1b
mov eax, dword [esp + 0x50]
push eax
push ecx
mov ecx, dword [esp + 0xe8]
push ecx
call fcn.00436980
add esp, 0xc
jmp 0x40fd96
mov ebx, dword [esp + 0x44]
test ebx, ebx
jle 0x40fd96
mov edx, dword [esp + 0xe0]
mov edi, ecx
lea eax, [edx + 4]
sub edi, edx
mov esi, dword [ecx]
mov edx, dword [eax - 4]
imul esi, esi, 0x5cd
imul edx, edx, 0x1a33
lea edx, [edx + esi + 0x1000]
mov esi, dword [eax]
sar edx, 0xd
imul esi, esi, 0x1a33
mov dword [eax - 4], edx
mov edx, dword [edi + eax]
imul edx, edx, 0x5cd
lea edx, [edx + esi + 0x1000]
mov esi, dword [eax + 4]
sar edx, 0xd
imul esi, esi, 0x1a33
mov dword [eax], edx
mov edx, dword [ecx + 8]
imul edx, edx, 0x5cd
lea edx, [edx + esi + 0x1000]
sar edx, 0xd
mov dword [eax + 4], edx
add ecx, 0xc
add eax, 0xc
sub ebx, 1
jne 0x40fd31
cmp dword [esp + 0x44], 0
jle 0x40ff40
mov eax, dword [esp + 0xe0]
mov ecx, dword [esp + 0x40]
mov edx, dword [0x4ac418]
add eax, 8
imul ecx, dword [esp + 0x34]
mov dword [esp + 0x54], eax
mov eax, dword [esp + 0x44]
lea ebx, [edx + ecx*8 + 4]
mov dword [esp + 0x24], eax
lea ebx, [ebx]
mov eax, dword [esp + 0x54]
mov ecx, dword [eax - 8]
mov edi, dword [eax]
mov esi, dword [eax - 4]
lea edx, [edi + ecx]
lea eax, [edx + esi + 0x1e]
movsx edx, word [ebx - 4]
mov dword [esp + 0x28], eax
movsx eax, word [ebx - 2]
add edx, eax
movsx eax, word [ebx]
lea eax, [edx + eax + 0x1e]
shl eax, 0x10
cdq
idiv dword [esp + 0x28]
imul ecx, eax
mov dword [esp + 0x30], eax
movsx eax, word [ebx - 4]
add ecx, 0x8000
sar ecx, 0x10
sub ecx, eax
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x138]
movsx edx, word [edx]
cmp eax, edx
jl 0x40fe2f
xor eax, eax
jmp 0x40fe53
test ecx, ecx
jge 0x40fe47
lea eax, [ecx + ecx]
mov ecx, dword [esp + 0x138]
sub ecx, eax
movsx eax, word [ecx + 2]
neg eax
jmp 0x40fe53
mov edx, dword [esp + 0x138]
movsx eax, word [edx + ecx*2 + 2]
imul esi, dword [esp + 0x30]
mov dword [esp + 0x70], eax
mov ecx, eax
movsx eax, word [ebx - 2]
add esi, 0x8000
sar esi, 0x10
sub esi, eax
mov eax, esi
cdq
xor eax, edx
sub eax, edx
mov edx, dword [esp + 0x13c]
movsx edx, word [edx]
cmp eax, edx
jl 0x40fe86
xor eax, eax
jmp 0x40feaa
test esi, esi
jge 0x40fe9e
mov edx, dword [esp + 0x13c]
lea eax, [esi + esi]
sub edx, eax
movsx eax, word [edx + 2]
neg eax
jmp 0x40feaa
mov eax, dword [esp + 0x13c]
movsx eax, word [eax + esi*2 + 2]
imul edi, dword [esp + 0x30]
add ecx, eax
mov dword [esp + 0x74], eax
movsx eax, word [ebx]
add edi, 0x8000
sar edi, 0x10
sub edi, eax
mov eax, edi
cdq
mov esi, eax
mov eax, dword [esp + 0x140]
xor esi, edx
sub esi, edx
movsx edx, word [eax]
cmp esi, edx
jl 0x40fede
xor edx, edx
jmp 0x40fef4
test edi, edi
jge 0x40feef
lea edx, [edi + edi]
sub eax, edx
movsx edx, word [eax + 2]
neg edx
jmp 0x40fef4
movsx edx, word [eax + edi*2 + 2]
mov eax, dword [esp + 0x70]
movsx esi, word [ebx - 4]
add ecx, edx
sar ecx, 3
sub eax, ecx
add eax, esi
jns 0x40ff09
xor eax, eax
mov word [ebx - 4], ax
movsx eax, word [ebx - 2]
sub eax, ecx
add eax, dword [esp + 0x74]
jns 0x40ff1b
xor eax, eax
mov word [ebx - 2], ax
movsx eax, word [ebx]
sub eax, ecx
add eax, edx
jns 0x40ff2a
xor eax, eax
add dword [esp + 0x54], 0xc
mov word [ebx], ax
add ebx, 8
sub dword [esp + 0x24], 1
jne 0x40fdd0
mov ecx, dword [esp + 0x34]
inc ecx
cmp ecx, dword [esp + 0x5c]
mov dword [esp + 0x34], ecx
jl 0x40fb91
mov eax, dword [esp + 0x38]
push eax
call fcn.0043481f
mov ecx, dword [esp + 0xf4]
add esp, 4
push ecx
call fcn.0043481f
add esp, 4
xor esi, esi
mov edx, dword [esp + esi*4 + 0x12c]
push edx
call fcn.0043481f
inc esi
add esp, 4
cmp esi, 8
jl 0x40ff72
mov eax, dword [esp + 0x15c]
sub eax, dword [esp + 0x178]
mov ecx, dword [esp + 0x164]
mov edx, dword [esp + 0x160]
sub edx, dword [esp + 0x158]
sub ecx, 2
sub ecx, eax
mov dword [esp + 0x28], edx
mov dword [esp + 0x34], 0
test ecx, ecx
jle 0x41000a
mov edi, dword [0x4ac418]
mov ebx, edx
mov edx, dword [esp + 0x40]
imul eax, edx
add ebx, ebx
add ebx, ebx
add ebx, ebx
add eax, dword [esp + 0x158]
lea esi, [edx*8]
mov dword [esp + 0x30], esi
lea esi, [edi + eax*8]
mov dword [esp + 0x24], ecx
mov dword [esp + 0x34], ecx
push ebx
push esi
push edi
call fcn.00436980
add esi, dword [esp + 0x3c]
add esp, 0xc
add edi, ebx
sub dword [esp + 0x24], 1
jne 0x40fff2
mov cx, word [esp + 0x34]
mov ax, word [esp + 0x28]
pop edi
mov word [0x4ac486], cx
mov ecx, dword [esp + 0x2f8]
pop esi
pop ebx
xor ecx, esp
mov word [0x466040], ax
call fcn.004334ab
mov esp, ebp
pop ebp
ret
mov edx, dword [0x4ac404]
push str.foveon_interpolate__
push edx
push str._s:_Out_of_memory_in__s_n
call fcn.00434a96
add eax, 0x40
push eax
call fcn.00435780
add esp, 0x10
push 1
push 0x4660c0
call fcn.00435cb8
mov eax, dword [0x4ac404]
push 0x45abec
push eax
jmp 0x410042