]> git.tdb.fi Git - r2c2.git/commitdiff
Allow custom objects for tracks
authorMikko Rasa <tdb@tdb.fi>
Sat, 15 Jan 2011 11:23:40 +0000 (11:23 +0000)
committerMikko Rasa <tdb@tdb.fi>
Sat, 15 Jan 2011 11:23:40 +0000 (11:23 +0000)
Create model for bumper (24977)
Smoothing support for generated track meshes
Improved rail profile

data/bumper.object [new file with mode: 0644]
data/track.technique
gfx.blend
source/3d/tracktype.cpp
source/3d/tracktype.h
source/libr2c2/catalogue.cpp
source/libr2c2/profile.cpp
source/libr2c2/profile.h
source/libr2c2/tracktype.cpp
source/libr2c2/tracktype.h
tracks.dat

diff --git a/data/bumper.object b/data/bumper.object
new file mode 100644 (file)
index 0000000..5146962
--- /dev/null
@@ -0,0 +1,1909 @@
+mesh
+{
+       winding COUNTERCLOCKWISE;
+       vertices NORMAL3_TEXCOORD2_VERTEX3
+       {
+               normal3 0 0 1;
+               texcoord2 0.1 0.5;
+               vertex3 0.055 0.014 0.008;
+               vertex3 0.055 -0.014 0.008;
+               vertex3 -1.49012e-08 -0.014 0.008;
+               vertex3 7.45058e-09 0.014 0.008;
+               normal3 0.0656471 0.781076 0.620976;
+               vertex3 0.081 0.02 9.31323e-10;
+               normal3 2.62962e-07 0.8 0.6;
+               vertex3 7.45058e-09 0.02 9.31323e-10;
+               normal3 0.0656456 -0.781076 0.620975;
+               vertex3 0.081 -0.02 9.31323e-10;
+               normal3 -8.76539e-08 -0.8 0.6;
+               vertex3 -1.49012e-08 -0.02 9.31323e-10;
+               normal3 0 -1 0;
+               texcoord2 0.3 0.5;
+               vertex3 7.45058e-09 -0.00975 0.008;
+               normal3 0 -0.755454 0.655202;
+               vertex3 7.45058e-09 -0.00975 0.0083;
+               vertex3 7.45058e-09 -0.00905 0.0084;
+               normal3 0 -0.92388 -0.382683;
+               vertex3 7.45058e-09 -0.00905 0.0095;
+               vertex3 7.45058e-09 -0.00925 0.0097;
+               normal3 0 -0.92388 0.382683;
+               vertex3 7.45058e-09 -0.00925 0.0101;
+               normal3 0 0.92388 0.382683;
+               vertex3 7.45058e-09 -0.00825 0.0101;
+               normal3 0 0.92388 -0.382683;
+               vertex3 7.45058e-09 -0.00825 0.0097;
+               vertex3 7.45058e-09 -0.00844999 0.0095;
+               normal3 0 0.755454 0.655202;
+               vertex3 7.45058e-09 -0.00844999 0.0084;
+               vertex3 7.45058e-09 -0.00775 0.0083;
+               normal3 0 1 0;
+               vertex3 7.45058e-09 -0.00775 0.008;
+               normal3 0 -0.382683 0.92388;
+               vertex3 7.45058e-09 -0.00905 0.0103;
+               normal3 0 0.382683 0.92388;
+               vertex3 7.45058e-09 -0.00844999 0.0103;
+               normal3 0 -1 0;
+               vertex3 0.0775 -0.00975 0.008;
+               normal3 0 -0.755454 0.655202;
+               vertex3 0.0775 -0.00975 0.0083;
+               vertex3 0.0775 -0.00905 0.0084;
+               normal3 0 -0.92388 -0.382683;
+               vertex3 0.0775 -0.00905 0.0095;
+               vertex3 0.0775 -0.00925 0.0097;
+               normal3 0 -0.92388 0.382683;
+               vertex3 0.0775 -0.00925 0.0101;
+               normal3 0 0.92388 -0.382683;
+               vertex3 0.0775 -0.00825 0.0097;
+               normal3 0 0.92388 0.382683;
+               vertex3 0.0775 -0.00825 0.0101;
+               normal3 0 0.92388 -0.382683;
+               vertex3 0.0775 -0.00844999 0.0095;
+               normal3 0 0.755454 0.655202;
+               vertex3 0.0775 -0.00844999 0.0084;
+               vertex3 0.0775 -0.00775 0.0083;
+               normal3 0 1 0;
+               vertex3 0.0775 -0.00775 0.008;
+               normal3 0 -0.382683 0.92388;
+               vertex3 0.0775 -0.00905 0.0103;
+               normal3 0 0.382683 0.92388;
+               vertex3 0.0775 -0.00844999 0.0103;
+               vertex3 0.0775 0.00905 0.0103;
+               normal3 0 -0.382683 0.92388;
+               vertex3 0.0775 0.00845 0.0103;
+               normal3 0 1 0;
+               vertex3 0.0775 0.00975 0.008;
+               normal3 0 0.755454 0.655202;
+               vertex3 0.0775 0.00975 0.0083;
+               vertex3 0.0775 0.00905 0.0084;
+               normal3 0 0.92388 -0.382683;
+               vertex3 0.0775 0.00905 0.0095;
+               normal3 0 0.92388 0.382683;
+               vertex3 0.0775 0.00925 0.0101;
+               normal3 0 0.92388 -0.382683;
+               vertex3 0.0775 0.00925 0.0097;
+               normal3 0 -0.92388 0.382683;
+               vertex3 0.0775 0.00825 0.0101;
+               normal3 0 -0.92388 -0.382683;
+               vertex3 0.0775 0.00825 0.0097;
+               vertex3 0.0775 0.00845 0.0095;
+               normal3 0 -0.755454 0.655202;
+               vertex3 0.0775 0.00845 0.0084;
+               vertex3 0.0775 0.00775 0.0083;
+               normal3 0 -1 0;
+               vertex3 0.0775 0.00775 0.008;
+               normal3 0 0.382683 0.92388;
+               vertex3 7.45058e-09 0.00905 0.0103;
+               normal3 0 -0.382683 0.92388;
+               vertex3 7.45058e-09 0.00845 0.0103;
+               normal3 0 1 0;
+               vertex3 7.45058e-09 0.00975 0.008;
+               normal3 0 0.755454 0.655202;
+               vertex3 7.45058e-09 0.00975 0.0083;
+               vertex3 7.45058e-09 0.00905 0.0084;
+               normal3 0 0.92388 -0.382683;
+               vertex3 7.45058e-09 0.00905 0.0095;
+               vertex3 7.45058e-09 0.00925 0.0097;
+               normal3 0 0.92388 0.382683;
+               vertex3 7.45058e-09 0.00925 0.0101;
+               normal3 0 -0.92388 0.382683;
+               vertex3 7.45058e-09 0.00825 0.0101;
+               normal3 0 -0.92388 -0.382683;
+               vertex3 7.45058e-09 0.00825 0.0097;
+               vertex3 7.45058e-09 0.00845 0.0095;
+               normal3 0 -0.755454 0.655202;
+               vertex3 7.45058e-09 0.00845 0.0084;
+               vertex3 7.45058e-09 0.00775 0.0083;
+               normal3 0 -1 0;
+               vertex3 7.45058e-09 0.00775 0.008;
+               normal3 0.366542 0.639382 0.675898;
+               texcoord2 0.1 0.5;
+               vertex3 0.0825 0.0195981 9.31323e-10;
+               normal3 0.646602 0.399223 0.650021;
+               vertex3 0.0835981 0.0185 9.31323e-10;
+               normal3 0.366538 -0.639384 0.675898;
+               vertex3 0.0825 -0.0195981 9.31323e-10;
+               normal3 0.646601 -0.399223 0.650021;
+               vertex3 0.0835981 -0.0185 9.31323e-10;
+               normal3 0.78707 -0.0566645 0.614255;
+               vertex3 0.087 -0.00500001 9.31323e-10;
+               normal3 0.787071 0.0566642 0.614255;
+               vertex3 0.087 0.00499999 9.31323e-10;
+               normal3 0.773259 -0.188548 0.605409;
+               vertex3 0.086 -0.012 9.31323e-10;
+               normal3 0.773259 0.188549 0.605409;
+               vertex3 0.086 0.012 9.31323e-10;
+               normal3 0.308076 -0.542522 0.78151;
+               vertex3 0.0765 -0.0111981 0.0112;
+               normal3 0.0848464 -0.674354 0.733518;
+               vertex3 0.075 -0.0116 0.0112;
+               normal3 0.549945 -0.326109 0.768904;
+               vertex3 0.0775981 -0.0101 0.0112;
+               normal3 0.308079 0.54252 0.781511;
+               vertex3 0.0765 0.0111981 0.0112;
+               normal3 0.0848482 0.674353 0.733518;
+               vertex3 0.075 0.0116 0.0112;
+               normal3 0.549945 0.32611 0.768904;
+               vertex3 0.0775981 0.0101 0.0112;
+               normal3 0.704971 0.10493 0.701431;
+               vertex3 0.078 0.0086 0.0112;
+               normal3 0.704972 -0.104929 0.701431;
+               vertex3 0.078 -0.00860001 0.0112;
+               normal3 1 0 0;
+               texcoord2 0.5 0.5;
+               vertex3 0.045 -0.0073 0.0108;
+               vertex3 0.045 -0.0073 0.00880001;
+               vertex3 0.045 -0.0103 0.00880001;
+               vertex3 0.045 -0.0108 0.0108;
+               vertex3 0.045 -0.0108 0.0103;
+               vertex3 0.045 -0.0098 0.0103;
+               vertex3 0.045 -0.0098 0.00920001;
+               vertex3 0.045 -0.0103 0.0092;
+               normal3 0 -1.49013e-05 1;
+               vertex3 0.012 -0.0103 0.0092;
+               vertex3 0.012 -0.0098 0.00920001;
+               normal3 0 -1 8.46657e-07;
+               vertex3 0.012 -0.0098 0.0103;
+               normal3 0 0 -1;
+               vertex3 0.012 -0.0108 0.0103;
+               normal3 0 -1 0;
+               vertex3 0.012 -0.0108 0.0108;
+               normal3 0 -1 9.31342e-06;
+               vertex3 0.012 -0.0103 0.00880001;
+               normal3 0 1 0;
+               vertex3 0.012 -0.0073 0.00880001;
+               normal3 0 0 1;
+               vertex3 0.012 -0.0073 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.016 -0.00779999 0.0128;
+               vertex3 0.016 -0.0078 0.0108;
+               vertex3 0.016 -0.0108 0.0108;
+               vertex3 0.016 -0.0108 0.0128;
+               normal3 0.948683 0 0.316228;
+               vertex3 0.022 -0.0108 0.0148;
+               vertex3 0.022 -0.00779999 0.0148;
+               vertex3 0.023 -0.00779999 0.0118;
+               normal3 1 0 0;
+               vertex3 0.023 -0.0078 0.0108;
+               vertex3 0.023 -0.0108 0.0108;
+               normal3 0.948683 0 0.316228;
+               vertex3 0.023 -0.0108 0.0118;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.0195 -0.00779999 0.0158;
+               vertex3 0.0195 -0.0108 0.0158;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0365 -0.0108 0.0153;
+               normal3 -1.82063e-07 1 1.47927e-07;
+               vertex3 0.0365 -0.00779999 0.0153;
+               normal3 1 0 0;
+               vertex3 0.0445 -0.0108 0.0128;
+               vertex3 0.0445 -0.0108 0.0108;
+               vertex3 0.0445 -0.0078 0.0108;
+               vertex3 0.0445 -0.00779999 0.0128;
+               normal3 -0.928476 0 -0.371392;
+               vertex3 0.035 -0.0108 0.0133;
+               vertex3 0.036 -0.0108 0.0108;
+               vertex3 0.036 -0.0078 0.0108;
+               vertex3 0.035 -0.00779999 0.0133;
+               normal3 0 -1 0;
+               vertex3 0.023 -0.0108 0.0258;
+               normal3 -7.76099e-08 -1 -3.8805e-07;
+               vertex3 0.0205 -0.0108 0.0193;
+               normal3 0 -1 0;
+               vertex3 0.0195 -0.0108 0.0203;
+               vertex3 0.0195 -0.0108 0.0258;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.0265 -0.0108 0.0233;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.023 -0.0108 0.0193;
+               normal3 1.44133e-07 1 7.20665e-07;
+               vertex3 0.023 -0.0078 0.0193;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.0265 -0.0078 0.0233;
+               normal3 0 0 1;
+               vertex3 0.0195 -0.0078 0.0258;
+               normal3 -0.707105 0 -0.707108;
+               vertex3 0.0195 -0.0078 0.0203;
+               vertex3 0.0205 -0.0078 0.0193;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.023 -0.0078 0.0258;
+               normal3 9.80338e-08 -1 -7.96528e-08;
+               vertex3 0.02475 -0.0108 0.0213;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.02475 -0.0078 0.0213;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.02475 0.0078 0.0213;
+               normal3 9.80338e-08 1 -7.96528e-08;
+               vertex3 0.02475 0.0108 0.0213;
+               normal3 0 -1 0;
+               vertex3 0.023 0.0078 0.0258;
+               normal3 7.20664e-08 -1 3.60332e-07;
+               vertex3 0.0205 0.0078 0.0193;
+               normal3 0 -1 0;
+               vertex3 0.0195 0.0078 0.0203;
+               vertex3 0.0195 0.0078 0.0258;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0265 0.0078 0.0233;
+               normal3 1.44133e-07 -1 7.20665e-07;
+               vertex3 0.023 0.0078 0.0193;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.023 0.0108 0.0193;
+               normal3 1.96068e-07 1 -1.59306e-07;
+               vertex3 0.0265 0.0108 0.0233;
+               normal3 0 0 1;
+               vertex3 0.0195 0.0108 0.0258;
+               normal3 -0.707105 0 -0.707108;
+               vertex3 0.0195 0.0108 0.0203;
+               normal3 -7.76099e-08 1 -3.8805e-07;
+               vertex3 0.0205 0.0108 0.0193;
+               normal3 0 1 0;
+               vertex3 0.023 0.0108 0.0258;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.035 0.00779999 0.0133;
+               normal3 -9.25541e-08 -1 -3.33195e-06;
+               vertex3 0.036 0.0078 0.0108;
+               normal3 9.25541e-08 1 3.33195e-06;
+               vertex3 0.036 0.0108 0.0108;
+               normal3 1.61563e-07 1 1.00445e-06;
+               vertex3 0.035 0.0108 0.0133;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0445 0.00779999 0.0128;
+               normal3 -9.25541e-08 -1 -3.33195e-06;
+               vertex3 0.0445 0.0078 0.0108;
+               normal3 9.25541e-08 1 3.33195e-06;
+               vertex3 0.0445 0.0108 0.0108;
+               normal3 4.62771e-08 1 1.66597e-06;
+               vertex3 0.0445 0.0108 0.0128;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0365 0.00779999 0.0153;
+               normal3 1.96068e-07 1 -1.59306e-07;
+               vertex3 0.0365 0.0108 0.0153;
+               normal3 -1.5522e-07 1 -7.76101e-07;
+               vertex3 0.0195 0.0108 0.0158;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0195 0.00779999 0.0158;
+               normal3 1.09568e-07 1 4.49229e-06;
+               vertex3 0.023 0.0108 0.0118;
+               normal3 0 1 7.45063e-06;
+               vertex3 0.023 0.0108 0.0108;
+               normal3 0 -1 -7.45063e-06;
+               vertex3 0.023 0.0078 0.0108;
+               normal3 -1.09568e-07 -1 -4.49229e-06;
+               vertex3 0.023 0.00779999 0.0118;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.022 0.00779999 0.0148;
+               normal3 -3.04349e-08 1 -6.08524e-09;
+               vertex3 0.022 0.0108 0.0148;
+               normal3 1.09568e-07 1 7.66973e-07;
+               vertex3 0.016 0.0108 0.0128;
+               normal3 1.09568e-07 1 4.49229e-06;
+               vertex3 0.016 0.0108 0.0108;
+               normal3 -1.09568e-07 -1 -4.49229e-06;
+               vertex3 0.016 0.0078 0.0108;
+               normal3 -1.09568e-07 -1 -7.66973e-07;
+               vertex3 0.016 0.00779999 0.0128;
+               normal3 -1 0 0;
+               vertex3 0.012 0.0073 0.0108;
+               vertex3 0.012 0.0073 0.00880001;
+               vertex3 0.012 0.0103 0.00880001;
+               vertex3 0.012 0.0108 0.0108;
+               vertex3 0.012 0.0108 0.0103;
+               vertex3 0.012 0.0098 0.0103;
+               vertex3 0.012 0.0098 0.00920001;
+               vertex3 0.012 0.0103 0.0092;
+               normal3 0 1 9.31342e-06;
+               vertex3 0.045 0.0103 0.0092;
+               normal3 0 1 8.46657e-07;
+               vertex3 0.045 0.0098 0.00920001;
+               normal3 0 0 -1;
+               vertex3 0.045 0.0098 0.0103;
+               normal3 0 1 0;
+               vertex3 0.045 0.0108 0.0103;
+               normal3 0 0 1;
+               vertex3 0.045 0.0108 0.0108;
+               normal3 0 0 -1;
+               vertex3 0.045 0.0103 0.00880001;
+               vertex3 0.045 0.0073 0.00880001;
+               normal3 0 -1 0;
+               vertex3 0.045 0.0073 0.0108;
+               normal3 0 1 0;
+               texcoord2 0.9 0.5;
+               vertex3 0.0195 0.015 0.0258;
+               vertex3 0.0195 0.015 0.0203;
+               vertex3 0.0165 0.015 0.0203;
+               vertex3 0.0165 0.015 0.0258;
+               normal3 0 -1 0;
+               vertex3 0.0195 -0.015 0.0258;
+               vertex3 0.0195 -0.015 0.0203;
+               vertex3 0.0165 -0.015 0.0203;
+               vertex3 0.0165 -0.015 0.0258;
+               normal3 1 -4.65661e-08 -2.53997e-07;
+               vertex3 0.0195 0.005 0.0203;
+               normal3 1 -4.65661e-08 -4.23328e-07;
+               texcoord2 0.7 0.5;
+               vertex3 0.0195 -0.005 0.0203;
+               vertex3 0.0195 -0.005 0.0258;
+               normal3 1 -4.65661e-08 -2.53997e-07;
+               texcoord2 0.9 0.5;
+               vertex3 0.0195 0.005 0.0258;
+               normal3 -4.65661e-07 4.65661e-08 -1;
+               vertex3 0.0165 0.005 0.0203;
+               normal3 -7.76102e-07 4.65662e-08 -1;
+               texcoord2 0.7 0.5;
+               vertex3 0.0165 -0.005 0.0203;
+               normal3 -1 -9.31323e-08 3.38663e-07;
+               vertex3 0.0165 -0.005 0.0258;
+               normal3 -1 -4.65661e-08 8.46657e-08;
+               texcoord2 0.9 0.5;
+               vertex3 0.0165 0.005 0.0258;
+               normal3 1 0 0;
+               texcoord2 0.5 0.5;
+               vertex3 0.0385 0.0078 0.0138;
+               vertex3 0.0385 0.0078 0.0108;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0365 0.0078 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.0365 0.0078 0.0138;
+               normal3 1 0 0;
+               vertex3 0.0385 -0.0078 0.0138;
+               vertex3 0.0385 -0.0078 0.0108;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0365 -0.0078 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.0365 -0.0078 0.0138;
+               normal3 0 0 1;
+               vertex3 0.0195 -0.0078 0.0138;
+               normal3 -1 0 0;
+               vertex3 0.0195 -0.0078 0.0108;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0215 -0.0078 0.0108;
+               normal3 0 0 1;
+               vertex3 0.0215 -0.0078 0.0138;
+               vertex3 0.0195 0.0078 0.0138;
+               normal3 -1 0 0;
+               vertex3 0.0195 0.0078 0.0108;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0215 0.0078 0.0108;
+               normal3 0 0 1;
+               vertex3 0.0215 0.0078 0.0138;
+               normal3 -0.447214 0.632455 0.632456;
+               vertex3 0.0165 -0.00858578 0.0247142;
+               normal3 -0.447214 0.86395 0.231495;
+               vertex3 0.0165 -0.00806815 0.0238176;
+               normal3 -0.447214 0.86395 -0.231495;
+               vertex3 0.0165 -0.00806815 0.0227824;
+               normal3 -0.447214 0.632456 -0.632455;
+               vertex3 0.0165 -0.00858578 0.0218858;
+               normal3 -0.447214 0.231495 -0.86395;
+               vertex3 0.0165 -0.00948236 0.0213681;
+               normal3 -0.447214 -0.231495 -0.86395;
+               vertex3 0.0165 -0.0105176 0.0213681;
+               normal3 -0.447214 -0.632456 -0.632455;
+               vertex3 0.0165 -0.0114142 0.0218858;
+               normal3 -0.447214 -0.86395 -0.231495;
+               vertex3 0.0165 -0.0119318 0.0227824;
+               normal3 -0.447214 -0.863951 0.231494;
+               vertex3 0.0165 -0.0119318 0.0238176;
+               normal3 -0.447214 -0.632456 0.632455;
+               vertex3 0.0165 -0.0114142 0.0247142;
+               normal3 -0.447214 -0.231495 0.86395;
+               vertex3 0.0165 -0.0105176 0.0252319;
+               normal3 -0.447214 0.231494 0.86395;
+               vertex3 0.0165 -0.00948236 0.0252319;
+               normal3 -0.447214 0.632455 0.632456;
+               vertex3 0.0155 -0.00893934 0.0243607;
+               normal3 -0.447214 0.86395 0.231495;
+               vertex3 0.0155 -0.00855111 0.0236882;
+               normal3 -0.447214 0.86395 -0.231495;
+               vertex3 0.0155 -0.00855111 0.0229118;
+               normal3 -0.447214 0.632456 -0.632455;
+               vertex3 0.0155 -0.00893934 0.0222393;
+               normal3 -0.447214 0.231495 -0.86395;
+               vertex3 0.0155 -0.00961177 0.0218511;
+               normal3 -0.447214 -0.231495 -0.86395;
+               vertex3 0.0155 -0.0103882 0.0218511;
+               normal3 -0.447214 -0.632456 -0.632455;
+               vertex3 0.0155 -0.0110607 0.0222393;
+               normal3 -0.447214 -0.86395 -0.231495;
+               vertex3 0.0155 -0.0114489 0.0229118;
+               normal3 -0.447214 -0.863951 0.231494;
+               vertex3 0.0155 -0.0114489 0.0236882;
+               normal3 -0.447214 -0.632456 0.632455;
+               vertex3 0.0155 -0.0110607 0.0243607;
+               normal3 -0.447214 -0.231495 0.86395;
+               vertex3 0.0155 -0.0103882 0.0247489;
+               normal3 -0.447214 0.231494 0.86395;
+               vertex3 0.0155 -0.00961177 0.0247489;
+               normal3 -1 0 0;
+               vertex3 0.0155 -0.00908077 0.0242192;
+               vertex3 0.0155 -0.0087443 0.0236365;
+               vertex3 0.0155 -0.0087443 0.0229635;
+               vertex3 0.0155 -0.00908077 0.0223808;
+               vertex3 0.0155 -0.00966354 0.0220443;
+               vertex3 0.0155 -0.0103365 0.0220443;
+               vertex3 0.0155 -0.0109192 0.0223808;
+               vertex3 0.0155 -0.0112557 0.0229635;
+               vertex3 0.0155 -0.0112557 0.0236365;
+               vertex3 0.0155 -0.0109192 0.0242192;
+               vertex3 0.0155 -0.0103365 0.0245557;
+               vertex3 0.0155 -0.00966354 0.0245557;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.0115 -0.0087443 0.0236365;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.0115 -0.00908077 0.0242192;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.0115 -0.0087443 0.0229635;
+               normal3 0 0.707108 -0.707106;
+               vertex3 0.0115 -0.00908077 0.0223808;
+               normal3 0 0.258821 -0.965925;
+               vertex3 0.0115 -0.00966354 0.0220443;
+               normal3 0 -0.25882 -0.965926;
+               vertex3 0.0115 -0.0103365 0.0220443;
+               normal3 0 -0.707108 -0.707106;
+               vertex3 0.0115 -0.0109192 0.0223808;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.0115 -0.0112557 0.0229635;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.0115 -0.0112557 0.0236365;
+               normal3 0 -0.707108 0.707106;
+               vertex3 0.0115 -0.0109192 0.0242192;
+               normal3 0 -0.258821 0.965925;
+               vertex3 0.0115 -0.0103365 0.0245557;
+               normal3 0 0.25882 0.965926;
+               vertex3 0.0115 -0.00966354 0.0245557;
+               normal3 -1 0 0;
+               vertex3 0.0115 -0.00926461 0.0240354;
+               vertex3 0.0115 -0.00899544 0.0235692;
+               vertex3 0.0115 -0.00899544 0.0230308;
+               vertex3 0.0115 -0.00926461 0.0225646;
+               vertex3 0.0115 -0.00973083 0.0222954;
+               vertex3 0.0115 -0.0102692 0.0222954;
+               vertex3 0.0115 -0.0107354 0.0225646;
+               vertex3 0.0115 -0.0110046 0.0230308;
+               vertex3 0.0115 -0.0110046 0.0235692;
+               vertex3 0.0115 -0.0107354 0.0240354;
+               vertex3 0.0115 -0.0102692 0.0243046;
+               vertex3 0.0115 -0.00973083 0.0243046;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.00950001 -0.00899544 0.0235692;
+               normal3 0 0.707106 0.707107;
+               vertex3 0.00950001 -0.00926461 0.0240354;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.00950001 -0.00899544 0.0230308;
+               normal3 0 0.707107 -0.707107;
+               vertex3 0.00950001 -0.00926461 0.0225646;
+               normal3 0 0.258819 -0.965926;
+               vertex3 0.00950001 -0.00973083 0.0222954;
+               normal3 0 -0.258819 -0.965926;
+               vertex3 0.00950001 -0.0102692 0.0222954;
+               normal3 0 -0.707107 -0.707107;
+               vertex3 0.00950001 -0.0107354 0.0225646;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.00950001 -0.0110046 0.0230308;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.00950001 -0.0110046 0.0235692;
+               normal3 0 -0.707107 0.707107;
+               vertex3 0.00950001 -0.0107354 0.0240354;
+               normal3 0 -0.258819 0.965926;
+               vertex3 0.00950001 -0.0102692 0.0243046;
+               normal3 0 0.258818 0.965926;
+               vertex3 0.00950001 -0.00973083 0.0243046;
+               normal3 1 0 0;
+               vertex3 0.00950001 -0.00824203 0.023771;
+               vertex3 0.00950001 -0.00871307 0.0245869;
+               vertex3 0.00950001 -0.00824203 0.022829;
+               vertex3 0.00950001 -0.00871307 0.0220131;
+               vertex3 0.00950001 -0.00952895 0.021542;
+               vertex3 0.00950001 -0.010471 0.021542;
+               vertex3 0.00950001 -0.0112869 0.0220131;
+               vertex3 0.00950001 -0.011758 0.022829;
+               vertex3 0.00950001 -0.011758 0.023771;
+               vertex3 0.00950001 -0.0112869 0.0245869;
+               vertex3 0.00950001 -0.010471 0.025058;
+               vertex3 0.00950001 -0.00952895 0.025058;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.00900001 -0.00871307 0.0245869;
+               normal3 -4.82087e-07 0.965926 0.258819;
+               vertex3 0.00900001 -0.00824203 0.023771;
+               normal3 4.82089e-07 -0.707108 -0.707106;
+               vertex3 0.00900001 -0.0112869 0.0220131;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.00900001 -0.011758 0.022829;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.00900001 -0.011758 0.023771;
+               normal3 0 -0.707107 0.707106;
+               vertex3 0.00900001 -0.0112869 0.0245869;
+               normal3 0 -0.25882 0.965926;
+               vertex3 0.00900001 -0.010471 0.025058;
+               normal3 0 0.258819 0.965926;
+               vertex3 0.00900001 -0.00952895 0.025058;
+               normal3 -1 0 0;
+               vertex3 0.00900001 -0.01 0.0233;
+               normal3 4.8209e-07 -0.25882 -0.965926;
+               vertex3 0.00900001 -0.010471 0.021542;
+               normal3 1.11869e-07 0.258819 -0.965926;
+               vertex3 0.00900001 -0.00952895 0.021542;
+               normal3 7.23132e-07 0.707107 -0.707107;
+               vertex3 0.00900001 -0.00871307 0.0220131;
+               normal3 1.29177e-07 0.965926 -0.258819;
+               vertex3 0.00900001 -0.00824203 0.022829;
+               normal3 -1 0 0;
+               vertex3 0.00900001 0.011758 0.022829;
+               vertex3 0.00900001 0.0112869 0.0220131;
+               vertex3 0.00900001 0.010471 0.021542;
+               vertex3 0.00900001 0.00952895 0.021542;
+               vertex3 0.00900001 0.01 0.0233;
+               vertex3 0.00900001 0.010471 0.025058;
+               vertex3 0.00900001 0.00952895 0.025058;
+               vertex3 0.00900001 0.00871308 0.0245869;
+               vertex3 0.00900001 0.00824203 0.023771;
+               vertex3 0.00900001 0.00824203 0.022829;
+               vertex3 0.00900001 0.00871308 0.0220131;
+               vertex3 0.00900001 0.011758 0.023771;
+               vertex3 0.00900001 0.0112869 0.0245869;
+               normal3 0 0.258819 0.965926;
+               vertex3 0.00950001 0.010471 0.025058;
+               normal3 0 -0.25882 0.965926;
+               vertex3 0.00950001 0.00952895 0.025058;
+               normal3 0 -0.707107 0.707106;
+               vertex3 0.00950001 0.00871308 0.0245869;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.00950001 0.00824203 0.023771;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.00950001 0.00824203 0.022829;
+               normal3 4.82089e-07 -0.707108 -0.707106;
+               vertex3 0.00950001 0.00871308 0.0220131;
+               normal3 4.8209e-07 -0.25882 -0.965926;
+               vertex3 0.00950001 0.00952895 0.021542;
+               normal3 1.11869e-07 0.258819 -0.965926;
+               vertex3 0.00950001 0.010471 0.021542;
+               normal3 7.23132e-07 0.707107 -0.707107;
+               vertex3 0.00950001 0.0112869 0.0220131;
+               normal3 1.29177e-07 0.965926 -0.258819;
+               vertex3 0.00950001 0.011758 0.022829;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.00950001 0.0112869 0.0245869;
+               normal3 -4.82087e-07 0.965926 0.258819;
+               vertex3 0.00950001 0.011758 0.023771;
+               normal3 1 0 0;
+               vertex3 0.00950001 0.0102692 0.0243046;
+               vertex3 0.00950001 0.00973083 0.0243046;
+               vertex3 0.00950001 0.00926462 0.0240354;
+               vertex3 0.00950001 0.00899545 0.0235692;
+               vertex3 0.00950001 0.00899545 0.0230308;
+               vertex3 0.00950001 0.00926462 0.0225646;
+               vertex3 0.00950001 0.00973083 0.0222954;
+               vertex3 0.00950001 0.0102692 0.0222954;
+               vertex3 0.00950001 0.0107354 0.0225646;
+               vertex3 0.00950001 0.0110046 0.0230308;
+               vertex3 0.00950001 0.0107354 0.0240354;
+               vertex3 0.00950001 0.0110046 0.0235692;
+               normal3 0 0.258818 0.965926;
+               vertex3 0.0115 0.0102692 0.0243046;
+               normal3 0 -0.258819 0.965926;
+               vertex3 0.0115 0.00973083 0.0243046;
+               normal3 0 -0.707107 0.707107;
+               vertex3 0.0115 0.00926462 0.0240354;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.0115 0.00899545 0.0235692;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.0115 0.00899545 0.0230308;
+               normal3 0 -0.707107 -0.707107;
+               vertex3 0.0115 0.00926462 0.0225646;
+               normal3 0 -0.258819 -0.965926;
+               vertex3 0.0115 0.00973083 0.0222954;
+               normal3 0 0.258819 -0.965926;
+               vertex3 0.0115 0.0102692 0.0222954;
+               normal3 0 0.707107 -0.707107;
+               vertex3 0.0115 0.0107354 0.0225646;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.0115 0.0110046 0.0230308;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.0115 0.0110046 0.0235692;
+               normal3 0 0.707106 0.707107;
+               vertex3 0.0115 0.0107354 0.0240354;
+               normal3 -1 0 0;
+               vertex3 0.0115 0.0103365 0.0245557;
+               vertex3 0.0115 0.00966354 0.0245557;
+               vertex3 0.0115 0.00908077 0.0242192;
+               vertex3 0.0115 0.00874431 0.0236365;
+               vertex3 0.0115 0.00874431 0.0229635;
+               vertex3 0.0115 0.00908077 0.0223808;
+               vertex3 0.0115 0.00966354 0.0220443;
+               vertex3 0.0115 0.0103365 0.0220443;
+               vertex3 0.0115 0.0109192 0.0223808;
+               vertex3 0.0115 0.0112557 0.0229635;
+               vertex3 0.0115 0.0109192 0.0242192;
+               vertex3 0.0115 0.0112557 0.0236365;
+               normal3 0 0.25882 0.965926;
+               vertex3 0.0155 0.0103365 0.0245557;
+               normal3 0 -0.258821 0.965925;
+               vertex3 0.0155 0.00966354 0.0245557;
+               normal3 0 -0.707108 0.707106;
+               vertex3 0.0155 0.00908077 0.0242192;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.0155 0.00874431 0.0236365;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.0155 0.00874431 0.0229635;
+               normal3 0 -0.707108 -0.707106;
+               vertex3 0.0155 0.00908077 0.0223808;
+               normal3 0 -0.25882 -0.965926;
+               vertex3 0.0155 0.00966354 0.0220443;
+               normal3 0 0.258821 -0.965925;
+               vertex3 0.0155 0.0103365 0.0220443;
+               normal3 0 0.707108 -0.707106;
+               vertex3 0.0155 0.0109192 0.0223808;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.0155 0.0112557 0.0229635;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.0155 0.0112557 0.0236365;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.0155 0.0109192 0.0242192;
+               normal3 -1 0 0;
+               vertex3 0.0155 0.0103882 0.0247489;
+               vertex3 0.0155 0.00961177 0.0247489;
+               vertex3 0.0155 0.00893934 0.0243607;
+               vertex3 0.0155 0.00855111 0.0236882;
+               vertex3 0.0155 0.00855111 0.0229118;
+               vertex3 0.0155 0.00893934 0.0222393;
+               vertex3 0.0155 0.00961177 0.0218511;
+               vertex3 0.0155 0.0103882 0.0218511;
+               vertex3 0.0155 0.0110607 0.0222393;
+               vertex3 0.0155 0.0114489 0.0229118;
+               vertex3 0.0155 0.0114489 0.0236882;
+               vertex3 0.0155 0.0110607 0.0243607;
+               normal3 -0.447214 0.231494 0.86395;
+               vertex3 0.0165 0.0105176 0.0252319;
+               normal3 -0.447214 -0.231495 0.86395;
+               vertex3 0.0165 0.00948236 0.0252319;
+               normal3 -0.447214 -0.632456 0.632455;
+               vertex3 0.0165 0.00858579 0.0247142;
+               normal3 -0.447214 -0.863951 0.231494;
+               vertex3 0.0165 0.00806815 0.0238176;
+               normal3 -0.447214 -0.86395 -0.231495;
+               vertex3 0.0165 0.00806815 0.0227824;
+               normal3 -0.447214 -0.632456 -0.632455;
+               vertex3 0.0165 0.00858579 0.0218858;
+               normal3 -0.447214 -0.231495 -0.86395;
+               vertex3 0.0165 0.00948236 0.0213681;
+               normal3 -0.447214 0.231495 -0.86395;
+               vertex3 0.0165 0.0105176 0.0213681;
+               normal3 -0.447214 0.632456 -0.632455;
+               vertex3 0.0165 0.0114142 0.0218858;
+               normal3 -0.447214 0.86395 -0.231495;
+               vertex3 0.0165 0.0119319 0.0227824;
+               normal3 -0.447214 0.86395 0.231495;
+               vertex3 0.0165 0.0119319 0.0238176;
+               normal3 -0.447214 0.632455 0.632456;
+               vertex3 0.0165 0.0114142 0.0247142;
+               normal3 0.178751 -0.319872 0.930446;
+               texcoord2 0.1 0.5;
+               vertex3 0.074 -0.00859809 0.0132;
+               normal3 0.0517699 -0.410228 0.910513;
+               vertex3 0.0725 -0.00900001 0.0132;
+               normal3 0.322167 -0.179415 0.929526;
+               vertex3 0.0750981 -0.00750002 0.0132;
+               normal3 0.178753 0.319871 0.930446;
+               vertex3 0.074 0.00859808 0.0132;
+               normal3 0.051771 0.410227 0.910513;
+               vertex3 0.0725 0.009 0.0132;
+               normal3 0.322166 0.179416 0.929526;
+               vertex3 0.0750981 0.0075 0.0132;
+               normal3 0.416806 -0.0524188 0.907483;
+               vertex3 0.0755 -0.00600001 0.0132;
+               normal3 0.416805 0.0524203 0.907483;
+               vertex3 0.0755 0.006 0.0132;
+               normal3 -0.416804 0.0524221 0.907483;
+               vertex3 0.0595 0.00600001 0.0132;
+               normal3 -0.322165 0.179418 0.929526;
+               vertex3 0.0599019 0.00749999 0.0132;
+               normal3 -0.178753 0.319872 0.930446;
+               vertex3 0.061 0.00859806 0.0132;
+               normal3 -0.0517715 0.410227 0.910513;
+               vertex3 0.0625 0.00899998 0.0132;
+               normal3 -0.0785041 0.649879 0.755972;
+               vertex3 0.06 0.0116 0.0112;
+               normal3 -0.27017 0.484986 0.831743;
+               vertex3 0.0585 0.0111981 0.0112;
+               normal3 -0.495229 0.273148 0.824705;
+               vertex3 0.0574019 0.0101 0.0112;
+               normal3 -0.678337 0.0814003 0.730228;
+               vertex3 0.057 0.00860001 0.0112;
+               normal3 -0.678337 -0.0814 0.730228;
+               vertex3 0.057 -0.00860001 0.0112;
+               normal3 -0.495229 -0.273147 0.824705;
+               vertex3 0.0574019 -0.0101 0.0112;
+               normal3 -0.27017 -0.484985 0.831744;
+               vertex3 0.0585 -0.0111981 0.0112;
+               normal3 -0.0785041 -0.649879 0.755972;
+               vertex3 0.06 -0.0116 0.0112;
+               normal3 -0.0517715 -0.410227 0.910513;
+               vertex3 0.0625 -0.00899998 0.0132;
+               normal3 -0.178753 -0.319872 0.930446;
+               vertex3 0.061 -0.00859807 0.0132;
+               normal3 -0.322165 -0.179418 0.929526;
+               vertex3 0.0599019 -0.0075 0.0132;
+               normal3 -0.416804 -0.0524221 0.907483;
+               vertex3 0.0595 -0.00600001 0.0132;
+               normal3 -0.129419 -0.0447985 0.990578;
+               vertex3 0.0615 -0.00600001 0.0137;
+               normal3 -0.0559446 -0.16162 0.985266;
+               vertex3 0.0625 -0.00699998 0.0137;
+               normal3 -0.0559446 0.16162 0.985266;
+               vertex3 0.0625 0.00699998 0.0137;
+               normal3 -0.129419 0.0447985 0.990578;
+               vertex3 0.0615 0.00600001 0.0137;
+               normal3 0.129419 0.0447977 0.990578;
+               vertex3 0.0735 0.006 0.0137;
+               normal3 0.129418 -0.0447972 0.990578;
+               vertex3 0.0735 -0.00600001 0.0137;
+               normal3 0.0559444 0.16162 0.985266;
+               vertex3 0.0725 0.007 0.0137;
+               normal3 0.0559437 -0.16162 0.985266;
+               vertex3 0.0725 -0.00700001 0.0137;
+               normal3 -0.393406 0.530239 0.751052;
+               vertex3 0.055 0.014 0.008;
+               normal3 -0.393406 -0.530238 0.751052;
+               vertex3 0.055 -0.014 0.008;
+               normal3 -8.76539e-08 -0.8 0.6;
+               vertex3 -1.49012e-08 -0.014 0.008;
+               normal3 2.62962e-07 0.8 0.6;
+               vertex3 7.45058e-09 0.014 0.008;
+               normal3 0 0 1;
+               texcoord2 0.5 0.5;
+               vertex3 0.045 -0.0073 0.0108;
+               normal3 0 1 0;
+               vertex3 0.045 -0.0073 0.0108;
+               vertex3 0.045 -0.0073 0.00880001;
+               normal3 0 0 -1;
+               vertex3 0.045 -0.0073 0.00880001;
+               normal3 0 -1 9.31342e-06;
+               vertex3 0.045 -0.0103 0.00880001;
+               normal3 0 0 -1;
+               vertex3 0.045 -0.0103 0.00880001;
+               normal3 0 -1 0;
+               vertex3 0.045 -0.0108 0.0108;
+               normal3 0 0 1;
+               vertex3 0.045 -0.0108 0.0108;
+               normal3 0 0 -1;
+               vertex3 0.045 -0.0108 0.0103;
+               normal3 0 -1 0;
+               vertex3 0.045 -0.0108 0.0103;
+               normal3 0 -1 8.46657e-07;
+               vertex3 0.045 -0.0098 0.0103;
+               normal3 0 0 -1;
+               vertex3 0.045 -0.0098 0.0103;
+               normal3 0 -1.49013e-05 1;
+               vertex3 0.045 -0.0098 0.00920001;
+               normal3 0 -1 8.46657e-07;
+               vertex3 0.045 -0.0098 0.00920001;
+               normal3 0 -1.49013e-05 1;
+               vertex3 0.045 -0.0103 0.0092;
+               normal3 0 -1 9.31342e-06;
+               vertex3 0.045 -0.0103 0.0092;
+               vertex3 0.012 -0.0103 0.0092;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0103 0.0092;
+               normal3 0 -1 8.46657e-07;
+               vertex3 0.012 -0.0098 0.00920001;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0098 0.00920001;
+               normal3 0 0 -1;
+               vertex3 0.012 -0.0098 0.0103;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0098 0.0103;
+               normal3 0 -1 0;
+               vertex3 0.012 -0.0108 0.0103;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0108 0.0103;
+               normal3 0 0 1;
+               vertex3 0.012 -0.0108 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0108 0.0108;
+               normal3 0 0 -1;
+               vertex3 0.012 -0.0103 0.00880001;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0103 0.00880001;
+               normal3 0 0 -1;
+               vertex3 0.012 -0.0073 0.00880001;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0073 0.00880001;
+               normal3 0 1 0;
+               vertex3 0.012 -0.0073 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.012 -0.0073 0.0108;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.016 -0.00779999 0.0128;
+               normal3 -1.09568e-07 1 -7.66973e-07;
+               vertex3 0.016 -0.00779999 0.0128;
+               normal3 -1.09568e-07 1 -4.49229e-06;
+               vertex3 0.016 -0.0078 0.0108;
+               normal3 1.09568e-07 -1 4.49229e-06;
+               vertex3 0.016 -0.0108 0.0108;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.016 -0.0108 0.0128;
+               normal3 1.09568e-07 -1 7.66973e-07;
+               vertex3 0.016 -0.0108 0.0128;
+               normal3 -3.04349e-08 -1 -6.08524e-09;
+               vertex3 0.022 -0.0108 0.0148;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.022 -0.0108 0.0148;
+               normal3 2.30435e-08 1 -3.0872e-08;
+               vertex3 0.022 -0.00779999 0.0148;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.022 -0.00779999 0.0148;
+               normal3 1 0 0;
+               vertex3 0.023 -0.00779999 0.0118;
+               normal3 -1.09568e-07 1 -4.49229e-06;
+               vertex3 0.023 -0.00779999 0.0118;
+               normal3 0 1 -7.45063e-06;
+               vertex3 0.023 -0.0078 0.0108;
+               normal3 0 -1 7.45063e-06;
+               vertex3 0.023 -0.0108 0.0108;
+               normal3 1 0 0;
+               vertex3 0.023 -0.0108 0.0118;
+               normal3 1.09568e-07 -1 4.49229e-06;
+               vertex3 0.023 -0.0108 0.0118;
+               normal3 1.44133e-07 1 7.20665e-07;
+               vertex3 0.0195 -0.00779999 0.0158;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0195 -0.00779999 0.0158;
+               normal3 -1.5522e-07 -1 -7.76101e-07;
+               vertex3 0.0195 -0.0108 0.0158;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0195 -0.0108 0.0158;
+               normal3 1.96068e-07 -1 -1.59306e-07;
+               vertex3 0.0365 -0.0108 0.0153;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0365 -0.0108 0.0153;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0365 -0.00779999 0.0153;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0365 -0.00779999 0.0153;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0445 -0.0108 0.0128;
+               normal3 4.62771e-08 -1 1.66597e-06;
+               vertex3 0.0445 -0.0108 0.0128;
+               normal3 9.25541e-08 -1 3.33195e-06;
+               vertex3 0.0445 -0.0108 0.0108;
+               normal3 -9.25541e-08 1 -3.33195e-06;
+               vertex3 0.0445 -0.0078 0.0108;
+               normal3 -4.62771e-08 1 -1.66597e-06;
+               vertex3 0.0445 -0.00779999 0.0128;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0445 -0.00779999 0.0128;
+               normal3 1.61563e-07 -1 1.00445e-06;
+               vertex3 0.035 -0.0108 0.0133;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.035 -0.0108 0.0133;
+               normal3 9.25541e-08 -1 3.33195e-06;
+               vertex3 0.036 -0.0108 0.0108;
+               normal3 -9.25541e-08 1 -3.33195e-06;
+               vertex3 0.036 -0.0078 0.0108;
+               normal3 -1.52227e-07 1 -1.01203e-06;
+               vertex3 0.035 -0.00779999 0.0133;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.035 -0.00779999 0.0133;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.023 -0.0108 0.0258;
+               normal3 0 0 1;
+               vertex3 0.023 -0.0108 0.0258;
+               normal3 -0.707105 0 -0.707108;
+               vertex3 0.0205 -0.0108 0.0193;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0205 -0.0108 0.0193;
+               normal3 -0.707105 0 -0.707108;
+               vertex3 0.0195 -0.0108 0.0203;
+               normal3 0 0 1;
+               vertex3 0.0195 -0.0108 0.0258;
+               normal3 1.96068e-07 -1 -1.59306e-07;
+               vertex3 0.0265 -0.0108 0.0233;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0265 -0.0108 0.0233;
+               normal3 -1.5522e-07 -1 -7.76101e-07;
+               vertex3 0.023 -0.0108 0.0193;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.023 -0.0108 0.0193;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.023 -0.0078 0.0193;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.023 -0.0078 0.0193;
+               normal3 -1.82063e-07 1 1.47927e-07;
+               vertex3 0.0265 -0.0078 0.0233;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0265 -0.0078 0.0233;
+               normal3 0 1 0;
+               vertex3 0.0195 -0.0078 0.0258;
+               vertex3 0.0195 -0.0078 0.0203;
+               normal3 7.20664e-08 1 3.60332e-07;
+               vertex3 0.0205 -0.0078 0.0193;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0205 -0.0078 0.0193;
+               normal3 0 0 1;
+               vertex3 0.023 -0.0078 0.0258;
+               normal3 0 1 0;
+               vertex3 0.023 -0.0078 0.0258;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.02475 -0.0108 0.0213;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.02475 -0.0108 0.0213;
+               normal3 -9.10314e-08 1 7.39633e-08;
+               vertex3 0.02475 -0.0078 0.0213;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.02475 -0.0078 0.0213;
+               normal3 -9.10314e-08 -1 7.39633e-08;
+               vertex3 0.02475 0.0078 0.0213;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.02475 0.0078 0.0213;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.02475 0.0108 0.0213;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.02475 0.0108 0.0213;
+               normal3 0 0 1;
+               vertex3 0.023 0.0078 0.0258;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.023 0.0078 0.0258;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0205 0.0078 0.0193;
+               normal3 -0.707105 0 -0.707108;
+               vertex3 0.0205 0.0078 0.0193;
+               vertex3 0.0195 0.0078 0.0203;
+               normal3 0 0 1;
+               vertex3 0.0195 0.0078 0.0258;
+               normal3 -1.82063e-07 -1 1.47927e-07;
+               vertex3 0.0265 0.0078 0.0233;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.0265 0.0078 0.0233;
+               normal3 0.752575 0 -0.658506;
+               vertex3 0.023 0.0078 0.0193;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.023 0.0078 0.0193;
+               normal3 -1.5522e-07 1 -7.76101e-07;
+               vertex3 0.023 0.0108 0.0193;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.023 0.0108 0.0193;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0265 0.0108 0.0233;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.0265 0.0108 0.0233;
+               normal3 0 1 0;
+               vertex3 0.0195 0.0108 0.0258;
+               vertex3 0.0195 0.0108 0.0203;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0205 0.0108 0.0193;
+               normal3 -0.707105 0 -0.707108;
+               vertex3 0.0205 0.0108 0.0193;
+               normal3 0 0 1;
+               vertex3 0.023 0.0108 0.0258;
+               normal3 0.581238 0 0.813734;
+               vertex3 0.023 0.0108 0.0258;
+               normal3 -1.52227e-07 -1 -1.01203e-06;
+               vertex3 0.035 0.00779999 0.0133;
+               normal3 -0.928476 0 -0.371392;
+               vertex3 0.035 0.00779999 0.0133;
+               vertex3 0.036 0.0078 0.0108;
+               vertex3 0.036 0.0108 0.0108;
+               normal3 -0.615271 0 -0.788315;
+               vertex3 0.035 0.0108 0.0133;
+               normal3 -0.928476 0 -0.371392;
+               vertex3 0.035 0.0108 0.0133;
+               normal3 -4.62771e-08 -1 -1.66597e-06;
+               vertex3 0.0445 0.00779999 0.0128;
+               normal3 1 0 0;
+               vertex3 0.0445 0.00779999 0.0128;
+               vertex3 0.0445 0.0078 0.0108;
+               vertex3 0.0445 0.0108 0.0108;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0445 0.0108 0.0128;
+               normal3 1 0 0;
+               vertex3 0.0445 0.0108 0.0128;
+               normal3 -1.82063e-07 -1 1.47927e-07;
+               vertex3 0.0365 0.00779999 0.0153;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0365 0.00779999 0.0153;
+               normal3 0.624695 0 0.780869;
+               vertex3 0.0365 0.0108 0.0153;
+               normal3 0.298275 0 0.95448;
+               vertex3 0.0365 0.0108 0.0153;
+               normal3 -0.961525 0 0.274719;
+               vertex3 0.0195 0.0108 0.0158;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.0195 0.0108 0.0158;
+               normal3 1.44133e-07 -1 7.20665e-07;
+               vertex3 0.0195 0.00779999 0.0158;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.0195 0.00779999 0.0158;
+               normal3 1 0 0;
+               vertex3 0.023 0.0108 0.0118;
+               normal3 0.948683 0 0.316228;
+               vertex3 0.023 0.0108 0.0118;
+               normal3 1 0 0;
+               vertex3 0.023 0.0108 0.0108;
+               vertex3 0.023 0.0078 0.0108;
+               vertex3 0.023 0.00779999 0.0118;
+               normal3 0.948683 0 0.316228;
+               vertex3 0.023 0.00779999 0.0118;
+               normal3 2.30435e-08 -1 -3.0872e-08;
+               vertex3 0.022 0.00779999 0.0148;
+               normal3 0.948683 0 0.316228;
+               vertex3 0.022 0.00779999 0.0148;
+               normal3 0.976187 0 -0.21693;
+               vertex3 0.022 0.0108 0.0148;
+               normal3 0.948683 0 0.316228;
+               vertex3 0.022 0.0108 0.0148;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.016 0.0108 0.0128;
+               normal3 -1 0 0;
+               vertex3 0.016 0.0108 0.0128;
+               vertex3 0.016 0.0108 0.0108;
+               vertex3 0.016 0.0078 0.0108;
+               normal3 -0.650791 0 0.759257;
+               vertex3 0.016 0.00779999 0.0128;
+               normal3 -1 0 0;
+               vertex3 0.016 0.00779999 0.0128;
+               normal3 0 -1 0;
+               vertex3 0.012 0.0073 0.0108;
+               normal3 0 0 1;
+               vertex3 0.012 0.0073 0.0108;
+               normal3 0 0 -1;
+               vertex3 0.012 0.0073 0.00880001;
+               normal3 0 -1 0;
+               vertex3 0.012 0.0073 0.00880001;
+               normal3 0 0 -1;
+               vertex3 0.012 0.0103 0.00880001;
+               normal3 0 1 9.31342e-06;
+               vertex3 0.012 0.0103 0.00880001;
+               normal3 0 0 1;
+               vertex3 0.012 0.0108 0.0108;
+               normal3 0 1 0;
+               vertex3 0.012 0.0108 0.0108;
+               vertex3 0.012 0.0108 0.0103;
+               normal3 0 0 -1;
+               vertex3 0.012 0.0108 0.0103;
+               vertex3 0.012 0.0098 0.0103;
+               normal3 0 1 8.46657e-07;
+               vertex3 0.012 0.0098 0.0103;
+               vertex3 0.012 0.0098 0.00920001;
+               normal3 0 1.49013e-05 1;
+               vertex3 0.012 0.0098 0.00920001;
+               normal3 0 1 9.31342e-06;
+               vertex3 0.012 0.0103 0.0092;
+               normal3 0 1.49013e-05 1;
+               vertex3 0.012 0.0103 0.0092;
+               vertex3 0.045 0.0103 0.0092;
+               normal3 1 0 0;
+               vertex3 0.045 0.0103 0.0092;
+               normal3 0 1.49013e-05 1;
+               vertex3 0.045 0.0098 0.00920001;
+               normal3 1 0 0;
+               vertex3 0.045 0.0098 0.00920001;
+               normal3 0 1 8.46657e-07;
+               vertex3 0.045 0.0098 0.0103;
+               normal3 1 0 0;
+               vertex3 0.045 0.0098 0.0103;
+               normal3 0 0 -1;
+               vertex3 0.045 0.0108 0.0103;
+               normal3 1 0 0;
+               vertex3 0.045 0.0108 0.0103;
+               normal3 0 1 0;
+               vertex3 0.045 0.0108 0.0108;
+               normal3 1 0 0;
+               vertex3 0.045 0.0108 0.0108;
+               normal3 0 1 9.31342e-06;
+               vertex3 0.045 0.0103 0.00880001;
+               normal3 1 0 0;
+               vertex3 0.045 0.0103 0.00880001;
+               normal3 0 -1 0;
+               vertex3 0.045 0.0073 0.00880001;
+               normal3 1 0 0;
+               vertex3 0.045 0.0073 0.00880001;
+               normal3 0 0 1;
+               vertex3 0.045 0.0073 0.0108;
+               normal3 1 0 0;
+               vertex3 0.045 0.0073 0.0108;
+               normal3 1 -9.31322e-08 -1.69331e-07;
+               texcoord2 0.9 0.5;
+               vertex3 0.0195 0.015 0.0258;
+               normal3 1.24176e-06 0 1;
+               vertex3 0.0195 0.015 0.0258;
+               normal3 1 -9.31322e-08 -1.69331e-07;
+               vertex3 0.0195 0.015 0.0203;
+               normal3 -3.10441e-07 9.31323e-08 -1;
+               vertex3 0.0195 0.015 0.0203;
+               vertex3 0.0165 0.015 0.0203;
+               normal3 -1 0 0;
+               vertex3 0.0165 0.015 0.0203;
+               vertex3 0.0165 0.015 0.0258;
+               normal3 1.24176e-06 0 1;
+               vertex3 0.0165 0.015 0.0258;
+               normal3 1 -9.31322e-08 -5.07994e-07;
+               vertex3 0.0195 -0.015 0.0258;
+               normal3 3.10441e-07 -9.31322e-08 1;
+               vertex3 0.0195 -0.015 0.0258;
+               normal3 1 -9.31322e-08 -5.07994e-07;
+               vertex3 0.0195 -0.015 0.0203;
+               normal3 -9.31323e-07 9.31323e-08 -1;
+               vertex3 0.0195 -0.015 0.0203;
+               vertex3 0.0165 -0.015 0.0203;
+               normal3 -1 -9.31323e-08 5.07994e-07;
+               vertex3 0.0165 -0.015 0.0203;
+               vertex3 0.0165 -0.015 0.0258;
+               normal3 3.10441e-07 -9.31322e-08 1;
+               vertex3 0.0165 -0.015 0.0258;
+               normal3 -4.65661e-07 4.65661e-08 -1;
+               vertex3 0.0195 0.005 0.0203;
+               normal3 -7.76102e-07 4.65662e-08 -1;
+               texcoord2 0.7 0.5;
+               vertex3 0.0195 -0.005 0.0203;
+               normal3 6.20882e-07 -9.31322e-08 1;
+               vertex3 0.0195 -0.005 0.0258;
+               normal3 1.08654e-06 -4.65661e-08 1;
+               texcoord2 0.9 0.5;
+               vertex3 0.0195 0.005 0.0258;
+               normal3 -1 -4.65661e-08 8.46657e-08;
+               vertex3 0.0165 0.005 0.0203;
+               normal3 -1 -9.31323e-08 3.38663e-07;
+               texcoord2 0.7 0.5;
+               vertex3 0.0165 -0.005 0.0203;
+               normal3 6.20882e-07 -9.31322e-08 1;
+               vertex3 0.0165 -0.005 0.0258;
+               normal3 1.08654e-06 -4.65661e-08 1;
+               texcoord2 0.9 0.5;
+               vertex3 0.0165 0.005 0.0258;
+               normal3 0 0 1;
+               texcoord2 0.5 0.5;
+               vertex3 0.0385 0.0078 0.0138;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0385 0.0078 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.0365 0.0078 0.0108;
+               normal3 0 0 1;
+               vertex3 0.0365 0.0078 0.0138;
+               vertex3 0.0385 -0.0078 0.0138;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0385 -0.0078 0.0108;
+               normal3 -1 0 0;
+               vertex3 0.0365 -0.0078 0.0108;
+               normal3 0 0 1;
+               vertex3 0.0365 -0.0078 0.0138;
+               normal3 -1 0 0;
+               vertex3 0.0195 -0.0078 0.0138;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0195 -0.0078 0.0108;
+               normal3 1 0 0;
+               vertex3 0.0215 -0.0078 0.0108;
+               vertex3 0.0215 -0.0078 0.0138;
+               normal3 -1 0 0;
+               vertex3 0.0195 0.0078 0.0138;
+               normal3 -1.86265e-06 2.38801e-07 -1;
+               vertex3 0.0195 0.0078 0.0108;
+               normal3 1 0 0;
+               vertex3 0.0215 0.0078 0.0108;
+               vertex3 0.0215 0.0078 0.0138;
+               normal3 -1 0 0;
+               vertex3 0.0155 -0.00893934 0.0243607;
+               vertex3 0.0155 -0.00855111 0.0236882;
+               vertex3 0.0155 -0.00855111 0.0229118;
+               vertex3 0.0155 -0.00893934 0.0222393;
+               vertex3 0.0155 -0.00961177 0.0218511;
+               vertex3 0.0155 -0.0103882 0.0218511;
+               vertex3 0.0155 -0.0110607 0.0222393;
+               vertex3 0.0155 -0.0114489 0.0229118;
+               vertex3 0.0155 -0.0114489 0.0236882;
+               vertex3 0.0155 -0.0110607 0.0243607;
+               vertex3 0.0155 -0.0103882 0.0247489;
+               vertex3 0.0155 -0.00961177 0.0247489;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.0155 -0.00908077 0.0242192;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.0155 -0.0087443 0.0236365;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.0155 -0.0087443 0.0229635;
+               normal3 0 0.707108 -0.707106;
+               vertex3 0.0155 -0.00908077 0.0223808;
+               normal3 0 0.258821 -0.965925;
+               vertex3 0.0155 -0.00966354 0.0220443;
+               normal3 0 -0.25882 -0.965926;
+               vertex3 0.0155 -0.0103365 0.0220443;
+               normal3 0 -0.707108 -0.707106;
+               vertex3 0.0155 -0.0109192 0.0223808;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.0155 -0.0112557 0.0229635;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.0155 -0.0112557 0.0236365;
+               normal3 0 -0.707108 0.707106;
+               vertex3 0.0155 -0.0109192 0.0242192;
+               normal3 0 -0.258821 0.965925;
+               vertex3 0.0155 -0.0103365 0.0245557;
+               normal3 0 0.25882 0.965926;
+               vertex3 0.0155 -0.00966354 0.0245557;
+               normal3 -1 0 0;
+               vertex3 0.0115 -0.0087443 0.0236365;
+               vertex3 0.0115 -0.00908077 0.0242192;
+               vertex3 0.0115 -0.0087443 0.0229635;
+               vertex3 0.0115 -0.00908077 0.0223808;
+               vertex3 0.0115 -0.00966354 0.0220443;
+               vertex3 0.0115 -0.0103365 0.0220443;
+               vertex3 0.0115 -0.0109192 0.0223808;
+               vertex3 0.0115 -0.0112557 0.0229635;
+               vertex3 0.0115 -0.0112557 0.0236365;
+               vertex3 0.0115 -0.0109192 0.0242192;
+               vertex3 0.0115 -0.0103365 0.0245557;
+               vertex3 0.0115 -0.00966354 0.0245557;
+               normal3 0 0.707106 0.707107;
+               vertex3 0.0115 -0.00926461 0.0240354;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.0115 -0.00899544 0.0235692;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.0115 -0.00899544 0.0230308;
+               normal3 0 0.707107 -0.707107;
+               vertex3 0.0115 -0.00926461 0.0225646;
+               normal3 0 0.258819 -0.965926;
+               vertex3 0.0115 -0.00973083 0.0222954;
+               normal3 0 -0.258819 -0.965926;
+               vertex3 0.0115 -0.0102692 0.0222954;
+               normal3 0 -0.707107 -0.707107;
+               vertex3 0.0115 -0.0107354 0.0225646;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.0115 -0.0110046 0.0230308;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.0115 -0.0110046 0.0235692;
+               normal3 0 -0.707107 0.707107;
+               vertex3 0.0115 -0.0107354 0.0240354;
+               normal3 0 -0.258819 0.965926;
+               vertex3 0.0115 -0.0102692 0.0243046;
+               normal3 0 0.258818 0.965926;
+               vertex3 0.0115 -0.00973083 0.0243046;
+               normal3 1 0 0;
+               vertex3 0.00950001 -0.00899544 0.0235692;
+               vertex3 0.00950001 -0.00926461 0.0240354;
+               vertex3 0.00950001 -0.00899544 0.0230308;
+               vertex3 0.00950001 -0.00926461 0.0225646;
+               vertex3 0.00950001 -0.00973083 0.0222954;
+               vertex3 0.00950001 -0.0102692 0.0222954;
+               vertex3 0.00950001 -0.0107354 0.0225646;
+               vertex3 0.00950001 -0.0110046 0.0230308;
+               vertex3 0.00950001 -0.0110046 0.0235692;
+               vertex3 0.00950001 -0.0107354 0.0240354;
+               vertex3 0.00950001 -0.0102692 0.0243046;
+               vertex3 0.00950001 -0.00973083 0.0243046;
+               normal3 -4.82087e-07 0.965926 0.258819;
+               vertex3 0.00950001 -0.00824203 0.023771;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.00950001 -0.00871307 0.0245869;
+               normal3 1.29177e-07 0.965926 -0.258819;
+               vertex3 0.00950001 -0.00824203 0.022829;
+               normal3 7.23132e-07 0.707107 -0.707107;
+               vertex3 0.00950001 -0.00871307 0.0220131;
+               normal3 1.11869e-07 0.258819 -0.965926;
+               vertex3 0.00950001 -0.00952895 0.021542;
+               normal3 4.8209e-07 -0.25882 -0.965926;
+               vertex3 0.00950001 -0.010471 0.021542;
+               normal3 4.82089e-07 -0.707108 -0.707106;
+               vertex3 0.00950001 -0.0112869 0.0220131;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.00950001 -0.011758 0.022829;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.00950001 -0.011758 0.023771;
+               normal3 0 -0.707107 0.707106;
+               vertex3 0.00950001 -0.0112869 0.0245869;
+               normal3 0 -0.25882 0.965926;
+               vertex3 0.00950001 -0.010471 0.025058;
+               normal3 0 0.258819 0.965926;
+               vertex3 0.00950001 -0.00952895 0.025058;
+               normal3 -1 0 0;
+               vertex3 0.00900001 -0.00871307 0.0245869;
+               vertex3 0.00900001 -0.00824203 0.023771;
+               vertex3 0.00900001 -0.0112869 0.0220131;
+               vertex3 0.00900001 -0.011758 0.022829;
+               vertex3 0.00900001 -0.011758 0.023771;
+               vertex3 0.00900001 -0.0112869 0.0245869;
+               vertex3 0.00900001 -0.010471 0.025058;
+               vertex3 0.00900001 -0.00952895 0.025058;
+               vertex3 0.00900001 -0.010471 0.021542;
+               vertex3 0.00900001 -0.00952895 0.021542;
+               vertex3 0.00900001 -0.00871307 0.0220131;
+               vertex3 0.00900001 -0.00824203 0.022829;
+               normal3 1.29177e-07 0.965926 -0.258819;
+               vertex3 0.00900001 0.011758 0.022829;
+               normal3 7.23132e-07 0.707107 -0.707107;
+               vertex3 0.00900001 0.0112869 0.0220131;
+               normal3 1.11869e-07 0.258819 -0.965926;
+               vertex3 0.00900001 0.010471 0.021542;
+               normal3 4.8209e-07 -0.25882 -0.965926;
+               vertex3 0.00900001 0.00952895 0.021542;
+               normal3 0 0.258819 0.965926;
+               vertex3 0.00900001 0.010471 0.025058;
+               normal3 0 -0.25882 0.965926;
+               vertex3 0.00900001 0.00952895 0.025058;
+               normal3 0 -0.707107 0.707106;
+               vertex3 0.00900001 0.00871308 0.0245869;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.00900001 0.00824203 0.023771;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.00900001 0.00824203 0.022829;
+               normal3 4.82089e-07 -0.707108 -0.707106;
+               vertex3 0.00900001 0.00871308 0.0220131;
+               normal3 -4.82087e-07 0.965926 0.258819;
+               vertex3 0.00900001 0.011758 0.023771;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.00900001 0.0112869 0.0245869;
+               normal3 1 0 0;
+               vertex3 0.00950001 0.010471 0.025058;
+               vertex3 0.00950001 0.00952895 0.025058;
+               vertex3 0.00950001 0.00871308 0.0245869;
+               vertex3 0.00950001 0.00824203 0.023771;
+               vertex3 0.00950001 0.00824203 0.022829;
+               vertex3 0.00950001 0.00871308 0.0220131;
+               vertex3 0.00950001 0.00952895 0.021542;
+               vertex3 0.00950001 0.010471 0.021542;
+               vertex3 0.00950001 0.0112869 0.0220131;
+               vertex3 0.00950001 0.011758 0.022829;
+               vertex3 0.00950001 0.0112869 0.0245869;
+               vertex3 0.00950001 0.011758 0.023771;
+               normal3 0 0.258818 0.965926;
+               vertex3 0.00950001 0.0102692 0.0243046;
+               normal3 0 -0.258819 0.965926;
+               vertex3 0.00950001 0.00973083 0.0243046;
+               normal3 0 -0.707107 0.707107;
+               vertex3 0.00950001 0.00926462 0.0240354;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.00950001 0.00899545 0.0235692;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.00950001 0.00899545 0.0230308;
+               normal3 0 -0.707107 -0.707107;
+               vertex3 0.00950001 0.00926462 0.0225646;
+               normal3 0 -0.258819 -0.965926;
+               vertex3 0.00950001 0.00973083 0.0222954;
+               normal3 0 0.258819 -0.965926;
+               vertex3 0.00950001 0.0102692 0.0222954;
+               normal3 0 0.707107 -0.707107;
+               vertex3 0.00950001 0.0107354 0.0225646;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.00950001 0.0110046 0.0230308;
+               normal3 0 0.707106 0.707107;
+               vertex3 0.00950001 0.0107354 0.0240354;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.00950001 0.0110046 0.0235692;
+               normal3 -1 0 0;
+               vertex3 0.0115 0.0102692 0.0243046;
+               vertex3 0.0115 0.00973083 0.0243046;
+               vertex3 0.0115 0.00926462 0.0240354;
+               vertex3 0.0115 0.00899545 0.0235692;
+               vertex3 0.0115 0.00899545 0.0230308;
+               vertex3 0.0115 0.00926462 0.0225646;
+               vertex3 0.0115 0.00973083 0.0222954;
+               vertex3 0.0115 0.0102692 0.0222954;
+               vertex3 0.0115 0.0107354 0.0225646;
+               vertex3 0.0115 0.0110046 0.0230308;
+               vertex3 0.0115 0.0110046 0.0235692;
+               vertex3 0.0115 0.0107354 0.0240354;
+               normal3 0 0.25882 0.965926;
+               vertex3 0.0115 0.0103365 0.0245557;
+               normal3 0 -0.258821 0.965925;
+               vertex3 0.0115 0.00966354 0.0245557;
+               normal3 0 -0.707108 0.707106;
+               vertex3 0.0115 0.00908077 0.0242192;
+               normal3 0 -0.965926 0.258819;
+               vertex3 0.0115 0.00874431 0.0236365;
+               normal3 0 -0.965926 -0.258819;
+               vertex3 0.0115 0.00874431 0.0229635;
+               normal3 0 -0.707108 -0.707106;
+               vertex3 0.0115 0.00908077 0.0223808;
+               normal3 0 -0.25882 -0.965926;
+               vertex3 0.0115 0.00966354 0.0220443;
+               normal3 0 0.258821 -0.965925;
+               vertex3 0.0115 0.0103365 0.0220443;
+               normal3 0 0.707108 -0.707106;
+               vertex3 0.0115 0.0109192 0.0223808;
+               normal3 0 0.965926 -0.258819;
+               vertex3 0.0115 0.0112557 0.0229635;
+               normal3 0 0.707107 0.707106;
+               vertex3 0.0115 0.0109192 0.0242192;
+               normal3 0 0.965926 0.258819;
+               vertex3 0.0115 0.0112557 0.0236365;
+               normal3 -1 0 0;
+               vertex3 0.0155 0.0103365 0.0245557;
+               vertex3 0.0155 0.00966354 0.0245557;
+               vertex3 0.0155 0.00908077 0.0242192;
+               vertex3 0.0155 0.00874431 0.0236365;
+               vertex3 0.0155 0.00874431 0.0229635;
+               vertex3 0.0155 0.00908077 0.0223808;
+               vertex3 0.0155 0.00966354 0.0220443;
+               vertex3 0.0155 0.0103365 0.0220443;
+               vertex3 0.0155 0.0109192 0.0223808;
+               vertex3 0.0155 0.0112557 0.0229635;
+               vertex3 0.0155 0.0112557 0.0236365;
+               vertex3 0.0155 0.0109192 0.0242192;
+               normal3 -0.447214 0.231494 0.86395;
+               vertex3 0.0155 0.0103882 0.0247489;
+               normal3 -0.447214 -0.231495 0.86395;
+               vertex3 0.0155 0.00961177 0.0247489;
+               normal3 -0.447214 -0.632456 0.632455;
+               vertex3 0.0155 0.00893934 0.0243607;
+               normal3 -0.447214 -0.863951 0.231494;
+               vertex3 0.0155 0.00855111 0.0236882;
+               normal3 -0.447214 -0.86395 -0.231495;
+               vertex3 0.0155 0.00855111 0.0229118;
+               normal3 -0.447214 -0.632456 -0.632455;
+               vertex3 0.0155 0.00893934 0.0222393;
+               normal3 -0.447214 -0.231495 -0.86395;
+               vertex3 0.0155 0.00961177 0.0218511;
+               normal3 -0.447214 0.231495 -0.86395;
+               vertex3 0.0155 0.0103882 0.0218511;
+               normal3 -0.447214 0.632456 -0.632455;
+               vertex3 0.0155 0.0110607 0.0222393;
+               normal3 -0.447214 0.86395 -0.231495;
+               vertex3 0.0155 0.0114489 0.0229118;
+               normal3 -0.447214 0.86395 0.231495;
+               vertex3 0.0155 0.0114489 0.0236882;
+               normal3 -0.447214 0.632455 0.632456;
+               vertex3 0.0155 0.0110607 0.0243607;
+               normal3 1 -4.65661e-08 -2.53997e-07;
+               texcoord2 0.7 0.5;
+               vertex3 0.0195 0.005 0.0203;
+               normal3 1 -4.65661e-08 -4.23328e-07;
+               texcoord2 0.9 0.5;
+               vertex3 0.0195 -0.005 0.0203;
+               vertex3 0.0195 -0.005 0.0258;
+               normal3 1 -4.65661e-08 -2.53997e-07;
+               texcoord2 0.7 0.5;
+               vertex3 0.0195 0.005 0.0258;
+               normal3 -4.65661e-07 4.65661e-08 -1;
+               vertex3 0.0165 0.005 0.0203;
+               normal3 -7.76102e-07 4.65662e-08 -1;
+               texcoord2 0.9 0.5;
+               vertex3 0.0165 -0.005 0.0203;
+               normal3 -1 -9.31323e-08 3.38663e-07;
+               vertex3 0.0165 -0.005 0.0258;
+               normal3 -1 -4.65661e-08 8.46657e-08;
+               texcoord2 0.7 0.5;
+               vertex3 0.0165 0.005 0.0258;
+               normal3 -4.65661e-07 4.65661e-08 -1;
+               vertex3 0.0195 0.005 0.0203;
+               normal3 -7.76102e-07 4.65662e-08 -1;
+               texcoord2 0.9 0.5;
+               vertex3 0.0195 -0.005 0.0203;
+               normal3 6.20882e-07 -9.31322e-08 1;
+               vertex3 0.0195 -0.005 0.0258;
+               normal3 1.08654e-06 -4.65661e-08 1;
+               texcoord2 0.7 0.5;
+               vertex3 0.0195 0.005 0.0258;
+               normal3 -1 -4.65661e-08 8.46657e-08;
+               vertex3 0.0165 0.005 0.0203;
+               normal3 -1 -9.31323e-08 3.38663e-07;
+               texcoord2 0.9 0.5;
+               vertex3 0.0165 -0.005 0.0203;
+               normal3 6.20882e-07 -9.31322e-08 1;
+               vertex3 0.0165 -0.005 0.0258;
+               normal3 1.08654e-06 -4.65661e-08 1;
+               texcoord2 0.7 0.5;
+               vertex3 0.0165 0.005 0.0258;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 5 445 4 442 76 422 414 421 440 436 438 437 439 434 441 435 411 430 73 429 6 443 7 444;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 424 442 425 443 426 427 433 432 434 431 435 430;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 422 442 423 424 420 419 436 437;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 424 425 419 418 437 433 434;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 422 423 421 420 436;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 427 443 428 429 431 430;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 64 4 75 76 413 414 440;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 65 64 77 75 415 413 438 440;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 71 65 78 77 417 415 438;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 438 439 417 416 78 79;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 441 411 410 73 72 6 66;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 439 441 412 410 74 72 67 66;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 439 412 416 74 79 67 70;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 71 78 69 79 68 70;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 8 22 9 23 10 24 11 25 12 26 13 27 20 34 21 35 14 29 15 28 16 30 17 31 18 32 19 33;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 63 49 62 48 61 47 60 46 59 45 58 44 51 37 50 36 57 42 56 43 55 41 54 40 53 39 52 38;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 83 84 80 85 81 86 82 87;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 469 471 467 477 465 475 463 473;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 490 480 489 479 486 494 124 530 536 533 526;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 536 526 512 109 506;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 491 493 481 484 483 496;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 496 484 119 522 130;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 121 120 118 119 130;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 118 130 520 508 498 503;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 152 148 153 149 155 133 141 145;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 557 556 144 145 133;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 133 552 144 163 156 164;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 164 163 165 158 159;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 147 151 562 568 574;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 562 574 538 548 134;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 137 136 134 135 538 139;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 139 135 588 580 167;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 588 167 161 166 160;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 175 170 174 169 173 168 172 171;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 625 615 627 617 629 619 623 621;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 228 216 229 217 230 218 231 219 232 220 233 221 234 222 235 223 236 224 237 225 238 226 239 227 228 216;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 240 670 241 671 242 672 243 673 244 674 245 675 246 676 247 677 248 678 249 679 250 680 251 681 240 670;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 253 682 252 683 254 684 255 685 256 686 257 687 258 688 259 689 260 690 261 691 262 692 263 693 253 682;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 264 695 265 694 266 696 267 697 268 698 269 699 270 700 271 701 272 702 273 703 274 704 275 705 264 695;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 277 706 276 707 278 708 279 709 280 710 281 711 282 712 283 713 284 714 285 715 286 716 287 717 277 706;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 289 719 288 718 290 720 291 721 292 722 293 723 294 724 295 725 296 726 297 727 298 728 299 729 289 719;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 300 731 301 730 312 732 311 733 310 734 309 735 302 736 303 737 304 738 305 739 306 740 307 741 300 731;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 742 743 308 753 752;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 742 308 749 748;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 752 751 308 750 744;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 748 308 747 746;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 746 308 745 744;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 324 313 317 314 315;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 324 317 325 318;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 315 316 317 323 322;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 318 317 319 320;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 320 317 321 322;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 758 326 765 336 764 337 754 335 755 334 756 333 757 332 763 331 762 330 761 329 760 328 759 327 758 326;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 766 338 776 348 777 349 775 347 774 346 773 345 772 344 771 343 770 342 769 341 768 340 767 339 766 338;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 778 350 788 361 789 360 787 359 786 358 785 357 784 356 783 355 782 354 781 353 780 352 779 351 778 350;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 790 362 801 372 800 373 799 371 798 370 797 369 796 368 795 367 794 366 793 365 792 364 791 363 790 362;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 802 374 812 385 813 384 811 383 810 382 809 381 808 380 807 379 806 378 805 377 804 376 803 375 802 374;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 814 386 825 397 824 396 823 395 822 394 821 393 820 392 819 391 818 390 817 389 816 388 815 387 814 386;
+       };
+       batch TRIANGLE_STRIP
+       {
+               indices 826 398 837 409 836 408 835 407 834 406 833 405 832 404 831 403 830 402 829 401 828 400 827 399 826 398;
+       };
+       batch TRIANGLES
+       {
+               indices 0 3 2;
+               indices 0 2 1;
+               indices 418 425 426;
+               indices 418 426 433;
+               indices 432 427 428;
+               indices 432 428 431;
+               indices 460 458 89;
+               indices 460 89 88;
+               indices 450 461 462;
+               indices 450 462 93;
+               indices 459 456 90;
+               indices 459 90 464;
+               indices 457 454 91;
+               indices 457 91 466;
+               indices 455 452 92;
+               indices 455 92 468;
+               indices 453 446 95;
+               indices 453 95 470;
+               indices 447 448 94;
+               indices 447 94 476;
+               indices 449 451 472;
+               indices 449 472 474;
+               indices 98 99 96;
+               indices 98 96 97;
+               indices 100 105 102;
+               indices 100 102 101;
+               indices 488 492 104;
+               indices 488 104 103;
+               indices 478 482 107;
+               indices 478 107 106;
+               indices 533 530 529;
+               indices 533 529 528;
+               indices 505 511 512;
+               indices 505 512 506;
+               indices 504 503 508;
+               indices 504 508 510;
+               indices 113 110 111;
+               indices 113 111 112;
+               indices 115 114 117;
+               indices 115 117 116;
+               indices 108 502 507;
+               indices 108 507 500;
+               indices 514 122 125;
+               indices 514 125 129;
+               indices 519 515 532;
+               indices 519 532 126;
+               indices 516 518 127;
+               indices 516 127 128;
+               indices 495 497 517;
+               indices 495 517 531;
+               indices 485 487 524;
+               indices 485 524 123;
+               indices 534 523 525;
+               indices 534 525 131;
+               indices 499 501 527;
+               indices 499 527 521;
+               indices 509 535 537;
+               indices 509 537 513;
+               indices 566 146 132;
+               indices 566 132 540;
+               indices 576 554 138;
+               indices 576 138 154;
+               indices 541 539 550;
+               indices 541 550 140;
+               indices 590 553 551;
+               indices 590 551 162;
+               indices 157 544 558;
+               indices 157 558 578;
+               indices 559 545 546;
+               indices 559 546 143;
+               indices 142 547 542;
+               indices 142 542 560;
+               indices 561 543 549;
+               indices 561 549 555;
+               indices 577 575 150;
+               indices 577 150 572;
+               indices 565 564 563;
+               indices 565 563 567;
+               indices 569 570 571;
+               indices 569 571 573;
+               indices 596 581 579;
+               indices 596 579 592;
+               indices 586 585 584;
+               indices 586 584 582;
+               indices 591 589 587;
+               indices 591 587 583;
+               indices 594 595 597;
+               indices 594 597 593;
+               indices 182 600 602;
+               indices 182 602 181;
+               indices 183 598 601;
+               indices 183 601 626;
+               indices 180 604 599;
+               indices 180 599 628;
+               indices 179 606 605;
+               indices 179 605 622;
+               indices 178 608 607;
+               indices 178 607 620;
+               indices 177 610 609;
+               indices 177 609 618;
+               indices 624 603 612;
+               indices 624 612 176;
+               indices 614 613 611;
+               indices 614 611 616;
+               indices 186 187 184;
+               indices 186 184 185;
+               indices 188 191 190;
+               indices 188 190 189;
+               indices 630 195 192;
+               indices 630 192 632;
+               indices 841 194 193;
+               indices 841 193 838;
+               indices 840 638 640;
+               indices 840 640 839;
+               indices 633 646 196;
+               indices 633 196 634;
+               indices 846 647 197;
+               indices 846 197 842;
+               indices 847 641 642;
+               indices 847 642 843;
+               indices 635 650 199;
+               indices 635 199 636;
+               indices 850 651 198;
+               indices 850 198 845;
+               indices 851 643 644;
+               indices 851 644 844;
+               indices 637 653 649;
+               indices 637 649 631;
+               indices 853 652 648;
+               indices 853 648 849;
+               indices 852 645 639;
+               indices 852 639 848;
+               indices 200 204 205;
+               indices 200 205 201;
+               indices 655 659 206;
+               indices 655 206 202;
+               indices 656 660 207;
+               indices 656 207 203;
+               indices 657 661 658;
+               indices 657 658 654;
+               indices 212 208 211;
+               indices 212 211 215;
+               indices 213 209 662;
+               indices 213 662 666;
+               indices 214 210 663;
+               indices 214 663 667;
+               indices 669 665 664;
+               indices 669 664 668;
+       };
+};
+technique
+{
+       pass ""
+       {
+               material
+               {
+                       diffuse 1 1 1 1;
+               };
+               texunit 0
+               {
+                       texture2d
+                       {
+                               min_filter NEAREST;
+                               mag_filter NEAREST;
+                               storage RGB 5 1;
+                               raw_data "\x3F\x3F\x3F\xB2\xB2\xB2\x33\x33\x33\xB2\x00\x00\xFF\xFF\xFF";
+                       };
+               };
+       };
+};
index 1fd35dda3fcc40523dce1f6d022d3825a684d85b..a1004ecfdcec46a2905713bdecf96a323e0efadf 100644 (file)
@@ -12,7 +12,7 @@ pass ""
                        storage RGB 2 1;
                        min_filter NEAREST;
                        mag_filter NEAREST;
