Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Larry Price
gmsh
Commits
05ff8244
Commit
05ff8244
authored
24 years ago
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
*** empty log message ***
parent
cdb42c59
No related branches found
No related tags found
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
Box/Box.cpp
+0
-191
0 additions, 191 deletions
Box/Box.cpp
Common/Views.cpp
+2
-2
2 additions, 2 deletions
Common/Views.cpp
Motif/CbOptions.cpp
+1
-5
1 addition, 5 deletions
Motif/CbOptions.cpp
README
+0
-24
0 additions, 24 deletions
README
TODO
+0
-9
0 additions, 9 deletions
TODO
with
3 additions
and
231 deletions
Box/Box.cpp
deleted
100644 → 0
+
0
−
191
View file @
cdb42c59
// $Id: Box.cpp,v 1.24 2001-02-12 17:38:02 geuzaine Exp $
#include
<signal.h>
#include
"Gmsh.h"
#include
"GmshVersion.h"
#include
"Const.h"
#include
"Geo.h"
#include
"Mesh.h"
#include
"Views.h"
#include
"Parser.h"
#include
"Context.h"
#include
"OpenFile.h"
#include
"GetOptions.h"
#include
"MinMax.h"
#include
"Static.h"
/* dummy defs for link purposes */
void
AddViewInUI
(
int
,
char
*
,
int
){}
void
draw_polygon_2d
(
double
,
double
,
double
,
int
,
double
*
,
double
*
,
double
*
){}
void
set_r
(
int
,
double
){}
void
Draw
(
void
){}
void
DrawUI
(
void
){}
void
Replot
(
void
){}
void
CreateOutputFile
(
char
*
,
int
){}
/* ------------------------------------------------------------------------ */
/* I n f o */
/* ------------------------------------------------------------------------ */
void
Info
(
int
level
,
char
*
arg0
){
switch
(
level
){
case
0
:
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_progname
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_copyright
);
fprintf
(
stderr
,
gmsh_options
,
arg0
);
exit
(
1
);
case
1
:
fprintf
(
stderr
,
"%.2f
\n
"
,
GMSH_VERSION
);
exit
(
1
)
;
case
2
:
fprintf
(
stderr
,
"%s%.2f
\n
"
,
gmsh_version
,
GMSH_VERSION
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_os
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_date
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_host
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_packager
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_url
);
fprintf
(
stderr
,
"%s
\n
"
,
gmsh_email
);
exit
(
1
)
;
default
:
break
;
}
}
/* ------------------------------------------------------------------------ */
/* m a i n */
/* ------------------------------------------------------------------------ */
int
main
(
int
argc
,
char
*
argv
[]){
int
i
,
nbf
;
Init_Context
(
0
);
Get_Options
(
argc
,
argv
,
&
nbf
);
signal
(
SIGINT
,
Signal
);
signal
(
SIGSEGV
,
Signal
);
signal
(
SIGFPE
,
Signal
);
OpenProblem
(
CTX
.
filename
);
if
(
yyerrorstate
)
exit
(
1
);
else
{
if
(
nbf
>
1
){
for
(
i
=
1
;
i
<
nbf
;
i
++
)
MergeProblem
(
TheFileNameTab
[
i
]);
}
if
(
TheBgmFileName
){
MergeProblem
(
TheBgmFileName
);
if
(
List_Nbr
(
Post_ViewList
))
BGMWithView
((
Post_View
*
)
List_Pointer
(
Post_ViewList
,
List_Nbr
(
Post_ViewList
)
-
1
));
else
fprintf
(
stderr
,
ERROR_STR
"Invalid BGM (no view)
\n
"
);
exit
(
1
);
}
if
(
CTX
.
interactive
>
0
){
mai3d
(
THEM
,
CTX
.
interactive
);
Print_Mesh
(
THEM
,
NULL
,
CTX
.
mesh
.
format
);
}
exit
(
1
);
}
}
/* ------------------------------------------------------------------------ */
/* S i g n a l */
/* ------------------------------------------------------------------------ */
void
Signal
(
int
sig_num
){
switch
(
sig_num
){
case
SIGSEGV
:
Msg
(
FATAL
,
"Segmentation Violation (Invalid Memory Reference)"
);
break
;
case
SIGFPE
:
Msg
(
FATAL
,
"Floating Point Exception (Division by Zero?)"
);
break
;
case
SIGINT
:
Msg
(
FATAL
,
"Interrupt (Generated from Terminal Special Char)"
);
break
;
default
:
Msg
(
FATAL
,
"Unknown Signal"
);
break
;
}
}
/* ------------------------------------------------------------------------ */
/* M s g */
/* ------------------------------------------------------------------------ */
void
Msg
(
int
level
,
char
*
fmt
,
...){
va_list
args
;
int
abort
=
0
;
int
nb
,
nbvis
;
va_start
(
args
,
fmt
);
switch
(
level
){
case
FATAL
:
case
FATAL1
:
case
FATAL2
:
case
FATAL3
:
fprintf
(
stderr
,
FATAL_STR
);
vfprintf
(
stderr
,
fmt
,
args
);
fprintf
(
stderr
,
"
\n
"
);
abort
=
1
;
break
;
case
GERROR
:
case
GERROR1
:
case
GERROR2
:
case
GERROR3
:
fprintf
(
stderr
,
ERROR_STR
);
vfprintf
(
stderr
,
fmt
,
args
);
fprintf
(
stderr
,
"
\n
"
);
abort
=
1
;
break
;
case
WARNING
:
case
WARNING1
:
case
WARNING2
:
case
WARNING3
:
fprintf
(
stderr
,
WARNING_STR
);
vfprintf
(
stderr
,
fmt
,
args
);
fprintf
(
stderr
,
"
\n
"
);
break
;
case
PARSER_ERROR
:
fprintf
(
stderr
,
PARSER_ERROR_STR
);
vfprintf
(
stderr
,
fmt
,
args
);
fprintf
(
stderr
,
"
\n
"
);
break
;
case
PARSER_INFO
:
if
(
CTX
.
verbosity
==
5
){
fprintf
(
stderr
,
PARSER_INFO_STR
);
vfprintf
(
stderr
,
fmt
,
args
);
fprintf
(
stderr
,
"
\n
"
);
}
break
;
default
:
if
(
CTX
.
verbosity
==
5
){
fprintf
(
stderr
,
INFO_STR
);
vfprintf
(
stderr
,
fmt
,
args
);
fprintf
(
stderr
,
"
\n
"
);
}
break
;
}
va_end
(
args
);
if
(
abort
)
exit
(
1
);
}
/* ------------------------------------------------------------------------ */
/* C p u */
/* ------------------------------------------------------------------------ */
double
Cpu
(
void
){
return
0.
;
}
/* ------------------------------------------------------------------------ */
/* P r o g r e s s */
/* ------------------------------------------------------------------------ */
void
Progress
(
int
i
){
}
void
AddALineInTheEditGeometryForm
(
char
*
line
){
};
This diff is collapsed.
Click to expand it.
Common/Views.cpp
+
2
−
2
View file @
05ff8244
// $Id: Views.cpp,v 1.3
0
2001-02-17 2
1:56:58
geuzaine Exp $
// $Id: Views.cpp,v 1.3
1
2001-02-17 2
2:25:46
geuzaine Exp $
#include
<set>
#include
<set>
#include
"Gmsh.h"
#include
"Gmsh.h"
...
@@ -533,7 +533,7 @@ void Write_View(int Flag_BIN, Post_View *v, char *filename){
...
@@ -533,7 +533,7 @@ void Write_View(int Flag_BIN, Post_View *v, char *filename){
fprintf
(
file
,
"$PostFormat /* Gmsh 1.0, %s */
\n
"
,
fprintf
(
file
,
"$PostFormat /* Gmsh 1.0, %s */
\n
"
,
Flag_BIN
?
"binary"
:
"ascii"
)
;
Flag_BIN
?
"binary"
:
"ascii"
)
;
fprintf
(
file
,
"1.0 %d %d
\n
"
,
Flag_BIN
,
sizeof
(
double
))
;
fprintf
(
file
,
"1.0 %d %d
\n
"
,
Flag_BIN
,
(
int
)
sizeof
(
double
))
;
fprintf
(
file
,
"$EndPostFormat
\n
"
)
;
fprintf
(
file
,
"$EndPostFormat
\n
"
)
;
for
(
i
=
0
;
i
<
(
int
)
strlen
(
v
->
Name
);
i
++
)
for
(
i
=
0
;
i
<
(
int
)
strlen
(
v
->
Name
);
i
++
)
if
(
v
->
Name
[
i
]
==
' '
)
v
->
Name
[
i
]
=
'_'
;
if
(
v
->
Name
[
i
]
==
' '
)
v
->
Name
[
i
]
=
'_'
;
...
...
This diff is collapsed.
Click to expand it.
Motif/CbOptions.cpp
+
1
−
5
View file @
05ff8244
// $Id: CbOptions.cpp,v 1.
7
2001-02-17 22:
04:05
geuzaine Exp $
// $Id: CbOptions.cpp,v 1.
8
2001-02-17 22:
25:49
geuzaine Exp $
#include
"Gmsh.h"
#include
"Gmsh.h"
#include
"GmshUI.h"
#include
"GmshUI.h"
...
@@ -120,11 +120,7 @@ void OptionsCb (Widget w, XtPointer client_data, XtPointer call_data){
...
@@ -120,11 +120,7 @@ void OptionsCb (Widget w, XtPointer client_data, XtPointer call_data){
CTX
.
r
[
0
],
CTX
.
r
[
1
],
CTX
.
r
[
2
],
CTX
.
r
[
0
],
CTX
.
r
[
1
],
CTX
.
r
[
2
],
CTX
.
t
[
0
],
CTX
.
t
[
1
],
CTX
.
t
[
2
],
CTX
.
t
[
0
],
CTX
.
t
[
1
],
CTX
.
t
[
2
],
CTX
.
s
[
0
],
CTX
.
s
[
1
],
CTX
.
s
[
2
]);
CTX
.
s
[
0
],
CTX
.
s
[
1
],
CTX
.
s
[
2
]);
<<<<<<<
CbOptions
.
cpp
Print_Context
(
0
,
GMSH_FULLRC
,
NULL
);
Print_Context
(
0
,
GMSH_FULLRC
,
NULL
);
=======
Print_Context
(
0
,
NULL
);
>>>>>>>
1.6
break
;
break
;
/* save */
/* save */
...
...
This diff is collapsed.
Click to expand it.
README
deleted
100644 → 0
+
0
−
24
View file @
cdb42c59
Some easy rules to make the code easy to read/debug/maintain:
- *please* enable full warnings for your compiler (e.g. gcc -Wall)
- *always* use Msg() to print information/errors/etc.
- indent your files and, if working on Windows, suppress the tabs (untabify)
To download the latset full source by CVS, type
cvs -d :pserver:YOUR_NAME@elap57.montefiore.ulg.ac.be:/usr/users57/cvs-master COMMAND
where YOUR_NAME is your username on elap57.montefiore.ulg.ac.be, and where COMMAND is
first 'login' (you will be prompted for a password), and then 'checkout gmsh'. When
this is done, you can use 'logout' to exit.
To update your local version, type
cvs update -d
To submit your changes, type
cvs commit
This diff is collapsed.
Click to expand it.
TODO
deleted
100644 → 0
+
0
−
9
View file @
cdb42c59
- Ecrire une vraie base de donnee des options, avec un fonction pour
chaque option. Cette fonction devrait modifier la GUI s'il y a lieu
- PostProcesing.NbViews est bugge si on fait
gmsh cartes.pos au lieu de
gmsh aa.geo cartes.pos
avec un script qui suit directement
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment