3DCoat Core API
The 3DCoat API documentation.
No Matches

Generate the surface figure "glass"

// Generate the surface figure "glass"
#include <CoreAPI.h>
//@config: Debug
using namespace coat;
int main() {
// get to sculpt room
// add new volume
auto current = coat::Scene::sculptRoot().addChild("glass");
auto volume = current.Volume();
// turn to surface
// add the solid glass using bezie points
// subtract sphere from solid glass
return 0;
SceneElement addChild(const char *name) const
add the child element of the same nature
static SceneElement sculptRoot()
get the root of all sculpt objects
box & size(const vec3 &_size)
set the box size
lathe primitive
Definition CorePrimAPI.h:1848
lathe & add_point(const vec2 &point, int st)
add the point into curve
void subtract(Volume &v)
subtract the prim from scene
prim & y(float y)
shift the primitive along the y - axis
void add(Volume &v)
add the prim into scene
The sphere.
Definition CorePrimAPI.h:620
sphere & diameter(const float &d)
set the diameter of the sphere.
static void toRoom(const char *name)
switch to the room
The coat namespace used for most 3DCoat API calls except low-level internal structures.
Definition CoreAPI.h:43
comms::cVec3 vec3
3D - float vector, see the cVec3
Definition CoreAPI.h:50
comms::cVec2 vec2
2D - vector, see the cVec2
Definition CoreAPI.h:56