// File: /workspace/github_cpp_makefile_star2_O2/donfreiday[P]gb/./imgui/imgui.cpp
// Function: ImGui::RenderCollapseTriangle(ImVec2, bool, float, bool)
void ImGui::RenderCollapseTriangle(ImVec2 p_min, bool opened, float scale, bool shadow)
{
    ImGuiState& g = *GImGui;
    ImGuiWindow* window = GetCurrentWindow();

    const float h = g.FontSize * 1.00f;
    const float r = h * 0.40f * scale;
    ImVec2 center = p_min + ImVec2(h*0.50f, h*0.50f*scale);

    ImVec2 a, b, c;
    if (opened)
    {
        center.y -= r*0.25f;
        a = center + ImVec2(0,1)*r;
        b = center + ImVec2(-0.866f,-0.5f)*r;
        c = center + ImVec2(0.866f,-0.5f)*r;
    }
    else
    {
        a = center + ImVec2(1,0)*r;
        b = center + ImVec2(-0.500f,0.866f)*r;
        c = center + ImVec2(-0.500f,-0.866f)*r;
    }

    if (shadow && (window->Flags & ImGuiWindowFlags_ShowBorders) != 0)
        window->DrawList->AddTriangleFilled(a+ImVec2(2,2), b+ImVec2(2,2), c+ImVec2(2,2), window->Color(ImGuiCol_BorderShadow));
    window->DrawList->AddTriangleFilled(a, b, c, window->Color(ImGuiCol_Text));
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq 0x43be0(%rip), %rax     # 0x50480
movq 0x1758(%rax), %rbx
movb $0x1, 0x72(%rbx)
movss 0x1718(%rax), %xmm5
movss 0x29b21(%rip), %xmm3    # 0x363dc
mulss %xmm5, %xmm3
mulss %xmm1, %xmm3
mulss 0x29b05(%rip), %xmm5    # 0x363d0
mulss %xmm5, %xmm1
addss %xmm0, %xmm5
shufps $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
addss %xmm1, %xmm0
testl %edi, %edi
je 0xc92f
movss 0x29b01(%rip), %xmm1    # 0x363e8
mulss %xmm3, %xmm1
addss %xmm1, %xmm0
xorps %xmm2, %xmm2
mulss %xmm3, %xmm2
addss %xmm5, %xmm2
movaps %xmm3, %xmm1
addss %xmm0, %xmm1
unpcklps %xmm1, %xmm2            # xmm2 = xmm2[0],xmm1[0],xmm2[1],xmm1[1]
movss 0x29ad8(%rip), %xmm1    # 0x363e4
mulss %xmm3, %xmm1
mulss 0x29ac8(%rip), %xmm3    # 0x363e0
movaps %xmm5, %xmm4
subss %xmm1, %xmm4
addss %xmm0, %xmm3
unpcklps %xmm3, %xmm4            # xmm4 = xmm4[0],xmm3[0],xmm4[1],xmm3[1]
addss %xmm5, %xmm1
unpcklps %xmm3, %xmm1            # xmm1 = xmm1[0],xmm3[0],xmm1[1],xmm3[1]
jmp 0xc970
xorps %xmm4, %xmm4
mulss %xmm3, %xmm4
movaps %xmm5, %xmm2
addss %xmm3, %xmm2
addss %xmm0, %xmm4
movss 0x29a97(%rip), %xmm1    # 0x363e0
mulss %xmm3, %xmm1
mulss 0x29a8f(%rip), %xmm3    # 0x363e4
unpcklps %xmm4, %xmm2            # xmm2 = xmm2[0],xmm4[0],xmm2[1],xmm4[1]
addss %xmm5, %xmm1
movaps %xmm0, %xmm5
addss %xmm3, %xmm5
movaps %xmm1, %xmm4
unpcklps %xmm5, %xmm4            # xmm4 = xmm4[0],xmm5[0],xmm4[1],xmm5[1]
subss %xmm3, %xmm0
unpcklps %xmm0, %xmm1            # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
movlps %xmm2, -0x40(%rbp)
movlps %xmm4, -0x38(%rbp)
movlps %xmm1, -0x30(%rbp)
testb %sil, %sil
je 0xca15
testb $-0x80, 0xc(%rbx)
je 0xca15
movaps %xmm2, %xmm0
shufps $0x55, %xmm2, %xmm0     # xmm0 = xmm0[1,1],xmm2[1,1]
movaps %xmm4, %xmm3
shufps $0x55, %xmm4, %xmm3     # xmm3 = xmm3[1,1],xmm4[1,1]
movaps %xmm1, %xmm5
shufps $0x55, %xmm1, %xmm5     # xmm5 = xmm5[1,1],xmm1[1,1]
movq 0x270(%rbx), %r14
movss 0x29a25(%rip), %xmm6    # 0x363d8
addss %xmm6, %xmm2
addss %xmm6, %xmm0
unpcklps %xmm0, %xmm2            # xmm2 = xmm2[0],xmm0[0],xmm2[1],xmm0[1]
leaq -0x58(%rbp), %r15
movlps %xmm2, (%r15)
addss %xmm6, %xmm4
addss %xmm6, %xmm3
unpcklps %xmm3, %xmm4            # xmm4 = xmm4[0],xmm3[0],xmm4[1],xmm3[1]
leaq -0x50(%rbp), %r12
movlps %xmm4, (%r12)
addss %xmm6, %xmm1
addss %xmm6, %xmm5
unpcklps %xmm5, %xmm1            # xmm1 = xmm1[0],xmm5[0],xmm1[1],xmm5[1]
leaq -0x48(%rbp), %r13
movlps %xmm1, (%r13)
pushq $0x5
popq %rsi
movss 0x29997(%rip), %xmm0    # 0x36390
movq %rbx, %rdi
callq 0x1eae4
movq %r14, %rdi
movq %r15, %rsi
movq %r12, %rdx
movq %r13, %rcx
movl %eax, %r8d
callq 0x29be0
movq 0x270(%rbx), %r14
movss 0x2996c(%rip), %xmm0    # 0x36390
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1eae4
leaq -0x40(%rbp), %rsi
leaq -0x38(%rbp), %rdx
leaq -0x30(%rbp), %rcx
movq %r14, %rdi
movl %eax, %r8d
callq 0x29be0
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq