Primitives in the 3DCoat can be created by using the primitive classes, control the parameters of primitives, add and delete the primitives from scene.
Lets start with a primitives tool.
Primitives tool
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
Debug dbg;
DebugLog log = dbg.log();
void main() {
Coat coat;
log.clear();
coat.room("Sculpt");
UI ui;
ui("$SCULP_PRIM");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume0");
PrimitivesTool tool;
SpherePrim sphere = tool.sphere();
CubPrim cube = tool.cube();
CylinderPrim cylinder = tool.cylinder();
ConePrim cone = tool.cone();
TorusPrim torus = tool.torus();
float timeDelay = 2000;
tool.SetPrim("sphere");
sphere.Radius(50.0);
sphere.Position(Vec3(-400,-50,0));
tool.Apply(0);
tool.SetPrim("cylinder");
cylinder.radius(50.0);
cylinder.startPoint(Vec3(-300,0,0));
cylinder.endPoint(Vec3(-300,100,0));
tool.Apply(0);
tool.SetPrim("cube");
Wait(timeDelay);
tool.SetPrim("cone");
cone.startPoint(Vec3(-500,0,0));
cone.endPoint(Vec3(-500,100,0));
cone.radius(50);
tool.Apply(0);
}
Primitives Tool
The result of code script see here
With help of `Primitives Tool` we'll make various primitives.
How to create a primitives in the Sculpt Room
We can use for creating primitives the following classes:
Sphere
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume4");
UI ui;
ui("$SCULP_PRIM");
PrimitivesTool tool;
SpherePrim sphere1;
sphere1 = tool.sphere();
sphere1.Position(Vec3(0.00,0.00,0.00));
sphere1.Radius(15.00);
vox1.toSurface();
sphere1.Position(Vec3(-300.00,-12.00,369.07));
sphere1.Radius(74.72);
tool.Apply(0);
}
SpherePrim sphere = tool.sphere()
All parameters related to Sphere check here.
Sphere Primitive
The result of code script see here
Cube
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume3");
UI ui;
ui("$SCULP_PRIM");
PrimitivesTool tool;
CubPrim cube2;
cube2 = tool.cube();
cube2.AxisX(Vec3(1.00,0.00,0.00));
cube2.AxisY(Vec3(0.00,1.00,0.00));
cube2.AxisZ(Vec3(0.00,0.00,1.00));
cube2.useFillet(false);
cube2.Position(Vec3(0.00,0.00,0.00));
cube2.SideA(30.00);
cube2.SideB(30.00);
cube2.SideC(30.00);
vox1.toSurface();
cube2.useFillet(true);
cube2.filletRadiusRelation(0.20);
cube2.filletRadius(14.41);
cube2.Position(Vec3(-223.11,44.94,336.39));
cube2.SideA(144.11);
cube2.SideB(144.11);
cube2.SideC(144.11);
cube2.details(0.38);
tool.Apply(0);
}
All parameters related to Cube check here.
Cube Primitive
The result of code script see here
Ellipse
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.clear();
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume12");
PrimitivesTool tool;
ui("$SCULP_PRIM");
EllipsePrim ellipse3;
ellipse3 = tool.ellipse();
ellipse3.Position(Vec3(-307.18,61.64,380.09));
ellipse3.SideA(40.82);
ellipse3.SideB(40.89);
ellipse3.SideC(108.31);
ellipse3.AxisX(Vec3(1.00,-0.04,-0.01));
ellipse3.AxisY(Vec3(0.04,0.99,0.15));
ellipse3.AxisZ(Vec3(0.00,-0.15,0.99));
vox1.toSurface();
ellipse3.SideA(51.39);
ellipse3.SideB(51.48);
ellipse3.SideC(136.36);
ellipse3.details(0.61);
tool.Apply(0);
}
Ellipse Primitive
The result of code script see here
Cylinder
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.clear();
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume3");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
CylinderPrim cylinder4;
cylinder4 = tool.cylinder();
cylinder4.useFillet(true);
cylinder4.filletRadiusRelation(0.20);
cylinder4.startPoint(Vec3(-280.98,23.17,236.68));
cylinder4.endPoint(Vec3(-292.61,159.80,242.19));
cylinder4.height(137.24);
cylinder4.radius(52.42);
cylinder4.topRadius(52.42);
cylinder4.bottomRadius(52.42);
cylinder4.scalex(1.00);
cylinder4.scaley(1.00);
cylinder4.details(0.69);
tool.Apply(0);
cylinder4.startPoint(Vec3(-251.18,102.24,277.48));
cylinder4.endPoint(Vec3(-221.85,103.49,308.54));
cylinder4.height(42.73);
cylinder4.radius(27.30);
cylinder4.topRadius(27.30);
cylinder4.bottomRadius(27.30);
tool.Apply(0);
cylinder4.startPoint(Vec3(-335.49,85.39,257.88));
cylinder4.endPoint(Vec3(-394.83,79.38,281.57));
cylinder4.height(64.17);
tool.Apply(0);
cylinder4.startPoint(Vec3(-295.43,127.83,244.86));
cylinder4.endPoint(Vec3(-306.96,263.31,250.33));
cylinder4.height(136.08);
tool.Apply(0);
}
Cylinder Primitive
The result of code script see here
Cone
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume1");
PrimitivesTool tool;
ui("$SCULP_PRIM");
ConePrim cone5;
cone5 = tool.cone();
cone5.startPoint(Vec3(0.00,0.00,0.00));
cone5.endPoint(Vec3(0.00,20.00,0.00));
cone5.height(20.00);
cone5.bottomRadius(10.00);
cone5.useFillet(true);
cone5.filletRadiusRelation(0.20);
cone5.startPoint(Vec3(-285.69,-58.62,257.72));
cone5.endPoint(Vec3(-305.78,108.83,232.01));
cone5.height(170.60);
cone5.bottomRadius(74.79);
tool.Apply(0);
}
Cone Primitive
The result of code script see here
Capsule
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume58");
PrimitivesTool tool;
ui("$SCULP_PRIM");
CapsulePrim capsule16;
capsule16 = tool.capsule();
capsule16.useDiameter(false);
capsule16.startPoint(Vec3(-502.04,-138.54,138.58));
capsule16.endPoint(Vec3(-502.04,31.45,138.58));
capsule16.height(169.98);
capsule16.radius(41.13);
capsule16.topRadius(41.13);
capsule16.bottomRadius(41.13);
capsule16.scalex(1.00);
capsule16.Cap1(1.00);
capsule16.scaley(1.00);
capsule16.Cap2(1.00);
capsule16.scalex(1.00);
capsule16.Cap1(1.00);
capsule16.scaley(1.00);
capsule16.Cap2(1.00);
vox1.to("Volume58");
vox1.toSurface();
capsule16.startPoint(Vec3(-457.88,-216.68,227.52));
capsule16.endPoint(Vec3(-583.86,-116.64,64.04));
capsule16.height(229.36);
capsule16.radius(55.49);
capsule16.topRadius(55.49);
capsule16.bottomRadius(55.49);
capsule16.details(0.84);
tool.Apply(0);
}
Capsule Primitive
The result of code script see here
Tube
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume1");
PrimitivesTool tool;
ui("$SCULP_PRIM");
vox1.toSurface();
TubePrim tube7;
tube7 = tool.tube();
tube7.startPoint(Vec3(-223.68,3.57,222.30));
tube7.endPoint(Vec3(-230.67,118.01,173.44));
tube7.height(124.63);
tube7.radius(32.72);
tube7.WallThickness(16.36);
tube7.details(0.84);
tube7.useFillet(true);
tube7.Bevel(1,false);
tube7.Bevel(2,true);
tube7.filletRadiusRelation(0.20);
tube7.startPoint(Vec3(-227.87,-73.63,238.01));
tube7.endPoint(Vec3(-217.73,113.49,199.92));
tube7.height(191.24);
tube7.radius(50.20);
tube7.WallThickness(25.10);
tube7.details(0.57);
tool.Apply(0);
}
Tube Primitive
The result of code script see here
NGon
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume1");
PrimitivesTool tool;
ui("$SCULP_PRIM");
NGonPrim ngon8;
ngon8 = tool.ngon();
ngon8.startPoint(Vec3(238.79,-48.69,340.52));
ngon8.endPoint(Vec3(238.79,118.53,340.52));
ngon8.height(167.22);
ngon8.radius(68.07);
ngon8.Order(6);
tool.Apply(0);
}
NGon Primitive
The result of code script see here
Gear
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume1");
PrimitivesTool tool;
ui("$SCULP_PRIM");
GearPrim gear9;
gear9 = tool.gear();
gear9.startPoint(Vec3(0.00,0.00,0.00));
gear9.endPoint(Vec3(0.00,20.00,0.00));
gear9.height(20.00);
gear9.radius(10.00);
gear9.Depth(0.10);
gear9.Sharpness(0.5);
gear9.Order(16);
gear9.startPoint(Vec3(285.31,-181.30,495.22));
gear9.endPoint(Vec3(285.31,-33.71,478.45));
gear9.height(148.55);
gear9.radius(94.87);
tool.Apply(0);
}
Gear Primitive
The result of code script see here
Lathe
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume2");
UI ui;
ui("$SCULP_PRIM");
PrimitivesTool tool;
LathePrim lathe10;
lathe10 = tool.lathe();
lathe10.AxisX(Vec3(0.22,0.08,0.97));
lathe10.AxisY(Vec3(-0.09,0.99,-0.06));
lathe10.AxisZ(Vec3(-0.97,-0.07,0.23));
lathe10.Position(Vec3(-141.10,35.58,306.22));
lathe10.SideA(160.96);
lathe10.SideB(160.96);
lathe10.SideC(160.96);
lathe10.LatheType(0);
lathe10.SetPoint(0,0.00,0.50,0);
lathe10.SetPoint(1,0.49,0.11,0);
lathe10.SetPoint(2,1.00,0.50,0);
tool.Apply(0);
}
Lathe Primitive
The result of code script see here
Text
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume2");
UI ui;
ui("$SCULP_PRIM");
Font font;
font.Name("Arial");
font.Size(96);
font.Weight(400);
font.Style(0);
font.OutPrecision(3);
font.ClipPrecision(2);
font.CharSet(0);
font.Quality(4);
font.Family(34);
PrimitivesTool tool;
TextPrim text11;
text11 = tool.text();
text11.SetText("Sculpt room");
text11.AxisX(Vec3(0.77,0.00,-0.64));
text11.AxisY(Vec3(-0.34,0.85,-0.41));
text11.AxisZ(Vec3(0.54,0.53,0.65));
text11.Position(Vec3(-293.23,132.34,210.24));
text11.SideA(174.53);
text11.SideB(174.53);
text11.SideC(17.45);
text11.ExtraRotation(-21.60);
text11.Bend(false);
tool.Apply(0);
}
Text Primitive
The result of code script see here
Image
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume3");
UI ui;
ui("$SCULP_PRIM");
PrimitivesTool tool;
ImagePrim image12;
image12 = tool.image();
image12.AxisX(Vec3(0.80,0.00,-0.60));
image12.AxisY(Vec3(0.00,1.00,0.00));
image12.AxisZ(Vec3(0.60,0.00,0.80));
image12.Position(Vec3(-257.19,0.00,282.29));
image12.SideA(128.02);
image12.SideB(128.02);
image12.SideC(12.80);
image12.ExtraRotation(0.00);
image12.Bend(false);
ImageMeshParam imparam1;
imparam1.SizeInScene(100.00);
imparam1.Top("/images/Bracelet.png");
imparam1.TopBump("/images/Bracelet.png");
imparam1.TopBottomWeight(0.70);
imparam1.BasicThickness(8.00);
imparam1.BumpThickness(8.00);
image12.PickImage();
image12.SideA(91.12);
image12.SideB(91.12);
image12.SideC(9.11);
tool.Apply(0);
}
Image Primitive
The result of code script see here
Spiral
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume4");
PrimitivesTool tool;
ui("$SCULP_PRIM");
SpringPrim spring13;
spring13 = tool.spring();
spring13.Position(Vec3(-318.50,0.00,316.36));
spring13.Position2(Vec3(-318.50,2.00,316.40));
spring13.ScaleRadius(1.00);
spring13.OuterDiameter(67.96);
spring13.Pitch(33.98);
spring13.ProfileDiameter(16.99);
spring13.ProfileRadiusRelation(0.50);
spring13.Turns(7);
spring13.ClockWise(true);
tool.Apply(0);
}
Spiral Primitive
The result of code script see here
Torus
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.clearScene();
vox1.rename("Volume5");
PrimitivesTool tool;
ui("$SCULP_PRIM");
TorusPrim torus14;
torus14 = tool.torus();
torus14.Position(Vec3(0.00,0.00,0.00));
torus14.SideA(30.00);
torus14.SideB(30.00);
torus14.SideC(30.00);
torus14.RadiusRelation(0.50);
torus14.OuterRadius(30.00);
torus14.InnerRadius(15.00);
torus14.ProfileRadius(7.50);
torus14.AxisX(Vec3(1.00,0.05,-0.04));
torus14.AxisY(Vec3(-0.05,1.00,0.05));
torus14.AxisZ(Vec3(0.04,-0.05,1.00));
vox1.toSurface();
torus14.Position(Vec3(-525.58,-37.10,196.04));
torus14.SideA(102.64);
torus14.SideB(102.64);
torus14.SideC(102.64);
torus14.OuterRadius(102.64);
torus14.InnerRadius(51.32);
torus14.ProfileRadius(25.66);
torus14.AxisX(Vec3(0.83,0.02,-0.56));
torus14.AxisY(Vec3(-0.01,1.00,0.02));
torus14.AxisZ(Vec3(0.56,-0.01,0.83));
torus14.details(0.81);
tool.Apply(0);
}
Torus Primitive
The result of code script see here
Screw-Thread
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume3");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
ThreadPrim thread15;
thread15 = tool.thread();
thread15.Position(Vec3(-416.06,-69.18,174.47));
thread15.Diameter(135.42);
thread15.Pitch(22.57);
thread15.Turns(10);
thread15.Profile(ProfileType::TRIANGLE);
thread15.ClockWise(true);
thread15.StubHeight(4.51);
vox1.toSurface();
thread15.details(0.59);
tool.Apply(0);
}
Screw-Thread Primitive
The result of code script see here
Screw Thread With Core
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
CoreThreadPrim coreThread16;
coreThread16 = tool.corethread();
coreThread16.Position(Vec3(-423.00,-51.63,202.36));
coreThread16.Length(252.50);
coreThread16.Diameter(126.25);
coreThread16.ThreadLength(168.33);
coreThread16.Pitch(21.04);
coreThread16.Profile(ProfileType::ROUND);
tool.Apply(0);
}
Screw-Thread With Core Primitive
The result of code script see here
Bolt's head
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
BoltHeadPrim bolthead17;
bolthead17 = tool.bolthead();
bolthead17.Position(Vec3(-366.07,0.00,196.40));
bolthead17.HeadType(SHeadType::HEXA);
bolthead17.UseSlit(false);
bolthead17.Diameter(165.80);
bolthead17.Height(55.27);
bolthead17.UseSlit(true);
bolthead17.SlitWidth(8.07);
bolthead17.SlitLength(120.39);
bolthead17.SlitHeight(5.00);
bolthead17.SlitType(SSlitType::SLOT);
tool.Apply(0);
}
Bolt's head Primitive
The result of code script see here
Bolt
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
BoltPrim bolt18;
bolt18 = tool.bolt();
bolt18.Custom();
bolt18.Position(Vec3(-336.02,-80.03,161.63));
bolt18.HeadType(SHeadType::HEXA);
bolt18.Profile(ProfileType::TRIANGLE);
vox1.toSurface();
bolt18.AxisX(Vec3(-0.01,-0.22,-0.97));
bolt18.AxisY(Vec3(0.93,0.36,-0.09));
bolt18.AxisZ(Vec3(0.37,-0.91,0.20));
bolt18.Diameter(281.71);
bolt18.Height(93.90);
bolt18.BodyLength(281.71);
bolt18.BodyDiameter(140.85);
bolt18.ThreadLength(187.81);
bolt18.Pitch(23.48);
bolt18.details(0.32);
tool.Apply(0);
}
Bolt Primitive
The result of code script see here
Screw
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
TapScrewPrim screw19;
screw19 = tool.tapscrew();
screw19.Custom();
vox1.toSurface();
screw19.AxisX(Vec3(0.03,0.03,-1.00));
screw19.AxisY(Vec3(0.98,0.18,0.03));
screw19.AxisZ(Vec3(0.18,-0.98,-0.03));
screw19.Position(Vec3(-239.87,-45.06,255.75));
screw19.HeadDiameter(210.99);
screw19.HeadHeight(70.33);
screw19.HeadType(SHeadType::BUGLE);
screw19.UseSlit(true);
screw19.SlitWidth(10.55);
screw19.SlitLength(216.26);
screw19.SlitHeight(17.58);
screw19.SlitType(SSlitType::SLOT);
screw19.Length(281.31);
screw19.Diameter(70.33);
screw19.UseThread(true);
screw19.UseGroove(false);
screw19.ThreadLength(210.99);
screw19.ThreadDiameter(84.39);
screw19.Pitch(17.58);
screw19.details(0.55);
tool.Apply(0);
}
Screw Primitive
The result of code script see here
Screw-Nut
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
NutPrim nut20;
nut20 = tool.nut();
nut20.Custom();
nut20.AxisX(Vec3(-0.59,0.36,-0.72));
nut20.AxisY(Vec3(0.81,0.26,-0.53));
nut20.AxisZ(Vec3(-0.00,-0.89,-0.45));
nut20.Position(Vec3(-30,0,0));
nut20.Name("hexa");
nut20.Diameter(233.01);
nut20.Height(116.51);
nut20.HeadType(SNutType::HEXA);
nut20.ThreadDiameter(155.34);
nut20.Pitch(19.42);
nut20.Profile(ProfileType::TRIANGLE);
nut20.UseThread(true);
vox1.toSurface();
nut20.details(0.61);
tool.Apply(0);
}
Screw-Nut Primitive
The result of code script see here
Screw-Washer
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
Vox vox1;
vox1.clearScene();
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
WasherPrim washer21;
washer21 = tool.washer();
washer21.Custom();
washer21.Position(Vec3(-372.39,-60.71,-2.84));
washer21.Position2(Vec3(-372.39,-58.80,-2.24));
washer21.ScaleRadius(1.00);
washer21.Name("conus");
washer21.InnerDiameter(182.73);
washer21.OuterDiameter(365.46);
washer21.Thickness(31.84);
washer21.Height(47.75);
washer21.InnerDiameter2(301.79);
washer21.WasherType(SWasherType::CONUS);
washer21.details(0.61);
washer21.Position(Vec3(-353.83,-60.71,-2.84));
washer21.Position2(Vec3(-353.83,-58.72,-2.22));
washer21.ScaleRadius(1.04);
washer21.InnerDiameter(190.18);
washer21.OuterDiameter(380.37);
washer21.Thickness(33.13);
washer21.Height(49.70);
washer21.InnerDiameter2(314.10);
washer21.details(0.41);
tool.Apply(0);
}
Screw-Washer Primitive
The result of code script see here
Free Form
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
UI ui;
coat.room("Sculpt");
SculptRoom sculpt;
sculpt.toVoxel();
Vox vox1;
vox1.rename("Volume36");
vox1.toSurface();
PrimitivesTool tool;
ui("$SCULP_PRIM");
FreeFormPrim ff32;
ff32 = tool.freeform("Blob:Blob2x2");
ff32.Transform(false);
ff32.SymmetryX(false);
ff32.SymmetryY(false);
ff32.SymmetryZ(false);
ff32.SetPoint(0,-51.67,-51.67,51.67);
ff32.SetPoint(1,-51.67,51.67,51.67);
ff32.SetPoint(2,51.67,51.67,51.67);
ff32.SetPoint(3,51.67,-51.67,51.67);
ff32.SetPoint(4,-51.67,-51.67,-51.67);
ff32.SetPoint(5,-51.67,51.67,-51.67);
ff32.SetPoint(6,51.67,51.67,-51.67);
ff32.SetPoint(7,51.67,-51.67,-51.67);
ff32.SubPrim(0);
ff32.details(0.26);
ff32.SetPoint(0,-97.98,-184.13,169.57);
ff32.SetPoint(1,-137.95,-23.70,192.67);
ff32.SetPoint(2,-75.81,-118.47,333.79);
ff32.SetPoint(3,25.56,-210.63,211.70);
ff32.SetPoint(4,-113.92,116.51,-214.19);
ff32.SetPoint(5,121.35,-253.16,-74.83);
ff32.SetPoint(6,172.05,6.77,-149.14);
ff32.SetPoint(7,125.49,-172.24,-62.55);
tool.Apply(0);
}
Free form Primitive
The result of code script see here
How to create a primitives in the Retopo Room
We can use for creating primitives the following classes:
Sphere
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoSphere rsphere22;
rsphere22 = tool.rsphere();
rsphere22.useDiameter(false);
rsphere22.Position(Vec3(-273.63,0.00,0.00));
rsphere22.Radius(10.00);
rsphere22.SubDivision(0);
rsphere22.Position(Vec3(-252.48,80.03,0.00));
rsphere22.Radius(120.15);
rsphere22.SubDivision(5);
tool.Apply();
}
Sphere Primitive
The result of code script see here
Cube
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoBox rbox23;
rbox23 = tool.rbox();
rbox23.AxisX(Vec3(1.00,0.00,0.00));
rbox23.AxisY(Vec3(0.00,1.00,0.00));
rbox23.AxisZ(Vec3(0.00,0.00,1.00));
rbox23.useUniform(true);
rbox23.Position(Vec3(-226.48,32.41,0.00));
rbox23.SideA(64.79);
rbox23.SideB(64.79);
rbox23.SideC(64.79);
rbox23.DivX(1);
rbox23.DivY(1);
rbox23.DivZ(1);
rbox23.AverageDivision(1);
rbox23.Position(Vec3(-179.87,32.41,0.00));
rbox23.SideA(85.72);
rbox23.SideB(85.72);
rbox23.SideC(85.72);
rbox23.DivX(7);
rbox23.DivY(7);
rbox23.DivZ(7);
rbox23.AverageDivision(7);
tool.Apply();
}
Box Primitive
The result of code script see here
Cylinder
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoCylinder rcylinder24;
rcylinder24 = tool.rcylinder();
rcylinder24.useDiameter(false);
rcylinder24.useFillet(false);
rcylinder24.RemoveCaps(false);
rcylinder24.useUniform(true);
rcylinder24.startPoint(Vec3(-145.07,0.00,0.00));
rcylinder24.endPoint(Vec3(-145.07,20.00,0.00));
rcylinder24.height(20.00);
rcylinder24.radius(10.00);
rcylinder24.topRadius(10.00);
rcylinder24.bottomRadius(10.00);
rcylinder24.DivY(3);
rcylinder24.DivX(1);
rcylinder24.DivZ(5);
rcylinder24.AverageDivision(3);
rcylinder24.startPoint(Vec3(-145.07,-101.38,0.00));
rcylinder24.endPoint(Vec3(-145.07,45.82,0.00));
rcylinder24.height(147.20);
rcylinder24.radius(72.82);
rcylinder24.topRadius(72.82);
rcylinder24.bottomRadius(72.82);
rcylinder24.DivY(13);
rcylinder24.DivX(3);
rcylinder24.DivZ(20);
rcylinder24.AverageDivision(12);
tool.Apply();
}
Cylinder Primitive
The result of code script see here
Cone
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoCone rcone25;
rcone25 = tool.rcone();
rcone25.useDiameter(false);
rcone25.useFillet(false);
rcone25.useUniform(true);
rcone25.startPoint(Vec3(0.00,0.00,0.00));
rcone25.endPoint(Vec3(0.00,20.00,0.00));
rcone25.height(20.00);
rcone25.bottomRadius(10.00);
rcone25.scalex(1.00);
rcone25.scaley(1.00);
rcone25.DivY(5);
rcone25.DivX(1);
rcone25.DivZ(4);
rcone25.AverageDivision(3);
rcone25.useFillet(true);
rcone25.filletRadiusRelation(0.34);
rcone25.filletRadius(16.61);
rcone25.startPoint(Vec3(-50.17,0.00,106.16));
rcone25.endPoint(Vec3(-50.17,161.35,106.16));
rcone25.height(161.35);
rcone25.bottomRadius(75.93);
rcone25.DivY(19);
rcone25.DivX(2);
rcone25.DivZ(14);
rcone25.AverageDivision(12);
tool.Apply();
}
Cone Primitive
The result of code script see here
Ellipse
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoEllipse rellipse26;
rellipse26 = tool.rellipse();
rellipse26.AxisX(Vec3(1.00,-0.04,0.04));
rellipse26.AxisY(Vec3(0.04,1.00,-0.04));
rellipse26.AxisZ(Vec3(-0.04,0.05,1.00));
rellipse26.Position(Vec3(-279.27,11.38,-12.08));
rellipse26.SideA(30.00);
rellipse26.SideB(30.00);
rellipse26.SideC(62.75);
rellipse26.AxisX(Vec3(0.34,0.03,0.94));
rellipse26.AxisZ(Vec3(-0.94,0.06,0.34));
rellipse26.Position(Vec3(-283.85,16.57,98.84));
tool.Apply();
}
Ellipse Primitive
The result of code script see here
Torus
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoTorus rtorus27;
rtorus27 = tool.rtorus();
rtorus27.AxisX(Vec3(1.00,0.00,0.00));
rtorus27.AxisY(Vec3(0.00,1.00,0.00));
rtorus27.AxisZ(Vec3(0.00,0.00,1.00));
rtorus27.useUniform(true);
rtorus27.Position(Vec3(0.00,0.00,0.00));
rtorus27.SideA(30.00);
rtorus27.SideB(30.00);
rtorus27.SideC(30.00);
rtorus27.RadiusRelation(0.50);
rtorus27.OuterRadius(30.00);
rtorus27.InnerRadius(15.00);
rtorus27.ProfileRadius(7.50);
rtorus27.AverageDivision(3);
rtorus27.AxisY(Vec3(0.00,0.28,-0.96));
rtorus27.AxisZ(Vec3(0.00,0.96,0.28));
rtorus27.Position(Vec3(-194.37,-15.59,52.99));
rtorus27.SideA(112.28);
rtorus27.SideB(112.28);
rtorus27.SideC(112.28);
rtorus27.OuterRadius(112.28);
rtorus27.InnerRadius(56.14);
rtorus27.ProfileRadius(28.07);
rtorus27.AverageDivision(27);
tool.Apply();
}
Torus Primitive
The result of code script see here
Capsule
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoCapsule rcapsule28;
rcapsule28 = tool.rcapsule();
rcapsule28.useDiameter(false);
rcapsule28.useUniform(true);
rcapsule28.startPoint(Vec3(0.00,0.00,0.00));
rcapsule28.endPoint(Vec3(0.00,20.00,0.00));
rcapsule28.height(20.00);
rcapsule28.radius(10.00);
rcapsule28.topRadius(10.00);
rcapsule28.bottomRadius(10.00);
rcapsule28.scalex(1.00);
rcapsule28.Cap1(1.00);
rcapsule28.scaley(1.00);
rcapsule28.Cap2(1.00);
rcapsule28.DivY(2);
rcapsule28.DivZ(6);
rcapsule28.DivX(1);
rcapsule28.AverageDivision(3);
rcapsule28.startPoint(Vec3(-27.64,-37.33,156.80));
rcapsule28.endPoint(Vec3(-54.29,101.93,125.67));
rcapsule28.height(145.17);
rcapsule28.radius(66.11);
rcapsule28.topRadius(66.11);
rcapsule28.bottomRadius(66.11);
rcapsule28.DivY(14);
rcapsule28.DivZ(39);
rcapsule28.DivX(10);
rcapsule28.AverageDivision(21);
tool.Apply();
}
Capsule Primitive
The result of code script see here
Tube
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoTube rtube29;
rtube29 = tool.rtube();
rtube29.useDiameter(false);
rtube29.useFillet(false);
rtube29.useUniform(true);
rtube29.startPoint(Vec3(0.00,0.00,188.41));
rtube29.endPoint(Vec3(0.00,119.83,188.41));
rtube29.height(119.83);
rtube29.radius(85.30);
rtube29.topRadius(85.30);
rtube29.bottomRadius(85.30);
rtube29.WallThickness(42.65);
rtube29.scalex(1.00);
rtube29.scaley(1.00);
rtube29.DivY(7);
rtube29.DivX(1);
rtube29.DivZ(16);
rtube29.AverageDivision(8);
tool.Apply();
}
Tube Primitive
The result of code script see here
NGon
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoNGon rngon30;
rngon30 = tool.rngon();
rngon30.useDiameter(false);
rngon30.useFillet(true);
rngon30.useUniform(false);
rngon30.Bevel(1,true);
rngon30.Bevel(2,true);
rngon30.filletRadiusRelation(0.02);
rngon30.filletRadius(0.34);
rngon30.startPoint(Vec3(-34.32,-54.38,124.74));
rngon30.endPoint(Vec3(-18.28,125.10,124.74));
rngon30.height(180.20);
rngon30.radius(73.82);
rngon30.topRadius(73.82);
rngon30.bottomRadius(73.82);
rngon30.Order(15);
rngon30.FilletSegs(1);
rngon30.DivY(14);
rngon30.DivX(5);
rngon30.DivZ(4);
tool.Apply();
}
NGon Primitive
The result of code script see here
Spiral
Copy this script to your local drive and run it from 3DCoat: "Script / Run Script". Don't know how to do that, check here.
void main() {
Coat coat;
coat.room("Retopo");
RetopoRoom retopo;
retopo.clear();
PrimitivesTool tool;
coat.room("Retopo");
cmd("$RTP_PRIM");
rGeoSpiral rspiral31;
rspiral31 = tool.rspiral();
rspiral31.AxisX(Vec3(0.00,-0.49,-0.87));
rspiral31.AxisY(Vec3(1.00,0.00,0.00));
rspiral31.AxisZ(Vec3(0.00,-0.87,0.49));
rspiral31.useUniform(true);
rspiral31.Position(Vec3(-140.16,0.00,69.79));
rspiral31.Position2(Vec3(-140.16,1.75,68.82));
rspiral31.UseRectProfile(false);
rspiral31.OuterDiameter(151.22);
rspiral31.Pitch(75.61);
rspiral31.ProfileDiameter(37.81);
rspiral31.ProfileRadiusRelation(0.50);
rspiral31.Turns(3);
rspiral31.ClockWise(true);
rspiral31.DivY(54);
rspiral31.DivX(18);
rspiral31.DivZ(8);
rspiral31.AverageDivision(37);
tool.Apply();
}
Spiral Primitive
The result of code script see here