-                       raw_data "\x40\x40\x40\xD0\xD0\xD0";
+                       raw_data "\x3F\x3F\x3F\xB2\xB2\xB2";
                };
        };
 };
index c69e2fb7380046a0b3f85f71a83e76cefecb2694..f8876471bb72ace58c3676142dfb6267a5206436 100644 (file)
Binary files a/gfx.blend and b/gfx.blend differ
index 1196b32ce18b7eb161f87e4c64487fcf45207378..755f0080807771f7e1bd4ddf76d34a86c0affaf5 100644 (file)
@@ -73,7 +73,8 @@ namespace R2C2 {
 
 TrackType3D::TrackType3D(Catalogue3D &cat3d, const TrackType &tt):
        catalogue(cat3d),
-       mesh((GL::NORMAL3, GL::TEXCOORD2, GL::VERTEX3))
+       mesh(0),
+       object(0)
 {
        const Catalogue &cat = cat3d.get_catalogue();
        const vector<TrackPart> &parts = tt.get_parts();
@@ -90,24 +91,34 @@ TrackType3D::TrackType3D(Catalogue3D &cat3d, const TrackType &tt):
 
        float gauge = cat.get_gauge();
 
+       string obj_name = tt.get_object();
+       if(!obj_name.empty())
        {
+               object = catalogue.get<GL::Object>(obj_name);
+               // XXX border
+       }
+       else
+       {
+               mesh = new GL::Mesh((GL::NORMAL3, GL::TEXCOORD2, GL::VERTEX3));
+               mesh->set_winding(&GL::WindingTest::counterclockwise());
+               GL::MeshBuilder bld(*mesh);
+
                unsigned index = 0;
-               GL::MeshBuilder bld(mesh);
                bld.texcoord(0.25, 0.5);
                for(vector<TrackPart>::const_iterator i=parts.begin(); i!=parts.end(); ++i)
-                       build_part(*i, ballast_profile, Point(0, -ballast_min.y), bld, index);
+                       build_part(*i, ballast_profile, Point(0, -ballast_min.y), false, bld, index);
 
                bld.texcoord(0.75, 0.5);
                float y = ballast_h-rail_min.y;
                for(vector<TrackPart>::const_iterator i=parts.begin(); i!=parts.end(); ++i)
-                       build_part(*i, rail_profile, Point(-gauge/2-rail_max.x, y), bld, index);
+                       build_part(*i, rail_profile, Point(-gauge/2, y), true, bld, index);
                for(vector<TrackPart>::const_iterator i=parts.begin(); i!=parts.end(); ++i)
-                       build_part(*i, rail_profile, Point(gauge/2-rail_min.x, y), bld, index);
-       }
+                       build_part(*i, rail_profile, Point(gauge/2, y), false, bld, index);
 
-       mesh.set_winding(&GL::WindingTest::counterclockwise());
-       object.set_mesh(&mesh);
-       object.set_technique(catalogue.get<GL::Technique>(cat.get_track_technique()));
+               object = new GL::Object;
+               object->set_mesh(mesh);
+               object->set_technique(catalogue.get<GL::Technique>(cat.get_track_technique()));
+       }
  
        unsigned paths = tt.get_paths();
        for(unsigned i=0; paths; ++i, paths>>=1)
@@ -120,7 +131,7 @@ TrackType3D::TrackType3D(Catalogue3D &cat3d, const TrackType &tt):
                        unsigned index = 0;
                        for(vector<TrackPart>::const_iterator j=parts.begin(); j!=parts.end(); ++j)
                                if(j->get_path()==i)
-                                       build_part(*j, cat.get_path_profile(), Point(0, ballast_h+1.5*rail_h), bld, index);
+                                       build_part(*j, cat.get_path_profile(), Point(0, ballast_h+1.5*rail_h), false, bld, index);
                }
                path_meshes.push_back(m);
        }
