// File: /workspace/github_cpp_makefile_star2_O1/Ciaxur[P]yagb-emu/include/imgui/imgui_widgets.cpp
// Function: ImGui::RadioButton(char const*, bool)
bool ImGui::RadioButton(const char* label, bool active)
{
    ImGuiWindow* window = GetCurrentWindow();
    if (window->SkipItems)
        return false;

    ImGuiContext& g = *GImGui;
    const ImGuiStyle& style = g.Style;
    const ImGuiID id = window->GetID(label);
    const ImVec2 label_size = CalcTextSize(label, NULL, true);

    const float square_sz = GetFrameHeight();
    const ImVec2 pos = window->DC.CursorPos;
    const ImRect check_bb(pos, pos + ImVec2(square_sz, square_sz));
    const ImRect total_bb(pos, pos + ImVec2(square_sz + (label_size.x > 0.0f ? style.ItemInnerSpacing.x + label_size.x : 0.0f), label_size.y + style.FramePadding.y * 2.0f));
    ItemSize(total_bb, style.FramePadding.y);
    if (!ItemAdd(total_bb, id))
        return false;

    ImVec2 center = check_bb.GetCenter();
    center.x = IM_ROUND(center.x);
    center.y = IM_ROUND(center.y);
    const float radius = (square_sz - 1.0f) * 0.5f;

    bool hovered, held;
    bool pressed = ButtonBehavior(total_bb, id, &hovered, &held);
    if (pressed)
        MarkItemEdited(id);

    RenderNavHighlight(total_bb, id);
    window->DrawList->AddCircleFilled(center, radius, GetColorU32((held && hovered) ? ImGuiCol_FrameBgActive : hovered ? ImGuiCol_FrameBgHovered : ImGuiCol_FrameBg), 16);
    if (active)
    {
        const float pad = ImMax(1.0f, IM_FLOOR(square_sz / 6.0f));
        window->DrawList->AddCircleFilled(center, radius - pad, GetColorU32(ImGuiCol_CheckMark), 16);
    }

    if (style.FrameBorderSize > 0.0f)
    {
        window->DrawList->AddCircle(center + ImVec2(1, 1), radius, GetColorU32(ImGuiCol_BorderShadow), 16, style.FrameBorderSize);
        window->DrawList->AddCircle(center, radius, GetColorU32(ImGuiCol_Border), 16, style.FrameBorderSize);
    }

    if (g.LogEnabled)
        LogRenderedText(&total_bb.Min, active ? "(x)" : "( )");
    if (label_size.x > 0.0f)
        RenderText(ImVec2(check_bb.Max.x + style.ItemInnerSpacing.x, check_bb.Min.y + style.FramePadding.y), label);

    IMGUI_TEST_ENGINE_ITEM_INFO(id, label, window->DC.ItemFlags);
    return pressed;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
leaq 0x693f5(%rip), %rax     # 0xfdcd0
movq (%rax), %rbx
movq 0x1ae0(%rbx), %r15
movb $0x1, 0x90(%r15)
cmpb $0x0, 0x93(%r15)
je 0x948ff
xorl %r12d, %r12d
jmp 0x94c58
movq %rdi, %r14
movl %esi, -0x3c(%rbp)
movq %r15, %rdi
movq %r14, %rsi
xorl %edx, %edx
callq 0x46258
movl %eax, %r13d
movss 0x226b3(%rip), %xmm0    # 0xb6fd0
movq %r14, -0x68(%rbp)
movq %r14, %rdi
xorl %esi, %esi
movl $0x1, %edx
callq 0x4548d
movaps %xmm0, -0xa0(%rbp)
callq 0x57404
movaps %xmm0, %xmm3
movaps -0xa0(%rbp), %xmm2
movl 0xd8(%r15), %eax
movl 0xdc(%r15), %ecx
movd %eax, %xmm5
movd %ecx, %xmm4
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm2
jbe 0x94970
movss 0x15b0(%rbx), %xmm1
addss %xmm2, %xmm1
addss %xmm3, %xmm1
shufps $0x55, %xmm2, %xmm2     # xmm2 = xmm2[1,1,1,1]
movss 0x159c(%rbx), %xmm0
movaps %xmm3, -0x60(%rbp)
movaps %xmm0, %xmm3
addss %xmm0, %xmm3
addss %xmm2, %xmm3
addss %xmm5, %xmm1
addss %xmm4, %xmm3
unpcklps %xmm3, %xmm1            # xmm1 = xmm1[0],xmm3[0],xmm1[1],xmm3[1]
leaq -0x78(%rbp), %r14
movl %eax, (%r14)
movl %ecx, 0x4(%r14)
movlps %xmm1, 0x8(%r14)
movq %r14, %rdi
movaps %xmm4, -0x90(%rbp)
movaps %xmm5, -0x50(%rbp)
callq 0x56a82
xorl %r12d, %r12d
movq %r14, %rdi
movl %r13d, %esi
xorl %edx, %edx
callq 0x5346f
testb %al, %al
je 0x94c58
movaps -0x60(%rbp), %xmm2
movaps %xmm2, %xmm1
movaps -0x50(%rbp), %xmm3
addss %xmm3, %xmm1
movaps %xmm2, %xmm0
movaps -0x90(%rbp), %xmm4
addss %xmm4, %xmm0
movaps %xmm1, -0xb0(%rbp)
addss %xmm1, %xmm3
movss 0x225ff(%rip), %xmm1    # 0xb7004
mulss %xmm1, %xmm3
addss %xmm4, %xmm0
mulss %xmm1, %xmm0
unpcklps %xmm0, %xmm3            # xmm3 = xmm3[0],xmm0[0],xmm3[1],xmm0[1]
movlps %xmm3, -0x38(%rbp)
movss -0x38(%rbp), %xmm0
addss %xmm1, %xmm0
cvttps2dq %xmm0, %xmm0
cvtdq2ps %xmm0, %xmm0
movss %xmm0, -0x38(%rbp)
movss -0x34(%rbp), %xmm0
addss %xmm1, %xmm0
cvttps2dq %xmm0, %xmm0
cvtdq2ps %xmm0, %xmm0
movss %xmm0, -0x34(%rbp)
movss 0x22586(%rip), %xmm0    # 0xb6fd0
addss %xmm2, %xmm0
movss %xmm0, -0x50(%rbp)
leaq -0x78(%rbp), %rdi
leaq -0x29(%rbp), %rdx
leaq -0x2a(%rbp), %rcx
movl %r13d, %esi
xorl %r8d, %r8d
callq 0x92870
movl %eax, %r12d
testb %al, %al
je 0x94a79
movl %r13d, %edi
callq 0x46ca4
movss -0x50(%rbp), %xmm0
mulss 0x2257e(%rip), %xmm0    # 0xb7004
movss %xmm0, -0x50(%rbp)
leaq -0x78(%rbp), %rdi
movl %r13d, %esi
movl $0x1, %edx
callq 0x45ca4
movq 0x2b8(%r15), %r13
cmpb $0x1, -0x2a(%rbp)
jne 0x94ab4
movl $0x9, %edi
cmpb $0x0, -0x29(%rbp)
jne 0x94abb
movzbl -0x29(%rbp), %edi
addl $0x7, %edi
movss 0x22521(%rip), %xmm0    # 0xb6fe4
callq 0x445bd
leaq -0x38(%rbp), %rsi
movq %r13, %rdi
movss -0x50(%rbp), %xmm0
movl %eax, %edx
movl $0x10, %ecx
callq 0x7aa54
movl -0x3c(%rbp), %r13d
testb %r13b, %r13b
je 0x94b42
movaps -0x60(%rbp), %xmm0
divss 0x22517(%rip), %xmm0    # 0xb700c
cvttps2dq %xmm0, %xmm0
cvtdq2ps %xmm0, %xmm2
movss 0x224e0(%rip), %xmm0    # 0xb6fe4
movaps %xmm0, %xmm1
maxss %xmm2, %xmm1
movq 0x2b8(%r15), %r14
movss -0x50(%rbp), %xmm2
subss %xmm1, %xmm2
movss %xmm2, -0x60(%rbp)
movl $0x12, %edi
callq 0x445bd
leaq -0x38(%rbp), %rsi
movq %r14, %rdi
movss -0x60(%rbp), %xmm0
movl %eax, %edx
movl $0x10, %ecx
callq 0x7aa54
movss 0x15a4(%rbx), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jbe 0x94bef
movq 0x2b8(%r15), %r14
leaq -0x38(%rbp), %rax
movss (%rax), %xmm2
movss 0x22477(%rip), %xmm0    # 0xb6fe4
addss %xmm0, %xmm2
movss 0x4(%rax), %xmm1
addss %xmm0, %xmm1
unpcklps %xmm1, %xmm2            # xmm2 = xmm2[0],xmm1[0],xmm2[1],xmm1[1]
leaq -0xb8(%rbp), %r13
movlps %xmm2, (%r13)
movl $0x6, %edi
callq 0x445bd
movss 0x15a4(%rbx), %xmm1
movq %r14, %rdi
movq %r13, %rsi
movl -0x3c(%rbp), %r13d
movss -0x50(%rbp), %xmm0
movl %eax, %edx
movl $0x10, %ecx
callq 0x7a922
movq 0x2b8(%r15), %r14
movl $0x5, %edi
movss 0x2241a(%rip), %xmm0    # 0xb6fe4
callq 0x445bd
movss 0x15a4(%rbx), %xmm1
movq %r14, %rdi
leaq -0x38(%rbp), %rsi
movss -0x50(%rbp), %xmm0
movl %eax, %edx
movl $0x10, %ecx
callq 0x7a922
cmpb $0x1, 0x3138(%rbx)
jne 0x94c18
leaq 0x3e7ba(%rip), %rax     # 0xd33b9
leaq 0x3e7b7(%rip), %rsi     # 0xd33bd
testb %r13b, %r13b
cmovneq %rax, %rsi
leaq -0x78(%rbp), %rdi
xorl %edx, %edx
callq 0x44fd9
xorps %xmm0, %xmm0
movaps -0xa0(%rbp), %xmm1
ucomiss %xmm0, %xmm1
jbe 0x94c58
movaps -0xb0(%rbp), %xmm0
addss 0x15b0(%rbx), %xmm0
movaps -0x90(%rbp), %xmm1
addss 0x159c(%rbx), %xmm1
unpcklps %xmm1, %xmm0            # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
movq -0x68(%rbp), %rdi
xorl %esi, %esi
movl $0x1, %edx
callq 0x44ec4
movl %r12d, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq