Sign in to follow this  

drawing a rotated circle

This topic is 3774 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

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[i] = Vector3.RotatePointAroundVector( radius, 0, 0, direction.getX(), direction.getY(), direction.getZ(), angle); verts[i].add(center); gl.glVertex3fv(verts[i].data, 0); } gl.glEnd(); here is the code what am i doing wrong Paul

Share this post


Link to post
Share on other sites

This topic is 3774 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this