@@ -168,54 +179,56 @@ const GL::Mesh &TrackType3D::get_path_mesh(unsigned p) const
        return *path_meshes[p];
 }
 
-void TrackType3D::build_part(const TrackPart &part, const Profile &profile, const Point &offset, GL::MeshBuilder &bld, unsigned &base_index)
+void TrackType3D::build_part(const TrackPart &part, const Profile &profile, const Point &offset, bool mirror, GL::MeshBuilder &bld, unsigned &base_index)
 {
        float plen = part.get_length();
        unsigned nsegs = (part.is_curved() ? static_cast<unsigned>(plen*32)+1 : 1);
 
-       unsigned n_points = profile.get_n_points();
+       unsigned n_vertices = profile.get_n_vertices();
        for(unsigned i=0; i<=nsegs; ++i)
        {
                TrackPoint basep = part.get_point(i*plen/nsegs);
                float c = cos(basep.dir);
                float s = sin(basep.dir);
 
-               Point p;
-               for(unsigned j=0; j<n_points; ++j)
+               for(unsigned j=0; j<n_vertices; ++j)
                {
-                       // TODO: smoothing - only duplicate vertex if the angle is large enough
-
-                       p = profile.get_point(j);
+                       const Profile::Vertex &v = profile.get_vertex(mirror ? n_vertices-1-j : j);
+                       Point p = v.pos;
+                       if(mirror)
+                               p.x = -p.x;
                        p.z = basep.pos.z+p.y+offset.y;
                        p.y = basep.pos.y-c*(p.x+offset.x);
                        p.x = basep.pos.x+s*(p.x+offset.x);
-                       if(j>0)
-                               bld.vertex(p.x, p.y, p.z);
 
-                       if(j+1<n_points)
-                       {
-                               Point n = profile.get_edge_normal(j);
-                               bld.normal(s*n.x, -c*n.x, n.y);
-                               bld.vertex(p.x, p.y, p.z);
-                       }
+                       Point n = v.normal;
+                       if(mirror)
+                               n.x = -n.x;
+
+                       bld.normal(s*n.x, -c*n.x, n.y);
+                       bld.vertex(p.x, p.y, p.z);
 
                        border.push_back(p);
                }
        }
 
-       for(unsigned i=0; i+1<n_points; ++i)
+       for(unsigned i=0; i+1<n_vertices; )
        {
                bld.begin(GL::TRIANGLE_STRIP);
                for(unsigned j=0; j<=nsegs; ++j)
                {
-                       unsigned k = (j*(n_points-1)+i)*2;
+                       unsigned k = j*n_vertices+i;
                        bld.element(base_index+k+1);
                        bld.element(base_index+k);
                }
                bld.end();
+
+               ++i;
+               if(!profile.get_vertex(i).smooth)
+                       ++i;
        }
 
-       base_index += (nsegs+1)*(n_points-1)*2;
+       base_index += (nsegs+1)*n_vertices;
 }
 
 } // namespace R2C2
