// File: /workspace/github_cpp_makefile_star2_O2/carlos-urena[P]svg-gen/figures.cpp
// Function: Figure4_EllipseSectorZ::Figure4_EllipseSectorZ()
Figure4_EllipseSectorZ::Figure4_EllipseSectorZ()
{
  vec3 observador = vec3(0.5,0.5,1.0), //vec3(0.9,0.5,1.0),
       lookat     = vec3(0.0,0.0,0.0),
       vup        = vec3(0.0,1.0,0.0);

  cam = Camera( lookat, observador, vup );

  // elipse plana tangente (perp. al eje Z, con eje mayor Y y eje menor X)
  const vec3 ejex = vec3(1.0,0.0,0.0),
             ejey = vec3(0.0,1.0,0.0),
             ejez = vec3(0.0,0.0,1.0);

  Ellipse * pell = new Ellipse( 128, vec3(0.0,0.0,1.0), vec3(0.6,0.0,0.0), vec3(0.0,1.5,0.0));

  EllipseSectorZ * peZ = new EllipseSectorZ( 64, real(0.6), real(1.5) );

  // esfera con relleno de gradiente radial
  Sphere * pes2D = new Sphere( vec3(0.0,0.0,0.0), 1.0 );

  // region
  SpherePolygon *    pesf  = new SpherePolygon( *(peZ->ppol) );
  YCylinderPolygon * pcy   = new YCylinderPolygon( *(peZ->ppol) );

  // polilineas proyecciones de la elipse completas, no rellenas
  SpherePolygon *    pellesf  = new SpherePolygon( *pell );
  YCylinderPolygon * pellcy   = new YCylinderPolygon( *pell );
  pellesf->style.draw_filled = false ;
  pellcy->style.draw_filled = false ;

  // points
  YCylinderPoint * ppun0 = new YCylinderPoint( *(peZ->ppun0)),
                   * ppun1 = new YCylinderPoint( *(peZ->ppun1));


  ppun0->color = vec3( 0.0, 0.7, 0.0 );
  ppun1->color = vec3( 0.0, 0.7, 0.0 );
  ppun0->radius = 0.05 ;
  ppun1->radius = 0.05 ;

  // segmento verde entre los points:
  Segment * segmv = new Segment( ppun0->pos3D, ppun1->pos3D - ppun0->pos3D,
                                ppun0->color, 0.025 );

  //añadir objetos
  const int cadacuantos = 4 ;

  objetos.add( new Axes( 0.010 ));
  objetos.add( new YAxisCylinder( cam ) );

  objetos.add( pellesf );
  objetos.add( pellcy );
  objetos.add( pes2D );
  objetos.add( pesf );
  objetos.add( pcy );
  objetos.add( ppun0 );
  objetos.add( ppun1 );
  objetos.add( segmv );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq %rdi, %r14
callq 0x8796
movabsq $0x3f0000003f000000, %rax # imm = 0x3F0000003F000000
leaq -0xac(%rbp), %rsi
andq $0x0, (%rsi)
leaq -0xb8(%rbp), %rdx
andl $0x0, 0x8(%rsi)
movq %rax, (%rdx)
movl $0x3f800000, 0x8(%rdx)  # imm = 0x3F800000
movabsq $0x3f80000000000000, %rax # imm = 0x3F80000000000000
leaq -0xa0(%rbp), %rcx
movq %rax, (%rcx)
andl $0x0, 0x8(%rcx)
leaq -0x88(%rbp), %rdi
movq %r14, -0x48(%rbp)
callq 0x5f0c
movups -0x88(%rbp), %xmm0
movups -0x78(%rbp), %xmm1
movups -0x68(%rbp), %xmm2
movups %xmm2, 0x20(%r14)
movups %xmm1, 0x10(%r14)
movups %xmm0, (%r14)
movl $0x98, %edi
callq 0x31b0
movq %rax, %r12
leaq -0x88(%rbp), %rdx
andq $0x0, (%rdx)
movl $0x3f800000, 0x8(%rdx)  # imm = 0x3F800000
leaq -0x94(%rbp), %rcx
movq $0x3f19999a, (%rcx)     # imm = 0x3F19999A
andl $0x0, 0x8(%rcx)
movsd 0x7400(%rip), %xmm0     # 0xb040
xorps %xmm1, %xmm1
movq %rax, %rdi
movl $0x80, %esi
callq 0x70d6
pushq $0x50
popq %rdi
callq 0x31b0
movq %rax, %rbx
pushq $0x40
popq %rsi
movss 0x73aa(%rip), %xmm0     # 0xb010
movss 0x73a6(%rip), %xmm1     # 0xb014
movq %rax, %rdi
callq 0x723a
pushq $0x38
popq %rdi
callq 0x31b0
movq %rax, %r13
leaq -0x88(%rbp), %rsi
andq $0x0, (%rsi)
andl $0x0, 0x8(%rsi)
movss 0x7370(%rip), %xmm0     # 0xb008
movq %rax, %rdi
callq 0x67a0
movl $0x98, %edi
callq 0x31b0
movq 0x38(%rbx), %rsi
movq %rax, -0x58(%rbp)
movq %rax, %rdi
xorl %edx, %edx
callq 0x8b4a
movl $0x98, %edi
callq 0x31b0
movq 0x38(%rbx), %rsi
movq %rax, -0x50(%rbp)
movq %rax, %rdi
callq 0x90e0
movl $0x98, %edi
callq 0x31b0
movq %rax, -0x40(%rbp)
movq %rax, %rdi
movq %r12, %rsi
xorl %edx, %edx
callq 0x8b4a
movl $0x98, %edi
callq 0x31b0
movq %rax, %r15
movq %r13, -0x30(%rbp)
movq %rax, %rdi
movq %r12, %rsi
callq 0x90e0
xorl %eax, %eax
movq -0x40(%rbp), %rcx
movb %al, 0x3a(%rcx)
movb %al, 0x3a(%r15)
pushq $0x40
popq %rdi
callq 0x31b0
movq %rax, %r13
movq 0x40(%rbx), %rsi
movq %rax, %rdi
callq 0x9024
pushq $0x40
popq %rdi
callq 0x31b0
movq %rax, %r12
movq 0x48(%rbx), %rsi
movq %rax, %rdi
callq 0x9024
movabsq $0x3f33333300000000, %rax # imm = 0x3F33333300000000
movq %rax, 0x28(%r13)
andl $0x0, 0x30(%r13)
movq %rax, 0x28(%r12)
andl $0x0, 0x30(%r12)
movl $0x3d4ccccd, %eax       # imm = 0x3D4CCCCD
movl %eax, 0x3c(%r13)
movl %eax, 0x3c(%r12)
movl $0x98, %edi
callq 0x31b0
movq %rax, -0x38(%rbp)
leaq 0x1c(%r13), %rbx
movq %r12, %rdi
addq $0x1c, %rdi
movq %rbx, %rsi
callq 0x530c
movq %r13, %rcx
addq $0x28, %rcx
leaq -0x88(%rbp), %rdx
movss %xmm0, (%rdx)
shufps $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
movss %xmm0, 0x4(%rdx)
movss %xmm1, 0x8(%rdx)
movss 0x725b(%rip), %xmm0     # 0xb018
movq -0x38(%rbp), %rdi
movq %rbx, %rsi
callq 0x6f22
pushq $0x38
popq %rdi
callq 0x31b0
movq %rax, %r14
movss 0x7230(%rip), %xmm0     # 0xb00c
movq %rax, %rdi
xorl %esi, %esi
callq 0x7ca0
movq -0x48(%rbp), %rax
leaq 0x30(%rax), %rbx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x664c
pushq $0x38
popq %rdi
callq 0x31b0
movq %rax, %r14
movq %rax, %rdi
movq -0x48(%rbp), %rsi
callq 0x804a
movq %rbx, %rdi
movq %r14, %rsi
callq 0x664c
movq %rbx, %rdi
movq -0x40(%rbp), %rsi
callq 0x664c
movq %rbx, %rdi
movq %r15, %rsi
callq 0x664c
movq %rbx, %rdi
movq -0x30(%rbp), %rsi
callq 0x664c
movq %rbx, %rdi
movq -0x58(%rbp), %rsi
callq 0x664c
movq %rbx, %rdi
movq -0x50(%rbp), %rsi
callq 0x664c
movq %rbx, %rdi
movq %r13, %rsi
callq 0x664c
movq %rbx, %rdi
movq %r12, %rsi
callq 0x664c
movq %rbx, %rdi
movq -0x38(%rbp), %rsi
callq 0x664c
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x3e8c
movq %rax, -0x30(%rbp)
movq %r14, %rdi
jmp 0x3ef9
jmp 0x3f00
jmp 0x3ee4
jmp 0x3f00
jmp 0x3ece
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq %r15, %rdi
jmp 0x3ef9
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq -0x40(%rbp), %rdi
jmp 0x3ef9
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq -0x50(%rbp), %rdi
jmp 0x3ef9
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq -0x58(%rbp), %rdi
jmp 0x3ef9
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq %r13, %rdi
jmp 0x3ef9
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq %rbx, %rdi
jmp 0x3ef9
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq %r12, %rdi
jmp 0x3ef9
jmp 0x3f00
jmp 0x3f00
movq %rax, -0x30(%rbp)
movq -0x38(%rbp), %rdi
callq 0x3190
jmp 0x3f04
movq %rax, -0x30(%rbp)
movq -0x48(%rbp), %rdi
callq 0x53e4
movq -0x30(%rbp), %rdi
callq 0x3250