We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpPrograms › CircleSegment Problem
Page Index Toggle Pages: 1
CircleSegment Problem (Read 317 times)
CircleSegment Problem
Aug 10th, 2008, 10:21am
 
I am playing arround with some broken circles and segments and got a probelm i couldnt solve yet.
is there a way to avoid these "white connection lines" ? i get them everytime i use smooth().

www.dec32.de/public/segments.jpg

I can tell why, but is there any workaround? ive found alot of images that dont have this problem...

This is the code im using: THX!

import processing.opengl.*;
void setup(){
 size(440,440,OPENGL);
 smooth();
}
void draw(){
 background(255);
 translate(width/2,height/2);
 int resolution=100;
 int start=0;
 int end=360;
 int radius=100;
 beginShape(QUAD_STRIP);
 for(int i=0;i<resolution;i++){
   float d=radians(map(i,0,resolution-1,start,end));
   noStroke();
   fill(0);

   vertex(sin(d)*radius,cos(d)*radius);
   vertex(sin(d)*radius*2,cos(d)*radius*2);
 }
 endShape();
}

Re: CircleSegment Problem
Reply #1 - Aug 10th, 2008, 11:54am
 
I don't see the lines at all (p5 143, MacBook Pro OS X 10.5.4)
Have you tried playing around with anti-aliasing values in OpenGL directly?
Re: CircleSegment Problem
Reply #2 - Aug 10th, 2008, 12:09pm
 
nope, i have to admit i have no clue how to...
Re: CircleSegment Problem
Reply #3 - Aug 11th, 2008, 2:25am
 
http://processing.org/reference/hint_.html

solved at least some of the problems .. now the font rendering seems to be a bit blurry, maybe i can fix that in some other ways
Page Index Toggle Pages: 1