diff --git a/Fltk/contextWindow.cpp b/Fltk/contextWindow.cpp index b5cc58f266f6cc628508e94227ad452d93660fb6..80ab3b40bf98e1a5c1c6ef1e870b8b1c8f4c881e 100644 --- a/Fltk/contextWindow.cpp +++ b/Fltk/contextWindow.cpp @@ -1049,11 +1049,11 @@ transformContextWindow::transformContextWindow(int deltaFontSize) { group[0] = new Fl_Group (WB, WB + BH, width - 2 * WB, height - 3 * WB - 2 * BH, "Translate"); - input[0] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "X component"); + input[0] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "DX"); input[0]->value("0"); - input[1] = new Fl_Input(2 * WB, 2 * WB + 2 * BH, IW, BH, "Y component"); + input[1] = new Fl_Input(2 * WB, 2 * WB + 2 * BH, IW, BH, "DY"); input[1]->value("0"); - input[2] = new Fl_Input(2 * WB, 2 * WB + 3 * BH, IW, BH, "Z component"); + input[2] = new Fl_Input(2 * WB, 2 * WB + 3 * BH, IW, BH, "DZ"); input[2]->value("1"); for(int i = 0; i < 3; i++) { input[i]->align(FL_ALIGN_RIGHT); @@ -1065,28 +1065,20 @@ transformContextWindow::transformContextWindow(int deltaFontSize) } // 1: Rotate { - group[1] = new Fl_Group - (WB, WB + BH, width - 2 * WB, height - 2 * WB - BH, "Rotate"); - input[3] = new Fl_Input - (2 * WB, 2 * WB + 1 * BH, IW, BH, "X coordinate of an axis point"); + group[1] = new Fl_Group(WB, WB + BH, width - 2 * WB, height - 2 * WB - BH, "Rotate"); + input[3] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "Axis point X"); input[3]->value("0"); - input[4] = new Fl_Input - (2 * WB, 2 * WB + 2 * BH, IW, BH, "Y coordinate of an axis point"); + input[4] = new Fl_Input(2 * WB, 2 * WB + 2 * BH, IW, BH, "Axis point Y"); input[4]->value("0"); - input[5] = new Fl_Input - (2 * WB, 2 * WB + 3 * BH, IW, BH, "Z coordinate of an axis point"); + input[5] = new Fl_Input(2 * WB, 2 * WB + 3 * BH, IW, BH, "Axis point Z"); input[5]->value("0"); - input[6] = new Fl_Input - (2 * WB, 2 * WB + 4 * BH, IW, BH, "X component of axis direction"); + input[6] = new Fl_Input(2 * WB, 2 * WB + 4 * BH, IW, BH, "Axis DX"); input[6]->value("0"); - input[7] = new Fl_Input - (2 * WB, 2 * WB + 5 * BH, IW, BH, "Y component of axis direction"); + input[7] = new Fl_Input(2 * WB, 2 * WB + 5 * BH, IW, BH, "Axis DY"); input[7]->value("1"); - input[8] = new Fl_Input - (2 * WB, 2 * WB + 6 * BH, IW, BH, "Z component of axis direction"); + input[8] = new Fl_Input(2 * WB, 2 * WB + 6 * BH, IW, BH, "Axis DZ"); input[8]->value("0"); - input[9] = new Fl_Input - (2 * WB, 2 * WB + 7 * BH, IW, BH, "Angle in radians"); + input[9] = new Fl_Input(2 * WB, 2 * WB + 7 * BH, IW, BH, "Angle"); input[9]->value("Pi/4"); for(int i = 3; i < 10; i++) { input[i]->align(FL_ALIGN_RIGHT); @@ -1098,24 +1090,23 @@ transformContextWindow::transformContextWindow(int deltaFontSize) } // 2: Scale { - group[2] = new Fl_Group - (WB, WB + BH, width - 2 * WB, height - 2 * WB - BH, "Scale"); - input[10] = new Fl_Input - (2 * WB, 2 * WB + 1 * BH, IW, BH, "X component of direction"); + group[2] = new Fl_Group(WB, WB + BH, width - 2 * WB, height - 2 * WB - BH, "Scale"); + input[10] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "Center X"); input[10]->value("0"); - input[11] = new Fl_Input - (2 * WB, 2 * WB + 2 * BH, IW, BH, "Y component of direction"); + input[11] = new Fl_Input(2 * WB, 2 * WB + 2 * BH, IW, BH, "Center Y"); input[11]->value("0"); - input[12] = new Fl_Input - (2 * WB, 2 * WB + 3 * BH, IW, BH, "Z component of direction"); + input[12] = new Fl_Input(2 * WB, 2 * WB + 3 * BH, IW, BH, "Center Z"); input[12]->value("0"); - input[13] = new Fl_Input - (2 * WB, 2 * WB + 4 * BH, IW, BH, "Factor"); + input[13] = new Fl_Input(2 * WB, 2 * WB + 4 * BH, IW, BH, "Scale X"); input[13]->value("0.5"); - for(int i = 10; i < 14; i++) { + input[14] = new Fl_Input(2 * WB, 2 * WB + 5 * BH, IW, BH, "Scale Y"); + input[14]->value("0.5"); + input[15] = new Fl_Input(2 * WB, 2 * WB + 6 * BH, IW, BH, "Scale Z"); + input[15]->value("0.5"); + for(int i = 10; i < 16; i++) { input[i]->align(FL_ALIGN_RIGHT); } - butt[2] = new Fl_Check_Button(2 * WB, 2 * WB + 5 * BH, width - 4 * WB, BH, + butt[2] = new Fl_Check_Button(2 * WB, 2 * WB + 7 * BH, width - 4 * WB, BH, "Apply operation on copy"); butt[2]->value(0); group[2]->end(); @@ -1124,15 +1115,15 @@ transformContextWindow::transformContextWindow(int deltaFontSize) { group[3] = new Fl_Group (WB, WB + BH, width - 2 * WB, height - 2 * WB - BH, "Symmetry"); - input[14] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "A"); - input[14]->value("1"); - input[15] = new Fl_Input(2 * WB, 2 * WB + 2 * BH, IW, BH, "B"); - input[15]->value("0"); - input[16] = new Fl_Input(2 * WB, 2 * WB + 3 * BH, IW, BH, "C"); - input[16]->value("0"); - input[17] = new Fl_Input(2 * WB, 2 * WB + 4 * BH, IW, BH, "D"); - input[17]->value("1"); - for(int i = 14; i < 18; i++) { + input[16] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "Plane A"); + input[16]->value("1"); + input[17] = new Fl_Input(2 * WB, 2 * WB + 2 * BH, IW, BH, "Plane B"); + input[17]->value("0"); + input[18] = new Fl_Input(2 * WB, 2 * WB + 3 * BH, IW, BH, "Plane C"); + input[18]->value("0"); + input[19] = new Fl_Input(2 * WB, 2 * WB + 4 * BH, IW, BH, "Plane D"); + input[19]->value("1"); + for(int i = 16; i < 20; i++) { input[i]->align(FL_ALIGN_RIGHT); } butt[3] = new Fl_Check_Button(2 * WB, 2 * WB + 5 * BH, width - 4 * WB, BH, @@ -1156,9 +1147,9 @@ transformContextWindow::transformContextWindow(int deltaFontSize) { group[5] = new Fl_Group (WB, WB + BH, width - 2 * WB, height - 2 * WB - BH, "Fillet"); - input[18] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "Radius"); - input[18]->value("0.1"); - input[18]->align(FL_ALIGN_RIGHT); + input[20] = new Fl_Input(2 * WB, 2 * WB + 1 * BH, IW, BH, "Radius"); + input[20]->value("0.1"); + input[20]->align(FL_ALIGN_RIGHT); group[5]->end(); } // 6: Delete diff --git a/Fltk/graphicWindow.cpp b/Fltk/graphicWindow.cpp index 97c6f22b900651164e13bfe5287cb0ff2f523340..b24b97f647346e3b57327dad513e8d6bbe3d0ea5 100644 --- a/Fltk/graphicWindow.cpp +++ b/Fltk/graphicWindow.cpp @@ -1416,14 +1416,16 @@ static void action_point_line_surface_volume(int action, const std::string &what FlGui::instance()->transformContext->input[11]->value(), FlGui::instance()->transformContext->input[12]->value(), FlGui::instance()->transformContext->input[13]->value(), + FlGui::instance()->transformContext->input[14]->value(), + FlGui::instance()->transformContext->input[15]->value(), FlGui::instance()->transformContext->butt[2]->value()); break; case 3: symmetry(GModel::current()->getFileName(), dimTags, - FlGui::instance()->transformContext->input[14]->value(), - FlGui::instance()->transformContext->input[15]->value(), FlGui::instance()->transformContext->input[16]->value(), FlGui::instance()->transformContext->input[17]->value(), + FlGui::instance()->transformContext->input[18]->value(), + FlGui::instance()->transformContext->input[19]->value(), FlGui::instance()->transformContext->butt[3]->value()); break; case 4: @@ -1754,7 +1756,7 @@ static void geometry_elementary_fillet_cb(Fl_Widget *w, void *data) } else{ apply_fillet(GModel::current()->getFileName(), regions, edges, - FlGui::instance()->transformContext->input[18]->value()); + FlGui::instance()->transformContext->input[20]->value()); GModel::current()->setSelection(0); selectRegions = true; regions.clear(); diff --git a/Geo/GModelIO_OCC.cpp b/Geo/GModelIO_OCC.cpp index 134a2e4d86e30f65cd423349dbb183131ff5578b..15e6d80b826f7f9e468bf763f79b5904523cbebc 100644 --- a/Geo/GModelIO_OCC.cpp +++ b/Geo/GModelIO_OCC.cpp @@ -2124,10 +2124,25 @@ bool OCC_Internals::dilate(const std::vector<std::pair<int, int> > &inDimTags, double x, double y, double z, double a, double b, double c) { - gp_GTrsf t; - t.SetTranslationPart(gp_XYZ(x,y,z)); - t.SetVectorialPart(gp_Mat(a, 0, 0, 0, b, 0, 0, 0, c)); - BRepBuilderAPI_GTransform gtfo(t); + gp_GTrsf gt; + gt.SetVectorialPart(gp_Mat(a, 0, 0, 0, b, 0, 0, 0, c)); + gt.SetTranslationPart(gp_XYZ(x * (1 - a), y * (1 - b), z * (1 - c))); + BRepBuilderAPI_GTransform gtfo(gt); + return _transform(inDimTags, 0, >fo); +} + +bool OCC_Internals::symmetry(const std::vector<std::pair<int, int> > &inDimTags, + double a, double b, double c, double d) +{ + gp_GTrsf gt; + double p = (a * a + b * b + c * c); + if(!p) p = 1e-12; + double f = -2.0 / p; + gt.SetVectorialPart(gp_Mat(1 + a * a * f, a * b * f, a * c * f, + a * b * f, 1. + b * b * f, b * c * f, + a * c * f, b * c * f, 1. + c * c * f)); + gt.SetTranslationPart(gp_XYZ(a * d * f, b * d * f, c * d * f)); + BRepBuilderAPI_GTransform gtfo(gt); return _transform(inDimTags, 0, >fo); } diff --git a/Geo/GModelIO_OCC.h b/Geo/GModelIO_OCC.h index ed81c70e93ea76eea5bde502c603dba27956fd11..6ed598b00116b87a6b378e3dba5ba7fa2642fd61 100644 --- a/Geo/GModelIO_OCC.h +++ b/Geo/GModelIO_OCC.h @@ -110,8 +110,7 @@ class OCC_Internals { // apply a geometrical transformation bool _transform(const std::vector<std::pair<int, int> > &inDimTags, - BRepBuilderAPI_Transform *tfo, - BRepBuilderAPI_GTransform *gtfo); + BRepBuilderAPI_Transform *tfo, BRepBuilderAPI_GTransform *gtfo); // add circle or ellipse arc bool _addArc(int &tag, int startTag, int centerTag, int endTag, int mode); @@ -254,6 +253,8 @@ class OCC_Internals { bool dilate(const std::vector<std::pair<int, int> > &inDimTags, double x, double y, double z, double a, double b, double c); + bool symmetry(const std::vector<std::pair<int, int> > &inDimTags, + double a, double b, double c, double d); // copy and remove bool copy(const std::vector<std::pair<int, int> > &inDimTags, @@ -531,6 +532,11 @@ public: { return _error("apply dilatation"); } + bool symmetry(const std::vector<std::pair<int, int> > &inDimTags, + double a, double b, double c, double d) + { + return _error("apply symmetry"); + } bool copy(const std::vector<std::pair<int, int> > &inDimTags, std::vector<std::pair<int, int> > &outDimTags) { diff --git a/Geo/Geo.cpp b/Geo/Geo.cpp index 0b81607845924923df9639d771edb19ee1d0ca0a..79d1fcf002be4cd3779c867c10e33526abbf2c9d 100644 --- a/Geo/Geo.cpp +++ b/Geo/Geo.cpp @@ -1242,7 +1242,9 @@ static void SetTranslationMatrix(double matrix[4][4], double T[3]) static void SetSymmetryMatrix(double matrix[4][4], double A, double B, double C, double D) { - double F = -2.0 / (A * A + B * B + C * C); + double p = (A * A + B * B + C * C); + if(!p) p = 1e-12; + double F = -2.0 / p; matrix[0][0] = 1. + A * A * F; matrix[0][1] = A * B * F; matrix[0][2] = A * C * F; diff --git a/Geo/GeoStringInterface.cpp b/Geo/GeoStringInterface.cpp index 0f95a53ba8ffd16fb684ffd0518538bcadfae452..d74c00c54488a5aa5b4513148c8fdcfadcd9fd42 100644 --- a/Geo/GeoStringInterface.cpp +++ b/Geo/GeoStringInterface.cpp @@ -622,11 +622,13 @@ void rotate(const std::string &fileName, const std::vector<std::pair<int, int> > } void dilate(const std::string &fileName, const std::vector<std::pair<int, int> > &l, - const std::string &dx, const std::string &dy, const std::string &dz, - const std::string &df, bool duplicata) + const std::string &cx, const std::string &cy, const std::string &cz, + const std::string &sx, const std::string &sy, const std::string &sz, + bool duplicata) { std::ostringstream sstream; - sstream << "Dilate {{" << dx << ", " << dy << ", " << dz << "}, " << df << "} {\n "; + sstream << "Dilate {{" << cx << ", " << cy << ", " << cz << "}, {" + << sx << ", " << sy << ", " << sz << "}} {\n "; if(duplicata) sstream << "Duplicata { "; sstream << dimTags2String(l); if(duplicata) sstream << "}"; diff --git a/Geo/GeoStringInterface.h b/Geo/GeoStringInterface.h index 7df9473cf99d4855b4af82001b51c229b2ffa7d9..645b48fc107dac941d20772051c7abd8d6a7c194 100644 --- a/Geo/GeoStringInterface.h +++ b/Geo/GeoStringInterface.h @@ -85,8 +85,9 @@ void rotate(const std::string &fileName, const std::vector<std::pair<int, int> > const std::string &px, const std::string &py, const std::string &pz, const std::string &angle, bool duplicata); void dilate(const std::string &fileName, const std::vector<std::pair<int, int> > &l, - const std::string &dx, const std::string &dy, const std::string &dz, - const std::string &df, bool duplicata); + const std::string &cx, const std::string &cy, const std::string &cz, + const std::string &sx, const std::string &sy, const std::string &sz, + bool duplicata); void symmetry(const std::string &fileName, const std::vector<std::pair<int, int> > &l, const std::string &sa, const std::string &sb, const std::string &sc, const std::string &sd, bool duplicata); diff --git a/Parser/Gmsh.tab.cpp b/Parser/Gmsh.tab.cpp index 05ae28cf9382c732f30b0e641028e6c462013db1..aa273bf5bbd15b0d45e681d063ad4f90b75b5994 100644 --- a/Parser/Gmsh.tab.cpp +++ b/Parser/Gmsh.tab.cpp @@ -1448,47 +1448,47 @@ static const yytype_uint16 yyrline[] = 1797, 1807, 1823, 1842, 1858, 1879, 1890, 1896, 1902, 1909, 1940, 1955, 1977, 2000, 2023, 2046, 2070, 2094, 2118, 2144, 2154, 2177, 2194, 2210, 2228, 2246, 2256, 2268, 2280, 2292, - 2309, 2325, 2341, 2356, 2373, 2390, 2425, 2447, 2471, 2472, - 2477, 2480, 2484, 2495, 2506, 2517, 2533, 2552, 2573, 2588, - 2604, 2622, 2673, 2694, 2716, 2739, 2844, 2860, 2895, 2906, - 2917, 2923, 2938, 2966, 2978, 2987, 2994, 3006, 3025, 3031, - 3037, 3044, 3051, 3058, 3070, 3143, 3161, 3178, 3193, 3226, - 3238, 3262, 3266, 3271, 3278, 3283, 3293, 3298, 3304, 3312, - 3316, 3320, 3329, 3393, 3409, 3426, 3443, 3465, 3487, 3522, - 3530, 3538, 3544, 3551, 3558, 3578, 3604, 3616, 3628, 3646, - 3664, 3683, 3682, 3707, 3706, 3733, 3732, 3757, 3756, 3779, - 3795, 3812, 3829, 3852, 3855, 3861, 3873, 3893, 3897, 3901, - 3905, 3909, 3913, 3917, 3921, 3930, 3943, 3944, 3945, 3946, - 3947, 3951, 3952, 3953, 3954, 3955, 3958, 3981, 4000, 4022, - 4025, 4041, 4044, 4061, 4064, 4070, 4073, 4080, 4083, 4090, - 4107, 4148, 4192, 4231, 4256, 4265, 4295, 4321, 4347, 4379, - 4406, 4432, 4458, 4484, 4510, 4532, 4538, 4544, 4550, 4556, - 4562, 4588, 4614, 4631, 4648, 4665, 4677, 4683, 4689, 4701, - 4705, 4715, 4726, 4727, 4728, 4732, 4738, 4750, 4768, 4796, - 4797, 4798, 4799, 4800, 4801, 4802, 4803, 4804, 4811, 4812, - 4813, 4814, 4815, 4816, 4817, 4818, 4819, 4820, 4821, 4822, - 4823, 4824, 4825, 4826, 4827, 4828, 4829, 4830, 4831, 4832, - 4833, 4834, 4835, 4836, 4837, 4838, 4839, 4840, 4841, 4842, - 4843, 4844, 4845, 4846, 4847, 4848, 4857, 4858, 4859, 4860, - 4861, 4862, 4863, 4864, 4865, 4866, 4867, 4872, 4871, 4879, - 4881, 4886, 4891, 4895, 4900, 4905, 4909, 4913, 4917, 4921, - 4927, 4943, 4948, 4954, 4960, 4979, 5000, 5033, 5037, 5042, - 5046, 5050, 5054, 5059, 5064, 5074, 5084, 5089, 5100, 5109, - 5114, 5119, 5147, 5148, 5154, 5155, 5161, 5160, 5183, 5185, - 5190, 5199, 5201, 5207, 5208, 5214, 5218, 5222, 5226, 5230, - 5237, 5241, 5245, 5249, 5256, 5261, 5268, 5273, 5277, 5282, - 5286, 5294, 5305, 5309, 5321, 5329, 5337, 5344, 5354, 5377, - 5383, 5389, 5395, 5401, 5412, 5423, 5434, 5445, 5451, 5457, - 5463, 5469, 5479, 5489, 5499, 5512, 5516, 5522, 5534, 5538, - 5542, 5546, 5564, 5572, 5580, 5609, 5619, 5635, 5646, 5651, - 5655, 5659, 5671, 5675, 5687, 5704, 5714, 5718, 5733, 5738, - 5745, 5749, 5754, 5768, 5785, 5789, 5794, 5798, 5803, 5811, - 5817, 5823, 5829, 5838, 5842, 5846, 5854, 5860, 5866, 5870, - 5878, 5886, 5893, 5903, 5908, 5913, 5928, 5942, 5956, 5968, - 5984, 5993, 6002, 6012, 6023, 6031, 6039, 6043, 6062, 6069, - 6075, 6082, 6090, 6089, 6099, 6123, 6125, 6131, 6136, 6138, - 6143, 6148, 6153, 6155, 6159, 6171, 6186, 6191, 6200, 6209, - 6218, 6230, 6233, 6237 + 2309, 2325, 2341, 2357, 2373, 2389, 2424, 2446, 2470, 2471, + 2476, 2479, 2483, 2494, 2505, 2516, 2532, 2551, 2572, 2587, + 2603, 2621, 2672, 2693, 2715, 2738, 2843, 2859, 2894, 2905, + 2916, 2922, 2937, 2965, 2977, 2986, 2993, 3005, 3024, 3030, + 3036, 3043, 3050, 3057, 3069, 3142, 3160, 3177, 3192, 3225, + 3237, 3261, 3265, 3270, 3277, 3282, 3292, 3297, 3303, 3311, + 3315, 3319, 3328, 3392, 3408, 3425, 3442, 3464, 3486, 3521, + 3529, 3537, 3543, 3550, 3557, 3577, 3603, 3615, 3627, 3645, + 3663, 3682, 3681, 3706, 3705, 3732, 3731, 3756, 3755, 3778, + 3794, 3811, 3828, 3851, 3854, 3860, 3872, 3892, 3896, 3900, + 3904, 3908, 3912, 3916, 3920, 3929, 3942, 3943, 3944, 3945, + 3946, 3950, 3951, 3952, 3953, 3954, 3957, 3980, 3999, 4021, + 4024, 4040, 4043, 4060, 4063, 4069, 4072, 4079, 4082, 4089, + 4106, 4147, 4191, 4230, 4255, 4264, 4294, 4320, 4346, 4378, + 4405, 4431, 4457, 4483, 4509, 4531, 4537, 4543, 4549, 4555, + 4561, 4587, 4613, 4630, 4647, 4664, 4676, 4682, 4688, 4700, + 4704, 4714, 4725, 4726, 4727, 4731, 4737, 4749, 4767, 4795, + 4796, 4797, 4798, 4799, 4800, 4801, 4802, 4803, 4810, 4811, + 4812, 4813, 4814, 4815, 4816, 4817, 4818, 4819, 4820, 4821, + 4822, 4823, 4824, 4825, 4826, 4827, 4828, 4829, 4830, 4831, + 4832, 4833, 4834, 4835, 4836, 4837, 4838, 4839, 4840, 4841, + 4842, 4843, 4844, 4845, 4846, 4847, 4856, 4857, 4858, 4859, + 4860, 4861, 4862, 4863, 4864, 4865, 4866, 4871, 4870, 4878, + 4880, 4885, 4890, 4894, 4899, 4904, 4908, 4912, 4916, 4920, + 4926, 4942, 4947, 4953, 4959, 4978, 4999, 5032, 5036, 5041, + 5045, 5049, 5053, 5058, 5063, 5073, 5083, 5088, 5099, 5108, + 5113, 5118, 5146, 5147, 5153, 5154, 5160, 5159, 5182, 5184, + 5189, 5198, 5200, 5206, 5207, 5213, 5217, 5221, 5225, 5229, + 5236, 5240, 5244, 5248, 5255, 5260, 5267, 5272, 5276, 5281, + 5285, 5293, 5304, 5308, 5320, 5328, 5336, 5343, 5353, 5376, + 5382, 5388, 5394, 5400, 5411, 5422, 5433, 5444, 5450, 5456, + 5462, 5468, 5478, 5488, 5498, 5511, 5515, 5521, 5533, 5537, + 5541, 5545, 5563, 5571, 5579, 5608, 5618, 5634, 5645, 5650, + 5654, 5658, 5670, 5674, 5686, 5703, 5713, 5717, 5732, 5737, + 5744, 5748, 5753, 5767, 5784, 5788, 5793, 5797, 5802, 5810, + 5816, 5822, 5828, 5837, 5841, 5845, 5853, 5859, 5865, 5869, + 5877, 5885, 5892, 5902, 5907, 5912, 5927, 5941, 5955, 5967, + 5983, 5992, 6001, 6011, 6022, 6030, 6038, 6042, 6061, 6068, + 6074, 6081, 6089, 6088, 6098, 6122, 6124, 6130, 6135, 6137, + 6142, 6147, 6152, 6154, 6158, 6170, 6185, 6190, 6199, 6208, + 6217, 6229, 6232, 6236 }; #endif @@ -8949,7 +8949,8 @@ yyreduce: ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), dimTags); bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ - Msg::Error("Symmetry not implemented yet with OpenCASCADE geometry kernel"); + r = GModel::current()->getOCCInternals()->symmetry + (dimTags, (yyvsp[(2) - (5)].v)[0], (yyvsp[(2) - (5)].v)[1], (yyvsp[(2) - (5)].v)[2], (yyvsp[(2) - (5)].v)[3]); } else{ r = GModel::current()->getGEOInternals()->symmetry @@ -8961,13 +8962,12 @@ yyreduce: break; case 203: -#line 2357 "Gmsh.y" +#line 2358 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(8) - (9)].l), dimTags); bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ - yymsg(1, "Warning Dilate OCC: Dilatation (second argument) + Translation (first argument) "); r = GModel::current()->getOCCInternals()->dilate (dimTags, (yyvsp[(3) - (9)].v)[0], (yyvsp[(3) - (9)].v)[1], (yyvsp[(3) - (9)].v)[2], (yyvsp[(5) - (9)].d), (yyvsp[(5) - (9)].d), (yyvsp[(5) - (9)].d)); } @@ -8987,7 +8987,6 @@ yyreduce: ListOfShapes2VectorOfPairs((yyvsp[(8) - (9)].l), dimTags); bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ - yymsg(1, "Warning Dilate OCC: Dilatation (second argument) + Translation (first argument) "); r = GModel::current()->getOCCInternals()->dilate (dimTags, (yyvsp[(3) - (9)].v)[0], (yyvsp[(3) - (9)].v)[1], (yyvsp[(3) - (9)].v)[2], (yyvsp[(5) - (9)].v)[0], (yyvsp[(5) - (9)].v)[1], (yyvsp[(5) - (9)].v)[2]); } @@ -9001,7 +9000,7 @@ yyreduce: break; case 205: -#line 2391 "Gmsh.y" +#line 2390 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(3) - (4)].l), inDimTags); @@ -9039,7 +9038,7 @@ yyreduce: break; case 206: -#line 2426 "Gmsh.y" +#line 2425 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -9063,7 +9062,7 @@ yyreduce: break; case 207: -#line 2448 "Gmsh.y" +#line 2447 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -9087,31 +9086,31 @@ yyreduce: break; case 208: -#line 2471 "Gmsh.y" +#line 2470 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 209: -#line 2472 "Gmsh.y" +#line 2471 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 210: -#line 2477 "Gmsh.y" +#line 2476 "Gmsh.y" { (yyval.l) = List_Create(3, 3, sizeof(Shape)); ;} break; case 211: -#line 2481 "Gmsh.y" +#line 2480 "Gmsh.y" { List_Add((yyval.l), &(yyvsp[(2) - (2)].s)); ;} break; case 212: -#line 2485 "Gmsh.y" +#line 2484 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ double d; @@ -9125,7 +9124,7 @@ yyreduce: break; case 213: -#line 2496 "Gmsh.y" +#line 2495 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ double d; @@ -9139,7 +9138,7 @@ yyreduce: break; case 214: -#line 2507 "Gmsh.y" +#line 2506 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ double d; @@ -9153,7 +9152,7 @@ yyreduce: break; case 215: -#line 2518 "Gmsh.y" +#line 2517 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ double d; @@ -9167,7 +9166,7 @@ yyreduce: break; case 216: -#line 2534 "Gmsh.y" +#line 2533 "Gmsh.y" { if(List_Nbr((yyvsp[(7) - (8)].l)) == 4){ int t = (int)(yyvsp[(4) - (8)].d); @@ -9189,7 +9188,7 @@ yyreduce: break; case 217: -#line 2553 "Gmsh.y" +#line 2552 "Gmsh.y" { int t = (int)(yyvsp[(4) - (10)].d); if(gLevelset::find(t)){ @@ -9213,7 +9212,7 @@ yyreduce: break; case 218: -#line 2575 "Gmsh.y" +#line 2574 "Gmsh.y" { int t = (int)(yyvsp[(4) - (14)].d); if(gLevelset::find(t)){ @@ -9230,7 +9229,7 @@ yyreduce: break; case 219: -#line 2590 "Gmsh.y" +#line 2589 "Gmsh.y" { int t = (int)(yyvsp[(4) - (16)].d); if(gLevelset::find(t)){ @@ -9248,7 +9247,7 @@ yyreduce: break; case 220: -#line 2605 "Gmsh.y" +#line 2604 "Gmsh.y" { if(List_Nbr((yyvsp[(10) - (12)].l)) == 1){ int t = (int)(yyvsp[(4) - (12)].d); @@ -9269,7 +9268,7 @@ yyreduce: break; case 221: -#line 2624 "Gmsh.y" +#line 2623 "Gmsh.y" { if(List_Nbr((yyvsp[(12) - (14)].l)) == 1){ int t = (int)(yyvsp[(4) - (14)].d); @@ -9322,7 +9321,7 @@ yyreduce: break; case 222: -#line 2675 "Gmsh.y" +#line 2674 "Gmsh.y" { if(List_Nbr((yyvsp[(12) - (14)].l)) == 1){ int t = (int)(yyvsp[(4) - (14)].d); @@ -9345,7 +9344,7 @@ yyreduce: break; case 223: -#line 2696 "Gmsh.y" +#line 2695 "Gmsh.y" { if(List_Nbr((yyvsp[(12) - (14)].l)) == 3){ int t = (int)(yyvsp[(4) - (14)].d); @@ -9369,7 +9368,7 @@ yyreduce: break; case 224: -#line 2718 "Gmsh.y" +#line 2717 "Gmsh.y" { if(List_Nbr((yyvsp[(12) - (14)].l)) == 5){ int t = (int)(yyvsp[(4) - (14)].d); @@ -9394,7 +9393,7 @@ yyreduce: break; case 225: -#line 2740 "Gmsh.y" +#line 2739 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (8)].c), "Union")){ int t = (int)(yyvsp[(4) - (8)].d); @@ -9502,7 +9501,7 @@ yyreduce: break; case 226: -#line 2845 "Gmsh.y" +#line 2844 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (8)].c), "MathEval")){ int t = (int)(yyvsp[(4) - (8)].d); @@ -9521,7 +9520,7 @@ yyreduce: break; case 227: -#line 2861 "Gmsh.y" +#line 2860 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (6)].c), "CutMesh")){ int t = (int)(yyvsp[(4) - (6)].d); @@ -9554,7 +9553,7 @@ yyreduce: break; case 228: -#line 2896 "Gmsh.y" +#line 2895 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(3) - (4)].l), dimTags); @@ -9568,7 +9567,7 @@ yyreduce: break; case 229: -#line 2907 "Gmsh.y" +#line 2906 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), dimTags); @@ -9582,7 +9581,7 @@ yyreduce: break; case 230: -#line 2918 "Gmsh.y" +#line 2917 "Gmsh.y" { #if defined(HAVE_MESH) GModel::current()->getFields()->deleteField((int)(yyvsp[(4) - (6)].d)); @@ -9591,7 +9590,7 @@ yyreduce: break; case 231: -#line 2924 "Gmsh.y" +#line 2923 "Gmsh.y" { #if defined(HAVE_POST) if(!strcmp((yyvsp[(2) - (6)].c), "View")){ @@ -9609,7 +9608,7 @@ yyreduce: break; case 232: -#line 2939 "Gmsh.y" +#line 2938 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (3)].c), "Meshes") || !strcmp((yyvsp[(2) - (3)].c), "All")){ ClearProject(); @@ -9640,7 +9639,7 @@ yyreduce: break; case 233: -#line 2967 "Gmsh.y" +#line 2966 "Gmsh.y" { #if defined(HAVE_POST) if(!strcmp((yyvsp[(2) - (4)].c), "Empty") && !strcmp((yyvsp[(3) - (4)].c), "Views")){ @@ -9655,14 +9654,14 @@ yyreduce: break; case 234: -#line 2979 "Gmsh.y" +#line 2978 "Gmsh.y" { gmsh_yynamespaces.clear(); ;} break; case 235: -#line 2988 "Gmsh.y" +#line 2987 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), dimTags); @@ -9672,7 +9671,7 @@ yyreduce: break; case 236: -#line 2995 "Gmsh.y" +#line 2994 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(5) - (6)].l), dimTags); @@ -9682,7 +9681,7 @@ yyreduce: break; case 237: -#line 3007 "Gmsh.y" +#line 3006 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), dimTags); @@ -9699,7 +9698,7 @@ yyreduce: break; case 238: -#line 3026 "Gmsh.y" +#line 3025 "Gmsh.y" { std::string what = (yyvsp[(2) - (3)].c); setVisibility(-1, 1, false); @@ -9708,7 +9707,7 @@ yyreduce: break; case 239: -#line 3032 "Gmsh.y" +#line 3031 "Gmsh.y" { std::string what = (yyvsp[(2) - (3)].c); setVisibility(-1, 0, false); @@ -9717,7 +9716,7 @@ yyreduce: break; case 240: -#line 3038 "Gmsh.y" +#line 3037 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(3) - (4)].l), dimTags); @@ -9727,7 +9726,7 @@ yyreduce: break; case 241: -#line 3045 "Gmsh.y" +#line 3044 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), dimTags); @@ -9737,7 +9736,7 @@ yyreduce: break; case 242: -#line 3052 "Gmsh.y" +#line 3051 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(3) - (4)].l), dimTags); @@ -9747,7 +9746,7 @@ yyreduce: break; case 243: -#line 3059 "Gmsh.y" +#line 3058 "Gmsh.y" { std::vector<std::pair<int, int> > dimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), dimTags); @@ -9757,7 +9756,7 @@ yyreduce: break; case 244: -#line 3071 "Gmsh.y" +#line 3070 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (3)].c), "Include")){ std::string tmp = FixRelativePath(gmsh_yyname, (yyvsp[(2) - (3)].c)); @@ -9833,7 +9832,7 @@ yyreduce: break; case 245: -#line 3144 "Gmsh.y" +#line 3143 "Gmsh.y" { int n = List_Nbr((yyvsp[(3) - (5)].l)); if(n == 1){ @@ -9854,7 +9853,7 @@ yyreduce: break; case 246: -#line 3162 "Gmsh.y" +#line 3161 "Gmsh.y" { #if defined(HAVE_POST) if(!strcmp((yyvsp[(1) - (7)].c), "Save") && !strcmp((yyvsp[(2) - (7)].c), "View")){ @@ -9874,7 +9873,7 @@ yyreduce: break; case 247: -#line 3179 "Gmsh.y" +#line 3178 "Gmsh.y" { #if defined(HAVE_POST) && defined(HAVE_MESH) if(!strcmp((yyvsp[(1) - (7)].c), "Background") && !strcmp((yyvsp[(2) - (7)].c), "Mesh") && !strcmp((yyvsp[(3) - (7)].c), "View")){ @@ -9892,7 +9891,7 @@ yyreduce: break; case 248: -#line 3194 "Gmsh.y" +#line 3193 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (3)].c), "Sleep")){ SleepInSeconds((yyvsp[(2) - (3)].d)); @@ -9928,7 +9927,7 @@ yyreduce: break; case 249: -#line 3227 "Gmsh.y" +#line 3226 "Gmsh.y" { #if defined(HAVE_PLUGINS) try { @@ -9943,7 +9942,7 @@ yyreduce: break; case 250: -#line 3239 "Gmsh.y" +#line 3238 "Gmsh.y" { #if defined(HAVE_POST) if(!strcmp((yyvsp[(2) - (3)].c), "ElementsFromAllViews")) @@ -9970,14 +9969,14 @@ yyreduce: break; case 251: -#line 3263 "Gmsh.y" +#line 3262 "Gmsh.y" { Msg::Exit(0); ;} break; case 252: -#line 3267 "Gmsh.y" +#line 3266 "Gmsh.y" { gmsh_yyerrorstate = 999; // this will be checked when yyparse returns YYABORT; @@ -9985,7 +9984,7 @@ yyreduce: break; case 253: -#line 3272 "Gmsh.y" +#line 3271 "Gmsh.y" { // force sync if(GModel::current()->getOCCInternals()) @@ -9995,7 +9994,7 @@ yyreduce: break; case 254: -#line 3279 "Gmsh.y" +#line 3278 "Gmsh.y" { new GModel(); GModel::current(GModel::list.size() - 1); @@ -10003,7 +10002,7 @@ yyreduce: break; case 255: -#line 3284 "Gmsh.y" +#line 3283 "Gmsh.y" { CTX::instance()->forcedBBox = 0; if(GModel::current()->getOCCInternals() && @@ -10016,7 +10015,7 @@ yyreduce: break; case 256: -#line 3294 "Gmsh.y" +#line 3293 "Gmsh.y" { CTX::instance()->forcedBBox = 1; SetBoundingBox((yyvsp[(3) - (15)].d), (yyvsp[(5) - (15)].d), (yyvsp[(7) - (15)].d), (yyvsp[(9) - (15)].d), (yyvsp[(11) - (15)].d), (yyvsp[(13) - (15)].d)); @@ -10024,7 +10023,7 @@ yyreduce: break; case 257: -#line 3299 "Gmsh.y" +#line 3298 "Gmsh.y" { #if defined(HAVE_OPENGL) drawContext::global()->draw(); @@ -10033,7 +10032,7 @@ yyreduce: break; case 258: -#line 3305 "Gmsh.y" +#line 3304 "Gmsh.y" { #if defined(HAVE_OPENGL) CTX::instance()->mesh.changed = ENT_ALL; @@ -10044,21 +10043,21 @@ yyreduce: break; case 259: -#line 3313 "Gmsh.y" +#line 3312 "Gmsh.y" { GModel::current()->createTopologyFromMesh(); ;} break; case 260: -#line 3317 "Gmsh.y" +#line 3316 "Gmsh.y" { GModel::current()->createTopologyFromMesh(1); ;} break; case 261: -#line 3321 "Gmsh.y" +#line 3320 "Gmsh.y" { if(GModel::current()->getOCCInternals() && GModel::current()->getOCCInternals()->getChanged()) @@ -10070,7 +10069,7 @@ yyreduce: break; case 262: -#line 3331 "Gmsh.y" +#line 3330 "Gmsh.y" { int lock = CTX::instance()->lock; CTX::instance()->lock = 0; @@ -10131,7 +10130,7 @@ yyreduce: break; case 263: -#line 3394 "Gmsh.y" +#line 3393 "Gmsh.y" { #if defined(HAVE_POPPLER) std::vector<int> is; @@ -10146,7 +10145,7 @@ yyreduce: break; case 264: -#line 3410 "Gmsh.y" +#line 3409 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(3) - (6)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(5) - (6)].d); @@ -10166,7 +10165,7 @@ yyreduce: break; case 265: -#line 3427 "Gmsh.y" +#line 3426 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(3) - (8)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(5) - (8)].d); @@ -10186,7 +10185,7 @@ yyreduce: break; case 266: -#line 3444 "Gmsh.y" +#line 3443 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(5) - (8)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(7) - (8)].d); @@ -10211,7 +10210,7 @@ yyreduce: break; case 267: -#line 3466 "Gmsh.y" +#line 3465 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(5) - (10)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(7) - (10)].d); @@ -10236,7 +10235,7 @@ yyreduce: break; case 268: -#line 3488 "Gmsh.y" +#line 3487 "Gmsh.y" { if(ImbricatedLoop <= 0){ yymsg(0, "Invalid For/EndFor loop"); @@ -10274,7 +10273,7 @@ yyreduce: break; case 269: -#line 3523 "Gmsh.y" +#line 3522 "Gmsh.y" { if(!FunctionManager::Instance()->createFunction (std::string((yyvsp[(2) - (2)].c)), gmsh_yyin, gmsh_yyname, gmsh_yylineno)) @@ -10285,7 +10284,7 @@ yyreduce: break; case 270: -#line 3531 "Gmsh.y" +#line 3530 "Gmsh.y" { if(!FunctionManager::Instance()->createFunction (std::string((yyvsp[(2) - (2)].c)), gmsh_yyin, gmsh_yyname, gmsh_yylineno)) @@ -10296,7 +10295,7 @@ yyreduce: break; case 271: -#line 3539 "Gmsh.y" +#line 3538 "Gmsh.y" { if(!FunctionManager::Instance()->leaveFunction (&gmsh_yyin, gmsh_yyname, gmsh_yylineno)) @@ -10305,7 +10304,7 @@ yyreduce: break; case 272: -#line 3545 "Gmsh.y" +#line 3544 "Gmsh.y" { if(!FunctionManager::Instance()->enterFunction (std::string((yyvsp[(2) - (3)].c)), &gmsh_yyin, gmsh_yyname, gmsh_yylineno)) @@ -10315,7 +10314,7 @@ yyreduce: break; case 273: -#line 3552 "Gmsh.y" +#line 3551 "Gmsh.y" { if(!FunctionManager::Instance()->enterFunction (std::string((yyvsp[(2) - (3)].c)), &gmsh_yyin, gmsh_yyname, gmsh_yylineno)) @@ -10325,7 +10324,7 @@ yyreduce: break; case 274: -#line 3559 "Gmsh.y" +#line 3558 "Gmsh.y" { ImbricatedTest++; if(ImbricatedTest > MAX_RECUR_TESTS-1){ @@ -10348,7 +10347,7 @@ yyreduce: break; case 275: -#line 3579 "Gmsh.y" +#line 3578 "Gmsh.y" { if(ImbricatedTest > 0){ if (statusImbricatedTests[ImbricatedTest]){ @@ -10377,7 +10376,7 @@ yyreduce: break; case 276: -#line 3605 "Gmsh.y" +#line 3604 "Gmsh.y" { if(ImbricatedTest > 0){ if(statusImbricatedTests[ImbricatedTest]){ @@ -10392,7 +10391,7 @@ yyreduce: break; case 277: -#line 3617 "Gmsh.y" +#line 3616 "Gmsh.y" { ImbricatedTest--; if(ImbricatedTest < 0) @@ -10401,7 +10400,7 @@ yyreduce: break; case 278: -#line 3629 "Gmsh.y" +#line 3628 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (5)].l), inDimTags); @@ -10422,7 +10421,7 @@ yyreduce: break; case 279: -#line 3647 "Gmsh.y" +#line 3646 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(10) - (11)].l), inDimTags); @@ -10443,7 +10442,7 @@ yyreduce: break; case 280: -#line 3665 "Gmsh.y" +#line 3664 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(12) - (13)].l), inDimTags); @@ -10464,7 +10463,7 @@ yyreduce: break; case 281: -#line 3683 "Gmsh.y" +#line 3682 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; @@ -10473,7 +10472,7 @@ yyreduce: break; case 282: -#line 3689 "Gmsh.y" +#line 3688 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(4) - (7)].l), inDimTags); @@ -10494,7 +10493,7 @@ yyreduce: break; case 283: -#line 3707 "Gmsh.y" +#line 3706 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; @@ -10503,7 +10502,7 @@ yyreduce: break; case 284: -#line 3713 "Gmsh.y" +#line 3712 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(10) - (13)].l), inDimTags); @@ -10526,7 +10525,7 @@ yyreduce: break; case 285: -#line 3733 "Gmsh.y" +#line 3732 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; @@ -10535,7 +10534,7 @@ yyreduce: break; case 286: -#line 3739 "Gmsh.y" +#line 3738 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(12) - (15)].l), inDimTags); @@ -10556,7 +10555,7 @@ yyreduce: break; case 287: -#line 3757 "Gmsh.y" +#line 3756 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; @@ -10565,7 +10564,7 @@ yyreduce: break; case 288: -#line 3763 "Gmsh.y" +#line 3762 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(3) - (6)].l), inDimTags); @@ -10585,7 +10584,7 @@ yyreduce: break; case 289: -#line 3780 "Gmsh.y" +#line 3779 "Gmsh.y" { std::vector<std::pair<int, int> > inDimTags, outDimTags; ListOfShapes2VectorOfPairs((yyvsp[(3) - (9)].l), inDimTags); @@ -10604,7 +10603,7 @@ yyreduce: break; case 290: -#line 3796 "Gmsh.y" +#line 3795 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -10624,7 +10623,7 @@ yyreduce: break; case 291: -#line 3813 "Gmsh.y" +#line 3812 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -10644,7 +10643,7 @@ yyreduce: break; case 292: -#line 3830 "Gmsh.y" +#line 3829 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -10667,19 +10666,19 @@ yyreduce: break; case 293: -#line 3853 "Gmsh.y" +#line 3852 "Gmsh.y" { ;} break; case 294: -#line 3856 "Gmsh.y" +#line 3855 "Gmsh.y" { ;} break; case 295: -#line 3862 "Gmsh.y" +#line 3861 "Gmsh.y" { int n = (int)fabs((yyvsp[(3) - (5)].d)); if(n){ // we accept n==0 to easily disable layers @@ -10694,7 +10693,7 @@ yyreduce: break; case 296: -#line 3874 "Gmsh.y" +#line 3873 "Gmsh.y" { extr.mesh.ExtrudeMesh = true; extr.mesh.NbLayer = List_Nbr((yyvsp[(3) - (7)].l)); @@ -10717,56 +10716,56 @@ yyreduce: break; case 297: -#line 3894 "Gmsh.y" +#line 3893 "Gmsh.y" { extr.mesh.ScaleLast = true; ;} break; case 298: -#line 3898 "Gmsh.y" +#line 3897 "Gmsh.y" { extr.mesh.Recombine = true; ;} break; case 299: -#line 3902 "Gmsh.y" +#line 3901 "Gmsh.y" { extr.mesh.Recombine = (yyvsp[(2) - (3)].d) ? true : false; ;} break; case 300: -#line 3906 "Gmsh.y" +#line 3905 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_ADDVERTS_1; ;} break; case 301: -#line 3910 "Gmsh.y" +#line 3909 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_ADDVERTS_1_RECOMB; ;} break; case 302: -#line 3914 "Gmsh.y" +#line 3913 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_NOVERTS_1; ;} break; case 303: -#line 3918 "Gmsh.y" +#line 3917 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_NOVERTS_1_RECOMB; ;} break; case 304: -#line 3922 "Gmsh.y" +#line 3921 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(6) - (9)].l), tags); int num = (int)(yyvsp[(3) - (9)].d); @@ -10778,7 +10777,7 @@ yyreduce: break; case 305: -#line 3931 "Gmsh.y" +#line 3930 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (6)].c), "Index")) extr.mesh.BoundaryLayerIndex = (yyvsp[(4) - (6)].d); @@ -10789,57 +10788,57 @@ yyreduce: break; case 306: -#line 3943 "Gmsh.y" +#line 3942 "Gmsh.y" { (yyval.i) = OCC_Internals::Union; ;} break; case 307: -#line 3944 "Gmsh.y" +#line 3943 "Gmsh.y" { (yyval.i) = OCC_Internals::Intersection; ;} break; case 308: -#line 3945 "Gmsh.y" +#line 3944 "Gmsh.y" { (yyval.i) = OCC_Internals::Difference; ;} break; case 309: -#line 3946 "Gmsh.y" +#line 3945 "Gmsh.y" { (yyval.i) = OCC_Internals::Section; ;} break; case 310: -#line 3947 "Gmsh.y" +#line 3946 "Gmsh.y" { (yyval.i) = OCC_Internals::Fragments; ;} break; case 311: -#line 3951 "Gmsh.y" +#line 3950 "Gmsh.y" { (yyval.i) = 0; ;} break; case 312: -#line 3952 "Gmsh.y" +#line 3951 "Gmsh.y" { (yyval.i) = 1; ;} break; case 313: -#line 3953 "Gmsh.y" +#line 3952 "Gmsh.y" { (yyval.i) = 2; ;} break; case 314: -#line 3954 "Gmsh.y" +#line 3953 "Gmsh.y" { (yyval.i) = (yyvsp[(2) - (3)].d) ? 1 : 0; ;} break; case 315: -#line 3955 "Gmsh.y" +#line 3954 "Gmsh.y" { (yyval.i) = (yyvsp[(3) - (4)].d) ? 2 : 0; ;} break; case 316: -#line 3960 "Gmsh.y" +#line 3959 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -10864,7 +10863,7 @@ yyreduce: break; case 317: -#line 3982 "Gmsh.y" +#line 3981 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); bool r = true; @@ -10883,7 +10882,7 @@ yyreduce: break; case 318: -#line 4002 "Gmsh.y" +#line 4001 "Gmsh.y" { bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ @@ -10903,14 +10902,14 @@ yyreduce: break; case 319: -#line 4022 "Gmsh.y" +#line 4021 "Gmsh.y" { (yyval.v)[0] = (yyval.v)[1] = 1.; ;} break; case 320: -#line 4026 "Gmsh.y" +#line 4025 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (3)].c), "Progression") || !strcmp((yyvsp[(2) - (3)].c), "Power")) (yyval.v)[0] = 1.; @@ -10926,14 +10925,14 @@ yyreduce: break; case 321: -#line 4041 "Gmsh.y" +#line 4040 "Gmsh.y" { (yyval.i) = -1; // left ;} break; case 322: -#line 4045 "Gmsh.y" +#line 4044 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (1)].c), "Right")) (yyval.i) = 1; @@ -10950,49 +10949,49 @@ yyreduce: break; case 323: -#line 4061 "Gmsh.y" +#line 4060 "Gmsh.y" { (yyval.l) = List_Create(1, 1, sizeof(double)); ;} break; case 324: -#line 4065 "Gmsh.y" +#line 4064 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (2)].l); ;} break; case 325: -#line 4070 "Gmsh.y" +#line 4069 "Gmsh.y" { (yyval.i) = 45; ;} break; case 326: -#line 4074 "Gmsh.y" +#line 4073 "Gmsh.y" { (yyval.i) = (int)(yyvsp[(2) - (2)].d); ;} break; case 327: -#line 4080 "Gmsh.y" +#line 4079 "Gmsh.y" { (yyval.l) = List_Create(1, 1, sizeof(double)); ;} break; case 328: -#line 4084 "Gmsh.y" +#line 4083 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (2)].l); ;} break; case 329: -#line 4091 "Gmsh.y" +#line 4090 "Gmsh.y" { // mesh sizes at vertices are stored in internal CAD data, as they can be // specified during vertex creation and copied around during CAD @@ -11012,7 +11011,7 @@ yyreduce: break; case 330: -#line 4108 "Gmsh.y" +#line 4107 "Gmsh.y" { // transfinite constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11056,7 +11055,7 @@ yyreduce: break; case 331: -#line 4149 "Gmsh.y" +#line 4148 "Gmsh.y" { // transfinite constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11103,7 +11102,7 @@ yyreduce: break; case 332: -#line 4193 "Gmsh.y" +#line 4192 "Gmsh.y" { // transfinite constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11145,7 +11144,7 @@ yyreduce: break; case 333: -#line 4232 "Gmsh.y" +#line 4231 "Gmsh.y" { // transfinite constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11173,7 +11172,7 @@ yyreduce: break; case 334: -#line 4257 "Gmsh.y" +#line 4256 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (8)].l)); i++){ double d; @@ -11185,7 +11184,7 @@ yyreduce: break; case 335: -#line 4266 "Gmsh.y" +#line 4265 "Gmsh.y" { // recombine constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11218,7 +11217,7 @@ yyreduce: break; case 336: -#line 4296 "Gmsh.y" +#line 4295 "Gmsh.y" { // recombine constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11247,7 +11246,7 @@ yyreduce: break; case 337: -#line 4322 "Gmsh.y" +#line 4321 "Gmsh.y" { // smoothing constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11276,7 +11275,7 @@ yyreduce: break; case 338: -#line 4349 "Gmsh.y" +#line 4348 "Gmsh.y" { if (List_Nbr((yyvsp[(4) - (11)].l)) != List_Nbr((yyvsp[(8) - (11)].l))){ yymsg(0, "Number of master lines (%d) different from number of " @@ -11310,7 +11309,7 @@ yyreduce: break; case 339: -#line 4381 "Gmsh.y" +#line 4380 "Gmsh.y" { if (List_Nbr((yyvsp[(4) - (11)].l)) != List_Nbr((yyvsp[(8) - (11)].l))){ yymsg(0, "Number of master faces (%d) different from number of " @@ -11339,7 +11338,7 @@ yyreduce: break; case 340: -#line 4408 "Gmsh.y" +#line 4407 "Gmsh.y" { if (List_Nbr((yyvsp[(4) - (18)].l)) != List_Nbr((yyvsp[(8) - (18)].l))){ yymsg(0, "Number of master edges (%d) different from number of " @@ -11367,7 +11366,7 @@ yyreduce: break; case 341: -#line 4434 "Gmsh.y" +#line 4433 "Gmsh.y" { if (List_Nbr((yyvsp[(4) - (18)].l)) != List_Nbr((yyvsp[(8) - (18)].l))){ yymsg(0, "Number of master faces (%d) different from number of " @@ -11395,7 +11394,7 @@ yyreduce: break; case 342: -#line 4460 "Gmsh.y" +#line 4459 "Gmsh.y" { if (List_Nbr((yyvsp[(4) - (12)].l)) != List_Nbr((yyvsp[(8) - (12)].l))){ yymsg(0, "Number of master edges (%d) different from number of " @@ -11423,7 +11422,7 @@ yyreduce: break; case 343: -#line 4486 "Gmsh.y" +#line 4485 "Gmsh.y" { if (List_Nbr((yyvsp[(4) - (12)].l)) != List_Nbr((yyvsp[(8) - (12)].l))){ yymsg(0, "Number of master faces (%d) different from number of " @@ -11451,7 +11450,7 @@ yyreduce: break; case 344: -#line 4512 "Gmsh.y" +#line 4511 "Gmsh.y" { if (List_Nbr((yyvsp[(5) - (12)].l)) != List_Nbr((yyvsp[(10) - (12)].l))){ yymsg(0, "Number of master surface edges (%d) different from number of " @@ -11475,7 +11474,7 @@ yyreduce: break; case 345: -#line 4533 "Gmsh.y" +#line 4532 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (10)].l), tags); addEmbedded(0, tags, 2, (int)(yyvsp[(8) - (10)].d)); @@ -11484,7 +11483,7 @@ yyreduce: break; case 346: -#line 4539 "Gmsh.y" +#line 4538 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (10)].l), tags); addEmbedded(1, tags, 2, (int)(yyvsp[(8) - (10)].d)); @@ -11493,7 +11492,7 @@ yyreduce: break; case 347: -#line 4545 "Gmsh.y" +#line 4544 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (10)].l), tags); addEmbedded(0, tags, 3, (int)(yyvsp[(8) - (10)].d)); @@ -11502,7 +11501,7 @@ yyreduce: break; case 348: -#line 4551 "Gmsh.y" +#line 4550 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (10)].l), tags); addEmbedded(1, tags, 3, (int)(yyvsp[(8) - (10)].d)); @@ -11511,7 +11510,7 @@ yyreduce: break; case 349: -#line 4557 "Gmsh.y" +#line 4556 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (10)].l), tags); addEmbedded(2, tags, 3, (int)(yyvsp[(8) - (10)].d)); @@ -11520,7 +11519,7 @@ yyreduce: break; case 350: -#line 4563 "Gmsh.y" +#line 4562 "Gmsh.y" { // reverse mesh constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11549,7 +11548,7 @@ yyreduce: break; case 351: -#line 4589 "Gmsh.y" +#line 4588 "Gmsh.y" { // reverse mesh constraints are stored in GEO internals in addition to // GModel, as they can be copied around during GEO operations @@ -11578,7 +11577,7 @@ yyreduce: break; case 352: -#line 4615 "Gmsh.y" +#line 4614 "Gmsh.y" { if(!(yyvsp[(3) - (4)].l)){ for(GModel::viter it = GModel::current()->firstVertex(); @@ -11598,7 +11597,7 @@ yyreduce: break; case 353: -#line 4632 "Gmsh.y" +#line 4631 "Gmsh.y" { if(!(yyvsp[(3) - (4)].l)){ for(GModel::eiter it = GModel::current()->firstEdge(); @@ -11618,7 +11617,7 @@ yyreduce: break; case 354: -#line 4649 "Gmsh.y" +#line 4648 "Gmsh.y" { if(!(yyvsp[(3) - (4)].l)){ for(GModel::fiter it = GModel::current()->firstFace(); @@ -11638,7 +11637,7 @@ yyreduce: break; case 355: -#line 4666 "Gmsh.y" +#line 4665 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ double dnum; @@ -11653,7 +11652,7 @@ yyreduce: break; case 356: -#line 4678 "Gmsh.y" +#line 4677 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (4)].l), tags); GModel::current()->getGEOInternals()->setCompoundMesh(1, tags); @@ -11662,7 +11661,7 @@ yyreduce: break; case 357: -#line 4684 "Gmsh.y" +#line 4683 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (4)].l), tags); GModel::current()->getGEOInternals()->setCompoundMesh(2, tags); @@ -11671,7 +11670,7 @@ yyreduce: break; case 358: -#line 4690 "Gmsh.y" +#line 4689 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(3) - (4)].l), tags); GModel::current()->getGEOInternals()->setCompoundMesh(3, tags); @@ -11680,14 +11679,14 @@ yyreduce: break; case 359: -#line 4702 "Gmsh.y" +#line 4701 "Gmsh.y" { GModel::current()->getGEOInternals()->removeAllDuplicates(); ;} break; case 360: -#line 4706 "Gmsh.y" +#line 4705 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (3)].c), "Geometry")) GModel::current()->getGEOInternals()->removeAllDuplicates(); @@ -11700,7 +11699,7 @@ yyreduce: break; case 361: -#line 4716 "Gmsh.y" +#line 4715 "Gmsh.y" { std::vector<int> tags; ListOfDouble2Vector((yyvsp[(4) - (6)].l), tags); GModel::current()->getGEOInternals()->mergeVertices(tags); @@ -11709,22 +11708,22 @@ yyreduce: break; case 362: -#line 4726 "Gmsh.y" +#line 4725 "Gmsh.y" { (yyval.c) = (char*)"Homology"; ;} break; case 363: -#line 4727 "Gmsh.y" +#line 4726 "Gmsh.y" { (yyval.c) = (char*)"Cohomology"; ;} break; case 364: -#line 4728 "Gmsh.y" +#line 4727 "Gmsh.y" { (yyval.c) = (char*)"Betti"; ;} break; case 365: -#line 4733 "Gmsh.y" +#line 4732 "Gmsh.y" { std::vector<int> domain, subdomain, dim; for(int i = 0; i < 4; i++) dim.push_back(i); @@ -11733,7 +11732,7 @@ yyreduce: break; case 366: -#line 4739 "Gmsh.y" +#line 4738 "Gmsh.y" { std::vector<int> domain, subdomain, dim; for(int i = 0; i < List_Nbr((yyvsp[(3) - (5)].l)); i++){ @@ -11748,7 +11747,7 @@ yyreduce: break; case 367: -#line 4751 "Gmsh.y" +#line 4750 "Gmsh.y" { std::vector<int> domain, subdomain, dim; for(int i = 0; i < List_Nbr((yyvsp[(3) - (7)].l)); i++){ @@ -11769,7 +11768,7 @@ yyreduce: break; case 368: -#line 4769 "Gmsh.y" +#line 4768 "Gmsh.y" { std::vector<int> domain, subdomain, dim; for(int i = 0; i < List_Nbr((yyvsp[(6) - (10)].l)); i++){ @@ -11795,47 +11794,47 @@ yyreduce: break; case 369: -#line 4796 "Gmsh.y" +#line 4795 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (1)].d); ;} break; case 370: -#line 4797 "Gmsh.y" +#line 4796 "Gmsh.y" { (yyval.d) = (yyvsp[(2) - (3)].d); ;} break; case 371: -#line 4798 "Gmsh.y" +#line 4797 "Gmsh.y" { (yyval.d) = -(yyvsp[(2) - (2)].d); ;} break; case 372: -#line 4799 "Gmsh.y" +#line 4798 "Gmsh.y" { (yyval.d) = (yyvsp[(2) - (2)].d); ;} break; case 373: -#line 4800 "Gmsh.y" +#line 4799 "Gmsh.y" { (yyval.d) = !(yyvsp[(2) - (2)].d); ;} break; case 374: -#line 4801 "Gmsh.y" +#line 4800 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) - (yyvsp[(3) - (3)].d); ;} break; case 375: -#line 4802 "Gmsh.y" +#line 4801 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) + (yyvsp[(3) - (3)].d); ;} break; case 376: -#line 4803 "Gmsh.y" +#line 4802 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) * (yyvsp[(3) - (3)].d); ;} break; case 377: -#line 4805 "Gmsh.y" +#line 4804 "Gmsh.y" { if(!(yyvsp[(3) - (3)].d)) yymsg(0, "Division by zero in '%g / %g'", (yyvsp[(1) - (3)].d), (yyvsp[(3) - (3)].d)); @@ -11845,257 +11844,257 @@ yyreduce: break; case 378: -#line 4811 "Gmsh.y" +#line 4810 "Gmsh.y" { (yyval.d) = (int)(yyvsp[(1) - (3)].d) | (int)(yyvsp[(3) - (3)].d); ;} break; case 379: -#line 4812 "Gmsh.y" +#line 4811 "Gmsh.y" { (yyval.d) = (int)(yyvsp[(1) - (3)].d) & (int)(yyvsp[(3) - (3)].d); ;} break; case 380: -#line 4813 "Gmsh.y" +#line 4812 "Gmsh.y" { (yyval.d) = (int)(yyvsp[(1) - (3)].d) % (int)(yyvsp[(3) - (3)].d); ;} break; case 381: -#line 4814 "Gmsh.y" +#line 4813 "Gmsh.y" { (yyval.d) = pow((yyvsp[(1) - (3)].d), (yyvsp[(3) - (3)].d)); ;} break; case 382: -#line 4815 "Gmsh.y" +#line 4814 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) < (yyvsp[(3) - (3)].d); ;} break; case 383: -#line 4816 "Gmsh.y" +#line 4815 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) > (yyvsp[(3) - (3)].d); ;} break; case 384: -#line 4817 "Gmsh.y" +#line 4816 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) <= (yyvsp[(3) - (3)].d); ;} break; case 385: -#line 4818 "Gmsh.y" +#line 4817 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) >= (yyvsp[(3) - (3)].d); ;} break; case 386: -#line 4819 "Gmsh.y" +#line 4818 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) == (yyvsp[(3) - (3)].d); ;} break; case 387: -#line 4820 "Gmsh.y" +#line 4819 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) != (yyvsp[(3) - (3)].d); ;} break; case 388: -#line 4821 "Gmsh.y" +#line 4820 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) && (yyvsp[(3) - (3)].d); ;} break; case 389: -#line 4822 "Gmsh.y" +#line 4821 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (3)].d) || (yyvsp[(3) - (3)].d); ;} break; case 390: -#line 4823 "Gmsh.y" +#line 4822 "Gmsh.y" { (yyval.d) = ((int)(yyvsp[(1) - (3)].d) >> (int)(yyvsp[(3) - (3)].d)); ;} break; case 391: -#line 4824 "Gmsh.y" +#line 4823 "Gmsh.y" { (yyval.d) = ((int)(yyvsp[(1) - (3)].d) << (int)(yyvsp[(3) - (3)].d)); ;} break; case 392: -#line 4825 "Gmsh.y" +#line 4824 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (5)].d) ? (yyvsp[(3) - (5)].d) : (yyvsp[(5) - (5)].d); ;} break; case 393: -#line 4826 "Gmsh.y" +#line 4825 "Gmsh.y" { (yyval.d) = exp((yyvsp[(3) - (4)].d)); ;} break; case 394: -#line 4827 "Gmsh.y" +#line 4826 "Gmsh.y" { (yyval.d) = log((yyvsp[(3) - (4)].d)); ;} break; case 395: -#line 4828 "Gmsh.y" +#line 4827 "Gmsh.y" { (yyval.d) = log10((yyvsp[(3) - (4)].d)); ;} break; case 396: -#line 4829 "Gmsh.y" +#line 4828 "Gmsh.y" { (yyval.d) = sqrt((yyvsp[(3) - (4)].d)); ;} break; case 397: -#line 4830 "Gmsh.y" +#line 4829 "Gmsh.y" { (yyval.d) = sin((yyvsp[(3) - (4)].d)); ;} break; case 398: -#line 4831 "Gmsh.y" +#line 4830 "Gmsh.y" { (yyval.d) = asin((yyvsp[(3) - (4)].d)); ;} break; case 399: -#line 4832 "Gmsh.y" +#line 4831 "Gmsh.y" { (yyval.d) = cos((yyvsp[(3) - (4)].d)); ;} break; case 400: -#line 4833 "Gmsh.y" +#line 4832 "Gmsh.y" { (yyval.d) = acos((yyvsp[(3) - (4)].d)); ;} break; case 401: -#line 4834 "Gmsh.y" +#line 4833 "Gmsh.y" { (yyval.d) = tan((yyvsp[(3) - (4)].d)); ;} break; case 402: -#line 4835 "Gmsh.y" +#line 4834 "Gmsh.y" { (yyval.d) = atan((yyvsp[(3) - (4)].d)); ;} break; case 403: -#line 4836 "Gmsh.y" +#line 4835 "Gmsh.y" { (yyval.d) = atan2((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d));;} break; case 404: -#line 4837 "Gmsh.y" +#line 4836 "Gmsh.y" { (yyval.d) = sinh((yyvsp[(3) - (4)].d)); ;} break; case 405: -#line 4838 "Gmsh.y" +#line 4837 "Gmsh.y" { (yyval.d) = cosh((yyvsp[(3) - (4)].d)); ;} break; case 406: -#line 4839 "Gmsh.y" +#line 4838 "Gmsh.y" { (yyval.d) = tanh((yyvsp[(3) - (4)].d)); ;} break; case 407: -#line 4840 "Gmsh.y" +#line 4839 "Gmsh.y" { (yyval.d) = fabs((yyvsp[(3) - (4)].d)); ;} break; case 408: -#line 4841 "Gmsh.y" +#line 4840 "Gmsh.y" { (yyval.d) = std::abs((yyvsp[(3) - (4)].d)); ;} break; case 409: -#line 4842 "Gmsh.y" +#line 4841 "Gmsh.y" { (yyval.d) = floor((yyvsp[(3) - (4)].d)); ;} break; case 410: -#line 4843 "Gmsh.y" +#line 4842 "Gmsh.y" { (yyval.d) = ceil((yyvsp[(3) - (4)].d)); ;} break; case 411: -#line 4844 "Gmsh.y" +#line 4843 "Gmsh.y" { (yyval.d) = floor((yyvsp[(3) - (4)].d) + 0.5); ;} break; case 412: -#line 4845 "Gmsh.y" +#line 4844 "Gmsh.y" { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); ;} break; case 413: -#line 4846 "Gmsh.y" +#line 4845 "Gmsh.y" { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); ;} break; case 414: -#line 4847 "Gmsh.y" +#line 4846 "Gmsh.y" { (yyval.d) = sqrt((yyvsp[(3) - (6)].d) * (yyvsp[(3) - (6)].d) + (yyvsp[(5) - (6)].d) * (yyvsp[(5) - (6)].d)); ;} break; case 415: -#line 4848 "Gmsh.y" +#line 4847 "Gmsh.y" { (yyval.d) = (yyvsp[(3) - (4)].d) * (double)rand() / (double)RAND_MAX; ;} break; case 416: -#line 4857 "Gmsh.y" +#line 4856 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (1)].d); ;} break; case 417: -#line 4858 "Gmsh.y" +#line 4857 "Gmsh.y" { (yyval.d) = 3.141592653589793; ;} break; case 418: -#line 4859 "Gmsh.y" +#line 4858 "Gmsh.y" { (yyval.d) = (double)ImbricatedTest; ;} break; case 419: -#line 4860 "Gmsh.y" +#line 4859 "Gmsh.y" { (yyval.d) = Msg::GetCommRank(); ;} break; case 420: -#line 4861 "Gmsh.y" +#line 4860 "Gmsh.y" { (yyval.d) = Msg::GetCommSize(); ;} break; case 421: -#line 4862 "Gmsh.y" +#line 4861 "Gmsh.y" { (yyval.d) = GetGmshMajorVersion(); ;} break; case 422: -#line 4863 "Gmsh.y" +#line 4862 "Gmsh.y" { (yyval.d) = GetGmshMinorVersion(); ;} break; case 423: -#line 4864 "Gmsh.y" +#line 4863 "Gmsh.y" { (yyval.d) = GetGmshPatchVersion(); ;} break; case 424: -#line 4865 "Gmsh.y" +#line 4864 "Gmsh.y" { (yyval.d) = Cpu(); ;} break; case 425: -#line 4866 "Gmsh.y" +#line 4865 "Gmsh.y" { (yyval.d) = GetMemoryUsage()/1024./1024.; ;} break; case 426: -#line 4867 "Gmsh.y" +#line 4866 "Gmsh.y" { (yyval.d) = TotalRam(); ;} break; case 427: -#line 4872 "Gmsh.y" +#line 4871 "Gmsh.y" { init_options(); ;} break; case 428: -#line 4874 "Gmsh.y" +#line 4873 "Gmsh.y" { std::vector<double> val(1, (yyvsp[(3) - (6)].d)); Msg::ExchangeOnelabParameter("", val, floatOptions, charOptions); @@ -12104,12 +12103,12 @@ yyreduce: break; case 429: -#line 4880 "Gmsh.y" +#line 4879 "Gmsh.y" { (yyval.d) = (yyvsp[(1) - (1)].d); ;} break; case 430: -#line 4882 "Gmsh.y" +#line 4881 "Gmsh.y" { (yyval.d) = Msg::GetOnelabNumber((yyvsp[(3) - (4)].c)); Free((yyvsp[(3) - (4)].c)); @@ -12117,7 +12116,7 @@ yyreduce: break; case 431: -#line 4887 "Gmsh.y" +#line 4886 "Gmsh.y" { (yyval.d) = Msg::GetOnelabNumber((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].d)); Free((yyvsp[(3) - (6)].c)); @@ -12125,56 +12124,56 @@ yyreduce: break; case 432: -#line 4892 "Gmsh.y" +#line 4891 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_Float((yyvsp[(1) - (1)].c2).char1, (yyvsp[(1) - (1)].c2).char2); ;} break; case 433: -#line 4897 "Gmsh.y" +#line 4896 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_Float(NULL, (yyvsp[(1) - (4)].c), 2, (int)(yyvsp[(3) - (4)].d)); ;} break; case 434: -#line 4902 "Gmsh.y" +#line 4901 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_Float(NULL, (yyvsp[(1) - (4)].c), 2, (int)(yyvsp[(3) - (4)].d)); ;} break; case 435: -#line 4906 "Gmsh.y" +#line 4905 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_Float((yyvsp[(3) - (4)].c2).char1, (yyvsp[(3) - (4)].c2).char2, 1, 0, 0., 1); ;} break; case 436: -#line 4910 "Gmsh.y" +#line 4909 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float((yyvsp[(3) - (6)].c2).char1, (yyvsp[(3) - (6)].c2).char2, (yyvsp[(5) - (6)].c), 0, 0., 1); ;} break; case 437: -#line 4914 "Gmsh.y" +#line 4913 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_Float((yyvsp[(3) - (5)].c2).char1, (yyvsp[(3) - (5)].c2).char2, 1, 0, (yyvsp[(4) - (5)].d), 2); ;} break; case 438: -#line 4918 "Gmsh.y" +#line 4917 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float((yyvsp[(3) - (7)].c2).char1, (yyvsp[(3) - (7)].c2).char2, (yyvsp[(5) - (7)].c), 0, (yyvsp[(6) - (7)].d), 2); ;} break; case 439: -#line 4922 "Gmsh.y" +#line 4921 "Gmsh.y" { std::string tmp = FixRelativePath(gmsh_yyname, (yyvsp[(3) - (4)].c)); (yyval.d) = !StatFile(tmp); @@ -12183,7 +12182,7 @@ yyreduce: break; case 440: -#line 4928 "Gmsh.y" +#line 4927 "Gmsh.y" { if(gmsh_yysymbols.count((yyvsp[(2) - (4)].c))){ gmsh_yysymbol &s(gmsh_yysymbols[(yyvsp[(2) - (4)].c)]); @@ -12201,14 +12200,14 @@ yyreduce: break; case 441: -#line 4944 "Gmsh.y" +#line 4943 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float_getDim((yyvsp[(2) - (6)].c2).char1, (yyvsp[(2) - (6)].c2).char2, (yyvsp[(4) - (6)].c)); ;} break; case 442: -#line 4949 "Gmsh.y" +#line 4948 "Gmsh.y" { std::string struct_namespace((yyvsp[(3) - (4)].c)); (yyval.d) = (double)gmsh_yynamespaces[struct_namespace].size(); @@ -12217,7 +12216,7 @@ yyreduce: break; case 443: -#line 4955 "Gmsh.y" +#line 4954 "Gmsh.y" { std::string struct_namespace(std::string("")); (yyval.d) = (double)gmsh_yynamespaces[struct_namespace].size(); @@ -12225,7 +12224,7 @@ yyreduce: break; case 444: -#line 4961 "Gmsh.y" +#line 4960 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(1) - (2)].c))){ yymsg(0, "Unknown variable '%s'", (yyvsp[(1) - (2)].c)); @@ -12247,7 +12246,7 @@ yyreduce: break; case 445: -#line 4980 "Gmsh.y" +#line 4979 "Gmsh.y" { int index = (int)(yyvsp[(3) - (5)].d); if(!gmsh_yysymbols.count((yyvsp[(1) - (5)].c))){ @@ -12270,7 +12269,7 @@ yyreduce: break; case 446: -#line 5001 "Gmsh.y" +#line 5000 "Gmsh.y" { int index = (int)(yyvsp[(3) - (5)].d); if(!gmsh_yysymbols.count((yyvsp[(1) - (5)].c))){ @@ -12293,49 +12292,49 @@ yyreduce: break; case 447: -#line 5034 "Gmsh.y" +#line 5033 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float(NULL, (yyvsp[(1) - (3)].c), (yyvsp[(3) - (3)].c)); ;} break; case 448: -#line 5038 "Gmsh.y" +#line 5037 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float((yyvsp[(1) - (5)].c), (yyvsp[(3) - (5)].c), (yyvsp[(5) - (5)].c)); ;} break; case 449: -#line 5043 "Gmsh.y" +#line 5042 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float(NULL, (yyvsp[(1) - (6)].c), (yyvsp[(3) - (6)].c), (int)(yyvsp[(5) - (6)].d)); ;} break; case 450: -#line 5047 "Gmsh.y" +#line 5046 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float((yyvsp[(1) - (8)].c), (yyvsp[(3) - (8)].c), (yyvsp[(5) - (8)].c), (int)(yyvsp[(7) - (8)].d)); ;} break; case 451: -#line 5051 "Gmsh.y" +#line 5050 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float(NULL, (yyvsp[(1) - (6)].c), (yyvsp[(3) - (6)].c), (int)(yyvsp[(5) - (6)].d)); ;} break; case 452: -#line 5055 "Gmsh.y" +#line 5054 "Gmsh.y" { (yyval.d) = treat_Struct_FullName_dot_tSTRING_Float((yyvsp[(1) - (8)].c), (yyvsp[(3) - (8)].c), (yyvsp[(5) - (8)].c), (int)(yyvsp[(7) - (8)].d)); ;} break; case 453: -#line 5060 "Gmsh.y" +#line 5059 "Gmsh.y" { NumberOption(GMSH_GET, (yyvsp[(1) - (6)].c), (int)(yyvsp[(3) - (6)].d), (yyvsp[(6) - (6)].c), (yyval.d)); Free((yyvsp[(1) - (6)].c)); Free((yyvsp[(6) - (6)].c)); @@ -12343,7 +12342,7 @@ yyreduce: break; case 454: -#line 5065 "Gmsh.y" +#line 5064 "Gmsh.y" { double d = 0.; if(NumberOption(GMSH_GET, (yyvsp[(1) - (4)].c), 0, (yyvsp[(3) - (4)].c), d)){ @@ -12356,7 +12355,7 @@ yyreduce: break; case 455: -#line 5075 "Gmsh.y" +#line 5074 "Gmsh.y" { double d = 0.; if(NumberOption(GMSH_GET, (yyvsp[(1) - (7)].c), (int)(yyvsp[(3) - (7)].d), (yyvsp[(6) - (7)].c), d)){ @@ -12369,7 +12368,7 @@ yyreduce: break; case 456: -#line 5085 "Gmsh.y" +#line 5084 "Gmsh.y" { (yyval.d) = Msg::GetValue((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].d)); Free((yyvsp[(3) - (6)].c)); @@ -12377,7 +12376,7 @@ yyreduce: break; case 457: -#line 5090 "Gmsh.y" +#line 5089 "Gmsh.y" { int matches = 0; for(int i = 0; i < List_Nbr((yyvsp[(3) - (6)].l)); i++){ @@ -12391,7 +12390,7 @@ yyreduce: break; case 458: -#line 5101 "Gmsh.y" +#line 5100 "Gmsh.y" { std::string s((yyvsp[(3) - (6)].c)), substr((yyvsp[(5) - (6)].c)); if(s.find(substr) != std::string::npos) @@ -12403,7 +12402,7 @@ yyreduce: break; case 459: -#line 5110 "Gmsh.y" +#line 5109 "Gmsh.y" { (yyval.d) = strlen((yyvsp[(3) - (4)].c)); Free((yyvsp[(3) - (4)].c)); @@ -12411,7 +12410,7 @@ yyreduce: break; case 460: -#line 5115 "Gmsh.y" +#line 5114 "Gmsh.y" { (yyval.d) = strcmp((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].c)); Free((yyvsp[(3) - (6)].c)); Free((yyvsp[(5) - (6)].c)); @@ -12419,7 +12418,7 @@ yyreduce: break; case 461: -#line 5120 "Gmsh.y" +#line 5119 "Gmsh.y" { int align = 0, font = 0, fontsize = CTX::instance()->glFontSize; if(List_Nbr((yyvsp[(3) - (4)].l)) % 2){ @@ -12446,27 +12445,27 @@ yyreduce: break; case 462: -#line 5147 "Gmsh.y" +#line 5146 "Gmsh.y" { (yyval.d) = 0.; ;} break; case 463: -#line 5149 "Gmsh.y" +#line 5148 "Gmsh.y" { (yyval.d) = (yyvsp[(2) - (2)].d);;} break; case 464: -#line 5154 "Gmsh.y" +#line 5153 "Gmsh.y" { (yyval.c) = NULL; ;} break; case 465: -#line 5156 "Gmsh.y" +#line 5155 "Gmsh.y" { (yyval.c) = (yyvsp[(2) - (2)].c);;} break; case 466: -#line 5161 "Gmsh.y" +#line 5160 "Gmsh.y" { std::string struct_namespace((yyvsp[(2) - (3)].c2).char1? (yyvsp[(2) - (3)].c2).char1 : std::string("")), struct_name((yyvsp[(2) - (3)].c2).char2); @@ -12476,7 +12475,7 @@ yyreduce: break; case 467: -#line 5168 "Gmsh.y" +#line 5167 "Gmsh.y" { std::string struct_namespace((yyvsp[(2) - (7)].c2).char1? (yyvsp[(2) - (7)].c2).char1 : std::string("")), struct_name((yyvsp[(2) - (7)].c2).char2); @@ -12492,105 +12491,105 @@ yyreduce: break; case 468: -#line 5184 "Gmsh.y" +#line 5183 "Gmsh.y" { (yyval.c2).char1 = NULL; (yyval.c2).char2 = (yyvsp[(1) - (1)].c); ;} break; case 469: -#line 5186 "Gmsh.y" +#line 5185 "Gmsh.y" { (yyval.c2).char1 = (yyvsp[(1) - (3)].c); (yyval.c2).char2 = (yyvsp[(3) - (3)].c); ;} break; case 470: -#line 5191 "Gmsh.y" +#line 5190 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); flag_tSTRING_alloc = 1; ;} break; case 471: -#line 5200 "Gmsh.y" +#line 5199 "Gmsh.y" { (yyval.i) = 99; ;} break; case 472: -#line 5202 "Gmsh.y" +#line 5201 "Gmsh.y" { (yyval.i) = (int)(yyvsp[(2) - (2)].d); ;} break; case 473: -#line 5207 "Gmsh.y" +#line 5206 "Gmsh.y" { (yyval.i) = 0; ;} break; case 474: -#line 5209 "Gmsh.y" +#line 5208 "Gmsh.y" { (yyval.i) = (yyvsp[(2) - (3)].i); ;} break; case 475: -#line 5215 "Gmsh.y" +#line 5214 "Gmsh.y" { memcpy((yyval.v), (yyvsp[(1) - (1)].v), 5*sizeof(double)); ;} break; case 476: -#line 5219 "Gmsh.y" +#line 5218 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = -(yyvsp[(2) - (2)].v)[i]; ;} break; case 477: -#line 5223 "Gmsh.y" +#line 5222 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = (yyvsp[(2) - (2)].v)[i]; ;} break; case 478: -#line 5227 "Gmsh.y" +#line 5226 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = (yyvsp[(1) - (3)].v)[i] - (yyvsp[(3) - (3)].v)[i]; ;} break; case 479: -#line 5231 "Gmsh.y" +#line 5230 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = (yyvsp[(1) - (3)].v)[i] + (yyvsp[(3) - (3)].v)[i]; ;} break; case 480: -#line 5238 "Gmsh.y" +#line 5237 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (11)].d); (yyval.v)[1] = (yyvsp[(4) - (11)].d); (yyval.v)[2] = (yyvsp[(6) - (11)].d); (yyval.v)[3] = (yyvsp[(8) - (11)].d); (yyval.v)[4] = (yyvsp[(10) - (11)].d); ;} break; case 481: -#line 5242 "Gmsh.y" +#line 5241 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (9)].d); (yyval.v)[1] = (yyvsp[(4) - (9)].d); (yyval.v)[2] = (yyvsp[(6) - (9)].d); (yyval.v)[3] = (yyvsp[(8) - (9)].d); (yyval.v)[4] = 1.0; ;} break; case 482: -#line 5246 "Gmsh.y" +#line 5245 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (7)].d); (yyval.v)[1] = (yyvsp[(4) - (7)].d); (yyval.v)[2] = (yyvsp[(6) - (7)].d); (yyval.v)[3] = 0.0; (yyval.v)[4] = 1.0; ;} break; case 483: -#line 5250 "Gmsh.y" +#line 5249 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (7)].d); (yyval.v)[1] = (yyvsp[(4) - (7)].d); (yyval.v)[2] = (yyvsp[(6) - (7)].d); (yyval.v)[3] = 0.0; (yyval.v)[4] = 1.0; ;} break; case 484: -#line 5257 "Gmsh.y" +#line 5256 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(List_T*)); List_Add((yyval.l), &((yyvsp[(1) - (1)].l))); @@ -12598,14 +12597,14 @@ yyreduce: break; case 485: -#line 5262 "Gmsh.y" +#line 5261 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].l))); ;} break; case 486: -#line 5269 "Gmsh.y" +#line 5268 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); List_Add((yyval.l), &((yyvsp[(1) - (1)].d))); @@ -12613,14 +12612,14 @@ yyreduce: break; case 487: -#line 5274 "Gmsh.y" +#line 5273 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 488: -#line 5278 "Gmsh.y" +#line 5277 "Gmsh.y" { // creates an empty list (yyval.l) = List_Create(2, 1, sizeof(double)); @@ -12628,14 +12627,14 @@ yyreduce: break; case 489: -#line 5283 "Gmsh.y" +#line 5282 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (3)].l); ;} break; case 490: -#line 5287 "Gmsh.y" +#line 5286 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (4)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ @@ -12646,7 +12645,7 @@ yyreduce: break; case 491: -#line 5295 "Gmsh.y" +#line 5294 "Gmsh.y" { (yyval.l) = (yyvsp[(4) - (5)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ @@ -12657,14 +12656,14 @@ yyreduce: break; case 492: -#line 5306 "Gmsh.y" +#line 5305 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 493: -#line 5310 "Gmsh.y" +#line 5309 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (1)].c), "*") || !strcmp((yyvsp[(1) - (1)].c), "all")) (yyval.l) = 0; @@ -12676,7 +12675,7 @@ yyreduce: break; case 494: -#line 5322 "Gmsh.y" +#line 5321 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (2)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ @@ -12687,7 +12686,7 @@ yyreduce: break; case 495: -#line 5330 "Gmsh.y" +#line 5329 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (3)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ @@ -12698,7 +12697,7 @@ yyreduce: break; case 496: -#line 5338 "Gmsh.y" +#line 5337 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); for(double d = (yyvsp[(1) - (3)].d); ((yyvsp[(1) - (3)].d) < (yyvsp[(3) - (3)].d)) ? (d <= (yyvsp[(3) - (3)].d)) : (d >= (yyvsp[(3) - (3)].d)); @@ -12708,7 +12707,7 @@ yyreduce: break; case 497: -#line 5345 "Gmsh.y" +#line 5344 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!(yyvsp[(5) - (5)].d)){ //|| ($1 < $3 && $5 < 0) || ($1 > $3 && $5 > 0) @@ -12721,7 +12720,7 @@ yyreduce: break; case 498: -#line 5355 "Gmsh.y" +#line 5354 "Gmsh.y" { (yyval.l) = List_Create(3, 1, sizeof(double)); int tag = (int)(yyvsp[(3) - (4)].d); @@ -12747,7 +12746,7 @@ yyreduce: break; case 499: -#line 5378 "Gmsh.y" +#line 5377 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getAllElementaryTags(0, (yyval.l)); @@ -12756,7 +12755,7 @@ yyreduce: break; case 500: -#line 5384 "Gmsh.y" +#line 5383 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getAllElementaryTags(1, (yyval.l)); @@ -12765,7 +12764,7 @@ yyreduce: break; case 501: -#line 5390 "Gmsh.y" +#line 5389 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getAllElementaryTags(2, (yyval.l)); @@ -12774,7 +12773,7 @@ yyreduce: break; case 502: -#line 5396 "Gmsh.y" +#line 5395 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getAllElementaryTags(3, (yyval.l)); @@ -12783,7 +12782,7 @@ yyreduce: break; case 503: -#line 5402 "Gmsh.y" +#line 5401 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); if(!(yyvsp[(3) - (3)].l)){ @@ -12797,7 +12796,7 @@ yyreduce: break; case 504: -#line 5413 "Gmsh.y" +#line 5412 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); if(!(yyvsp[(3) - (3)].l)){ @@ -12811,7 +12810,7 @@ yyreduce: break; case 505: -#line 5424 "Gmsh.y" +#line 5423 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); if(!(yyvsp[(3) - (3)].l)){ @@ -12825,7 +12824,7 @@ yyreduce: break; case 506: -#line 5435 "Gmsh.y" +#line 5434 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); if(!(yyvsp[(3) - (3)].l)){ @@ -12839,7 +12838,7 @@ yyreduce: break; case 507: -#line 5447 "Gmsh.y" +#line 5446 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getElementaryTagsInBoundingBox(0, (yyvsp[(5) - (16)].d), (yyvsp[(7) - (16)].d), (yyvsp[(9) - (16)].d), (yyvsp[(11) - (16)].d), (yyvsp[(13) - (16)].d), (yyvsp[(15) - (16)].d), (yyval.l)); @@ -12847,7 +12846,7 @@ yyreduce: break; case 508: -#line 5453 "Gmsh.y" +#line 5452 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getElementaryTagsInBoundingBox(1, (yyvsp[(5) - (16)].d), (yyvsp[(7) - (16)].d), (yyvsp[(9) - (16)].d), (yyvsp[(11) - (16)].d), (yyvsp[(13) - (16)].d), (yyvsp[(15) - (16)].d), (yyval.l)); @@ -12855,7 +12854,7 @@ yyreduce: break; case 509: -#line 5459 "Gmsh.y" +#line 5458 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getElementaryTagsInBoundingBox(2, (yyvsp[(5) - (16)].d), (yyvsp[(7) - (16)].d), (yyvsp[(9) - (16)].d), (yyvsp[(11) - (16)].d), (yyvsp[(13) - (16)].d), (yyvsp[(15) - (16)].d), (yyval.l)); @@ -12863,7 +12862,7 @@ yyreduce: break; case 510: -#line 5465 "Gmsh.y" +#line 5464 "Gmsh.y" { (yyval.l) = List_Create(10, 10, sizeof(double)); getElementaryTagsInBoundingBox(3, (yyvsp[(5) - (16)].d), (yyvsp[(7) - (16)].d), (yyvsp[(9) - (16)].d), (yyvsp[(11) - (16)].d), (yyvsp[(13) - (16)].d), (yyvsp[(15) - (16)].d), (yyval.l)); @@ -12871,7 +12870,7 @@ yyreduce: break; case 511: -#line 5470 "Gmsh.y" +#line 5469 "Gmsh.y" { (yyval.l) = List_Create(List_Nbr((yyvsp[(1) - (1)].l)), 1, sizeof(double)); for(int i = 0; i < List_Nbr((yyvsp[(1) - (1)].l)); i++){ @@ -12884,7 +12883,7 @@ yyreduce: break; case 512: -#line 5480 "Gmsh.y" +#line 5479 "Gmsh.y" { (yyval.l) = List_Create(List_Nbr((yyvsp[(1) - (1)].l)), 1, sizeof(double)); for(int i = 0; i < List_Nbr((yyvsp[(1) - (1)].l)); i++){ @@ -12897,7 +12896,7 @@ yyreduce: break; case 513: -#line 5490 "Gmsh.y" +#line 5489 "Gmsh.y" { (yyval.l) = List_Create(List_Nbr((yyvsp[(1) - (1)].l)), 1, sizeof(double)); for(int i = 0; i < List_Nbr((yyvsp[(1) - (1)].l)); i++){ @@ -12910,7 +12909,7 @@ yyreduce: break; case 514: -#line 5500 "Gmsh.y" +#line 5499 "Gmsh.y" { (yyval.l) = List_Create(20, 20, sizeof(double)); if(!gmsh_yysymbols.count((yyvsp[(1) - (3)].c))) @@ -12925,21 +12924,21 @@ yyreduce: break; case 515: -#line 5513 "Gmsh.y" +#line 5512 "Gmsh.y" { (yyval.l) = treat_Struct_FullName_dot_tSTRING_ListOfFloat(NULL, (yyvsp[(1) - (5)].c), (yyvsp[(3) - (5)].c)); ;} break; case 516: -#line 5517 "Gmsh.y" +#line 5516 "Gmsh.y" { (yyval.l) = treat_Struct_FullName_dot_tSTRING_ListOfFloat((yyvsp[(1) - (7)].c), (yyvsp[(3) - (7)].c), (yyvsp[(5) - (7)].c)); ;} break; case 517: -#line 5523 "Gmsh.y" +#line 5522 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!gmsh_yysymbols.count((yyvsp[(3) - (4)].c))) @@ -12954,28 +12953,28 @@ yyreduce: break; case 518: -#line 5535 "Gmsh.y" +#line 5534 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (4)].l); ;} break; case 519: -#line 5539 "Gmsh.y" +#line 5538 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (4)].l); ;} break; case 520: -#line 5543 "Gmsh.y" +#line 5542 "Gmsh.y" { (yyval.l) = (yyvsp[(4) - (6)].l); ;} break; case 521: -#line 5547 "Gmsh.y" +#line 5546 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!gmsh_yysymbols.count((yyvsp[(1) - (6)].c))) @@ -12996,7 +12995,7 @@ yyreduce: break; case 522: -#line 5565 "Gmsh.y" +#line 5564 "Gmsh.y" { (yyval.l) = List_Create(20,20,sizeof(double)); for(int i = 0; i < (int)(yyvsp[(7) - (8)].d); i++) { @@ -13007,7 +13006,7 @@ yyreduce: break; case 523: -#line 5573 "Gmsh.y" +#line 5572 "Gmsh.y" { (yyval.l) = List_Create(20,20,sizeof(double)); for(int i = 0; i < (int)(yyvsp[(7) - (8)].d); i++) { @@ -13018,7 +13017,7 @@ yyreduce: break; case 524: -#line 5581 "Gmsh.y" +#line 5580 "Gmsh.y" { Msg::Barrier(); FILE *File; @@ -13050,7 +13049,7 @@ yyreduce: break; case 525: -#line 5610 "Gmsh.y" +#line 5609 "Gmsh.y" { double x0 = (yyvsp[(3) - (14)].d), x1 = (yyvsp[(5) - (14)].d), y0 = (yyvsp[(7) - (14)].d), y1 = (yyvsp[(9) - (14)].d), ys = (yyvsp[(11) - (14)].d); int N = (int)(yyvsp[(13) - (14)].d); @@ -13063,7 +13062,7 @@ yyreduce: break; case 526: -#line 5620 "Gmsh.y" +#line 5619 "Gmsh.y" { std::vector<double> tmp; for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ @@ -13082,7 +13081,7 @@ yyreduce: break; case 527: -#line 5636 "Gmsh.y" +#line 5635 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ double *d = (double*)List_Pointer((yyvsp[(3) - (4)].l), i); @@ -13093,7 +13092,7 @@ yyreduce: break; case 528: -#line 5647 "Gmsh.y" +#line 5646 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); List_Add((yyval.l), &((yyvsp[(1) - (1)].d))); @@ -13101,21 +13100,21 @@ yyreduce: break; case 529: -#line 5652 "Gmsh.y" +#line 5651 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 530: -#line 5656 "Gmsh.y" +#line 5655 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].d))); ;} break; case 531: -#line 5660 "Gmsh.y" +#line 5659 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (3)].l)); i++){ double d; @@ -13127,21 +13126,21 @@ yyreduce: break; case 532: -#line 5672 "Gmsh.y" +#line 5671 "Gmsh.y" { (yyval.u) = CTX::instance()->packColor((int)(yyvsp[(2) - (9)].d), (int)(yyvsp[(4) - (9)].d), (int)(yyvsp[(6) - (9)].d), (int)(yyvsp[(8) - (9)].d)); ;} break; case 533: -#line 5676 "Gmsh.y" +#line 5675 "Gmsh.y" { (yyval.u) = CTX::instance()->packColor((int)(yyvsp[(2) - (7)].d), (int)(yyvsp[(4) - (7)].d), (int)(yyvsp[(6) - (7)].d), 255); ;} break; case 534: -#line 5688 "Gmsh.y" +#line 5687 "Gmsh.y" { int flag = 0; if(gmsh_yystringsymbols.count((yyvsp[(1) - (1)].c))){ @@ -13161,7 +13160,7 @@ yyreduce: break; case 535: -#line 5705 "Gmsh.y" +#line 5704 "Gmsh.y" { unsigned int val = 0; ColorOption(GMSH_GET, (yyvsp[(1) - (5)].c), 0, (yyvsp[(5) - (5)].c), val); @@ -13171,14 +13170,14 @@ yyreduce: break; case 536: -#line 5715 "Gmsh.y" +#line 5714 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (3)].l); ;} break; case 537: -#line 5719 "Gmsh.y" +#line 5718 "Gmsh.y" { (yyval.l) = List_Create(256, 10, sizeof(unsigned int)); GmshColorTable *ct = GetColorTable((int)(yyvsp[(3) - (6)].d)); @@ -13193,7 +13192,7 @@ yyreduce: break; case 538: -#line 5734 "Gmsh.y" +#line 5733 "Gmsh.y" { (yyval.l) = List_Create(256, 10, sizeof(unsigned int)); List_Add((yyval.l), &((yyvsp[(1) - (1)].u))); @@ -13201,21 +13200,21 @@ yyreduce: break; case 539: -#line 5739 "Gmsh.y" +#line 5738 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].u))); ;} break; case 540: -#line 5746 "Gmsh.y" +#line 5745 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); ;} break; case 541: -#line 5750 "Gmsh.y" +#line 5749 "Gmsh.y" { // No need to extend to Struct_FullName (a Tag is not a String) (yyval.c) = treat_Struct_FullName_String(NULL, (yyvsp[(1) - (1)].c)); @@ -13223,7 +13222,7 @@ yyreduce: break; case 542: -#line 5755 "Gmsh.y" +#line 5754 "Gmsh.y" { std::string val; int j = (int)(yyvsp[(3) - (4)].d); @@ -13240,7 +13239,7 @@ yyreduce: break; case 543: -#line 5769 "Gmsh.y" +#line 5768 "Gmsh.y" { std::string val; int j = (int)(yyvsp[(3) - (4)].d); @@ -13257,35 +13256,35 @@ yyreduce: break; case 544: -#line 5786 "Gmsh.y" +#line 5785 "Gmsh.y" { (yyval.c) = treat_Struct_FullName_dot_tSTRING_String(NULL, (yyvsp[(1) - (3)].c), (yyvsp[(3) - (3)].c)); ;} break; case 545: -#line 5790 "Gmsh.y" +#line 5789 "Gmsh.y" { (yyval.c) = treat_Struct_FullName_dot_tSTRING_String((yyvsp[(1) - (5)].c), (yyvsp[(3) - (5)].c), (yyvsp[(5) - (5)].c)); ;} break; case 546: -#line 5795 "Gmsh.y" +#line 5794 "Gmsh.y" { (yyval.c) = treat_Struct_FullName_dot_tSTRING_String(NULL, (yyvsp[(1) - (6)].c), (yyvsp[(3) - (6)].c), (int)(yyvsp[(5) - (6)].d)); ;} break; case 547: -#line 5799 "Gmsh.y" +#line 5798 "Gmsh.y" { (yyval.c) = treat_Struct_FullName_dot_tSTRING_String((yyvsp[(1) - (8)].c), (yyvsp[(3) - (8)].c), (yyvsp[(5) - (8)].c), (int)(yyvsp[(7) - (8)].d)); ;} break; case 548: -#line 5804 "Gmsh.y" +#line 5803 "Gmsh.y" { std::string out; StringOption(GMSH_GET, (yyvsp[(1) - (6)].c), (int)(yyvsp[(3) - (6)].d), (yyvsp[(6) - (6)].c), out); @@ -13296,7 +13295,7 @@ yyreduce: break; case 549: -#line 5812 "Gmsh.y" +#line 5811 "Gmsh.y" { std::string name = GModel::current()->getPhysicalName(0, (int)(yyvsp[(4) - (5)].d)); (yyval.c) = (char*)Malloc((name.size() + 1) * sizeof(char)); @@ -13305,7 +13304,7 @@ yyreduce: break; case 550: -#line 5818 "Gmsh.y" +#line 5817 "Gmsh.y" { std::string name = GModel::current()->getPhysicalName(1, (int)(yyvsp[(4) - (5)].d)); (yyval.c) = (char*)Malloc((name.size() + 1) * sizeof(char)); @@ -13314,7 +13313,7 @@ yyreduce: break; case 551: -#line 5824 "Gmsh.y" +#line 5823 "Gmsh.y" { std::string name = GModel::current()->getPhysicalName(2, (int)(yyvsp[(4) - (5)].d)); (yyval.c) = (char*)Malloc((name.size() + 1) * sizeof(char)); @@ -13323,7 +13322,7 @@ yyreduce: break; case 552: -#line 5830 "Gmsh.y" +#line 5829 "Gmsh.y" { std::string name = GModel::current()->getPhysicalName(3, (int)(yyvsp[(4) - (5)].d)); (yyval.c) = (char*)Malloc((name.size() + 1) * sizeof(char)); @@ -13332,21 +13331,21 @@ yyreduce: break; case 553: -#line 5839 "Gmsh.y" +#line 5838 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); ;} break; case 554: -#line 5843 "Gmsh.y" +#line 5842 "Gmsh.y" { (yyval.c) = (yyvsp[(3) - (4)].c); ;} break; case 555: -#line 5847 "Gmsh.y" +#line 5846 "Gmsh.y" { (yyval.c) = (char *)Malloc(32 * sizeof(char)); time_t now; @@ -13357,7 +13356,7 @@ yyreduce: break; case 556: -#line 5855 "Gmsh.y" +#line 5854 "Gmsh.y" { std::string exe = Msg::GetExecutableName(); (yyval.c) = (char *)Malloc(exe.size() + 1); @@ -13366,7 +13365,7 @@ yyreduce: break; case 557: -#line 5861 "Gmsh.y" +#line 5860 "Gmsh.y" { std::string action = Msg::GetOnelabAction(); (yyval.c) = (char *)Malloc(action.size() + 1); @@ -13375,14 +13374,14 @@ yyreduce: break; case 558: -#line 5867 "Gmsh.y" +#line 5866 "Gmsh.y" { (yyval.c) = strsave((char*)"Gmsh"); ;} break; case 559: -#line 5871 "Gmsh.y" +#line 5870 "Gmsh.y" { const char *env = GetEnvironmentVar((yyvsp[(3) - (4)].c)); if(!env) env = ""; @@ -13393,7 +13392,7 @@ yyreduce: break; case 560: -#line 5879 "Gmsh.y" +#line 5878 "Gmsh.y" { std::string s = Msg::GetString((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].c)); (yyval.c) = (char *)Malloc((s.size() + 1) * sizeof(char)); @@ -13404,7 +13403,7 @@ yyreduce: break; case 561: -#line 5887 "Gmsh.y" +#line 5886 "Gmsh.y" { std::string s = Msg::GetOnelabString((yyvsp[(3) - (4)].c)); (yyval.c) = (char *)Malloc((s.size() + 1) * sizeof(char)); @@ -13414,7 +13413,7 @@ yyreduce: break; case 562: -#line 5894 "Gmsh.y" +#line 5893 "Gmsh.y" { std::string s = Msg::GetOnelabString((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].c)); (yyval.c) = (char *)Malloc((s.size() + 1) * sizeof(char)); @@ -13425,21 +13424,21 @@ yyreduce: break; case 563: -#line 5904 "Gmsh.y" +#line 5903 "Gmsh.y" { (yyval.c) = treat_Struct_FullName_String(NULL, (yyvsp[(3) - (5)].c2).char2, 1, 0, (yyvsp[(4) - (5)].c), 2); ;} break; case 564: -#line 5909 "Gmsh.y" +#line 5908 "Gmsh.y" { (yyval.c) = treat_Struct_FullName_dot_tSTRING_String((yyvsp[(3) - (7)].c2).char1, (yyvsp[(3) - (7)].c2).char2, (yyvsp[(5) - (7)].c), 0, (yyvsp[(6) - (7)].c), 2); ;} break; case 565: -#line 5914 "Gmsh.y" +#line 5913 "Gmsh.y" { int size = 1; for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++) @@ -13457,7 +13456,7 @@ yyreduce: break; case 566: -#line 5929 "Gmsh.y" +#line 5928 "Gmsh.y" { (yyval.c) = (char *)Malloc((strlen((yyvsp[(3) - (4)].c)) + 1) * sizeof(char)); int i; @@ -13474,7 +13473,7 @@ yyreduce: break; case 567: -#line 5943 "Gmsh.y" +#line 5942 "Gmsh.y" { (yyval.c) = (char *)Malloc((strlen((yyvsp[(3) - (4)].c)) + 1) * sizeof(char)); int i; @@ -13491,7 +13490,7 @@ yyreduce: break; case 568: -#line 5957 "Gmsh.y" +#line 5956 "Gmsh.y" { std::string input = (yyvsp[(3) - (8)].c); std::string substr_old = (yyvsp[(5) - (8)].c); @@ -13506,7 +13505,7 @@ yyreduce: break; case 569: -#line 5969 "Gmsh.y" +#line 5968 "Gmsh.y" { int size = 1; for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++) @@ -13525,7 +13524,7 @@ yyreduce: break; case 570: -#line 5985 "Gmsh.y" +#line 5984 "Gmsh.y" { int i = 0; while ((yyvsp[(3) - (4)].c)[i]) { @@ -13537,7 +13536,7 @@ yyreduce: break; case 571: -#line 5994 "Gmsh.y" +#line 5993 "Gmsh.y" { int i = 0; while ((yyvsp[(3) - (4)].c)[i]) { @@ -13549,7 +13548,7 @@ yyreduce: break; case 572: -#line 6003 "Gmsh.y" +#line 6002 "Gmsh.y" { int i = 0; while ((yyvsp[(3) - (4)].c)[i]) { @@ -13562,7 +13561,7 @@ yyreduce: break; case 573: -#line 6013 "Gmsh.y" +#line 6012 "Gmsh.y" { if((yyvsp[(3) - (8)].d)){ (yyval.c) = (yyvsp[(5) - (8)].c); @@ -13576,7 +13575,7 @@ yyreduce: break; case 574: -#line 6024 "Gmsh.y" +#line 6023 "Gmsh.y" { std::string in = (yyvsp[(3) - (8)].c); std::string out = in.substr((int)(yyvsp[(5) - (8)].d), (int)(yyvsp[(7) - (8)].d)); @@ -13587,7 +13586,7 @@ yyreduce: break; case 575: -#line 6032 "Gmsh.y" +#line 6031 "Gmsh.y" { std::string in = (yyvsp[(3) - (6)].c); std::string out = in.substr((int)(yyvsp[(5) - (6)].d), std::string::npos); @@ -13598,14 +13597,14 @@ yyreduce: break; case 576: -#line 6040 "Gmsh.y" +#line 6039 "Gmsh.y" { (yyval.c) = (yyvsp[(3) - (4)].c); ;} break; case 577: -#line 6044 "Gmsh.y" +#line 6043 "Gmsh.y" { char tmpstring[5000]; int i = printListOfDouble((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].l), tmpstring); @@ -13627,7 +13626,7 @@ yyreduce: break; case 578: -#line 6063 "Gmsh.y" +#line 6062 "Gmsh.y" { std::string tmp = FixRelativePath(gmsh_yyname, (yyvsp[(3) - (4)].c)); (yyval.c) = (char*)Malloc((tmp.size() + 1) * sizeof(char)); @@ -13637,7 +13636,7 @@ yyreduce: break; case 579: -#line 6070 "Gmsh.y" +#line 6069 "Gmsh.y" { std::string tmp = SplitFileName(GetAbsolutePath(gmsh_yyname))[0]; (yyval.c) = (char*)Malloc((tmp.size() + 1) * sizeof(char)); @@ -13646,7 +13645,7 @@ yyreduce: break; case 580: -#line 6076 "Gmsh.y" +#line 6075 "Gmsh.y" { std::string tmp = SplitFileName((yyvsp[(3) - (4)].c))[0]; (yyval.c) = (char*)Malloc((tmp.size() + 1) * sizeof(char)); @@ -13656,7 +13655,7 @@ yyreduce: break; case 581: -#line 6083 "Gmsh.y" +#line 6082 "Gmsh.y" { std::string tmp = GetAbsolutePath((yyvsp[(3) - (4)].c)); (yyval.c) = (char*)Malloc((tmp.size() + 1) * sizeof(char)); @@ -13666,12 +13665,12 @@ yyreduce: break; case 582: -#line 6090 "Gmsh.y" +#line 6089 "Gmsh.y" { init_options(); ;} break; case 583: -#line 6092 "Gmsh.y" +#line 6091 "Gmsh.y" { std::string val((yyvsp[(3) - (6)].c)); Msg::ExchangeOnelabParameter("", val, floatOptions, charOptions); @@ -13682,7 +13681,7 @@ yyreduce: break; case 584: -#line 6100 "Gmsh.y" +#line 6099 "Gmsh.y" { std::string out; const std::string * key_struct = NULL; @@ -13706,37 +13705,37 @@ yyreduce: break; case 585: -#line 6124 "Gmsh.y" +#line 6123 "Gmsh.y" { struct_namespace = std::string(""); (yyval.d) = (yyvsp[(2) - (2)].d); ;} break; case 586: -#line 6126 "Gmsh.y" +#line 6125 "Gmsh.y" { struct_namespace = (yyvsp[(1) - (4)].c); Free((yyvsp[(1) - (4)].c)); (yyval.d) = (yyvsp[(4) - (4)].d); ;} break; case 587: -#line 6132 "Gmsh.y" +#line 6131 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (4)].l); ;} break; case 588: -#line 6137 "Gmsh.y" +#line 6136 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 589: -#line 6139 "Gmsh.y" +#line 6138 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 590: -#line 6144 "Gmsh.y" +#line 6143 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (3)].l); ;} break; case 591: -#line 6149 "Gmsh.y" +#line 6148 "Gmsh.y" { (yyval.l) = List_Create(20,20,sizeof(char*)); List_Add((yyval.l), &((yyvsp[(1) - (1)].c))); @@ -13744,19 +13743,19 @@ yyreduce: break; case 592: -#line 6154 "Gmsh.y" +#line 6153 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 593: -#line 6156 "Gmsh.y" +#line 6155 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].c))); ;} break; case 594: -#line 6160 "Gmsh.y" +#line 6159 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (3)].l)); i++){ char* c; @@ -13768,7 +13767,7 @@ yyreduce: break; case 595: -#line 6172 "Gmsh.y" +#line 6171 "Gmsh.y" { (yyval.l) = List_Create(20, 20, sizeof(char *)); if(!gmsh_yystringsymbols.count((yyvsp[(1) - (3)].c))) @@ -13785,21 +13784,21 @@ yyreduce: break; case 596: -#line 6187 "Gmsh.y" +#line 6186 "Gmsh.y" { (yyval.l) = treat_Struct_FullName_dot_tSTRING_ListOfString(NULL, (yyvsp[(1) - (5)].c), (yyvsp[(3) - (5)].c)); ;} break; case 597: -#line 6192 "Gmsh.y" +#line 6191 "Gmsh.y" { (yyval.l) = treat_Struct_FullName_dot_tSTRING_ListOfString((yyvsp[(1) - (7)].c), (yyvsp[(3) - (7)].c), (yyvsp[(5) - (7)].c)); ;} break; case 598: -#line 6201 "Gmsh.y" +#line 6200 "Gmsh.y" { char tmpstr[256]; sprintf(tmpstr, "_%d", (int)(yyvsp[(4) - (5)].d)); @@ -13810,7 +13809,7 @@ yyreduce: break; case 599: -#line 6210 "Gmsh.y" +#line 6209 "Gmsh.y" { char tmpstr[256]; sprintf(tmpstr, "_%d", (int)(yyvsp[(4) - (5)].d)); @@ -13821,7 +13820,7 @@ yyreduce: break; case 600: -#line 6219 "Gmsh.y" +#line 6218 "Gmsh.y" { char tmpstr[256]; sprintf(tmpstr, "_%d", (int)(yyvsp[(7) - (8)].d)); @@ -13832,23 +13831,23 @@ yyreduce: break; case 601: -#line 6231 "Gmsh.y" +#line 6230 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); ;} break; case 602: -#line 6234 "Gmsh.y" +#line 6233 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); ;} break; case 603: -#line 6238 "Gmsh.y" +#line 6237 "Gmsh.y" { (yyval.c) = (yyvsp[(3) - (4)].c); ;} break; /* Line 1267 of yacc.c. */ -#line 13852 "Gmsh.tab.cpp" +#line 13851 "Gmsh.tab.cpp" default: break; } YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); @@ -14062,7 +14061,7 @@ yyreturn: } -#line 6241 "Gmsh.y" +#line 6240 "Gmsh.y" void assignVariable(const std::string &name, int index, int assignType, diff --git a/Parser/Gmsh.y b/Parser/Gmsh.y index 024d3cf5ec767ddc264d017f1cf0176d8b64c05a..15af36c10098d1e8ff2039ee9f34ebaf242e6ec3 100644 --- a/Parser/Gmsh.y +++ b/Parser/Gmsh.y @@ -2344,7 +2344,8 @@ Transform : ListOfShapes2VectorOfPairs($4, dimTags); bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ - Msg::Error("Symmetry not implemented yet with OpenCASCADE geometry kernel"); + r = GModel::current()->getOCCInternals()->symmetry + (dimTags, $2[0], $2[1], $2[2], $2[3]); } else{ r = GModel::current()->getGEOInternals()->symmetry @@ -2359,7 +2360,6 @@ Transform : ListOfShapes2VectorOfPairs($8, dimTags); bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ - yymsg(1, "Warning Dilate OCC: Dilatation (second argument) + Translation (first argument) "); r = GModel::current()->getOCCInternals()->dilate (dimTags, $3[0], $3[1], $3[2], $5, $5, $5); } @@ -2376,7 +2376,6 @@ Transform : ListOfShapes2VectorOfPairs($8, dimTags); bool r = true; if(gmsh_yyfactory == "OpenCASCADE" && GModel::current()->getOCCInternals()){ - yymsg(1, "Warning Dilate OCC: Dilatation (second argument) + Translation (first argument) "); r = GModel::current()->getOCCInternals()->dilate (dimTags, $3[0], $3[1], $3[2], $5[0], $5[1], $5[2]); } diff --git a/benchmarks/2d/raccord.geo b/benchmarks/2d/raccord.geo index 0951467d390a38cd68117d6a637e26467f0dadd5..0531a9fcd576aa86421b49cd6a47fc70967e3f68 100644 --- a/benchmarks/2d/raccord.geo +++ b/benchmarks/2d/raccord.geo @@ -1,4 +1,4 @@ -Include "raccord.phy"; +//Include "raccord.phy"; r1 = 30.; h1 = 100.; h2 = 150.; al0 = 30.; al1 = al0 / 180. * 3.1415; dd1 = 3.; diff --git a/doc/texinfo/gmsh.texi b/doc/texinfo/gmsh.texi index 3b690e660f0e86565aa5f123f1c7fbfe3b2a7424..9d57add35783491cd26ce351229588a0989415b1 100644 --- a/doc/texinfo/gmsh.texi +++ b/doc/texinfo/gmsh.texi @@ -2342,7 +2342,14 @@ below). The syntax of the transformation commands is: @item Dilate @{ @{ @var{expression-list} @}, @var{expression} @} @{ @var{transform-list} @} Scales all elementary entities in @var{transform-list} by a factor @var{expression}. The @var{expression-list} should contain three -@w{@var{expression}s} giving the X, Y and Z direction of the homothetic +@w{@var{expression}s} giving the X, Y, and Z coordinates of the center +of the homothetic transformation. + +@item Dilate @{ @{ @var{expression-list} @}, @{ @var{expression}, @var{expression}, @var{expression} @} @} @{ @var{transform-list} @} +Scales all elementary entities in @var{transform-list} using different +factors along X, Y and Z (the three @var{expression}s). The +@var{expression-list} should contain three @w{@var{expression}s} giving +the X, Y, and Z coordinates of the center of the homothetic transformation. @item Rotate @{ @{ @var{expression-list} @}, @{ @var{expression-list} @}, @var{expression} @} @{ @var{transform-list} @}