// File: /workspace/github_cpp_makefile_star2_O2/carlos-urena[P]svg-gen/svgobjects.cpp
// Function: YAxisCylinder::YAxisCylinder(Camera const&)
YAxisCylinder::YAxisCylinder( const Camera & cam )
{

  // circunferencia inferior
  Ellipse * pcinf = new Ellipse( 64, vec3(0.0,-1.0,0.0), vec3(1.0,0.0,0.0), vec3(0.0,0.0,1.0));
  pcinf->style.draw_filled = false ;
  pcinf->style.lines_color = vec3(1.0,0.0,0.0) ;

  // circunferencia ecuador
  Ellipse * pcecu = new Ellipse( 64, vec3(0.0,0.0,0.0), vec3(1.0,0.0,0.0), vec3(0.0,0.0,1.0));
  pcecu->style.draw_filled = false ;
  pcecu->style.close_lines = true ;
  pcecu->style.lines_color = vec3(0.4,0.4,0.4) ;
  pcecu->style.lines_width = 0.002 ;

  // circunferencia superior
  Ellipse * pcsup = new Ellipse( 64, vec3(0.0,1.0,0.0), vec3(1.0,0.0,0.0), vec3(0.0,0.0,1.0));
  pcsup->style.draw_filled = false ;
  pcsup->style.lines_color = vec3(1.0,0.0,0.0) ;

  // segmentos verticales que delimitan el cilindro
  const vec3 v  = cam.src.zAxis.normalized() ;
  const real s  = sqrt(v[0]*v[0]+v[2]*v[2]);
  const vec3 n1 = vec3(  v[2]/s, -1.0, -v[0]/s ),
             n2 = vec3( -v[2]/s, -1.0,  v[0]/s );
  Segment
    * s1 = new Segment( n1, vec3(0.0,2.0,0.0), vec3(1.0,0.0,0.0), pcinf->style.lines_width ),
    * s2 = new Segment( n2, vec3(0.0,2.0,0.0), vec3(1.0,0.0,0.0), pcinf->style.lines_width );

    add( pcinf );
    add( pcecu );
    add( pcsup );
    add( s1 );
    add( s2 );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r13
movq %rdi, -0x50(%rbp)
movb $0x0, 0x8(%rdi)
andq $0x0, 0x30(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x20(%rdi)
leaq 0x798f(%rip), %rax      # 0xfa08
movq %rax, (%rdi)
movl $0x98, %edi
callq 0x31b0
movq %rax, %r14
movabsq $-0x4080000000000000, %rax # imm = 0xBF80000000000000
leaq -0x40(%rbp), %rdx
movq %rax, (%rdx)
andl $0x0, 0x8(%rdx)
leaq -0x34(%rbp), %rcx
movq $0x3f800000, (%rcx)     # imm = 0x3F800000
andl $0x0, 0x8(%rcx)
pushq $0x40
popq %rsi
movss 0x2f50(%rip), %xmm1     # 0xb008
xorps %xmm0, %xmm0
movq %r14, %rdi
callq 0x70d6
movb $0x0, 0x3a(%r14)
movq $0x3f800000, 0x20(%r14) # imm = 0x3F800000
andl $0x0, 0x28(%r14)
movl $0x98, %edi
callq 0x31b0
movq %rax, %r15
leaq -0x40(%rbp), %rdx
andq $0x0, (%rdx)
andl $0x0, 0x8(%rdx)
leaq -0x34(%rbp), %rcx
movq $0x3f800000, (%rcx)     # imm = 0x3F800000
andl $0x0, 0x8(%rcx)
pushq $0x40
popq %rsi
movss 0x2f00(%rip), %xmm1     # 0xb008
xorps %xmm0, %xmm0
movq %rax, %rdi
callq 0x70d6
movw $0x1, 0x39(%r15)
movabsq $0x3ecccccd3ecccccd, %rax # imm = 0x3ECCCCCD3ECCCCCD
movq %rax, 0x20(%r15)
movl $0x3ecccccd, 0x28(%r15) # imm = 0x3ECCCCCD
movl $0x3b03126f, 0x3c(%r15) # imm = 0x3B03126F
movl $0x98, %edi
callq 0x31b0
movq %rax, %r12
movabsq $0x3f80000000000000, %rax # imm = 0x3F80000000000000
leaq -0x40(%rbp), %rdx
movq %rax, (%rdx)
andl $0x0, 0x8(%rdx)
leaq -0x34(%rbp), %rcx
movq $0x3f800000, (%rcx)     # imm = 0x3F800000
andl $0x0, 0x8(%rcx)
pushq $0x40
popq %rsi
movss 0x2e94(%rip), %xmm1     # 0xb008
xorps %xmm0, %xmm0
movq %r12, %rdi
callq 0x70d6
movb $0x0, 0x3a(%r12)
movq $0x3f800000, 0x20(%r12) # imm = 0x3F800000
andl $0x0, 0x28(%r12)
addq $0x24, %r13
movq %r13, %rdi
callq 0x5372
movaps %xmm1, %xmm2
mulss %xmm1, %xmm2
movaps %xmm0, %xmm3
mulss %xmm0, %xmm3
addss %xmm2, %xmm3
sqrtss %xmm3, %xmm2
movaps %xmm1, %xmm3
divss %xmm2, %xmm3
movaps 0x30ec(%rip), %xmm4     # 0xb2b0
movaps %xmm0, %xmm5
xorps %xmm4, %xmm5
divss %xmm2, %xmm5
movss %xmm3, -0x40(%rbp)
movl $0xbf800000, %eax       # imm = 0xBF800000
movl %eax, -0x3c(%rbp)
movss %xmm5, -0x38(%rbp)
xorps %xmm1, %xmm4
divss %xmm2, %xmm4
divss %xmm2, %xmm0
movss %xmm4, -0x34(%rbp)
movl %eax, -0x30(%rbp)
movss %xmm0, -0x2c(%rbp)
movl $0x98, %edi
callq 0x31b0
movabsq $0x4000000000000000, %r13 # imm = 0x4000000000000000
leaq -0x68(%rbp), %rdx
movq %r13, (%rdx)
andl $0x0, 0x8(%rdx)
leaq -0x5c(%rbp), %rcx
movq $0x3f800000, (%rcx)     # imm = 0x3F800000
andl $0x0, 0x8(%rcx)
movss 0x3c(%r14), %xmm0
leaq -0x40(%rbp), %rsi
movq %rax, -0x48(%rbp)
movq %rax, %rdi
callq 0x6f22
movl $0x98, %edi
callq 0x31b0
movq %rax, %rbx
leaq -0x68(%rbp), %rdx
movq %r13, (%rdx)
andl $0x0, 0x8(%rdx)
leaq -0x5c(%rbp), %rcx
movq $0x3f800000, (%rcx)     # imm = 0x3F800000
andl $0x0, 0x8(%rcx)
movss 0x3c(%r14), %xmm0
leaq -0x34(%rbp), %rsi
movq %rax, %rdi
callq 0x6f22
movq -0x50(%rbp), %r13
movq %r13, %rdi
movq %r14, %rsi
callq 0x664c
movq %r13, %rdi
movq %r15, %rsi
callq 0x664c
movq %r13, %rdi
movq %r12, %rsi
callq 0x664c
movq %r13, %rdi
movq -0x48(%rbp), %rsi
callq 0x664c
movq %r13, %rdi
movq %rbx, %rsi
callq 0x664c
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r13
movq %rbx, %rdi
jmp 0x82ef
movq %rax, %r13
movq -0x48(%rbp), %rdi
jmp 0x82ef
jmp 0x82f8
jmp 0x82f8
movq %rax, %r13
movq %r12, %rdi
jmp 0x82ef
jmp 0x82f8
movq %rax, %r13
movq %r15, %rdi
jmp 0x82ef
jmp 0x82f8
movq %rax, %r13
movq %r14, %rdi
callq 0x3190
jmp 0x82fb
jmp 0x82f8
movq %rax, %r13
movq -0x50(%rbp), %rdi
callq 0x971e
movq %r13, %rdi
callq 0x3250