drawing a rotated circle

Started by
-1 comments, last by PaulHolverda 16 years, 8 months ago
i want to draw a circle, with radius r it's center (xyz) and it is laying on a plane with normal (nx, ny, nz), i've got it managed somehow, but sometimes it totally get screwed up: gl.glBegin(GL.GL_LINE_LOOP); for( int i = 0; i < NUM_LINES; i++){ float angle = (float) Math.toRadians(i * 360 /NUM_LINES); verts = Vector3.RotatePointAroundVector( radius, 0, 0, direction.getX(), direction.getY(), direction.getZ(), angle); verts.add(center); gl.glVertex3fv(verts.data, 0); } gl.glEnd(); here is the code what am i doing wrong Paul

This topic is closed to new replies.

Advertisement