index 3c06c58d8234047d7b198f2d0f9a68cfb1744f4a..8a5123b27ba16b6d8566e95221f486733a19295b 100644 (file)
@@ -22,8 +22,8 @@ class TrackType3D
 {
 private:
        Catalogue3D &catalogue;
-       Msp::GL::Mesh mesh;
-       Msp::GL::Object object;
+       Msp::GL::Mesh *mesh;
+       Msp::GL::Object *object;
        std::vector<Msp::GL::Mesh *> path_meshes;
        std::vector<Point> border;
        float min_z;
@@ -34,11 +34,11 @@ public:
        ~TrackType3D();
 
        void get_bounds(float, Point &, Point &) const;
-       const Msp::GL::Object &get_object() const { return object; }
+       const Msp::GL::Object &get_object() const { return *object; }
        const Msp::GL::Mesh &get_path_mesh(unsigned) const;
 
 private:
-       void build_part(const TrackPart &, const Profile &, const Point &, Msp::GL::MeshBuilder &, unsigned &);
+       void build_part(const TrackPart &, const Profile &, const Point &, bool, Msp::GL::MeshBuilder &, unsigned &);
 };
 
 } // namespace R2C2
index d2ee1447639fd459296168fb8c48bfe649f19a9a..51cad9a031a134ddc4107e7413f2d0b5da4b7a02 100644 (file)
@@ -96,8 +96,8 @@ void Catalogue::Loader::gauge(float g)
 {
        obj.gauge = g/1000;
        obj.path_profile = Profile();
-       obj.path_profile.append_point(Point(0.1*obj.gauge, 0));
-       obj.path_profile.append_point(Point(-0.1*obj.gauge, 0));
+       obj.path_profile.append_vertex(Point(0.1*obj.gauge, 0), false);
+       obj.path_profile.append_vertex(Point(-0.1*obj.gauge, 0), false);
 }
 
 void Catalogue::Loader::layout()
