// File: /workspace/github_cpp_makefile_star2_O1/icemiliang[P]vot/src/vot/cell.cc
// Function: voro::voronoicell_base::output_pov_mesh_new(double, double, double, std::shared_ptr<std::vector<std::array<double, 3ul>, std::allocator<std::array<double, 3ul>>>>, std::shared_ptr<std::vector<std::array<int, 3ul>, std::allocator<std::array<int, 3ul>>>>)
void voronoicell_base::output_pov_mesh_new(double x, double y, double z, 
                                           std::shared_ptr<std::vector<std::array<double,3>>> pv, 
                                           std::shared_ptr<std::vector<std::array<int, 3>>>   pf) {
    int i, j, k, l, m, n;
    double *ptsp = pts;
    for (i = 0; i < p; i++, ptsp += 3){
        std::array<double, 3> tmp = { x + *ptsp*0.5, y + ptsp[1] * 0.5, z + ptsp[2] * 0.5 };
        pv->push_back(tmp);
        //v[i][0] = x + *ptsp*0.5; v[i][1] = y + ptsp[1] * 0.5; v[i][2] = z + ptsp[2] * 0.5;
    }
    // int numf = 0;
    for (i = 1; i<p; i++) for (j = 0; j<nu[i]; j++) {
        k = ed[i][j];
        if (k >= 0) {
            ed[i][j] = -1 - k;
            l = cycle_up(ed[i][nu[i] + j], k);
            m = ed[k][l]; ed[k][l] = -1 - m;
            while (m != i) {
                n = cycle_up(ed[k][nu[k] + l], m);
                std::array<int, 3> tmp = { i, k, m };
                pf->push_back(tmp);
                //f[numf][0] = i; f[numf][1] = k; f[numf++][2] = m;
                k = m; l = n;
                m = ed[k][l]; ed[k][l] = -1 - m;
            }
        }
    }
    reset_edges();
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movq %rdi, %rbx
cmpl $0x0, 0x18(%rdi)
movq %rdx, 0x18(%rsp)
jle 0x1dd63
movq %rsi, %r15
movq 0x30(%rbx), %r13
xorl %ebp, %ebp
movsd 0x318c1(%rip), %xmm4    # 0x4f578
movq %rsp, %r12
movsd %xmm2, 0x30(%rsp)
movsd %xmm1, 0x28(%rsp)
movsd %xmm0, 0x20(%rsp)
movsd (%r13), %xmm3
mulsd %xmm4, %xmm3
addsd %xmm0, %xmm3
movsd %xmm3, (%rsp)
movsd 0x8(%r13), %xmm3
mulsd %xmm4, %xmm3
addsd %xmm1, %xmm3
movsd %xmm3, 0x8(%rsp)
movsd 0x10(%r13), %xmm3
mulsd %xmm4, %xmm3
addsd %xmm2, %xmm3
movsd %xmm3, 0x10(%rsp)
movq (%r15), %rdi
movq 0x8(%rdi), %rsi
cmpq 0x10(%rdi), %rsi
je 0x1dd2d
movq 0x10(%rsp), %rax
movq %rax, 0x10(%rsi)
movupd (%rsp), %xmm3
movupd %xmm3, (%rsi)
addq $0x18, 0x8(%rdi)
jmp 0x1dd54
movq %r12, %rdx
callq 0x25e64
movsd 0x3183b(%rip), %xmm4    # 0x4f578
movsd 0x20(%rsp), %xmm0
movsd 0x28(%rsp), %xmm1
movsd 0x30(%rsp), %xmm2
movq 0x18(%rsp), %rdx
incl %ebp
addq $0x18, %r13
cmpl 0x18(%rbx), %ebp
jl 0x1dccc
movl 0x18(%rbx), %eax
cmpl $0x2, %eax
jl 0x1de81
movl $0x1, %r12d
xorl %r9d, %r9d
movq 0x28(%rbx), %rax
cmpl $0x0, (%rax,%r12,4)
jle 0x1de71
leaq (%rax,%r12,4), %rcx
xorl %ebp, %ebp
movq 0x20(%rbx), %r8
movq (%r8,%r12,8), %rsi
movslq (%rsi,%rbp,4), %r15
testq %r15, %r15
js 0x1de5a
movl %r15d, %edi
notl %edi
movl %edi, (%rsi,%rbp,4)
movslq (%rcx), %rcx
movslq %ebp, %rdi
addq %rcx, %rdi
movl (%rsi,%rdi,4), %ecx
movl (%rax,%r15,4), %eax
decl %eax
leal 0x1(%rcx), %r13d
cmpl %ecx, %eax
cmovel %r9d, %r13d
movq (%r8,%r15,8), %rcx
movslq %r13d, %rdi
movl (%rcx,%rdi,4), %eax
movl %eax, %esi
notl %esi
movl %esi, (%rcx,%rdi,4)
cmpq %rax, %r12
je 0x1de5a
movslq %r15d, %rcx
movl %eax, %r15d
movq 0x20(%rbx), %rax
movq 0x28(%rbx), %r8
movq (%rax,%rcx,8), %rax
movslq (%r8,%rcx,4), %rsi
movslq %r13d, %rdi
addq %rsi, %rdi
movl (%rax,%rdi,4), %eax
movslq %r15d, %r14
movl (%r8,%r14,4), %esi
decl %esi
leal 0x1(%rax), %r13d
cmpl %eax, %esi
cmovel %r9d, %r13d
movl %r12d, (%rsp)
movl %ecx, 0x4(%rsp)
movl %r14d, 0x8(%rsp)
movq (%rdx), %rdi
movq 0x8(%rdi), %rsi
cmpq 0x10(%rdi), %rsi
je 0x1de3d
movl 0x8(%rsp), %eax
movl %eax, 0x8(%rsi)
movq (%rsp), %rax
movq %rax, (%rsi)
addq $0xc, 0x8(%rdi)
jmp 0x1de4d
movq %rsp, %rdx
callq 0x25fdc
xorl %r9d, %r9d
movq 0x18(%rsp), %rdx
movq 0x20(%rbx), %rax
movq (%rax,%r14,8), %rcx
jmp 0x1ddca
incq %rbp
movq 0x28(%rbx), %rax
leaq (%rax,%r12,4), %rcx
movslq (%rcx), %rsi
cmpq %rsi, %rbp
jl 0x1dd8d
incq %r12
movslq 0x18(%rbx), %rax
cmpq %rax, %r12
jl 0x1dd78
testl %eax, %eax
jle 0x1dec3
movq 0x20(%rbx), %rax
movq 0x28(%rbx), %rcx
xorl %edx, %edx
cmpl $0x0, (%rcx,%rdx,4)
jle 0x1deb7
movq (%rax,%rdx,8), %rsi
xorl %edi, %edi
movl (%rsi,%rdi,4), %r8d
testl %r8d, %r8d
jns 0x1ded2
notl %r8d
movl %r8d, (%rsi,%rdi,4)
incq %rdi
movslq (%rcx,%rdx,4), %r8
cmpq %r8, %rdi
jl 0x1de9b
incq %rdx
movslq 0x18(%rbx), %rsi
cmpq %rsi, %rdx
jl 0x1de8f
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
callq 0x7c28
nop