Function at 0x140088fc0
Capabilities:
Link many functions at runtime

Disassembly:
push rbp
push rbx
push r12
push r13
lea rbp, [rsp - 0x1f8]
sub rsp, 0x2f8
mov rax, qword [0x1402a83b0]
xor rax, rsp
mov qword [rbp + 0x1d0], rax
mov rbx, rcx
lea rcx, [rbp + 0xc0]
mov r12, rdx
mov qword [rsp + 0x38], rdx
call fcn.14006e770
lea rcx, [rbp + 0xc0]
dec rcx
nop dword [rax + rax]
cmp byte [rcx + 1], 0
lea rcx, [rcx + 1]
jne 0x140089010
mov eax, dword [0x140219e90]
movsd xmm0, qword [str.pcdlib32.dll]
movsd qword [rcx], xmm0
mov dword [rcx + 8], eax
movzx eax, byte [0x140219e94]
mov byte [rcx + 0xc], al
lea rcx, [rbp + 0xc0]
call qword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov r13, rax
test rax, rax
jne 0x140089057
lea eax, [r13 + 2]
jmp 0x140089413
mov qword [rsp + 0x330], rsi
mov qword [rsp + 0x2f0], rdi
lea rdx, str.PCDopen
mov rcx, rax
mov qword [rsp + 0x2e8], r14
mov qword [rsp + 0x2e0], r15
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.PCDsetResolution
mov rcx, r13
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.PCDsetFormat
mov rcx, r13
mov r15, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.PCDloadImage
mov rcx, r13
mov qword [rsp + 0x28], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.PCDclose
mov rcx, r13
mov rsi, rax
mov qword [rsp + 0x48], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.PCDgetRotation
mov rcx, r13
mov qword [rsp + 0x40], rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov r14, rax
test rdi, rdi
je 0x1400893e5
test r15, r15
je 0x1400893e5
cmp qword [rsp + 0x28], 0
je 0x1400893e5
test rsi, rsi
je 0x1400893e5
test rax, rax
je 0x1400893e5
cmp qword [rsp + 0x40], 0
je 0x1400893e5
lea rdx, [rsp + 0x30]
mov rcx, rbx
call rdi
test ax, ax
jne 0x1400893e5
movsx ecx, byte [r12 + 0x184]
mov eax, 4
lea edx, [rax - 3]
lea r8d, [rax - 1]
test ecx, ecx
je 0x1400891bd
dec ecx
je 0x1400891ac
sub ecx, 2
je 0x14008919d
dec ecx
je 0x14008918c
dec ecx
je 0x14008917b
movzx edi, r8w
mov esi, 0x200
mov ebx, 0x300
jmp 0x1400891c8
mov edi, 6
mov esi, 0x1000
mov ebx, 0x1800
jmp 0x1400891c8
mov edi, 5
mov esi, 0x800
mov ebx, 0xc00
jmp 0x1400891c8
movzx edi, ax
mov esi, 0x400
mov ebx, 0x600
jmp 0x1400891c8
mov edi, 2
mov esi, 0x100
mov ebx, 0x180
jmp 0x1400891c8
mov esi, 0x80
movzx edi, dx
lea ebx, [rsi + 0x40]
lea rcx, [rsp + 0x50]
call fcn.140060c40
test dword [r12 + 0xc0], 0x800
je 0x140089239
mov rcx, qword [rsp + 0x30]
mov edi, 1
lea rdx, [rsp + 0x20]
lea esi, [rdi + 0x7f]
lea ebx, [rsi + 0x40]
call r14
test byte [rsp + 0x20], 4
je 0x140089216
mov dword [rbp - 0x7c], 0x800
mov dword [rbp - 0x78], 0xc00
mov dword [rbp - 0x74], 0x1800
jmp 0x14008922b
mov dword [rbp - 0x7c], 0xc00
mov dword [rbp - 0x78], 0x800
mov dword [rbp - 0x74], 0x2400
mov dword [rbp - 0x70], 8
mov dword [rbp - 0x6c], 3
mov rcx, qword [rsp + 0x30]
movzx edx, di
call r15
mov rcx, qword [rsp + 0x30]
mov edx, 0xb
call qword [rsp + 0x28]
mov rcx, qword [rsp + 0x30]
lea rdx, [rsp + 0x20]
call r14
test byte [rsp + 0x20], 4
je 0x14008926c
mov eax, ebx
mov ebx, esi
mov esi, eax
mov eax, dword [0x14020d7b0]
movsd xmm0, qword [str.Kodak_Photo_CD]
lea rdx, [rsp + 0x50]
mov dword [rbp + 0x46], eax
movzx eax, word [0x14020d7b4]
mov rcx, r12
movsd qword [rbp + 0x3e], xmm0
mov word [rbp + 0x4a], ax
movzx eax, byte [0x14020d7b6]
mov dword [rsp + 0x50], 8
mov byte [rbp + 0x4c], al
mov eax, 0x10
mov dword [rsp + 0x70], 0x180001
mov word [rsp + 0x54], ax
lea eax, [rbx + rbx*2]
mov dword [rsp + 0x68], ebx
mov dword [rsp + 0x78], eax
mov dword [rsp + 0x6c], esi
call fcn.14005ee10
movzx r15d, ax
test ax, ax
jne 0x1400893c5
mov rcx, qword [rsp + 0x30]
lea r8, [rsp + 0x28]
xor edx, edx
call qword [rsp + 0x48]
test ax, ax
je 0x1400892fa
mov r15d, 4
jmp 0x1400893b5
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GlobalLock]
mov r14, rax
test rax, rax
je 0x1400893dd
cmp dword [rax], 0x28
jne 0x1400893dd
cmp word [rax + 0xe], 0x18
jne 0x1400893dd
mov ecx, dword [rax + 4]
xor ebx, ebx
lea eax, [rcx + rcx*2]
lea eax, [rax*8 + 0x1f]
cdq
and edx, 0x1f
add eax, edx
sar eax, 5
mov r12d, eax
shl r12d, 2
test esi, esi
jle 0x14008939a
mov edi, ebx
nop word [rax + rax]
mov edx, dword [r14 + 0x20]
movsxd r8, dword [rsp + 0x78]
movsxd rcx, edi
add rcx, 0x28
add rcx, r14
lea rdx, [rcx + rdx*4]
mov rcx, qword [rsp + 0x60]
call fcn.1401bd6e0
mov rcx, qword [rsp + 0x38]
or r8d, 0xffffffff
or edx, r8d
mov r9d, 1
call fcn.1400615b0
movzx r15d, ax
test ax, ax
jne 0x14008939a
inc ebx
add edi, r12d
cmp ebx, esi
jl 0x140089350
mov r12, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GlobalUnlock]
mov rcx, qword [rsp + 0x28]
call qword [sym.imp.KERNEL32.dll_GlobalFree]
xor r8d, r8d
xor edx, edx
xor r9d, r9d
mov rcx, r12
call fcn.14005cb20
mov rcx, qword [rsp + 0x30]
call qword [rsp + 0x40]
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
movzx eax, r15w
jmp 0x1400893f3
mov r15d, 4
jmp 0x14008939f
mov rcx, r13
call qword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, 2
mov r14, qword [rsp + 0x2e8]
mov rdi, qword [rsp + 0x2f0]
mov rsi, qword [rsp + 0x330]
mov r15, qword [rsp + 0x2e0]
mov rcx, qword [rbp + 0x1d0]
xor rcx, rsp
call fcn.1401bd600
add rsp, 0x2f8
pop r13
pop r12
pop rbx
pop rbp
ret