Function at 0x1400385a0
Capabilities:
Encode data using xor

Disassembly:
mov r11, rsp
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xb0
mov qword [r11 - 0x70], 0xfffffffffffffffe
mov qword [r11 + 0x18], rbx
mov rax, qword [0x140079008]
xor rax, rsp
mov qword [rsp + 0xa8], rax
mov rbx, rdx
mov r13, rcx
mov qword [rsp + 0x70], 0
xor ebp, ebp
lea rcx, [r11 - 0x68]
call qword [sym.imp.CRLCLR.dll_public:_void___cdecl_CLR_COLORSPEC::constructor_void____ptr64]
nop
test rbx, rbx
je 0x1400389fc
mov r14, qword [r13]
test r14, r14
je 0x1400389fc
mov rdx, rbx
call fcn.140038350
mov rsi, rax
test rax, rax
je 0x1400389fc
mov eax, dword [r14 + 0x1694]
xorps xmm2, xmm2
cvtsi2sd xmm2, rax
lea edx, [rbp + 1]
mov ebx, 0xa
mov ecx, ebx
call qword [sym.imp.CrlUtl.dll_UNITConvertResUnitToUnit]
addsd xmm0, qword [0x14005e468]
cvttsd2si rax, xmm0
mov qword [rsp + 0x68], rax
mov eax, dword [r14 + 0x1694]
xorps xmm2, xmm2
cvtsi2sd xmm2, rax
lea edx, [rbp + 1]
mov ecx, ebx
call qword [sym.imp.CrlUtl.dll_UNITConvertResUnitToUnit]
addsd xmm0, qword [0x14005e468]
cvttsd2si rax, xmm0
mov qword [rsp + 0x60], rax
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_long_int___cdecl_RIPGetWidth_struct__RIMAGE____ptr64_]
mov r15d, eax
mov ebx, eax
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_long_int___cdecl_RIPGetHeight_struct__RIMAGE____ptr64_]
mov r12d, eax
mov edi, eax
movsd xmm2, qword [0x14005e470]
movaps xmm3, xmm2
cmp dword [0x14007ee74], ebp
je 0x14003870d
mov eax, dword [0x14007ee78]
mov ecx, dword [0x14007ee7c]
cmp eax, 0x64
jne 0x1400386be
cmp ecx, eax
je 0x1400387a7
xorps xmm2, xmm2
cvtsi2sd xmm2, rax
xorps xmm0, xmm0
cvtsi2sd xmm0, r15
mulsd xmm0, xmm2
movsd xmm1, qword [0x14005e4a8]
divsd xmm0, xmm1
cvttsd2si rbx, xmm0
xorps xmm3, xmm3
cvtsi2sd xmm3, rcx
xorps xmm0, xmm0
cvtsi2sd xmm0, r12
mulsd xmm0, xmm3
divsd xmm0, xmm1
cvttsd2si rdi, xmm0
divsd xmm2, xmm1
divsd xmm3, xmm1
jmp 0x1400387a7
mov ebx, dword [r14 + 0x1688]
mov edi, dword [r14 + 0x168c]
cmp dword [r14 + 0x1674], 0
je 0x14003877b
xorps xmm2, xmm2
xorps xmm0, xmm0
xorps xmm1, xmm1
cmp ebx, edi
jb 0x140038750
cvtsi2sd xmm2, rbx
cvtsi2sd xmm0, r15
divsd xmm2, xmm0
cvtsi2sd xmm1, r12
mulsd xmm2, xmm1
cvttsd2si rdi, xmm2
jmp 0x14003876c
cvtsi2sd xmm2, rdi
cvtsi2sd xmm0, r12
divsd xmm2, xmm0
cvtsi2sd xmm1, r15
mulsd xmm2, xmm1
cvttsd2si rbx, xmm2
test edi, edi
mov eax, 0xa
cmove edi, eax
test ebx, ebx
cmove ebx, eax
mov eax, ebx
xorps xmm2, xmm2
cvtsi2sd xmm2, rax
xorps xmm0, xmm0
cvtsi2sd xmm0, r15
divsd xmm2, xmm0
mov eax, edi
xorps xmm3, xmm3
cvtsi2sd xmm3, rax
xorps xmm0, xmm0
cvtsi2sd xmm0, r12
divsd xmm3, xmm0
xor r9d, r9d
mov rax, qword [r13]
cmp dword [rax + 0x5e8], r9d
jbe 0x140038828
nop word [rax + rax]
mov rcx, qword [r13]
mov eax, dword [rcx + r9*8 + 0x458]
sub eax, dword [rcx + 0x5ec]
movd xmm0, eax
cvtdq2pd xmm0, xmm0
mulsd xmm0, xmm2
cvttsd2si eax, xmm0
cdq
xor eax, edx
sub eax, edx
mov dword [r13 + r9*8 + 8], eax
mov rax, qword [r13]
mov ecx, dword [rax + 0x5f0]
sub ecx, dword [rax + r9*8 + 0x45c]
movd xmm0, ecx
cvtdq2pd xmm0, xmm0
mulsd xmm0, xmm3
cvttsd2si eax, xmm0
cdq
xor eax, edx
sub eax, edx
mov dword [r13 + r9*8 + 0xc], eax
inc r9d
mov rax, qword [r13]
cmp r9d, dword [rax + 0x5e8]
jb 0x1400387c0
call qword [sym.imp.CRLCLR.dll_public:_static_class_ColorSystem::ColorContext_const____ptr64___cdecl_ColorSystem::ColorContext::GetActiveColorContext_void_]
mov rcx, rax
call qword [sym.imp.CdrRip.dll_struct__RS____ptr64___cdecl_RIPCreateRS_class_ColorSystem::ColorContext_const____ptr64_]
mov r14, rax
test rax, rax
je 0x14003898e
xor eax, eax
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], 1
mov rax, qword [rsp + 0x60]
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0x68]
mov r8d, edi
mov edx, ebx
mov ecx, 1
call qword [sym.imp.CdrRip.dll_struct__RIMAGE____ptr64___cdecl_RIPCreateImageEx2_unsigned_int__long_int__long_int__unsigned_int__unsigned_int__unsigned_int__class_CLR_COLORSPEC____ptr64__void____ptr64__class_ColorSystem::ColorContext_const____ptr64_]
mov r13, rax
mov qword [rsp + 0x70], rax
test rax, rax
je 0x140038985
mov dl, 0xff
lea rcx, [rsp + 0x80]
call qword [sym.imp.CRLCLR.dll_public:_static_void___cdecl_CLR_COLORSPEC::MakeGRAY_class_CLR_COLORSPEC____ptr64__unsigned_char_]
lea rax, [rsp + 0x80]
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], ebx
xor r9d, r9d
xor r8d, r8d
mov rdx, r13
mov rcx, r14
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPSolidRectangle_struct__RS____ptr64__struct__RIMAGE____ptr64__long_int__long_int__long_int__long_int__class_CLR_COLORSPEC_const____ptr64_]
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_enum_R_IMG_ENUM___cdecl_RIPGetImageType_struct__RIMAGE____ptr64_]
cmp eax, 0xa
je 0x1400388f2
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_enum_R_IMG_ENUM___cdecl_RIPGetImageType_struct__RIMAGE____ptr64_]
cmp eax, 9
je 0x1400388f2
mov dword [rsp + 0x50], r12d
mov dword [rsp + 0x48], r15d
mov qword [rsp + 0x30], rsi
jmp 0x140038972
xor eax, eax
mov qword [rsp + 0x40], rax
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rax
mov dword [rsp + 0x28], 1
mov rax, qword [rsp + 0x60]
mov dword [rsp + 0x20], eax
mov r9d, dword [rsp + 0x68]
mov r8d, r12d
mov edx, r15d
mov ecx, 1
call qword [sym.imp.CdrRip.dll_struct__RIMAGE____ptr64___cdecl_RIPCreateImageEx2_unsigned_int__long_int__long_int__unsigned_int__unsigned_int__unsigned_int__class_CLR_COLORSPEC____ptr64__void____ptr64__class_ColorSystem::ColorContext_const____ptr64_]
mov rbp, rax
test rax, rax
je 0x140038985
mov dword [rsp + 0x40], r12d
mov dword [rsp + 0x38], r15d
mov dword [rsp + 0x30], 0
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], rsi
xor r9d, r9d
xor r8d, r8d
mov rdx, rax
mov rcx, r14
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPConvertImageToImage_struct__RS____ptr64__struct__RIMAGE____ptr64__long_int__long_int__struct__RIMAGE____ptr64__long_int__long_int__long_int__long_int_]
mov dword [rsp + 0x50], r12d
mov dword [rsp + 0x48], r15d
mov qword [rsp + 0x30], rbp
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], ebx
mov rdx, r13
mov rcx, r14
call fcn.140034250
mov rcx, r14
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPDestroyRS_struct__RS____ptr64_]
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_struct___RPALETTE____ptr64___cdecl_RIPGetPalette_struct__RIMAGE____ptr64_]
test rax, rax
je 0x1400389b9
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_struct___RPALETTE____ptr64___cdecl_RIPGetPalette_struct__RIMAGE____ptr64_]
mov rcx, rax
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPDestroyPalette_struct___RPALETTE____ptr64_]
xor edx, edx
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_void___cdecl_RIPSetPalette_struct__RIMAGE____ptr64__struct___RPALETTE____ptr64_]
mov rcx, rsi
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPDestroyImage_struct__RIMAGE____ptr64_]
test rbp, rbp
je 0x1400389fc
mov rcx, rbp
call qword [sym.imp.CdrRip.dll_struct___RPALETTE____ptr64___cdecl_RIPGetPalette_struct__RIMAGE____ptr64_]
test rax, rax
je 0x1400389f2
mov rcx, rbp
call qword [sym.imp.CdrRip.dll_struct___RPALETTE____ptr64___cdecl_RIPGetPalette_struct__RIMAGE____ptr64_]
mov rcx, rax
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPDestroyPalette_struct___RPALETTE____ptr64_]
xor edx, edx
mov rcx, rbp
call qword [sym.imp.CdrRip.dll_void___cdecl_RIPSetPalette_struct__RIMAGE____ptr64__struct___RPALETTE____ptr64_]
mov rcx, rbp
call qword [sym.imp.CdrRip.dll_int___cdecl_RIPDestroyImage_struct__RIMAGE____ptr64_]
nop
lea rcx, [rsp + 0x80]
call qword [sym.imp.CRLCLR.dll_public:_void___cdecl_CLR_COLORSPEC::destructor_void____ptr64]
mov rax, qword [rsp + 0x70]
mov rcx, qword [rsp + 0xa8]
xor rcx, rsp
call fcn.140047b30
mov rbx, qword [rsp + 0x100]
add rsp, 0xb0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret