// File: /workspace/github_c_makefile_star2_O1/algorithm-archivists[P]GathVL/src/objects/tex_string.cpp
// Function: tex_string::tex_string(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, vec, vec, double, color)
tex_string::tex_string(const std::string& str, vec location, vec size,
                       double rotation, color clr)
    : location(location), size(size), rotation(rotation), clr(clr) {

    texfile = string_generator();

    if (tex_to_png(str, texfile)) {
        std::cout << "Failed to make Latex png file." << std::endl;
        return;
    }

    std::string tmp = texfile + "png";
    image_data = stbi_load(tmp.c_str(), &width, &height, NULL, 4);

    if (!image_data) {
        std::cout << "The image " << tmp << " can't be opened." << std::endl;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x2768, %rsp           # imm = 0x2768
movq %rsi, %r15
movq %rdi, %rbx
xorps %xmm5, %xmm5
movups %xmm5, 0x8(%rdi)
xorl %eax, %eax
movq %rax, 0x18(%rdi)
leaq 0xc91f(%rip), %rcx      # 0x2cc00
movq %rcx, (%rdi)
movaps 0x27a0(%rsp), %xmm5
movaps 0x27b0(%rsp), %xmm6
movups %xmm5, 0x20(%rdi)
movups %xmm6, 0x30(%rdi)
movsd %xmm0, 0x40(%rdi)
movsd %xmm1, 0x48(%rdi)
movsd %xmm2, 0x50(%rdi)
movsd %xmm3, 0x58(%rdi)
movsd %xmm4, 0x60(%rdi)
leaq 0x68(%rdi), %rcx
movq %rcx, 0x30(%rsp)
leaq 0x78(%rdi), %rcx
movq %rcx, 0x28(%rsp)
movq %rcx, 0x68(%rdi)
movq %rax, 0x70(%rdi)
movb $0x0, 0x78(%rdi)
leaq 0x13e0(%rsp), %rdi
callq 0x20f94
leaq 0x13e0(%rsp), %rdi
callq 0x51e0
movl %eax, %eax
movq %rax, 0x58(%rsp)
movl $0x1, %ecx
movq %rax, %rdx
shrq $0x1e, %rdx
xorl %eax, %edx
imull $0x6c078965, %edx, %eax # imm = 0x6C078965
addl %ecx, %eax
movq %rax, 0x58(%rsp,%rcx,8)
incq %rcx
cmpq $0x270, %rcx            # imm = 0x270
jne 0x20359
leaq 0x58(%rsp), %rsi
movq $0x270, 0x1380(%rsi) # imm = 0x270
movabsq $0x7a00000061, %rax     # imm = 0x7A00000061
leaq 0x38(%rsp), %rdi
movq %rax, (%rdi)
movq %rdi, %rdx
callq 0x2100e
movl %eax, %ebp
leaq 0x18(%rsp), %rax
movq %rax, -0x10(%rax)
leaq 0x40(%rsp), %rsi
movq $0x10, (%rsi)
leaq 0x8(%rsp), %rdi
xorl %edx, %edx
callq 0x5550
movslq %ebp, %r14
imulq $0x66666667, %r14, %rcx # imm = 0x66666667
movq %rcx, %rdx
shrq $0x3f, %rdx
sarq $0x22, %rcx
addl %edx, %ecx
addl %ecx, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %r14d
movq %rax, 0x8(%rsp)
movq 0x40(%rsp), %rcx
movq %rcx, 0x18(%rsp)
movups 0x5702(%rip), %xmm0     # 0x25aff
movups %xmm0, (%rax)
movq %rcx, 0x10(%rsp)
movq 0x8(%rsp), %rax
movb $0x0, (%rax,%rcx)
cmpl $-0x4, %r14d
jl 0x20445
addl $0x5, %r14d
leaq 0x58(%rsp), %r12
leaq 0x38(%rsp), %r13
leaq 0x8(%rsp), %rbp
movq %r13, %rdi
movq %r12, %rsi
movq %r13, %rdx
callq 0x2100e
movsbl %al, %esi
movq %rbp, %rdi
callq 0x5830
decl %r14d
jne 0x20427
leaq 0x56c4(%rip), %rsi      # 0x25b10
leaq 0x8(%rsp), %rdi
callq 0x5520
leaq 0x13e0(%rsp), %rdi
callq 0x5150
leaq 0x8(%rsp), %r12
movq 0x30(%rsp), %rdi
movq %r12, %rsi
callq 0x53e0
movq (%r12), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x20490
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x50c0
leaq 0x68(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq 0x68(%rbx), %rsi
movq 0x70(%rbx), %rdx
addq %rsi, %rdx
leaq 0x58(%rsp), %rdi
callq 0x6cf2
leaq 0x5681(%rip), %rsi      # 0x25b36
leaq 0x58(%rsp), %rdi
callq 0x5520
leaq 0x13e0(%rsp), %rdi
leaq 0x58(%rsp), %rsi
movl $0x10, %edx
callq 0x50f0
movq 0x58(%rsp), %rdi
cmpq %rbp, %rdi
je 0x204ed
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x50c0
leaq 0x56ac(%rip), %rsi      # 0x25ba0
leaq 0x13e0(%rsp), %rdi
movl $0x60, %edx
callq 0x53c0
movq (%r15), %rsi
movq 0x8(%r15), %rdx
leaq 0x13e0(%rsp), %rdi
callq 0x53c0
leaq 0x55fa(%rip), %rsi      # 0x25b1b
leaq 0x13e0(%rsp), %rdi
movl $0xf, %edx
callq 0x53c0
leaq 0x13e0(%rsp), %rdi
callq 0x56f0
leaq 0x78(%rsp), %r12
movq %rbp, -0x20(%r12)
movl $0x6574616c, -0x10(%r12) # imm = 0x6574616C
movw $0x78, -0xc(%r12)
movq $0x5, -0x18(%r12)
leaq 0x88(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x68(%rbx), %rsi
movq 0x70(%rbx), %rdx
addq %rsi, %rdx
movq %r12, %rdi
callq 0x6cf2
leaq 0x55ac(%rip), %rsi      # 0x25b36
movq %r12, %rdi
callq 0x5520
leaq 0x8(%rsp), %rdi
leaq 0x58(%rsp), %r13
leaq 0x40(%rsp), %rcx
movl $0x2, %edx
movq %r13, %rsi
callq 0x21246
movq $-0x40, %r15
movq -0x10(%r14), %rdi
cmpq %rdi, %r14
je 0x205c9
movq (%r14), %rsi
incq %rsi
callq 0x50c0
addq $-0x20, %r14
addq $0x20, %r15
jne 0x205b5
leaq 0x5551(%rip), %rdi      # 0x25b2b
leaq 0x8(%rsp), %rsi
callq 0x221fc
testl %eax, %eax
je 0x205ef
xorl %ebp, %ebp
jmp 0x2076d
leaq 0x88(%rsp), %r14
movq %rbp, -0x30(%r14)
movl $0x70697664, -0x20(%r14) # imm = 0x70697664
movw $0x676e, -0x1c(%r14)    # imm = 0x676E
movq $0x6, -0x28(%r14)
movb $0x0, -0x1a(%r14)
movq %r14, -0x10(%r14)
movq 0x68(%rbx), %rsi
movq 0x70(%rbx), %rdx
addq %rsi, %rdx
movq %r12, %rdi
callq 0x6cf2
leaq 0x54be(%rip), %rsi      # 0x25af3
movq %r12, %rdi
callq 0x5520
leaq 0xa8(%rsp), %rax
movq %rax, -0x10(%rax)
movw $0x442d, (%rax)         # imm = 0x442D
movl $0x2, %ecx
movq %rcx, -0x8(%rax)
xorl %edx, %edx
movb %dl, 0x2(%rax)
leaq 0xc8(%rsp), %rax
movq %rax, -0x10(%rax)
movl $0x30303032, (%rax)     # imm = 0x30303032
movq $0x4, -0x8(%rax)
movb %dl, 0x4(%rax)
leaq 0xe8(%rsp), %rax
movq %rax, -0x10(%rax)
movl $0x67622d, (%rax)       # imm = 0x67622D
movq $0x3, -0x8(%rax)
leaq 0x108(%rsp), %rax
movq %rax, -0x10(%rax)
movabsq $0x726170736e617274, %rsi # imm = 0x726170736E617274
movq %rsi, (%rax)
movl $0x746e6572, 0x7(%rax)  # imm = 0x746E6572
movq $0xb, -0x8(%rax)
movb %dl, 0xb(%rax)
leaq 0x128(%rsp), %rax
movq %rax, -0x10(%rax)
movw $0x6f2d, (%rax)         # imm = 0x6F2D
movq %rcx, -0x8(%rax)
movb %dl, 0x2(%rax)
leaq 0x138(%rsp), %r12
leaq 0x148(%rsp), %r14
movq %r14, -0x10(%r14)
movq 0x68(%rbx), %rsi
movq 0x70(%rbx), %rdx
addq %rsi, %rdx
movq %r12, %rdi
callq 0x6cf2
leaq 0x5504(%rip), %rsi      # 0x25c08
movq %r12, %rdi
callq 0x5520
leaq 0x40(%rsp), %rdi
leaq 0x58(%rsp), %rsi
leaq 0x38(%rsp), %rcx
movl $0x8, %edx
callq 0x21246
movq $-0x100, %r15
movq -0x10(%r14), %rdi
cmpq %rdi, %r14
je 0x20740
movq (%r14), %rsi
incq %rsi
callq 0x50c0
addq $-0x20, %r14
addq $0x20, %r15
jne 0x2072c
leaq 0x53f9(%rip), %rdi      # 0x25b4a
leaq 0x40(%rsp), %rsi
callq 0x221fc
movl %eax, %ebp
leaq 0x40(%rsp), %rdi
callq 0x2128e
testl %ebp, %ebp
sete %bpl
leaq 0x8(%rsp), %rdi
callq 0x2128e
movq 0xc82a(%rip), %rax      # 0x2cfa8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x13e8(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x13e0(%rsp,%rcx)
callq 0x54e0
leaq 0x14d8(%rsp), %rdi
callq 0x5590
testb %bpl, %bpl
je 0x208b1
leaq 0x13f0(%rsp), %r12
movq %r12, -0x10(%r12)
movq 0x68(%rbx), %rsi
movq 0x70(%rbx), %rdx
addq %rsi, %rdx
leaq 0x13e0(%rsp), %rdi
callq 0x6cf2
leaq 0x5424(%rip), %rsi      # 0x25c08
leaq 0x13e0(%rsp), %rdi
callq 0x5520
movq 0x13e0(%rsp), %rdi
leaq 0x90(%rbx), %rsi
leaq 0x94(%rbx), %rdx
xorl %ecx, %ecx
movl $0x4, %r8d
callq 0x94f4
movq %rax, 0x88(%rbx)
testq %rax, %rax
jne 0x20892
movq 0xc791(%rip), %rdi      # 0x2cfb8
leaq 0x3ad1(%rip), %rsi      # 0x242ff
movl $0xa, %edx
callq 0x5760
movq 0x13e0(%rsp), %rsi
movq 0x13e8(%rsp), %rdx
movq 0xc769(%rip), %rdi      # 0x2cfb8
callq 0x5760
movq %rax, %r15
leaq 0x5264(%rip), %rsi      # 0x25ac2
movl $0x11, %edx
movq %rax, %rdi
callq 0x5760
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x57d0
movsbl %al, %esi
movq %r15, %rdi
callq 0x5440
movq %rax, %rdi
callq 0x53d0
movq 0x13e0(%rsp), %rdi
cmpq %r12, %rdi
je 0x208f7
movq 0x13f0(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x208f7
movq 0xc700(%rip), %r15      # 0x2cfb8
leaq 0x51e4(%rip), %rsi      # 0x25aa3
movl $0x1e, %edx
movq %r15, %rdi
callq 0x5760
movq (%r15), %rax
addq -0x18(%rax), %r15
movq %r15, %rdi
movl $0xa, %esi
callq 0x57d0
movsbl %al, %esi
movq 0xc6ce(%rip), %rdi      # 0x2cfb8
callq 0x5440
movq %rax, %rdi
callq 0x53d0
addq $0x2768, %rsp           # imm = 0x2768
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
leaq 0x40(%rsp), %rdi
callq 0x2128e
jmp 0x209b2
movq %rax, %r15
leaq 0x158(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x592e
movb $0x1, %al
jmp 0x20974
movq %rax, %r15
movq 0x138(%rsp), %rdi
cmpq %r14, %rdi
je 0x20972
movq 0x148(%rsp), %rsi
jmp 0x20965
jmp 0x2096f
movq %rax, %r15
movq 0x78(%rsp), %rdi
cmpq %r14, %rdi
je 0x20972
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20972
movq %rax, %r15
xorl %eax, %eax
testb %al, %al
jne 0x209b2
addq $-0x10, %r12
movq -0x10(%r12), %rdi
cmpq %rdi, %r12
je 0x20992
movq (%r12), %rsi
incq %rsi
callq 0x50c0
leaq -0x20(%r12), %rax
addq $-0x10, %r12
cmpq %r13, %r12
movq %rax, %r12
jne 0x2097c
jmp 0x209b2
jmp 0x20a43
jmp 0x20a65
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x2128e
jmp 0x20a6d
movq %rax, %r15
leaq 0x98(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x58f4
movb $0x1, %al
jmp 0x209fe
movq %rax, %r15
movq 0x78(%rsp), %rdi
cmpq %r14, %rdi
je 0x209fc
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x209fc
movq %rax, %r15
xorl %eax, %eax
testb %al, %al
jne 0x20a6d
movq 0x58(%rsp), %rdi
cmpq %rbp, %rdi
je 0x20a6d
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20a6d
jmp 0x20a1d
movq %rax, %r15
movq 0x58(%rsp), %rdi
cmpq %rbp, %rdi
je 0x20aa8
movq 0x68(%rsp), %rsi
jmp 0x20a5b
jmp 0x20ae5
jmp 0x20a7c
jmp 0x20a3c
jmp 0x20a3c
movq %rax, %r15
jmp 0x20a9b
jmp 0x20a65
movq %rax, %r15
movq 0x13e0(%rsp), %rdi
cmpq %r12, %rdi
je 0x20aa8
movq 0x13f0(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20aa8
movq %rax, %r15
jmp 0x20aa8
movq %rax, %r15
leaq 0x13e0(%rsp), %rdi
callq 0x55d0
jmp 0x20aa8
movq %rax, %r15
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x20a9b
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x50c0
leaq 0x13e0(%rsp), %rdi
callq 0x5150
leaq 0x8(%rbx), %r12
movq 0x30(%rsp), %rax
movq (%rax), %rdi
cmpq 0x28(%rsp), %rdi
je 0x20acb
movq 0x28(%rsp), %rax
movq (%rax), %rsi
incq %rsi
callq 0x50c0
leaq 0xbc5e(%rip), %rax      # 0x2c730
movq %rax, (%rbx)
movq %r12, %rdi
callq 0x6d82
movq %r15, %rdi
callq 0x5510
movq %rax, %rdi
callq 0x68f1
nop