~ubuntu-branches/ubuntu/maverick/freecad/maverick

« back to all changes in this revision

Viewing changes to src/Mod/Mesh/App/FeatureMeshSolid.h

  • Committer: Bazaar Package Importer
  • Author(s): Teemu Ikonen
  • Date: 2009-07-16 18:37:41 UTC
  • Revision ID: james.westby@ubuntu.com-20090716183741-oww9kcxqrk991i1n
Tags: upstream-0.8.2237
ImportĀ upstreamĀ versionĀ 0.8.2237

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/***************************************************************************
 
2
 *   Copyright (c) 2006 Werner Mayer <werner.wm.mayer@gmx.de>              *
 
3
 *                                                                         *
 
4
 *   This file is part of the FreeCAD CAx development system.              *
 
5
 *                                                                         *
 
6
 *   This library is free software; you can redistribute it and/or         *
 
7
 *   modify it under the terms of the GNU Library General Public           *
 
8
 *   License as published by the Free Software Foundation; either          *
 
9
 *   version 2 of the License, or (at your option) any later version.      *
 
10
 *                                                                         *
 
11
 *   This library  is distributed in the hope that it will be useful,      *
 
12
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
 
13
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
 
14
 *   GNU Library General Public License for more details.                  *
 
15
 *                                                                         *
 
16
 *   You should have received a copy of the GNU Library General Public     *
 
17
 *   License along with this library; see the file COPYING.LIB. If not,    *
 
18
 *   write to the Free Software Foundation, Inc., 59 Temple Place,         *
 
19
 *   Suite 330, Boston, MA  02111-1307, USA                                *
 
20
 *                                                                         *
 
21
 ***************************************************************************/
 
22
 
 
23
 
 
24
#ifndef FEATURE_MESH_SOLID_H
 
25
#define FEATURE_MESH_SOLID_H
 
26
 
 
27
#include "MeshFeature.h"
 
28
 
 
29
#include <App/PropertyStandard.h>
 
30
#include <App/PropertyLinks.h>
 
31
 
 
32
namespace Mesh
 
33
{
 
34
 
 
35
/**
 
36
 * @author Werner Mayer
 
37
 */
 
38
class Sphere : public Mesh::Feature
 
39
{
 
40
  PROPERTY_HEADER(Mesh::Sphere);
 
41
 
 
42
public:
 
43
  Sphere();
 
44
 
 
45
  App::PropertyFloatConstraint Radius;
 
46
  App::PropertyIntegerConstraint Sampling;
 
47
 
 
48
  /** @name methods override Feature */
 
49
  //@{
 
50
  /// recalculate the Feature
 
51
  App::DocumentObjectExecReturn *execute(void);
 
52
  short mustExecute() const;
 
53
  //@}
 
54
};
 
55
 
 
56
// -------------------------------------------------------------
 
57
 
 
58
class Ellipsoid : public Mesh::Feature
 
59
{
 
60
  PROPERTY_HEADER(Mesh::Ellipsoid);
 
61
 
 
62
public:
 
63
  Ellipsoid();
 
64
 
 
65
  App::PropertyFloatConstraint Radius1;
 
66
  App::PropertyFloatConstraint Radius2;
 
67
  App::PropertyIntegerConstraint Sampling;
 
68
 
 
69
  /** @name methods override Feature */
 
70
  //@{
 
71
  /// recalculate the Feature
 
72
  App::DocumentObjectExecReturn *execute(void);
 
73
  short mustExecute() const;
 
74
  //@}
 
75
};
 
76
 
 
77
// -------------------------------------------------------------
 
78
 
 
79
class Cylinder : public Mesh::Feature
 
80
{
 
81
  PROPERTY_HEADER(Mesh::Cylinder);
 
82
 
 
83
public:
 
84
  Cylinder();
 
85
 
 
86
  App::PropertyFloatConstraint Radius;
 
87
  App::PropertyFloatConstraint Length;
 
88
  App::PropertyFloatConstraint EdgeLength;
 
89
  App::PropertyBool Closed;
 
90
  App::PropertyIntegerConstraint Sampling;
 
91
 
 
92
  /** @name methods override Feature */
 
93
  //@{
 
94
  /// recalculate the Feature
 
95
  App::DocumentObjectExecReturn *execute(void);
 
96
  short mustExecute() const;
 
97
  //@}
 
98
};
 
99
 
 
100
// -------------------------------------------------------------
 
101
 
 
102
class Cone : public Mesh::Feature
 
103
{
 
104
  PROPERTY_HEADER(Mesh::Cone);
 
105
 
 
106
public:
 
107
  Cone();
 
108
 
 
109
  App::PropertyFloatConstraint Radius1;
 
110
  App::PropertyFloatConstraint Radius2;
 
111
  App::PropertyFloatConstraint Length;
 
112
  App::PropertyFloatConstraint EdgeLength;
 
113
  App::PropertyBool Closed;
 
114
  App::PropertyIntegerConstraint Sampling;
 
115
 
 
116
  /** @name methods override Feature */
 
117
  //@{
 
118
  /// recalculate the Feature
 
119
  App::DocumentObjectExecReturn *execute(void);
 
120
  short mustExecute() const;
 
121
  //@}
 
122
};
 
123
 
 
124
// -------------------------------------------------------------
 
125
 
 
126
class Torus : public Mesh::Feature
 
127
{
 
128
  PROPERTY_HEADER(Mesh::Torus);
 
129
 
 
130
public:
 
131
  Torus();
 
132
 
 
133
  App::PropertyFloatConstraint Radius1;
 
134
  App::PropertyFloatConstraint Radius2;
 
135
  App::PropertyIntegerConstraint Sampling;
 
136
 
 
137
  /** @name methods override Feature */
 
138
  //@{
 
139
  /// recalculate the Feature
 
140
  App::DocumentObjectExecReturn *execute(void);
 
141
  short mustExecute() const;
 
142
  //@}
 
143
};
 
144
 
 
145
// -------------------------------------------------------------
 
146
 
 
147
class Cube : public Mesh::Feature
 
148
{
 
149
  PROPERTY_HEADER(Mesh::Cube);
 
150
 
 
151
public:
 
152
  Cube();
 
153
 
 
154
  App::PropertyFloatConstraint Length;
 
155
  App::PropertyFloatConstraint Width;
 
156
  App::PropertyFloatConstraint Height;
 
157
 
 
158
  /** @name methods override Feature */
 
159
  //@{
 
160
  /// recalculate the Feature
 
161
  App::DocumentObjectExecReturn *execute(void);
 
162
  short mustExecute() const;
 
163
  //@}
 
164
};
 
165
 
 
166
}
 
167
 
 
168
#endif // FEATURE_MESH_SOLID_H