// File: /workspace/github_c_makefile_star2_O3/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 0xc3d3(%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 0x214d2
leaq 0x13e0(%rsp), %rdi
callq 0x51d0
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 0x208a5
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 0x2154c
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 0x5540
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 0x52f3(%rip), %xmm0     # 0x25c3c
movups %xmm0, (%rax)
movq %rcx, 0x10(%rsp)
movq 0x8(%rsp), %rax
movb $0x0, (%rax,%rcx)
cmpl $-0x4, %r14d
jl 0x20991
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 0x2154c
movsbl %al, %esi
movq %rbp, %rdi
callq 0x5830
decl %r14d
jne 0x20973
leaq 0x52b5(%rip), %rsi      # 0x25c4d
leaq 0x8(%rsp), %rdi
callq 0x5510
leaq 0x13e0(%rsp), %rdi
callq 0x5150
leaq 0x8(%rsp), %r12
movq 0x30(%rsp), %rdi
movq %r12, %rsi
callq 0x53d0
movq (%r12), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x209dc
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 0x6c58
leaq 0x5272(%rip), %rsi      # 0x25c73
leaq 0x58(%rsp), %rdi
callq 0x5510
leaq 0x13e0(%rsp), %rdi
leaq 0x58(%rsp), %rsi
movl $0x10, %edx
callq 0x50f0
movq 0x58(%rsp), %rdi
cmpq %rbp, %rdi
je 0x20a39
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x50c0
leaq 0x52a0(%rip), %rsi      # 0x25ce0
leaq 0x13e0(%rsp), %rdi
movl $0x60, %edx
callq 0x53b0
movq (%r15), %rsi
movq 0x8(%r15), %rdx
leaq 0x13e0(%rsp), %rdi
callq 0x53b0
leaq 0x51eb(%rip), %rsi      # 0x25c58
leaq 0x13e0(%rsp), %rdi
movl $0xf, %edx
callq 0x53b0
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 0x6c58
leaq 0x519d(%rip), %rsi      # 0x25c73
movq %r12, %rdi
callq 0x5510
leaq 0x8(%rsp), %rdi
leaq 0x58(%rsp), %r13
leaq 0x40(%rsp), %rcx
movl $0x2, %edx
movq %r13, %rsi
callq 0x217aa
movq $-0x40, %r15
movq -0x10(%r14), %rdi
cmpq %rdi, %r14
je 0x20b15
movq (%r14), %rsi
incq %rsi
callq 0x50c0
addq $-0x20, %r14
addq $0x20, %r15
jne 0x20b01
leaq 0x5142(%rip), %rdi      # 0x25c68
leaq 0x8(%rsp), %rsi
callq 0x22734
testl %eax, %eax
je 0x20b3b
xorl %ebp, %ebp
jmp 0x20cb9
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 0x6c58
leaq 0x50af(%rip), %rsi      # 0x25c30
movq %r12, %rdi
callq 0x5510
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 0x6c58
leaq 0x50f8(%rip), %rsi      # 0x25d48
movq %r12, %rdi
callq 0x5510
leaq 0x40(%rsp), %rdi
leaq 0x58(%rsp), %rsi
leaq 0x38(%rsp), %rcx
movl $0x8, %edx
callq 0x217aa
movq $-0x100, %r15
movq -0x10(%r14), %rdi
cmpq %rdi, %r14
je 0x20c8c
movq (%r14), %rsi
incq %rsi
callq 0x50c0
addq $-0x20, %r14
addq $0x20, %r15
jne 0x20c78
leaq 0x4fea(%rip), %rdi      # 0x25c87
leaq 0x40(%rsp), %rsi
callq 0x22734
movl %eax, %ebp
leaq 0x40(%rsp), %rdi
callq 0x217f2
testl %ebp, %ebp
sete %bpl
leaq 0x8(%rsp), %rdi
callq 0x217f2
movq 0xc2de(%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 0x54d0
leaq 0x14d8(%rsp), %rdi
callq 0x5580
testb %bpl, %bpl
je 0x20dfd
leaq 0x13f0(%rsp), %r12
movq %r12, -0x10(%r12)
movq 0x68(%rbx), %rsi
movq 0x70(%rbx), %rdx
addq %rsi, %rdx
leaq 0x13e0(%rsp), %rdi
callq 0x6c58
leaq 0x5018(%rip), %rsi      # 0x25d48
leaq 0x13e0(%rsp), %rdi
callq 0x5510
movq 0x13e0(%rsp), %rdi
leaq 0x90(%rbx), %rsi
leaq 0x94(%rbx), %rdx
xorl %ecx, %ecx
movl $0x4, %r8d
callq 0x9278
movq %rax, 0x88(%rbx)
testq %rax, %rax
jne 0x20dde
movq 0xc245(%rip), %rdi      # 0x2cfb8
leaq 0x36bd(%rip), %rsi      # 0x24437
movl $0xa, %edx
callq 0x5760
movq 0x13e0(%rsp), %rsi
movq 0x13e8(%rsp), %rdx
movq 0xc21d(%rip), %rdi      # 0x2cfb8
callq 0x5760
movq %rax, %r15
leaq 0x4e55(%rip), %rsi      # 0x25bff
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 0x5430
movq %rax, %rdi
callq 0x53c0
movq 0x13e0(%rsp), %rdi
cmpq %r12, %rdi
je 0x20e43
movq 0x13f0(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20e43
movq 0xc1b4(%rip), %r15      # 0x2cfb8
leaq 0x4dd5(%rip), %rsi      # 0x25be0
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 0xc182(%rip), %rdi      # 0x2cfb8
callq 0x5430
movq %rax, %rdi
callq 0x53c0
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 0x217f2
jmp 0x20ef6
movq %rax, %r15
leaq 0x158(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x592a
jmp 0x20ef6
movq %rax, %r15
movq 0x138(%rsp), %rdi
cmpq %r14, %rdi
je 0x20ebc
movq 0x148(%rsp), %rsi
jmp 0x20eaf
jmp 0x20eb9
movq %rax, %r15
movq 0x78(%rsp), %rdi
cmpq %r14, %rdi
je 0x20ebc
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20ebc
movq %rax, %r15
addq $-0x10, %r12
movq -0x10(%r12), %rdi
cmpq %rdi, %r12
je 0x20ed6
movq (%r12), %rsi
incq %rsi
callq 0x50c0
leaq -0x20(%r12), %rax
addq $-0x10, %r12
cmpq %r13, %r12
movq %rax, %r12
jne 0x20ec0
jmp 0x20ef6
jmp 0x20f82
jmp 0x20fa4
movq %rax, %r15
leaq 0x8(%rsp), %rdi
callq 0x217f2
jmp 0x20fac
movq %rax, %r15
leaq 0x98(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x58f0
jmp 0x20fac
movq %rax, %r15
movq 0x78(%rsp), %rdi
cmpq %r14, %rdi
je 0x20f41
movq 0x88(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20f41
movq %rax, %r15
movq 0x58(%rsp), %rdi
cmpq %rbp, %rdi
je 0x20fac
movq 0x68(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20fac
jmp 0x20f5c
movq %rax, %r15
movq 0x58(%rsp), %rdi
cmpq %rbp, %rdi
je 0x20fe7
movq 0x68(%rsp), %rsi
jmp 0x20f9a
jmp 0x21024
jmp 0x20fbb
jmp 0x20f7b
jmp 0x20f7b
movq %rax, %r15
jmp 0x20fda
jmp 0x20fa4
movq %rax, %r15
movq 0x13e0(%rsp), %rdi
cmpq %r12, %rdi
je 0x20fe7
movq 0x13f0(%rsp), %rsi
incq %rsi
callq 0x50c0
jmp 0x20fe7
movq %rax, %r15
jmp 0x20fe7
movq %rax, %r15
leaq 0x13e0(%rsp), %rdi
callq 0x55c0
jmp 0x20fe7
movq %rax, %r15
movq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rax
cmpq %rax, %rdi
je 0x20fda
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 0x2100a
movq 0x28(%rsp), %rax
movq (%rax), %rsi
incq %rsi
callq 0x50c0
leaq 0xb727(%rip), %rax      # 0x2c738
movq %rax, (%rbx)
movq %r12, %rdi
callq 0x6cee
movq %r15, %rdi
callq 0x5500
movq %rax, %rdi
callq 0x6859