Function at 0x1004fc80
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x60
mov eax, ecx
xor ecx, ecx
cmp dword [ebp + 0x18], 0x10
push ebx
sete cl
mov dword [ebp - 0x28], eax
mov eax, dword [eax]
inc ecx
push esi
push edi
mov esi, ecx
mov edi, edx
mov edx, dword [ebp + 0xc]
mov eax, dword [eax + 8]
imul esi, edx
mov dword [ebp - 0x20], eax
mov ebx, esi
mov dword [ebp - 4], esi
imul ebx, dword [ebp + 0x10]
mov dword [ebp - 0x2c], ebx
mov ebx, eax
imul ebx, ecx
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x48], ecx
mov dword [ebp - 0xc], ebx
cmp edx, eax
je 0x1004fce7
inc eax
cmp edx, eax
je 0x1004fce7
push 0x11c8
push 0x10125050
push str.out_n__s__img_n__out_n__s__img_n1
call fcn.100dbf84
mov ecx, dword [ebp + 0x10]
add esp, 0xc
test ecx, ecx
js 0x10050c5b
mov eax, dword [ebp + 0x14]
test eax, eax
js 0x10050c5b
je 0x1004fd11
xor edx, edx
mov eax, 0x7fffffff
div dword [ebp + 0x14]
cmp ecx, eax
jg 0x10050c5b
mov eax, dword [ebp + 0x14]
imul ecx, eax
test ecx, ecx
js 0x10050c5b
test esi, esi
js 0x10050c5b
je 0x1004fd36
mov eax, 0x7fffffff
cdq
idiv esi
cmp ecx, eax
jg 0x10050c5b
mov eax, dword [ebp - 0x2c]
imul eax, dword [ebp + 0x14]
push eax
call fcn.100dc086
mov ecx, dword [ebp - 0x28]
add esp, 4
mov dword [ecx + 0xc], eax
test eax, eax
je 0x10050c65
mov eax, dword [ebp - 0x20]
test eax, eax
js 0x10050c39
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x1004fd7b
xor edx, edx
mov eax, 0x7fffffff
div ecx
cmp dword [ebp - 0x20], eax
jg 0x10050c39
mov eax, dword [ebp - 0x20]
imul eax, ecx
mov dword [ebp - 0x1c], eax
test eax, eax
js 0x10050c39
mov edx, dword [ebp + 0x18]
test edx, edx
js 0x10050c39
je 0x1004fdaf
xor edx, edx
mov eax, 0x7fffffff
div dword [ebp + 0x18]
cmp dword [ebp - 0x1c], eax
jg 0x10050c39
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp - 0x1c]
imul eax, edx
cmp eax, 0x7ffffff8
jg 0x10050c39
mov eax, dword [ebp - 0x1c]
imul eax, edx
add eax, 7
shr eax, 3
mov dword [ebp - 0x34], eax
inc eax
imul eax, dword [ebp + 0x14]
cmp dword [ebp + 8], eax
jae 0x1004fdf8
mov ecx, dword [0x1017cf24]
mov eax, dword fs:[0x2c]
pop edi
pop esi
pop ebx
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], str.not_enough_pixels
xor eax, eax
mov esp, ebp
pop ebp
ret
xor eax, eax
mov dword [ebp - 0x30], eax
cmp dword [ebp + 0x14], eax
jbe 0x1005083a
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0x1c], ecx
nop dword [eax]
imul eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0x28]
mov ecx, dword [ecx + 0xc]
add ecx, eax
mov dword [ebp - 0x60], eax
movzx eax, byte [edi]
inc edi
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x24], eax
cmp eax, 4
ja 0x10050818
cmp edx, 8
jge 0x1004fe61
mov edx, dword [ebp + 0x10]
cmp dword [ebp - 0x34], edx
ja 0x100507f6
mov eax, dword [ebp + 0xc]
mov ebx, 1
imul eax, edx
mov edx, dword [ebp - 0x34]
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x48], edx
sub eax, edx
add ecx, eax
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x18], ecx
mov edx, ecx
sub edx, dword [ebp - 0x2c]
cmp dword [ebp - 0x30], 0
mov dword [ebp - 0x14], edx
jne 0x1004fe79
movzx eax, byte [eax + 0x10125eb0]
mov dword [ebp - 0x24], eax
test ebx, ebx
jle 0x1004ff77
mov eax, dword [ebp - 0x14]
mov edx, edi
sub eax, edi
mov esi, ebx
sub ecx, edi
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x44], ecx
cmp dword [ebp - 0x24], 6
ja case.default.0x1004fe9b
mov ebx, dword [ebp - 0x24]
jmp dword [ebx*4 + 0x10050c88]
mov ebx, dword [ebp - 0xc]
inc edx
sub esi, 1
jne 0x1004fe92
jmp 0x1004ff6e
mov ebx, dword [ebp - 0xc]
mov al, byte [edx]
lea edx, [edx + 1]
mov byte [ecx + edx - 1], al
sub esi, 1
jne 0x1004feb3
jmp 0x1004ff6e
mov ebx, dword [ebp - 0xc]
nop dword [eax]
mov al, byte [edx]
lea edx, [edx + 1]
mov byte [ecx + edx - 1], al
sub esi, 1
jne 0x1004fed0
jmp 0x1004ff6e
mov ebx, dword [ebp - 0xc]
mov al, byte [eax + edx]
lea edx, [edx + 1]
add al, byte [edx - 1]
mov byte [ecx + edx - 1], al
sub esi, 1
je 0x1004ff6e
mov eax, dword [ebp - 0x10]
jmp 0x1004fee6
mov ebx, dword [ebp - 0xc]
mov al, byte [eax + edx]
lea edx, [edx + 1]
shr al, 1
add al, byte [edx - 1]
mov byte [ecx + edx - 1], al
sub esi, 1
je 0x1004ff6e
mov eax, dword [ebp - 0x10]
jmp 0x1004ff00
mov ebx, dword [ebp - 0xc]
nop dword [eax]
mov cl, byte [eax + edx]
lea edx, [edx + 1]
xor al, al
cmp al, cl
sbb al, al
and al, cl
mov ecx, dword [ebp - 0x44]
add al, byte [edx - 1]
mov byte [ecx + edx - 1], al
sub esi, 1
je 0x1004ff6e
mov eax, dword [ebp - 0x10]
jmp 0x1004ff20
mov ebx, dword [ebp - 0xc]
mov al, byte [edx]
lea edx, [edx + 1]
mov byte [ecx + edx - 1], al
sub esi, 1
jne 0x1004ff45
jmp 0x1004ff6e
mov ebx, dword [ebp - 0xc]
nop dword [eax + eax]
mov al, byte [edx]
lea edx, [edx + 1]
mov byte [ecx + edx - 1], al
sub esi, 1
jne 0x1004ff60
mov edx, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x18]
mov esi, dword [ebp - 4]
mov eax, dword [ebp + 0x18]
cmp eax, 8
jne 0x1004ff91
mov esi, dword [ebp + 0xc]
mov eax, dword [ebp - 0x20]
cmp eax, esi
je 0x1004ff8d
mov byte [ecx + eax], 0xff
add edi, eax
jmp 0x1004ffa6
cmp eax, 0x10
jne 0x1004ffb8
mov eax, dword [ebp - 0x20]
cmp eax, dword [ebp + 0xc]
je 0x1004ffa4
mov word [ecx + ebx], 0xffff
add edi, ebx
add edx, esi
mov dword [ebp - 8], edi
add esi, ecx
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x10], edx
mov dword [ebp - 0x18], esi
jmp 0x1004ffd2
inc edi
lea esi, [ecx + 1]
inc edx
mov dword [ebp - 8], edi
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x10], edx
mov dword [ebp - 0x18], esi
cmp eax, 8
jl 0x100504f1
mov ecx, dword [ebp + 0xc]
mov eax, dword [ebp - 0x20]
cmp eax, ecx
je 0x100504f1
inc eax
cmp eax, ecx
je 0x1004fffc
push 0x121c
push 0x101250f0
push str.img_n1__out_n
call fcn.100dbf84
add esp, 0xc
mov eax, dword [ebp - 0x24]
cmp eax, 6
ja case.default.0x1005000d
mov ecx, dword [ebp - 0x14]
mov edi, ecx
jmp dword [eax*4 + 0x10050ca4]
mov eax, dword [ebp + 0x10]
mov edi, ecx
mov edx, dword [ebp - 4]
dec eax
mov dword [ebp - 0x24], eax
cmp eax, 1
jb 0x100504c1
nop dword [eax]
test ebx, ebx
jle 0x10050058
mov eax, edi
mov edx, ebx
sub eax, esi
mov ecx, esi
mov dword [ebp - 0x44], eax
mov ebx, eax
mov al, byte [ebx + ecx]
lea ecx, [ecx + 1]
mov byte [ecx - 1], al
sub edx, 1
jne 0x10050041
mov ebx, dword [ebp - 0xc]
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x24]
mov byte [esi + ebx], 0xff
add edi, ebx
add esi, edx
sub eax, 1
mov dword [ebp - 0x24], eax
jne 0x10050030
jmp 0x100504c1
mov eax, dword [ebp + 0x10]
mov edi, ecx
dec eax
mov dword [ebp - 0x18], eax
cmp eax, 1
jb case.default.0x1005000d
mov eax, esi
mov dword [ebp - 8], ecx
sub eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x24], eax
nop dword [eax]
xor edx, edx
test ebx, ebx
jle 0x100500bf
mov dword [ebp - 0x44], edi
sub edi, esi
nop dword [eax + eax]
mov ebx, dword [ebp - 0x24]
lea ecx, [edx + esi]
mov al, byte [edi + ecx]
add al, byte [edx + ebx]
inc edx
mov ebx, dword [ebp - 0xc]
mov byte [ecx], al
cmp edx, ebx
jl 0x100500a0
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 4]
add edi, ebx
mov byte [esi + ebx], 0xff
add eax, edx
add esi, edx
mov dword [ebp - 8], edi
sub ecx, 1
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x18], ecx
jne 0x10050090
jmp 0x100504c1
mov eax, dword [ebp + 0x10]
mov edi, ecx
dec eax
mov dword [ebp - 0x3c], eax
cmp eax, 1
jb case.default.0x1005000d
mov ecx, 0x20
mov dword [ebp - 8], edi
sub ecx, ebx
lea eax, [esi + ebx]
mov dword [ebp - 0x44], ecx
mov ecx, dword [ebp - 0x10]
mov dword [ebp - 0x24], eax
nop word [eax + eax]
xor edx, edx
test ebx, ebx
jle 0x10050230
cmp ebx, 0x40
jb 0x100501f8
lea eax, [edi - 1]
add eax, ebx
cmp esi, eax
ja 0x10050139
lea eax, [esi - 1]
add eax, ebx
cmp eax, edi
jae 0x100501f8
lea eax, [ecx - 1]
add eax, ebx
cmp esi, eax
ja 0x1005014f
lea eax, [esi - 1]
add eax, ebx
cmp eax, ecx
jae 0x100501f8
mov eax, ebx
and eax, 0x8000003f
jns 0x1005015d
dec eax
or eax, 0xffffffc0
inc eax
mov dword [ebp - 0x14], ebx
mov ebx, ecx
sub dword [ebp - 0x14], eax
sub ebx, edi
mov eax, dword [ebp - 0x24]
add eax, dword [ebp - 0x44]
mov dword [ebp - 0x38], ebx
mov ebx, esi
sub ebx, edi
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x4c], ebx
lea eax, [edi + 0x10]
mov edi, dword [ebp - 0x4c]
mov ebx, ecx
sub ebx, esi
mov esi, dword [ebp - 0x38]
mov dword [ebp - 0x50], ebx
mov ebx, dword [ebp - 0x40]
nop dword [eax]
movups xmm0, xmmword [eax - 0x10]
lea eax, [eax + 0x40]
movups xmm1, xmmword [edx + ecx]
lea ebx, [ebx + 0x40]
paddb xmm1, xmm0
movups xmm0, xmmword [eax - 0x40]
movups xmmword [ebx - 0x60], xmm1
movups xmm1, xmmword [esi + eax - 0x40]
mov esi, dword [ebp - 0x50]
paddb xmm1, xmm0
movups xmm0, xmmword [eax - 0x30]
movups xmmword [edi + eax - 0x40], xmm1
movups xmm1, xmmword [esi + ebx - 0x40]
mov esi, dword [ebp - 0x38]
paddb xmm1, xmm0
movups xmm0, xmmword [eax - 0x20]
movups xmmword [ebx - 0x40], xmm1
movups xmm1, xmmword [ecx + edx + 0x30]
add edx, 0x40
paddb xmm1, xmm0
movups xmmword [ebx - 0x30], xmm1
cmp edx, dword [ebp - 0x14]
jl 0x10050190
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 0x18]
mov edi, dword [ebp - 8]
mov dword [ebp - 0x50], edx
cmp edx, ebx
jge 0x1005022d
mov eax, dword [ebp - 0x10]
lea ecx, [edx + edi]
sub esi, edi
mov dword [ebp - 0x50], ebx
sub eax, edi
mov dword [ebp - 0x40], esi
sub ebx, edx
mov dword [ebp - 0x4c], eax
mov edx, dword [ebp - 0x40]
mov esi, eax
mov al, byte [esi + ecx]
lea ecx, [ecx + 1]
add al, byte [ecx - 1]
mov byte [edx + ecx - 1], al
sub ebx, 1
jne 0x10050212
mov esi, dword [ebp - 0x18]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x24]
mov edx, dword [ebp - 4]
add edi, ebx
mov byte [eax], 0xff
add esi, edx
add eax, edx
mov dword [ebp - 8], edi
add ecx, edx
mov dword [ebp - 0x18], esi
sub dword [ebp - 0x3c], 1
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x10], ecx
jne 0x10050110
jmp 0x100504c1
mov eax, dword [ebp + 0x10]
mov edi, ecx
mov edx, dword [ebp - 4]
dec eax
mov dword [ebp - 0x3c], eax
cmp eax, 1
jb 0x100504c1
mov eax, dword [ebp - 0x10]
mov ecx, esi
sub ecx, edx
mov dword [ebp - 8], edi
mov dword [ebp - 0x24], ecx
nop dword [eax + eax]
mov dword [ebp - 0x50], 0
test ebx, ebx
jle 0x100502ce
sub eax, edi
mov edx, edi
sub esi, edi
mov dword [ebp - 0x4c], eax
mov dword [ebp - 0x44], esi
mov edi, eax
mov esi, dword [ebp - 0x50]
nop dword [eax]
movzx ecx, byte [ecx + esi]
lea edx, [edx + 1]
movzx eax, byte [edi + edx - 1]
inc esi
add ecx, eax
mov eax, dword [ebp - 0x44]
shr ecx, 1
add cl, byte [edx - 1]
mov byte [eax + edx - 1], cl
mov ecx, dword [ebp - 0x24]
cmp esi, ebx
jl 0x100502a0
mov esi, dword [ebp - 0x18]
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 0x10]
mov edx, dword [ebp - 4]
mov byte [esi + ebx], 0xff
add edi, ebx
add esi, edx
mov dword [ebp - 8], edi
add ecx, edx
mov dword [ebp - 0x18], esi
add eax, edx
mov dword [ebp - 0x24], ecx
sub dword [ebp - 0x3c], 1
mov dword [ebp - 0x10], eax
jne 0x10050280
jmp 0x100504c1
mov eax, dword [ebp + 0x10]
mov edi, ecx
mov edx, dword [ebp - 4]
dec eax
mov dword [ebp - 0x44], eax
cmp eax, 1
jb 0x100504c1
mov eax, dword [ebp - 0x10]
mov ecx, esi
sub ecx, edx
mov dword [ebp - 8], edi
mov dword [ebp - 0x24], ecx
test ebx, ebx
jle 0x100503b9
mov edx, eax
mov dword [ebp - 0x40], ebx
mov ebx, dword [ebp - 0x24]
sub edx, esi
mov esi, dword [ebp - 4]
mov ecx, edi
sub eax, edi
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x5c], edx
mov dword [ebp - 0x4c], eax
movzx eax, byte [ebx + edx]
mov edx, dword [ebp - 0x4c]
mov dword [ebp - 0x3c], eax
movzx edi, byte [edx + ecx]
movzx edx, byte [ebx]
mov ecx, edx
mov dword [ebp - 0x58], edi
sub ecx, eax
mov dword [ebp - 0x38], edx
add edi, ecx
mov eax, edi
sub edi, dword [ebp - 0x3c]
sub eax, edx
cdq
xor eax, edx
sub eax, edx
mov dword [ebp - 0x50], eax
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
mov dword [ebp - 0x54], eax
mov eax, edi
cdq
mov ecx, eax
mov eax, dword [ebp - 0x50]
xor ecx, edx
sub ecx, edx
mov edx, dword [ebp - 0x54]
cmp eax, edx
jg 0x10050382
cmp eax, ecx
jle 0x1005038e
mov eax, dword [ebp - 0x3c]
cmp edx, ecx
cmovle eax, dword [ebp - 0x58]
mov dword [ebp - 0x38], eax
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp - 0x5c]
mov al, byte [ecx]
inc ecx
add al, byte [ebp - 0x38]
mov byte [ebx + esi], al
inc ebx
sub dword [ebp - 0x40], 1
mov dword [ebp - 0x14], ecx
jne 0x10050335
mov esi, dword [ebp - 0x18]
mov ebx, dword [ebp - 0xc]
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 0x10]
mov edx, dword [ebp - 4]
mov ecx, dword [ebp - 0x24]
mov byte [esi + ebx], 0xff
add edi, ebx
add esi, edx
mov dword [ebp - 8], edi
add ecx, edx
mov dword [ebp - 0x18], esi
add eax, edx
mov dword [ebp - 0x24], ecx
sub dword [ebp - 0x44], 1
mov dword [ebp - 0x10], eax
jne 0x10050313
jmp 0x100504c1
mov eax, dword [ebp + 0x10]
mov edi, ecx
dec eax
mov dword [ebp - 0x18], eax
cmp eax, 1
jb case.default.0x1005000d
mov eax, esi
mov dword [ebp - 8], ecx
sub eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x18]
mov dword [ebp - 0x24], eax
xor edx, edx
test ebx, ebx
jle 0x1005042e
sub edi, esi
mov dword [ebp - 0x5c], edi
nop dword [eax + eax]
mov eax, dword [ebp - 0x24]
lea ecx, [edx + esi]
mov al, byte [eax + edx]
inc edx
shr al, 1
add al, byte [edi + ecx]
mov byte [ecx], al
cmp edx, ebx
jl 0x10050410
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 4]
add edi, ebx
mov byte [esi + ebx], 0xff
add eax, edx
add esi, edx
mov dword [ebp - 8], edi
sub ecx, 1
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x18], ecx
jne 0x10050400
jmp 0x100504c1
mov eax, dword [ebp + 0x10]
mov edi, ecx
mov edx, dword [ebp - 4]
dec eax
mov dword [ebp - 0x44], eax
cmp eax, 1
jb 0x100504c1
mov ecx, esi
mov dword [ebp - 8], edi
sub ecx, edx
mov dword [ebp - 0x24], ecx
nop word [eax + eax]
mov dword [ebp - 0x5c], 0
test ebx, ebx
jle 0x100504a4
mov eax, edi
mov edi, dword [ebp - 0x5c]
sub eax, esi
mov dword [ebp - 0x58], eax
lea edx, [edi + esi]
mov al, byte [eax + edx]
add al, byte [ecx + edi]
inc edi
mov ecx, dword [ebp - 0x24]
mov byte [edx], al
mov eax, dword [ebp - 0x58]
cmp edi, ebx
jl 0x10050485
mov edi, dword [ebp - 8]
mov edx, dword [ebp - 4]
mov eax, dword [ebp - 0x44]
mov byte [esi + ebx], 0xff
add edi, ebx
add ecx, edx
mov dword [ebp - 8], edi
add esi, edx
mov dword [ebp - 0x24], ecx
sub eax, 1
mov dword [ebp - 0x44], eax
jne 0x10050470
jmp 0x100504c1
mov edx, dword [ebp - 4]
cmp dword [ebp + 0x18], 0x10
mov ecx, dword [ebp + 0x10]
jne 0x100507dd
mov eax, dword [ebp - 0x28]
mov eax, dword [eax + 0xc]
inc eax
test ecx, ecx
je 0x100507dd
add eax, dword [ebp - 0x60]
add eax, ebx
mov byte [eax], 0xff
add eax, edx
sub ecx, 1
jne 0x100504e2
jmp 0x100507da
mov ecx, dword [ebp - 0x48]
mov eax, dword [ebp - 0x24]
dec ecx
imul ecx, ebx
mov dword [ebp - 0x14], ecx
cmp eax, 6
ja case.default.0x10050507
jmp dword [eax*4 + 0x10050cc0]
push ecx
push edi
push esi
call fcn.100d2db0
add esp, 0xc
jmp 0x100507d5
xor edx, edx
test ecx, ecx
jle case.default.0x10050507
mov eax, esi
sub eax, ebx
mov dword [ebp - 0x60], eax
mov eax, edi
mov edi, dword [ebp - 0x60]
sub eax, esi
mov dword [ebp - 0x5c], eax
nop dword [eax]
mov ebx, dword [ebp - 0x5c]
lea ecx, [esi + edx]
mov al, byte [edi + edx]
inc edx
add al, byte [ecx + ebx]
mov byte [ecx], al
cmp edx, dword [ebp - 0x14]
jl 0x10050540
jmp 0x100507cf
xor eax, eax
test ecx, ecx
jle case.default.0x10050507
cmp ecx, 0x40
jb 0x10050653
mov dword [ebp - 0x24], eax
lea eax, [edi - 1]
add eax, ecx
cmp esi, eax
ja 0x10050585
lea eax, [esi - 1]
add eax, ecx
cmp eax, edi
jae 0x10050650
lea eax, [edx - 1]
add eax, ecx
cmp esi, eax
ja 0x1005059b
lea eax, [esi - 1]
add eax, ecx
cmp eax, edx
jae 0x10050650
mov eax, ecx
and eax, 0x8000003f
jns 0x100505a9
dec eax
or eax, 0xffffffc0
inc eax
mov ebx, ecx
mov ecx, edx
sub ecx, edi
sub ebx, eax
mov dword [ebp - 0x44], ecx
lea eax, [esi + 0x20]
mov ecx, esi
mov dword [ebp - 0x60], eax
sub ecx, edi
mov dword [ebp - 0x54], ebx
mov ebx, dword [ebp - 0x24]
lea eax, [edi + 0x10]
mov dword [ebp - 0x5c], ecx
mov ecx, edx
mov edi, dword [ebp - 0x5c]
sub ecx, esi
mov esi, dword [ebp - 0x44]
mov dword [ebp - 0x58], ecx
mov ecx, dword [ebp - 0x60]
nop word [eax + eax]
movups xmm0, xmmword [eax - 0x10]
lea eax, [eax + 0x40]
movups xmm1, xmmword [edx + ebx]
lea ecx, [ecx + 0x40]
paddb xmm1, xmm0
movups xmm0, xmmword [eax - 0x40]
movups xmmword [ecx - 0x60], xmm1
movups xmm1, xmmword [esi + eax - 0x40]
mov esi, dword [ebp - 0x58]
paddb xmm1, xmm0
movups xmm0, xmmword [eax - 0x30]
movups xmmword [edi + eax - 0x40], xmm1
movups xmm1, xmmword [esi + ecx - 0x40]
mov esi, dword [ebp - 0x44]
paddb xmm1, xmm0
movups xmm0, xmmword [eax - 0x20]
movups xmmword [ecx - 0x40], xmm1
movups xmm1, xmmword [edx + ebx + 0x30]
add ebx, 0x40
paddb xmm1, xmm0
movups xmmword [ecx - 0x30], xmm1
cmp ebx, dword [ebp - 0x54]
jl 0x100505e0
mov ecx, dword [ebp - 0x14]
mov esi, dword [ebp - 0x18]
mov edi, dword [ebp - 8]
mov eax, ebx
mov ebx, dword [ebp - 0xc]
cmp eax, ecx
jge case.default.0x10050507
jmp 0x10050653
mov eax, dword [ebp - 0x24]
mov ebx, dword [ebp - 0x14]
lea ecx, [edi + eax]
sub edx, edi
sub esi, edi
sub ebx, eax
nop
mov al, byte [ecx + edx]
lea ecx, [ecx + 1]
add al, byte [ecx - 1]
mov byte [ecx + esi - 1], al
sub ebx, 1
jne 0x10050660
jmp 0x100507d2
xor eax, eax
mov dword [ebp - 0x44], eax
test ecx, ecx
jle case.default.0x10050507
mov ecx, esi
mov dword [ebp - 0x60], edi
sub ecx, ebx
sub edx, edi
mov ebx, dword [ebp - 0x14]
sub esi, edi
mov dword [ebp - 0x5c], ecx
nop word [eax + eax]
movzx ecx, byte [ecx + eax]
lea edi, [edi + 1]
movzx eax, byte [edx + edi - 1]
add ecx, eax
mov eax, dword [ebp - 0x44]
shr ecx, 1
inc eax
add cl, byte [edi - 1]
mov byte [esi + edi - 1], cl
mov ecx, dword [ebp - 0x5c]
mov dword [ebp - 0x44], eax
cmp eax, ebx
jl 0x100506a0
jmp 0x100507cf
test ecx, ecx
jle case.default.0x10050507
mov eax, esi
mov dword [ebp - 0x24], edi
sub eax, ebx
mov dword [ebp - 0x3c], ecx
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x60], eax
mov eax, edx
sub eax, esi
sub edx, edi
mov edi, dword [ebp - 0x60]
mov dword [ebp - 0x54], eax
mov dword [ebp - 0x10], edx
movzx esi, byte [edx + ecx]
movzx eax, byte [eax + edi]
movzx edx, byte [edi]
mov dword [ebp - 0x44], eax
mov ecx, edx
sub ecx, eax
mov dword [ebp - 0x58], esi
add esi, ecx
mov dword [ebp - 0x40], edx
mov eax, esi
sub esi, dword [ebp - 0x44]
sub eax, edx
cdq
xor eax, edx
sub eax, edx
mov dword [ebp - 0x60], eax
mov eax, ecx
cdq
xor eax, edx
sub eax, edx
mov dword [ebp - 0x5c], eax
mov eax, esi
cdq
mov ecx, eax
mov eax, dword [ebp - 0x60]
xor ecx, edx
sub ecx, edx
mov edx, dword [ebp - 0x5c]
cmp eax, edx
jg 0x1005073b
cmp eax, ecx
jle 0x10050747
mov eax, dword [ebp - 0x44]
cmp edx, ecx
cmovle eax, dword [ebp - 0x58]
mov dword [ebp - 0x40], eax
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp - 0x10]
mov al, byte [ecx]
inc ecx
add al, byte [ebp - 0x40]
mov byte [edi + ebx], al
inc edi
sub dword [ebp - 0x3c], 1
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x24], ecx
jne 0x100506f1
mov edi, dword [ebp - 8]
jmp 0x100507d5
xor edx, edx
test ecx, ecx
jle case.default.0x10050507
mov eax, esi
sub eax, ebx
mov dword [ebp - 0x60], eax
mov eax, edi
mov edi, dword [ebp - 0x60]
sub eax, esi
mov dword [ebp - 0x5c], eax
nop
mov al, byte [edi + edx]
lea ecx, [esi + edx]
mov ebx, dword [ebp - 0x5c]
inc edx
shr al, 1
add al, byte [ecx + ebx]
mov byte [ecx], al
cmp edx, dword [ebp - 0x14]
jl 0x10050780
jmp 0x100507cf
mov dword [ebp - 0x60], 0
test ecx, ecx
jle case.default.0x10050507
mov eax, esi
mov ecx, edi
mov edi, dword [ebp - 0x60]
sub eax, ebx
mov ebx, dword [ebp - 0x14]
sub ecx, esi
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x5c], ecx
mov cl, byte [eax + edi]
lea edx, [esi + edi]
mov eax, dword [ebp - 0x5c]
inc edi
mov al, byte [edx + eax]
add al, cl
mov byte [edx], al
mov eax, dword [ebp - 0x58]
cmp edi, ebx
jl 0x100507b7
mov edi, dword [ebp - 8]
mov ebx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x14]
add edi, ecx
mov ecx, dword [ebp + 0x10]
mov eax, dword [ebp - 0x30]
mov esi, dword [ebp + 0x14]
inc eax
mov edx, dword [ebp + 0x18]
mov dword [ebp - 0x30], eax
cmp eax, esi
jae 0x1005083d
mov esi, dword [ebp - 4]
jmp 0x1004fe10
mov ecx, dword [0x1017cf24]
mov eax, dword fs:[0x2c]
pop edi
pop esi
pop ebx
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], str.invalid_width
xor eax, eax
mov esp, ebp
pop ebp
ret
mov ecx, dword [0x1017cf24]
mov eax, dword fs:[0x2c]
pop edi
pop esi
pop ebx
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], str.invalid_filter
xor eax, eax
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp + 0x14]
cmp edx, 8
jge 0x10050bf5
test esi, esi
je 0x10050c2d
mov ebx, dword [ebp + 0xc]
imul ebx, ecx
xor ecx, ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x5c], ebx
nop dword [eax]
mov eax, dword [ebp - 0x28]
mov esi, ebx
sub esi, dword [ebp - 0x34]
mov eax, dword [eax + 0xc]
add esi, eax
add esi, ecx
cmp dword [ebp + 0x1c], 0
lea edi, [eax + ecx]
mov eax, dword [ebp + 0x18]
mov dword [ebp - 0x30], edi
mov edx, edi
jne 0x10050888
mov bl, byte [eax + 0x10125e24]
jmp 0x1005088a
mov bl, 1
cmp eax, 4
jne 0x100508e9
mov ecx, dword [ebp - 0x1c]
cmp ecx, 2
jl 0x100508d7
mov edi, ecx
shr edi, 1
mov eax, edi
neg eax
lea ecx, [ecx + eax*2]
mov dword [ebp - 0x60], ecx
movzx ecx, byte [esi]
shr cl, 4
movzx ecx, cl
movzx eax, bl
imul ecx, eax
movzx eax, bl
mov byte [edx], cl
movzx ecx, byte [esi]
inc esi
and cl, 0xf
movzx ecx, cl
imul ecx, eax
mov byte [edx + 1], cl
add edx, 2
sub edi, 1
jne 0x100508a5
mov edi, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x60]
test ecx, ecx
jle 0x10050b4e
mov cl, byte [esi]
shr cl, 4
jmp 0x10050b43
cmp eax, 2
jne 0x100509b6
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0x24], ecx
cmp ecx, 4
jl 0x1005096c
mov edi, ecx
shr edi, 2
mov eax, edi
neg eax
lea ecx, [ecx + eax*4]
mov dword [ebp - 0x24], ecx
nop dword [eax]
movzx ecx, byte [esi]
shr cl, 6
movzx ecx, cl
movzx eax, bl
imul ecx, eax
movzx eax, bl
mov byte [edx], cl
movzx ecx, byte [esi]
shr cl, 4
and cl, 3
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 1], cl
movzx ecx, byte [esi]
shr cl, 2
and cl, 3
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 2], cl
movzx ecx, byte [esi]
inc esi
and cl, 3
movzx ecx, cl
imul ecx, eax
mov byte [edx + 3], cl
add edx, 4
sub edi, 1
jne 0x10050910
mov edi, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x24]
test ecx, ecx
jle 0x10050984
mov cl, byte [esi]
shr cl, 6
movzx ecx, cl
movzx eax, bl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x24]
cmp ecx, 1
jle 0x100509a0
mov cl, byte [esi]
shr cl, 4
and cl, 3
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x24]
cmp ecx, 2
jle 0x10050b4e
mov cl, byte [esi]
shr cl, 2
and cl, 3
jmp 0x10050b43
cmp eax, 1
jne 0x10050b51
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 0x18], ecx
cmp ecx, 8
jl 0x10050a93
mov edi, ecx
shr edi, 3
mov eax, edi
neg eax
lea ecx, [ecx + eax*8]
mov dword [ebp - 0x18], ecx
nop dword [eax]
movzx ecx, byte [esi]
shr cl, 7
movzx ecx, cl
movzx eax, bl
imul ecx, eax
movzx eax, bl
mov byte [edx], cl
movzx ecx, byte [esi]
shr cl, 6
and cl, 1
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 1], cl
movzx ecx, byte [esi]
shr cl, 5
and cl, 1
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 2], cl
movzx ecx, byte [esi]
shr cl, 4
and cl, 1
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 3], cl
movzx ecx, byte [esi]
shr cl, 3
and cl, 1
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 4], cl
movzx ecx, byte [esi]
shr cl, 2
and cl, 1
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 5], cl
movzx ecx, byte [esi]
shr cl, 1
and cl, 1
movzx ecx, cl
imul ecx, eax
movzx eax, bl
mov byte [edx + 6], cl
movzx ecx, byte [esi]
inc esi
and cl, 1
movzx ecx, cl
imul ecx, eax
mov byte [edx + 7], cl
add edx, 8
sub edi, 1
jne 0x100509e0
mov edi, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x18]
test ecx, ecx
jle 0x10050aab
mov cl, byte [esi]
shr cl, 7
movzx ecx, cl
movzx eax, bl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x18]
cmp ecx, 1
jle 0x10050ac7
mov cl, byte [esi]
shr cl, 6
and cl, 1
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x18]
cmp ecx, 2
jle 0x10050ae3
mov cl, byte [esi]
shr cl, 5
and cl, 1
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x18]
cmp ecx, 3
jle 0x10050aff
mov cl, byte [esi]
shr cl, 4
and cl, 1
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x18]
cmp ecx, 4
jle 0x10050b1b
mov cl, byte [esi]
shr cl, 3
and cl, 1
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x18]
cmp ecx, 5
jle 0x10050b37
mov cl, byte [esi]
shr cl, 2
and cl, 1
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
inc edx
mov ecx, dword [ebp - 0x18]
cmp ecx, 6
jle 0x10050b4e
mov cl, byte [esi]
shr cl, 1
and cl, 1
movzx eax, bl
movzx ecx, cl
imul ecx, eax
mov byte [edx], cl
mov ecx, dword [ebp - 0x14]
mov eax, dword [ebp - 0x20]
cmp eax, dword [ebp + 0xc]
je 0x10050bd6
cmp eax, 1
jne 0x10050b77
mov ecx, dword [ebp + 0x10]
sub ecx, eax
js 0x10050bd3
mov byte [edi + ecx*2 + 1], 0xff
mov al, byte [ecx + edi]
mov byte [edi + ecx*2], al
sub ecx, 1
jns 0x10050b65
jmp 0x10050bd3
cmp eax, 3
je 0x10050b93
push 0x1275
push 0x10124e38
push str.img_n__3
call fcn.100dbf84
add esp, 0xc
mov esi, dword [ebp + 0x10]
sub esi, 1
js 0x10050bd3
lea edx, [esi*2 + 1]
add edx, edi
lea ecx, [esi*4 + 2]
add edx, esi
add ecx, edi
nop
sub esi, 1
mov byte [ecx + 1], 0xff
movzx eax, byte [edx + 1]
lea edx, [edx - 3]
mov byte [ecx], al
lea ecx, [ecx - 4]
movzx eax, byte [edx + 3]
mov byte [ecx + 3], al
movzx eax, byte [edx + 2]
mov byte [ecx + 2], al
jns 0x10050bb0
mov ecx, dword [ebp - 0x14]
add ecx, dword [ebp - 0x2c]
sub dword [ebp + 0x14], 1
mov ebx, dword [ebp - 0x5c]
mov dword [ebp - 0x14], ecx
jne 0x10050860
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
cmp edx, 0x10
jne 0x10050c2d
mov ebx, dword [ebp + 0xc]
mov eax, dword [ebp - 0x28]
imul ebx, ecx
mov esi, dword [eax + 0xc]
mov edx, esi
imul ebx, dword [ebp + 0x14]
test ebx, ebx
je 0x10050c2d
movzx ecx, byte [esi]
lea edx, [edx + 2]
movzx eax, byte [edx - 1]
lea esi, [esi + 2]
shl cx, 8
or cx, ax
mov word [edx - 2], cx
sub ebx, 1
jne 0x10050c10
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [0x1017cf24]
mov eax, dword fs:[0x2c]
pop edi
pop esi
pop ebx
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x10125044
xor eax, eax
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x28]
mov dword [eax + 0xc], 0
mov ecx, dword [0x1017cf24]
mov eax, dword fs:[0x2c]
pop edi
pop esi
pop ebx
mov eax, dword [eax + ecx*4]
mov dword [eax + 0x10], 0x101250b4
xor eax, eax
mov esp, ebp
pop ebp
ret