MarginallyClever / weaving_algorithm

weaving thread between nails in a circle to produce an image.
GNU General Public License v2.0
163 stars 49 forks source link

error msg #1

Closed EyalALEF closed 5 years ago

EyalALEF commented 8 years ago

Hello,

Thank you so much for the code!

I am very new to this, and when I try to run the code it gives me an error msg saying: size() can not be used here.

Is it possible that there is a small bug? Thanks!

i-make-robots commented 8 years ago

Can you give the rest of the error message? Also your version of processing.

i-make-robots commented 8 years ago

Tested in processing 3.1.2 for OSX and 2.2.0 for Windows. No problems.

EyalALEF commented 8 years ago

I am using processing 3

this is the full error:

Exception in thread "Animation Thread" java.lang.IllegalStateException: size() cannot be used here, see https://processing.org/reference/size_.html at processing.core.PApplet.insideSettings(PApplet.java:933) at processing.core.PApplet.size(PApplet.java:1969) at sketch_160813a.setup(sketch_160813a.java:68) at processing.core.PApplet.handleDraw(PApplet.java:2378) at processing.awt.PSurfaceAWT$12.callDraw(PSurfaceAWT.java:1540) at processing.core.PSurfaceNone$AnimationThread.run(PSurfaceNone.java:316)

i-make-robots commented 8 years ago

size() is not used in my code. This bug is somewhere inside Processing.

On Fri, Aug 12, 2016 at 3:40 PM, EyalALEF notifications@github.com wrote:

I am using processing 3

this is the full error:

Exception in thread "Animation Thread" java.lang.IllegalStateException: size() cannot be used here, see https://processing.org/ reference/size_.html at processing.core.PApplet.insideSettings(PApplet.java:933) at processing.core.PApplet.size(PApplet.java:1969) at sketch_160813a.setup(sketch_160813a.java:68) at processing.core.PApplet.handleDraw(PApplet.java:2378) at processing.awt.PSurfaceAWT$12.callDraw(PSurfaceAWT.java:1540) at processing.core.PSurfaceNone$AnimationThread.run(PSurfaceNone.java:316)

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/i-make-robots/weaving_algorithm/issues/1#issuecomment-239576818, or mute the thread https://github.com/notifications/unsubscribe-auth/ABZYhnvrAjq_iEA3BfBqEN3GALODXeheks5qfPZigaJpZM4Jjg0l .

Dan Royer, Owner, Marginally Clever Robots https://www.marginallyclever.com/ Ph: +1 (604) 259-9564 Mo: +1 (604) 916-2281

EyalALEF commented 8 years ago

isnt it this line from the code?

// the size of the screen is img.width*2, img.height size(1336,1000);

do u have any idea what can I do to run the code properly? I realy want to try it out!

EyalALEF commented 8 years ago

If it helps: I tried another version of processing and still the same problem..when I comment this "size" line, the script runs but in a very small screen and I dont see anything actually happening

Im using version 3.1.2 on osx Thank u!

i-make-robots commented 8 years ago

I'm Running 3.1.2 on OS X and windows. Please try running the same.

On Aug 12, 2016, at 4:15 PM, EyalALEF notifications@github.com wrote:

If it helps: I tried another version of processing and still the same problem..when I comment this "size" line, the script runs but in a very small screen and I dont see anything actually happening

Thank u!

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

EyalALEF commented 8 years ago

I am running the same version and OS X, but I found a solution:

for some reason if I put the size line in the beginning, inside " void settings() { ", than it works beautifully!

My mac is quite old, maybe thats the reason somehow.

I cant tell you how cool this is for me. I make pixel art, and I would really want to try and follow the script with a real thread and nails.

If you don't mind me asking another question..Is there a way to get an output of the lines being drawn? from which dot number and to which?

Thanks a lot:)


From: Dan Royer notifications@github.com Sent: Saturday, August 13, 2016 3:22 AM To: i-make-robots/weaving_algorithm Cc: EyalALEF; Author Subject: Re: [i-make-robots/weaving_algorithm] error msg (#1)

I'm Running 3.1.2 on OS X and windows. Please try running the same.

On Aug 12, 2016, at 4:15 PM, EyalALEF notifications@github.com wrote:

If it helps: I tried another version of processing and still the same problem..when I comment this "size" line, the script runs but in a very small screen and I dont see anything actually happening

Thank u!

You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/i-make-robots/weaving_algorithm/issues/1#issuecomment-239599120, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AUBvJDVazpewpyagftlq7zEc1bwR7-wjks5qfTh-gaJpZM4Jjg0l.

i-make-robots commented 8 years ago

What are you walking about? Size() is the second line of setup().

I'll add something to spit out the PIN numbers.

On Aug 13, 2016, at 3:46 AM, EyalALEF notifications@github.com wrote:

I am running the same version and OS X, but I found a solution:

for some reason if I put the size line in the beginning, inside " void settings() { ", than it works beautifully!

My mac is quite old, maybe thats the reason somehow.

I cant tell you how cool this is for me. I make pixel art, and I would really want to try and follow the script with a real thread and nails.

If you don't mind me asking another question..Is there a way to get an output of the lines being drawn? from which dot number and to which?

Thanks a lot:)


From: Dan Royer notifications@github.com Sent: Saturday, August 13, 2016 3:22 AM To: i-make-robots/weaving_algorithm Cc: EyalALEF; Author Subject: Re: [i-make-robots/weaving_algorithm] error msg (#1)

I'm Running 3.1.2 on OS X and windows. Please try running the same.

On Aug 12, 2016, at 4:15 PM, EyalALEF notifications@github.com wrote:

If it helps: I tried another version of processing and still the same problem..when I comment this "size" line, the script runs but in a very small screen and I dont see anything actually happening

Thank u!

You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/i-make-robots/weaving_algorithm/issues/1#issuecomment-239599120, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AUBvJDVazpewpyagftlq7zEc1bwR7-wjks5qfTh-gaJpZM4Jjg0l. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.