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 & HelpSyntax Questions › How to draw a heart
Page Index Toggle Pages: 1
How to draw a heart (Read 1836 times)
How to draw a heart
Jun 28th, 2009, 9:15am
 
Hi, I'm very new at processing. I would like to draw a heart but I don't know how. Can anyone help me?
thanks!!!
Re: How to draw a heart
Reply #1 - Jun 28th, 2009, 10:09am
 
i've done it!!

smooth();
noStroke();
fill(255,0,0);
beginShape();
vertex(50, 15);
bezierVertex(50, -5, 90, 5, 50, 40);
vertex(50, 15);
bezierVertex(50, -5, 10, 5, 50, 40);
endShape();

Re: How to draw a heart
Reply #2 - Jun 28th, 2009, 10:28am
 
nice one Smiley if you want more complex shapes, you can simple draw them in an vector programm like Illustrator and save them as SVG. and then import the shapes with PShape
http://processing.org/reference/PShape.html
Page Index Toggle Pages: 1