Package com.deadtroll.model

Examples of com.deadtroll.model.Circulo


      mousePos[1] = NDCUtil.yScreenParaOrtho(event.getY(), glDrawable.getHeight(), minOrthoYTransf, maxOrthoYTransf);
     
      Ponto2d pontoMouse = new Ponto2d(this.mousePos[0], this.mousePos[1]);
      if (this.controller.modoAdicaoCirculo()) {
        if (objetoAdicao != null) {
          Circulo circulo = (Circulo)objetoAdicao;
          float raio = MathUtil.calcularDistancia(circulo.getCentro(), pontoMouse);
          circulo.setRaio(raio);
        }
      }
     
      glDrawable.display();
    }
View Full Code Here


  @Override
  public void mousePressed(MouseEvent e) {
    Ponto2d pontoMouse = new Ponto2d(this.mousePos[0], this.mousePos[1]);
    if (this.controller.modoAdicaoCirculo()) {
      if (this.objetoAdicao == null) {
        this.objetoAdicao = new Circulo(pontoMouse, 0.0f);
        this.controller.addObject(this.objetoAdicao);
      } else {
        Circulo circulo = (Circulo)this.objetoAdicao;
        float raio = MathUtil.calcularDistancia(circulo.getCentro(), pontoMouse);
        circulo.setRaio(raio);
        this.objetoAdicao = null;
      }
    } else if (this.controller.modoAdicaoSpline()) {
      if (this.objetoAdicao == null) {
        this.objetoAdicao = new Spline();
View Full Code Here

TOP

Related Classes of com.deadtroll.model.Circulo

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.