Im from Processing .
in processing
stroke(float r, float g, float b); <-- with this i can change stroke color
fill(float r, float g, float b); <-- with this i can change color of fill
how can I change stroke color and change fill color in openframeworks.
thanks for reply
hello,
to fill a shape use (prior to draw)
ofFill()
to draw only contour use
ofNoFill()
to change draw color use
ofSetColor(r,g,b,a)
Thanks but is there any possible way to change
color of inside shape and prior together
if you need to set a inside shape color and contour with another color, i would say you need to draw them separately
ofFill();
ofSetColor(255, 255, 255, 255); // fill color
ofDrawRectangle(x, y, width, height);
ofNoFill();
ofSetColor(255, 0, 0, 255); // contour (stroke) color
ofDrawRectangle(x, y, width, height);
2 Likes
Thanks so much I was finding that