Package javax.media.opengl

Examples of javax.media.opengl.GL.glVertex3f()


          * (float) Math.sin(angle), -width * 0.5f);
      gl.glVertex3f(r0 * (float) Math.cos(angle), r0
          * (float) Math.sin(angle), -width * 0.5f);
      gl.glVertex3f(r1 * (float) Math.cos(angle + 3 * da), r1
          * (float) Math.sin(angle + 3 * da), -width * 0.5f);
      gl.glVertex3f(r0 * (float) Math.cos(angle), r0
          * (float) Math.sin(angle), -width * 0.5f);
    }
    gl.glEnd();
    gl.glPopMatrix();
  }
 
View Full Code Here


        /////TEST/// //TODO make vertex pointer arrays?
        gl.glColor4d (strokeColBuff.get(0), strokeColBuff.get(1), strokeColBuff.get(2), strokeColBuff.get(3));
        for (Vertex[] outline : outLines){
         gl.glBegin (GL.GL_LINE_STRIP);
           for (Vertex vertex : outline){
             gl.glVertex3f (vertex.getX(), vertex.getY(), vertex.getZ());
           }
          gl.glEnd();
      }
      ////
//      gl.glDisable (GL.GL_LINE_SMOOTH);
View Full Code Here

       gl.glColor4f(1.0f, 1.0f, 1.0f, 1.0f);
       //gl.glBegin (GL.GL_LINE_STRIP);
         gl.glBegin (GL.GL_TRIANGLE_FAN);
           for (int i = 0; i < allVertsBezierResolved.length; i++) {
          Vertex vertex = allVertsBezierResolved[i];
          gl.glVertex3f(vertex.x, vertex.y, vertex.z);
        }
       gl.glEnd ();

       //Draw aliased off-pixels to real
        gl.glColorMask (true, true, true, true);
View Full Code Here

       gl.glLineWidth(1.0f);
       gl.glColor4f(0.0f, 0.0f, 0.0f, 1.0f);
        gl.glBegin (GL.GL_LINES);
         for (int i = 0; i < allVertsBezierResolved.length; i++) {
          Vertex vertex = allVertsBezierResolved[i];
          gl.glVertex3f(vertex.x, vertex.y, vertex.z);
         }
        gl.glEnd ();
        gl.glDisable (GL.GL_LINE_SMOOTH);
//    */
//    /*
 
View Full Code Here

        gl.glStencilFunc (GL.GL_EQUAL, 0x01, 0x01);
        gl.glStencilOp (GL.GL_ZERO, GL.GL_ZERO, GL.GL_ZERO);
      
        gl.glColor4f(0.0f, 0.0f, 0.0f, 1.0f);
        gl.glBegin (GL.GL_QUADS);
          gl.glVertex3f (minMax[0], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[3], 0.0f);
          gl.glVertex3f (minMax[0],  minMax[3], 0.0f);
        gl.glEnd ();
View Full Code Here

        gl.glStencilOp (GL.GL_ZERO, GL.GL_ZERO, GL.GL_ZERO);
      
        gl.glColor4f(0.0f, 0.0f, 0.0f, 1.0f);
        gl.glBegin (GL.GL_QUADS);
          gl.glVertex3f (minMax[0], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[3], 0.0f);
          gl.glVertex3f (minMax[0],  minMax[3], 0.0f);
        gl.glEnd ();

        gl.glDisable(GL.GL_STENCIL_TEST);
View Full Code Here

      
        gl.glColor4f(0.0f, 0.0f, 0.0f, 1.0f);
        gl.glBegin (GL.GL_QUADS);
          gl.glVertex3f (minMax[0], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[3], 0.0f);
          gl.glVertex3f (minMax[0],  minMax[3], 0.0f);
        gl.glEnd ();

        gl.glDisable(GL.GL_STENCIL_TEST);
//    */
 
View Full Code Here

        gl.glColor4f(0.0f, 0.0f, 0.0f, 1.0f);
        gl.glBegin (GL.GL_QUADS);
          gl.glVertex3f (minMax[0], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[1], 0.0f);
          gl.glVertex3f (minMax[2], minMax[3], 0.0f);
          gl.glVertex3f (minMax[0],  minMax[3], 0.0f);
        gl.glEnd ();

        gl.glDisable(GL.GL_STENCIL_TEST);
//    */
        ((PGraphicsOpenGL)pa.g).endGL();
View Full Code Here

    FloatBuffer strokeColBuff = this.getGeometryInfo().getStrokeColBuff();
    gl.glColor4d (strokeColBuff.get(0), strokeColBuff.get(1), strokeColBuff.get(2), strokeColBuff.get(3));
    for (Vertex[] varr : this.outlineContours){
      gl.glBegin(GL.GL_LINE_STRIP);
      for(Vertex v : varr){
        gl.glVertex3f(v.x, v.y, v.z);
      }
      gl.glEnd();
    }
   
    //FIXME TEST
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.