Function at 0x1400c8d60
Capabilities:
Write file on windows

Disassembly:
push rbp
push rsi
push rdi
push r13
push r14
push r15
lea rbp, [rsp - 8]
sub rsp, 0x108
mov rax, qword [0x1402a83b0]
xor rax, rsp
mov qword [rbp - 0x10], rax
mov r14, rcx
lea rcx, [rsp + 0x40]
mov rdi, rdx
call fcn.140061e90
cmp word [rdi + 0x138], 0
lea rax, str.IFF_ILBM_Packbits
lea rcx, str.IFF_ILBM
lea rdx, [rsp + 0x70]
cmovne rcx, rax
sub rdx, rcx
nop word [rax + rax]
movzx eax, byte [rcx]
inc rcx
mov byte [rdx + rcx - 1], al
test al, al
jne 0x1400c8dc0
mov eax, dword [rdi + 0x50]
movzx ecx, word [rdi + 0x48]
xor r13d, r13d
add eax, 0xf
mov r15d, 0x7f0
mov qword [rsp + 0x100], r12
cdq
mov word [rsp + 0x44], r13w
lea r12d, [r13 + 1]
and edx, 7
add eax, edx
sar eax, 3
and eax, 0xfffffffe
mov dword [rsp + 0x5c], eax
cmp cx, r15w
jne 0x1400c8e23
lea eax, [rax + rax*2]
mov dword [rsp + 0x50], 0x180001
mov word [rsp + 0x60], r13w
shl eax, 3
mov dword [rsp + 0x5c], eax
jmp 0x1400c8e4d
mov word [rsp + 0x52], r12w
cmp cx, r12w
jne 0x1400c8e37
mov word [rsp + 0x50], r12w
jmp 0x1400c8e45
movsx ecx, word [rdi + 0x58]
call fcn.14005e1c0
mov word [rsp + 0x50], ax
mov dword [rsp + 0x60], 0x80100
lea rdx, [rsp + 0x40]
mov rcx, rdi
call fcn.14005fe70
movzx esi, ax
test ax, ax
jne 0x1400c916a
xor r8d, r8d
mov edx, 0x464f524d
mov rcx, r14
call fcn.1400c9290
mov rcx, r14
call fcn.1400c92d0
test ax, ax
je 0x1400c8e95
mov rcx, rdi
call fcn.14005dcb0
mov eax, 6
jmp 0x1400c916d
mov edx, 0x424d4844
mov r8d, 0x14
mov rcx, r14
call fcn.1400c9290
movzx r9d, word [rsp + 0x50]
movzx eax, word [rdi + 0x138]
imul r9w, word [rsp + 0x52]
movzx r8d, word [rdi + 0x54]
movzx edx, word [rdi + 0x50]
mov rcx, r14
mov word [rsp + 0x20], ax
call fcn.1400c91a0
test ax, ax
jne 0x1400c8e83
cmp word [rdi + 0x48], r15w
je 0x1400c8f20
mov ecx, dword [rsp + 0x50]
mov eax, r12d
mov edx, 0x434d4150
shl eax, cl
mov rcx, r14
lea r8d, [rax + rax*2]
call fcn.1400c9290
mov ecx, dword [rsp + 0x50]
mov r9, qword [r14]
mov eax, r12d
mov r8, r12
shl eax, cl
mov rcx, qword [rsp + 0x68]
lea eax, [rax + rax*2]
movsxd rdx, eax
call fcn.1401c24f8
test rax, rax
je 0x1400c8e83
mov edx, 0x43414d47
mov r8d, 4
mov rcx, r14
call fcn.1400c9290
mov rcx, r14
call fcn.1400c9270
movzx esi, ax
test ax, ax
jne 0x1400c8e83
movsx r8d, word [rsp + 0x50]
mov edx, 0x424f4459
mov rcx, r14
mov qword [rsp + 0x150], rbx
imul r8d, dword [rdi + 0x54]
imul r8d, dword [rsp + 0x5c]
call fcn.1400c9290
cmp word [rdi + 0x48], r15w
jne 0x1400c906d
movsxd rcx, dword [rsp + 0x5c]
call fcn.1401bee78
mov ebx, r13d
mov r15, rax
cmp dword [rdi + 0x54], ebx
jle 0x1400c8fd3
nop dword [rax]
mov r8d, r12d
mov edx, ebx
mov rcx, rdi
call fcn.1400629c0
mov rcx, qword [rsp + 0x48]
movzx r9d, word [rdi + 0x138]
mov r8d, dword [rsp + 0x5c]
mov edx, dword [rdi + 0x50]
mov qword [rsp + 0x28], r15
mov qword [rsp + 0x20], rcx
mov rcx, r14
call fcn.1400c8bb0
movzx esi, ax
test ax, ax
jne 0x1400c8fd3
inc ebx
cmp ebx, dword [rdi + 0x54]
jl 0x1400c8f90
mov rcx, r15
call fcn.1401be23c
mov r15d, 0x7f0
mov rcx, qword [r14]
call fcn.1401c2310
lea ebx, [rax - 8]
test bl, 1
je 0x1400c9001
mov rdx, qword [r14]
xor ecx, ecx
call fcn.1401c1ae4
inc ebx
movzx r13d, r12w
mov rcx, qword [r14]
mov r8d, r12d
xor edx, edx
call fcn.1401c1f88
mov rcx, qword [r14]
xor r8d, r8d
lea edx, [r8 + 4]
call fcn.1401c1f88
mov rdx, r14
mov ecx, ebx
call fcn.140067100
test r13w, r13w
je 0x1400c902f
dec ebx
xor r8d, r8d
cmp word [rdi + 0x48], r15w
je 0x1400c9140
mov ecx, dword [rsp + 0x50]
mov eax, r12d
shl eax, cl
mov rcx, qword [r14]
lea edx, [rax + 0x20]
lea edx, [rax + rdx*2]
call fcn.1401c1f88
mov ecx, dword [rsp + 0x50]
shl r12d, cl
mov ecx, 0xffffffc4
lea eax, [r12 + r12*2]
sub ecx, eax
add ebx, ecx
jmp 0x1400c9150
cmp word [rdi + 0x138], r13w
je 0x1400c90f1
mov r15d, r13d
cmp dword [rdi + 0x54], r13d
jle 0x1400c8fdb
test si, si
jne 0x1400c8fdb
mov r8d, r12d
mov edx, r15d
mov rcx, rdi
call fcn.1400629c0
mov ebx, r13d
cmp r13w, word [rsp + 0x50]
jge 0x1400c90e3
nop word [rax + rax]
mov r8d, dword [rsp + 0x5c]
mov eax, ebx
lea r9, [rsp + 0x30]
mov rcx, r14
imul eax, r8d
movsxd rdx, eax
add rdx, qword [rsp + 0x48]
call fcn.140138280
movzx esi, ax
test ax, ax
jne 0x1400c90e3
movsx eax, word [rsp + 0x50]
inc ebx
cmp ebx, eax
jl 0x1400c90b0
inc r15d
cmp r15d, dword [rdi + 0x54]
jl 0x1400c9084
jmp 0x1400c8fdb
mov ebx, r13d
cmp dword [rdi + 0x54], ebx
jle 0x1400c8fe1
nop dword [rax]
mov r8d, r12d
mov edx, ebx
mov rcx, rdi
call fcn.1400629c0
movsx r8, word [rsp + 0x50]
movsxd rdx, dword [rsp + 0x5c]
mov r9, qword [r14]
mov rcx, qword [rsp + 0x48]
call fcn.1401c24f8
movsx rcx, word [rsp + 0x50]
cmp rax, rcx
jne 0x1400c8fe1
inc ebx
cmp ebx, dword [rdi + 0x54]
jl 0x1400c9100
jmp 0x1400c8fe1
mov rcx, qword [r14]
mov edx, 0x38
call fcn.1401c1f88
add ebx, 0xffffffcc
mov rdx, r14
mov ecx, ebx
call fcn.140067100
mov rcx, rdi
call fcn.14005dcb0
mov rbx, qword [rsp + 0x150]
movzx eax, si
mov r12, qword [rsp + 0x100]
mov rcx, qword [rbp - 0x10]
xor rcx, rsp
call fcn.1401bd600
add rsp, 0x108
pop r15
pop r14
pop r13
pop rdi
pop rsi
pop rbp
ret