diff --git a/Common/DefaultOptions.h b/Common/DefaultOptions.h index eda386c866116dabd1eb7f15611a3b463488c36c..7d242b32f1acad25c6ac15b6505f607320ffca10 100644 --- a/Common/DefaultOptions.h +++ b/Common/DefaultOptions.h @@ -95,7 +95,7 @@ StringXString MeshOptions_String[] = { StringXString SolverOptions_String[] = { { F|O, "SocketName" , opt_solver_socket_name , #if defined(WIN32) && !defined(__CYGWIN__) - "localhost:44122" , // use TCP/IP sockets by default on Windows + "127.0.0.1:44122" , // use TCP/IP sockets by default on Windows #else ".gmshsock" , // otherwise use Unix sockets by default #endif diff --git a/Common/ListUtils.cpp b/Common/ListUtils.cpp index 7125a3526afd1b06839c738bcbe4fc0e57bac3f3..c12bed2f303827dd15586808508cf600c5113bbe 100644 --- a/Common/ListUtils.cpp +++ b/Common/ListUtils.cpp @@ -269,20 +269,24 @@ void List_Merge(List_T * a, List_T * b) } } -void List_Remove (List_T *a, int i){ - memcpy(&a->array[i*a->size], &a->array[(i+1)*a->size],a->size*(a->n-i-1)); +void List_Remove(List_T *a, int i) +{ + memcpy(&a->array[i * a->size], &a->array[(i + 1) * a->size], + a->size * (a->n - i - 1)); a->n--; } //insert a in b before i -void List_Insert_In_List (List_T *a, int i, List_T *b){ - int oldn=b->n; - b->n+=a->n; - List_Realloc(b,b->n); - for(int j=0;j<oldn-i;j++) - memcpy(List_Pointer_Fast(b,b->n-j-1),List_Pointer_Fast(b,oldn-j-1),b->size); - for(int j=0;j<a->n;j++) - memcpy(List_Pointer_Fast(b,oldn+j),List_Pointer_Fast(a,j),b->size); +void List_Insert_In_List(List_T *a, int i, List_T *b) +{ + int oldn = b->n; + b->n += a->n; + List_Realloc(b, b->n); + for(int j = 0; j < oldn - i; j++) + memcpy(List_Pointer_Fast(b, b->n - j - 1), List_Pointer_Fast(b, oldn - j - 1), + b->size); + for(int j = 0;j < a->n; j++) + memcpy(List_Pointer_Fast(b, oldn + j), List_Pointer_Fast(a, j), b->size); } void swap_bytes(char *array, int size, int n) diff --git a/Geo/GFace.cpp b/Geo/GFace.cpp index 619cc9727011381c3db74599a441f1ae17aebace..aa3d2e6dd97b128cc82159824375dce2297528f0 100644 --- a/Geo/GFace.cpp +++ b/Geo/GFace.cpp @@ -537,15 +537,13 @@ void GFace::XYZtoUV(const double X, const double Y, const double Z, V = Vnew; } - //printf("i=%d j=%d err=%g iter=%d err2=%g u=%.16g v=%.16g x=%g y=%g z=%g\n", - // i, j, err, iter, err2, U, V, X, Y, Z); - if(iter < MaxIter && err <= Precision && Unew <= umax && Vnew <= vmax && Unew >= umin && Vnew >= vmin){ if (onSurface && err2 > 1.e-4 * CTX.lc) - Msg::Warning("Converged for i=%d j=%d (err=%g iter=%d) BUT xyz error = %g in point (%e,%e,%e) on surface %d", - i, j, err, iter, err2,X,Y,Z,tag()); + Msg::Warning("Converged for i=%d j=%d (err=%g iter=%d) BUT " + "xyz error = %g in point (%e,%e,%e) on surface %d", + i, j, err, iter, err2, X, Y, Z, tag()); return; } } diff --git a/Post/shapeFunctions.h b/Post/shapeFunctions.h index 678fa8bc1475a765e3b34b843f2d4944507eefac..b7b491ba148a1a20b92faae492a86c4e0c346aa9 100644 --- a/Post/shapeFunctions.h +++ b/Post/shapeFunctions.h @@ -830,7 +830,6 @@ public: inline int getNumGaussPoints(){ return 8; } void getGaussPoint(int num, double &u, double &v, double &w, double &weight) { - //Integration points for old_pyramids double u8[8] = {0.2631840555694285,-0.2631840555694285, 0.2631840555694285,-0.2631840555694285, 0.5066163033492386,-0.5066163033492386, @@ -847,7 +846,6 @@ public: 0.100785882079825,0.100785882079825, 0.232547451253508,0.232547451253508, 0.232547451253508,0.232547451253508}; - if(num < 0 || num > 7) return; u = u8[num]; v = v8[num]; diff --git a/doc/VERSIONS.txt b/doc/VERSIONS.txt index d1075e49c365a194bb90b7e6235b2fd7d2c56740..f5649dacbd6d883ae88b5d884074987049b5bb93 100644 --- a/doc/VERSIONS.txt +++ b/doc/VERSIONS.txt @@ -1,8 +1,8 @@ -$Id: VERSIONS.txt,v 1.9 2008-10-21 16:37:24 geuzaine Exp $ +$Id: VERSIONS.txt,v 1.10 2008-10-25 07:39:15 geuzaine Exp $ -2.2.5 (xxx): better STL import; upgraded Netgen; gmsh now requires -FLTK >= 1.1.7; added support for Visual C++; fixed pyramid -interpolation; lots of small bug fixes. +2.2.5 (Oct 25, 2008): Gmsh now requires FLTK 1.1.7 or above; various +small improvements (STL and VTK mesh IO, Netgen upgrade, Visual C++ +support, Fields) and bug fixes (pyramid interpolation, Chaco crashes). 2.2.4 (Aug 14, 2008): integrated Metis and Chaco mesh partitioners; variables can now be deleted in geo files; added support for point diff --git a/doc/gmsh.html b/doc/gmsh.html index 8950669ad7c6c48e54f819c0eabdd909fa79b969..660dfc394b942a3a16705fcd73583688b8626629 100644 --- a/doc/gmsh.html +++ b/doc/gmsh.html @@ -25,7 +25,7 @@ generator with built-in pre- and post-processing facilities</h1> <p> <h3 align="center">Christophe Geuzaine and Jean-Fran�ois Remacle</h3> <p> -<h3 align=center>Version 2.2.4, August 14 2008</h3> +<h3 align=center>Version 2.2.5, October 25 2008</h3> <p> <center> <a href="#Description">Description</a> | @@ -67,10 +67,10 @@ binary). Tutorial and demos files are included in all the archives. <ul> <li> <strong>Current stable release</strong>: -<a href="/gmsh/bin/Windows/gmsh-2.2.4-Windows.zip"><strong>Windows</strong></a>, -<a href="/gmsh/bin/Linux/gmsh-2.2.4-Linux.tgz"><strong>Linux</strong></a>, -<a href="/gmsh/bin/MacOSX/gmsh-2.2.4-MacOSX.tgz"><strong>Mac OS X</strong></a> and -<a href="/gmsh/src/gmsh-2.2.4-source.tgz"><strong>source code</strong></a> +<a href="/gmsh/bin/Windows/gmsh-2.2.5-Windows.zip"><strong>Windows</strong></a>, +<a href="/gmsh/bin/Linux/gmsh-2.2.5-Linux.tgz"><strong>Linux</strong></a>, +<a href="/gmsh/bin/MacOSX/gmsh-2.2.5-MacOSX.tgz"><strong>Mac OS X</strong></a> and +<a href="/gmsh/src/gmsh-2.2.5-source.tgz"><strong>source code</strong></a> <a href="#build-footnote" name="build-footmark"><sup>2</sup></a> <p> <li>Experimental versions (these might be buggy, or might not even diff --git a/doc/texinfo/opt_mesh.texi b/doc/texinfo/opt_mesh.texi index d5b652eafee60535ed9cd3b624a1b6459dc86973..8854a29bb497a87cb4ba22b32e88f721110dc494 100644 --- a/doc/texinfo/opt_mesh.texi +++ b/doc/texinfo/opt_mesh.texi @@ -29,6 +29,11 @@ Field format for Nastran BDF files (0=free, 1=small, 2=large)@* Default value: @code{1}@* Saved in: @code{General.OptionsFileName} +@item Mesh.Binary +Write mesh files in binary format (if possible)@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + @item Mesh.C1Continuity Impose C1 continuity to high order meshes (only valid in 2D plane and ElemenOrder = 2)@* Default value: @code{0}@* @@ -254,11 +259,6 @@ Minimum number of points used to mesh a (non-straight) curve@* Default value: @code{3}@* Saved in: @code{General.OptionsFileName} -@item Mesh.MshBinary -Write MSH files in binary format?@* -Default value: @code{0}@* -Saved in: @code{General.OptionsFileName} - @item Mesh.MshFileVersion Version of the MSH file format to use@* Default value: @code{2}@* @@ -454,11 +454,6 @@ Smooth the mesh normals?@* Default value: @code{0}@* Saved in: @code{General.OptionsFileName} -@item Mesh.StlBinary -Save STL files in binary format?@* -Default value: @code{0}@* -Saved in: @code{General.OptionsFileName} - @item Mesh.SurfaceEdges Display edges of surface mesh?@* Default value: @code{1}@* diff --git a/doc/texinfo/opt_plugin.texi b/doc/texinfo/opt_plugin.texi index 240985f23fa338ae196936a1c8dcb8e17e716c41..4a38dc15ba049fe0d89647bdf54d26188aacf146 100644 --- a/doc/texinfo/opt_plugin.texi +++ b/doc/texinfo/opt_plugin.texi @@ -547,6 +547,19 @@ Default value: @code{2} Default value: @code{-1} @end table +@item Plugin(LongitudeLatitude) +Plugin(LongituteLatitude) Project the view `iView' +in Longitude-Latitude. If `iView' < 0, the plugin +is run on the current view. + +Plugin(LongituteLatitude) is executed in place. + +Numeric options: +@table @code +@item iView +Default value: @code{-1} +@end table + @item Plugin(MakeSimplex) Plugin(MakeSimplex) decomposes all non- simplectic elements (quadrangles, prisms, @@ -807,27 +820,6 @@ Default value: @code{0} Default value: @code{-1} @end table -@item Plugin(TransformLatLon) -Plugin(TransformLatLon) transforms the homogeneous -node coordinates (x,y,z,1) of the elements in -the view `iView' by the matrix -[`A11' `A12' `A13' `Tx'] -[`A21' `A22' `A23' `Ty'] -[`A31' `A32' `A33' `Tz']. -If `SwapOrientation' is set, the orientation of the -elements is reversed. If `iView' < 0, the plugin -is run on the current view. - -Plugin(TransformLatLon) is executed in-place. - -Numeric options: -@table @code -@item iView -Default value: @code{-1} -@item Longitude0 -Default value: @code{0} -@end table - @item Plugin(Triangulate) Plugin(Triangulate) triangulates the points in the view `iView', assuming that all the points belong diff --git a/utils/solvers/c++/GmshSocket.h b/utils/solvers/c++/GmshSocket.h index 5bf280b7d1d65103769584ba08d0d62d7cac6314..3495ebe9a81b6a2db3fefcfdaa6367dad91832ae 100644 --- a/utils/solvers/c++/GmshSocket.h +++ b/utils/solvers/c++/GmshSocket.h @@ -214,7 +214,7 @@ class GmshClient : public GmshSocket { if(_sock < 0) return -1; // Error: Couldn't create socket // try to connect socket to host:port - char *port = strstr(sockname, ":"); + const char *port = strstr(sockname, ":"); int portno = atoi(port + 1); int remotelen = strlen(sockname) - strlen(port); char remote[256];