Category : C Source Code
Archive   : IRITS.ZIP
Filename : AMBIGUIT.IRT

 
Output of file : AMBIGUIT.IRT contained in archive : IRITS.ZIP
#
# The most common example of wireframe ambiguity. See for example:
# Geometric Modeling by Michael E. Mortenson, page 4...
#

save_res = resolution;
save_view = view_mat;

view_mat = view_mat * scale(vector(0.6, 0.6, 0.6)) * rotx(30) * roty(20);

A = box(vector(-0.5, -0.5, -0.55), 1.0, 1.0, 1.1);

resolution = 4; # To create 4 sided pyramids from cones...
C1 = cone(vector(0.0, 0.0, -0.6), vector(0.0, 0.0, 0.6), 0.6 * sqrt(2.0)) *
rotz(45);
C2 = cone(vector(0.0, 0.0, 0.6), vector(0.0, 0.0, -0.6), 0.6 * sqrt(2.0)) *
rotz(45);

A = A - C1 - C2;
free(C1);
free(C2);
view(list(A), 1);

B = box(vector(-0.3, -0.3, -1.0), 0.6, 0.6, 2.0);
C = A - B;
free(A);
free(B);

final = convex(C);
free(C);

beep(1000,100);
interact(list(final), 0);

mdump("ambiguit", view_mat);
gdump("ambiguit", final);
free(final);

view_mat = save_view;
resolution = save_res;


  3 Responses to “Category : C Source Code
Archive   : IRITS.ZIP
Filename : AMBIGUIT.IRT

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/