index b44ee3606c6018ccf9918e9d4b32cfe263c12488..257b898f39d14fa390e8d58b3b918faf24cc520f 100644 (file)
@@ -13,10 +13,39 @@ using namespace Msp;
 
 namespace R2C2 {
 
-void Profile::append_point(const Point &p)
+void Profile::append_vertex(const Point &p, bool smooth)
 {
-       points.push_back(p);
-       if(points.size()==1)
+       if(vertices.size()>1 && !vertices.back().smooth)
+               vertices.push_back(vertices.back());
+
+       Vertex v;
+       v.pos = p;
+       v.smooth = (!vertices.empty() && smooth);
+
+       if(!vertices.empty())
+       {
+               float dx = p.x-vertices.back().pos.x;
+               float dy = p.y-vertices.back().pos.y;
+               float len = sqrt(dx*dx+dy*dy);
+               v.normal.x = dy/len;
+               v.normal.y = -dx/len;
+
+               if(vertices.back().smooth)
+               {
+                       Point &n = vertices.back().normal;
+                       n.x += v.normal.x;
+                       n.y += v.normal.y;
+                       len = sqrt(n.x*n.x+n.y*n.y);
+                       n.x /= len;
+                       n.y /= len;
+               }
+               else
+                       vertices.back().normal = v.normal;
+       }
+
+       vertices.push_back(v);
+
+       if(vertices.size()==1)
        {
                min_coords = p;
                max_coords = p;
@@ -30,21 +59,11 @@ void Profile::append_point(const Point &p)
        }
 }
 
-const Point &Profile::get_point(unsigned i) const
+const Profile::Vertex &Profile::get_vertex(unsigned i) const
 {
-       if(i>=points.size())
+       if(i>=vertices.size())
                throw InvalidParameterValue("Index out of range");
-       return points[i];
-}
-
-Point Profile::get_edge_normal(unsigned i) const
-{
-       if(i+1>=points.size())
-               throw InvalidParameterValue("Index out of range");
-       float dx = points[i+1].x-points[i].x;
-       float dy = points[i+1].y-points[i].y;
-       float len = sqrt(dx*dx+dy*dy);
-       return Point(dy/len, -dx/len);
+       return vertices[i];
 }
 
 
@@ -52,11 +71,17 @@ Profile::Loader::Loader(Profile &p):
        DataFile::ObjectLoader<Profile>(p)
 {
        add("point", &Loader::point);
+       add("smooth_point", &Loader::smooth_point);
 }
 
 void Profile::Loader::point(float x, float y)
 {
-       obj.append_point(Point(x/1000, y/1000));
+       obj.append_vertex(Point(x/1000, y/1000), false);
+}
+
+void Profile::Loader::smooth_point(float x, float y)
+{
+       obj.append_vertex(Point(x/1000, y/1000), true);
 }
 
 } // namespace R2C2
