vector - Processing 3 - Cannot insert .svg -


i'm trying enter .svg using loadshape , says "the variable 'head' not exist. files in data folder, i'm not sure what's going on. here's code:

// global stuff - variables    //setup routine - runs once @ beginning of sketch void setup()  {    head=loadshape("head.svg");    size(500, 500);    background(0);    nostroke();    smooth();  }    //draw routine - runs on , on again forever void draw()  {    background(200);    shape(head, width/2, height/2, 475, 475); } 

the error says all: you're never declaring head variable, doesn't exist.

see comment @ top says // global stuff - variables? need declare head variable there. declare variable, give type , name. in case, type pshape , name head:

pshape head; 

Comments

Popular posts from this blog

amazon web services - S3 Pre-signed POST validate file type? -

c# - Check Keyboard Input Winforms -