| 1 |
// SPDX-FileCopyrightText: Copyright © DUNE Project contributors, see file LICENSE.md in module root |
| 2 |
// SPDX-License-Identifier: LGPL-2.1-or-later |
| 3 |
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- |
| 4 |
// vi: set et ts=4 sw=2 sts=2: |
| 5 |
/****************************************************************************/ |
| 6 |
/* */ |
| 7 |
/* File: initgm.c */ |
| 8 |
/* */ |
| 9 |
/* Purpose: call the init routines of the grid manager module */ |
| 10 |
/* */ |
| 11 |
/* Author: Henrik Rentz-Reichert */ |
| 12 |
/* Institut fuer Computeranwendungen III */ |
| 13 |
/* Universitaet Stuttgart */ |
| 14 |
/* Pfaffenwaldring 27 */ |
| 15 |
/* 70569 Stuttgart */ |
| 16 |
/* email: [email protected] */ |
| 17 |
/* */ |
| 18 |
/* History: 27.02.95 begin, ug version 3.0 */ |
| 19 |
/* */ |
| 20 |
/* Remarks: */ |
| 21 |
/* */ |
| 22 |
/****************************************************************************/ |
| 23 |
|
| 24 |
|
| 25 |
/****************************************************************************/ |
| 26 |
/* */ |
| 27 |
/* include files */ |
| 28 |
/* system include files */ |
| 29 |
/* application include files */ |
| 30 |
/* */ |
| 31 |
/****************************************************************************/ |
| 32 |
|
| 33 |
/* ANSI-C includes */ |
| 34 |
#include <config.h> |
| 35 |
#include <cstdio> |
| 36 |
|
| 37 |
/* low module */ |
| 38 |
#include <dune/uggrid/low/misc.h> |
| 39 |
#include <dune/uggrid/low/ugtypes.h> |
| 40 |
|
| 41 |
/* gm module */ |
| 42 |
#include "gm.h" |
| 43 |
#include "algebra.h" |
| 44 |
#include "cw.h" |
| 45 |
#include "ugm.h" |
| 46 |
#include "elements.h" |
| 47 |
#include "refine.h" |
| 48 |
#include "rm.h" |
| 49 |
|
| 50 |
/* own header */ |
| 51 |
#include "initgm.h" |
| 52 |
|
| 53 |
|
| 54 |
USING_UG_NAMESPACE |
| 55 |
USING_UGDIM_NAMESPACE |
| 56 |
|
| 57 |
/****************************************************************************/ |
| 58 |
/* */ |
| 59 |
/* definition of variables global to this source file only (static!) */ |
| 60 |
/* */ |
| 61 |
/****************************************************************************/ |
| 62 |
|
| 63 |
/****************************************************************************/ |
| 64 |
/* |
| 65 |
InitGm - Call the inits for the grid manager module |
| 66 |
|
| 67 |
SYNOPSIS: |
| 68 |
INT InitGm (); |
| 69 |
|
| 70 |
PARAMETERS: |
| 71 |
. void |
| 72 |
|
| 73 |
DESCRIPTION: |
| 74 |
This function calls the inits for the grid manager module. |
| 75 |
|
| 76 |
RETURN VALUE: |
| 77 |
INT |
| 78 |
.n 0 if ok |
| 79 |
.n 1 if some error occurred. |
| 80 |
*/ |
| 81 |
/****************************************************************************/ |
| 82 |
|
| 83 |
INT NS_DIM_PREFIX InitGm () |
| 84 |
{ |
| 85 |
INT err; |
| 86 |
|
| 87 |
/* cw.c */ |
| 88 |
if ((err=InitCW())!=0) |
| 89 |
{ |
| 90 |
SetHiWrd(err,__LINE__); |
| 91 |
return (err); |
| 92 |
} |
| 93 |
|
| 94 |
/* elements.c */ |
| 95 |
if ((err=InitElementTypes())!=0) |
| 96 |
{ |
| 97 |
SetHiWrd(err,__LINE__); |
| 98 |
return (err); |
| 99 |
} |
| 100 |
|
| 101 |
/* ugm.c */ |
| 102 |
if ((err=InitUGManager())!=0) |
| 103 |
{ |
| 104 |
SetHiWrd(err,__LINE__); |
| 105 |
return (err); |
| 106 |
} |
| 107 |
|
| 108 |
/* rm.c */ |
| 109 |
if ((err=InitRuleManager())!=0) |
| 110 |
{ |
| 111 |
SetHiWrd(err,__LINE__); |
| 112 |
return (err); |
| 113 |
} |
| 114 |
|
| 115 |
return (0); |
| 116 |
} |
| 117 |
|
| 118 |
|
| 119 |
INT NS_DIM_PREFIX ExitGm() |
| 120 |
{ |
| 121 |
INT err; |
| 122 |
|
| 123 |
/* ugm.c */ |
| 124 |
if ((err=ExitUGManager())!=0) |
| 125 |
{ |
| 126 |
SetHiWrd(err,__LINE__); |
| 127 |
return (err); |
| 128 |
} |
| 129 |
|
| 130 |
return 0; |
| 131 |
} |