index 00132e9d9d8455d73923b54719af21c948fe180f..7a19fbe39998adc45ed6171fdc41e394cf0e8793 100644 (file)
@@ -23,22 +23,29 @@ public:
                Loader(Profile &);
        private:
                void point(float, float);
+               void smooth_point(float, float);
+       };
+
+       struct Vertex
+       {
+               Point pos;
+               Point normal;
+               bool smooth;
        };
 
 private:
-       std::vector<Point> points;
+       std::vector<Vertex> vertices;
        Point min_coords;
        Point max_coords;
 
 public:
-       void append_point(const Point &);
-       unsigned get_n_points() const { return points.size(); }
-       const Point &get_point(unsigned) const;
+       void append_vertex(const Point &, bool);
+       unsigned get_n_vertices() const { return vertices.size(); }
+       const Vertex &get_vertex(unsigned) const;
        const Point &get_min_coords() const { return min_coords; }
        const Point &get_max_coords() const { return max_coords; }
        float get_width() const { return max_coords.x-min_coords.x; }
        float get_height() const { return max_coords.y-min_coords.y; }
-       Point get_edge_normal(unsigned) const;
 };
 
 } // namespace R2C2
index 1679dc3f93f8a736efa4f54718cb7a6040bb9db3..35d220821500e1621dbb19bc732587398154507b 100644 (file)
@@ -176,6 +176,7 @@ TrackType::Loader::Loader(TrackType &t):
 {
        add("autofit_preference", &TrackType::autofit_preference);
        add("description", &TrackType::description);
+       add("object",      &TrackType::object);
        add("state_bits",  &Loader::state_bits);
        add("part",        &Loader::part);
 }
