- String numbers[] = loadStrings("xb.txt");
- // I decided to put everthing into one file
- //string numbers = ??? Do I have to see them here??
- int[] nums = int(split(numbers, ' ')); // how daoes that work. It says the method split(String, char) in the type PApplet is not applicable for the arguments.
- // I tried to change the "numbers" into lines like in the example but it gives me the same error
- void setup() {
- size(720,560);
- background(255);
- }
- void draw() {
- fill(244,45,67);
- beginShape();
- vertex(nums[0],nums[143]);
- vertex(nums[1],nums[144]);
- vertex(nums[2],nums[145]);
- vertex(nums[3],nums[146]);
- vertex(nums[4],nums[147]);
- vertex(nums[5],nums[148]);
- vertex(nums[6],nums[149]);
- vertex(nums[7],nums[150]);
- vertex(nums[8],nums[151]);
- vertex(nums[9],nums[152]);
- vertex(nums[10],nums[153]);
- vertex(nums[11],nums[154]);
- vertex(nums[12],nums[155]);
- vertex(nums[13],nums[156]);
- vertex(nums[14],nums[157]);
- vertex(nums[15],nums[158]);
- vertex(nums[16],nums[159]);
- vertex(nums[17],nums[160]);
- /*vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- vertex(nums[],nums[]);
- */
- //.......
- endShape(CLOSE);
- }