General Category > General Anim8or Forum
WEEHEEEE oh, oh wait its dead, I thought it was dancing (CRE8OR NOTICE)
Thanos:
Ok I found 1 bug so far, if the line is vertical, the tangent of angle is infinite,... so it's blown up. I should try to find an alternative way to describe the line.
cooldude234:
--- Quote from: Thanos on February 13, 2013, 09:54:37 am ---Ok I found 1 bug so far, if the line is vertical, the tangent of angle is infinite,... so it's blown up. I should try to find an alternative way to describe the line.
--- End quote ---
??? :S ???
Thanos:
--- Quote from: Thanos on February 12, 2013, 04:20:58 pm ---EDIT: Uhh :-[ :-X it seems it needs just a tad of debugging, I'm sorry cooldude234!!
--- End quote ---
I meant that my code needs debugging, not yours. :D Yours is probably ok. I have little time this days because of exams, but I'll find some soon to do more tests to find the other bug too.
--- Quote from: cooldude234 ---??? :S ???
--- End quote ---
Um in other words there is a chance of division by zero in my code. :)
cooldude234:
if there was a division by zero then the code would crash (the program would just stop running and close), and VC++'s debugger would recognize the crash code and tell me it was a division by zero.
And I know that you mean your code, but I have no clue what you said by...
--- Quote ---Ok I found 1 bug so far, if the line is vertical, the tangent of angle is infinite,... so it's blown up. I should try to find an alternative way to describe the line.
--- End quote ---
something about the tan of the angle is infinite, which I don't even know how that's possible and I just don't understand it.
Thanos:
--- Quote from: cooldude234 on February 14, 2013, 05:34:53 pm ---if there was a division by zero then the code would crash (the program would just stop running and close), and VC++'s debugger would recognize the crash code and tell me it was a division by zero.
--- End quote ---
Yes, in integers it would crash. In floats however the float variable gets a special value, #inf. Processing this value usually gives #nan (not a number), which makes things stop working well in general. I'm not sure if we are testing the same input though.
--- Quote from: cooldude234 ---And I know that you mean your code, but I have no clue what you said by...
--- Quote ---Ok I found 1 bug so far, if the line is vertical, the tangent of angle is infinite,... so it's blown up. I should try to find an alternative way to describe the line.
--- End quote ---
something about the tan of the angle is infinite, which I don't even know how that's possible and I just don't understand it.
--- End quote ---
An example in 2D: a 2D line is described by y=ax+b. a is equal to tan(t), where t is the angle of the line. A vertical line is x=c. How much is a here? There is no a here, but vertical means, t=90 deg -> a=tan90 = #inf... unless you use different system to describe the line, without a and b.
Same for 3D.
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version