index fb40ac9473708623c3560ac586f4b79a8557902b..9c4865f1ff3f655bd8578a98ae200ab46bc866d4 100644 (file)
@@ -48,6 +48,7 @@ private:
        std::vector<Endpoint> endpoints;
        unsigned state_bits;
        unsigned autofit_preference;
+       std::string object;
 
 public:
        TrackType(const ArticleNumber &);
@@ -62,6 +63,7 @@ public:
        bool is_turnout() const;
        bool is_dead_end() const;
        unsigned get_autofit_preference() const { return autofit_preference; }
+       const std::string &get_object() const { return object; }
        const std::vector<TrackPart> &get_parts() const { return parts; }
        const std::vector<Endpoint> &get_endpoints() const { return endpoints; }
        const Endpoint &get_endpoint(unsigned) const;
index 33e4ca8dbf87546c8c3dffac7905cc2af3327de8..ac4c63908ea62b0bb2ab7a3b0ef25fea32e207ee 100644 (file)
@@ -4,9 +4,19 @@ scale 1 87;
 gauge 16.5;
 rail_profile
 {
-       point 0.5 0.0;
-       point 0.5 2.3;
-       point -0.5 2.3;
+       point 1.5 0.0;
+       smooth_point 1.5 0.3;
+       smooth_point 0.8 0.4;
+       smooth_point 0.8 1.4;
+       smooth_point 1.0 1.6;
+       smooth_point 1.0 2.1;
+       smooth_point 0.8 2.3;
+       smooth_point 0.2 2.3;
+       smooth_point 0.0 2.1;
+       smooth_point 0.0 1.6;
+       smooth_point 0.2 1.4;
+       smooth_point 0.2 0.4;
+       smooth_point -0.5 0.3;
        point -0.5 0.0;
 };
 ballast_profile
@@ -447,6 +457,7 @@ track 24740
 track 24977
 {
        description "Bumper";
+       object "bumper.object";
        part
        {
                length 77.5;