RE: Rounding Errors in primitives?
2021-04-29, 19:59 (This post was last modified: 2021-04-29, 20:02 by Lasse Deleuran.)
2021-04-29, 19:59 (This post was last modified: 2021-04-29, 20:02 by Lasse Deleuran.)
Thanks for the explanation! I am using this to improve the automated testing framework that I am currently working on.
However. I have found an issue with 4-4con12.dat. The official file uses the following point in the quads:
-11.0868 1 4.5924
Such as in the following quads:
4 16 -8.4852 1 8.4852 -11.0868 1 4.5924 -12.0107 0 4.9751 -9.1923 0 9.1923
4 16 -11.0868 1 4.5924 -12 1 0 -13 0 0 -12.0107 0 4.9751
And even this conditional line:
5 24 -11.0868 1 4.5924 -12.0107 0 4.9751 -8.4853 1 8.4853 -12 1 0
However. The other conditional lines, where I expect the same point to be used, use:
-11.0866 1 4.5922
such as in:
5 24 -8.4852 1 8.4852 -9.1923 0 9.1923 -4.5922 1 11.0866 -11.0866 1 4.5922
5 24 -12 1 0 -13 0 0 -11.0866 1 4.5922 -11.0866 1 -4.5922
You can get to this point by computing the points without using the tip from this thread. With full decimals through the full calculation, the point should be:
11.08655439013544 1 4.592201188381077
which rounds to 4 decimals as:
-11.0866 1 4.5922
How do I know which method to use in conditional lines?
Please note that other cones, such as the following do not have this issue:
Edit: It seems that for a conditional line A B C D, A and B use the scaling trick from this thread, while the control points C and D do not.
However. I have found an issue with 4-4con12.dat. The official file uses the following point in the quads:
-11.0868 1 4.5924
Such as in the following quads:
4 16 -8.4852 1 8.4852 -11.0868 1 4.5924 -12.0107 0 4.9751 -9.1923 0 9.1923
4 16 -11.0868 1 4.5924 -12 1 0 -13 0 0 -12.0107 0 4.9751
And even this conditional line:
5 24 -11.0868 1 4.5924 -12.0107 0 4.9751 -8.4853 1 8.4853 -12 1 0
However. The other conditional lines, where I expect the same point to be used, use:
-11.0866 1 4.5922
such as in:
5 24 -8.4852 1 8.4852 -9.1923 0 9.1923 -4.5922 1 11.0866 -11.0866 1 4.5922
5 24 -12 1 0 -13 0 0 -11.0866 1 4.5922 -11.0866 1 -4.5922
You can get to this point by computing the points without using the tip from this thread. With full decimals through the full calculation, the point should be:
11.08655439013544 1 4.592201188381077
which rounds to 4 decimals as:
-11.0866 1 4.5922
How do I know which method to use in conditional lines?
Please note that other cones, such as the following do not have this issue:
- 2-4con0.dat
- 2-4con1.dat
- 4-4con0.dat
- 4-4con1.dat
- 4-4con2.dat
- 4-4con3.dat
- 4-4con4.dat
- 4-4con5.dat
- 4-4con6.dat
- 4-4con7.dat
- 4-4con8.dat
- 4-4con9.dat
- 4-4con10.dat
- 4-4con11.dat
Edit: It seems that for a conditional line A B C D, A and B use the scaling trick from this thread, while the control points C and D do not.