3DCoat Core API
The 3DCoat API documentation.
Loading...
Searching...
No Matches
coat Namespace Reference

The coat namespace used for most 3DCoat API calls except low-level internal structures. More...

Classes

class  bolt
 bolt primitive More...
 
class  boltHead
 bolt head primitive More...
 
class  box
 The box. More...
 
class  Camera
 
class  capsule
 The capsule. More...
 
class  cone
 The cone. More...
 
class  Curve
 
class  cylinder
 The cylinder. More...
 
class  dialog
 the rich dialog. You may customize it, show your custom parameters and custom buttons. More...
 
class  ellipse
 The ellipse. More...
 
class  EyeParams
 struct of the EyeParams data More...
 
class  Font
 
class  FontInfo
 Holds the general information about font. More...
 
class  freeform
 freeform primitive More...
 
class  gear
 The gear. More...
 
class  HeadBaseParams
 HeadBaseParams struct of the head data. More...
 
class  HeadParams
 class HeadParams More...
 
class  Image
 The image references. Look the cImage for the list of allowed operations. More...
 
class  image
 image primitive More...
 
class  io
 General I/O access. More...
 
class  LambParams
 struct of the LambParams data More...
 
class  lathe
 lathe primitive More...
 
class  logger
 
class  Mesh
 The mesh reference. More...
 
class  Model
 The class that corresponds to the retopo/modeling rooms meshes. This is advanced version of the Mesh that allows essential topology changes on the fly. It is very similar to Mesh by basic functionality, may be easily converted to Mesh and vice versa. But it is more heavy structure, use Mesh if you don't need the advanced functionality. More...
 
class  ngon
 The ngon. More...
 
class  nut
 nut primitive More...
 
class  NutAcornParams
 
class  NutClampLever
 
class  NutFlangeParams
 
class  NutHeadBaseParams
 
class  NutHexaParams
 
class  NutLambParams
 
class  NutLowAcornParams
 
class  NutQuardParams
 
class  NutRadialParams
 
class  NutRimParams
 
class  NutSelfLockParams
 
class  NutSlitsParams
 
class  NutTShapedParams
 
class  prim
 The abstract prim class. More...
 
class  RenderRoom
 
class  resource
 this class represents different resources accessible in UI - alphas, strips, materials, models, etc More...
 
class  RimParams
 struct of the RimParams data More...
 
class  Scene
 referes the roots of the scene graph More...
 
class  SceneElement
 The scene element, like sculpt object or curve. More...
 
class  screw
 screw primitive More...
 
class  settings
 
class  Slit
 class of the slits More...
 
class  sphere
 The sphere. More...
 
class  SphericalCollision
 The class intended to place spheres in space and identify if there are spheres around. It is important for random objects generating and avoiding self-intersection of objects. More...
 
class  spiral
 The spiral. More...
 
class  symm
 
class  text
 text primitive More...
 
class  thread
 thread primitive More...
 
class  threadStud
 thread stud primitive More...
 
class  torus
 The torus. More...
 
class  TShapedParams
 struct of the TShapedParams data More...
 
class  tube
 The tube. More...
 
class  ui
 operate over the Coat's ui More...
 
class  utils
 
class  uv
 The UV API. The mesh is taken from the current room. If paint or UV rooms is active, the mesh is taken from the paint room, otherwise the mesh is taken from the Retopo room. More...
 
class  Volume
 The class allows to operate over voxels/surface on the relatively low-level. More...
 
class  VolumeCache
 
class  washer
 washer primitive More...
 

Typedefs

typedef comms::cVec4 vec4
 4D - float vector, see the cVec4
 
typedef comms::cVec3 vec3
 3D - float vector, see the cVec3
 
typedef comms::cVec3i vec3i
 3D - int vector, see the cVec3i
 
typedef comms::cVec2 vec2
 2D - vector, see the cVec2
 
typedef comms::cMat4 mat4
 4x4 float matrix, see the cMat4
 
typedef comms::cMat3 mat3
 3x3 float matrix, see the cMat3
 
typedef comms::cMath math
 
typedef comms::cStr str
 the string that is compatible with the 3DCoat engine, see the cStr
 
template<class X >
using list = comms::cList<X>
 the array template, see cList
 
typedef comms::cRect rect
 rect float, see the cRect
 
typedef comms::cQuat quat
 
typedef comms::cRotation rotation
 
typedef comms::cAngles angles
 
typedef comms::cBounds boundbox
 
typedef One2DCurve curve2d
 

Enumerations

enum  BoolOpType { BOOL_MERGE = -1 , BOOL_ADD = 0 , BOOL_SUBTRACT = 1 , BOOL_INTERSECT = 2 }
 Boolean operations type. More...
 
enum  ClusterScale {
  Uniform_Scaling = 0 , Axial_Normal = 1 , Axial_X = 2 , Axial_Y = 3 ,
  Axial_Z = 4 , Radial_Normal = 5 , Radial_X = 6 , Radial_Y = 7 ,
  Radial_Z = 8
}
 the parameters to be used for cluster scaling in Model, scaleSelectedFacesClusters
 
enum class  SpiralProfile { CIRCLE = 0 , RECTANGLE = 1 }
 The profile type of the spiral. More...
 
enum  FontStyle { Regular = 0 , Italic = 1 << 0 , Underline = 1 << 1 , StrikeThrough = 1 << 2 }
 Enumeration of the string drawing styles.
 
enum  FontWeight {
  Dont = 0 , Thin = 100 , ExtraLight = 200 , Light = 300 ,
  Normal = 400 , Medium = 500 , DemiBold = 600 , Bold = 700 ,
  ExtraBold = 800 , Black = 900
}
 
enum  ThreadProfile {
  ThreadNone = -1 , ThreadTriangle = 0 , ThreadTrapeze = 1 , ThreadRectangular = 2 ,
  ThreadRound = 3 , ThreadPersistent = 4
}
 thread profile types
 
enum  ThreadStudBodyType { StudCylinder = 0 , StudCone = 1 }
 thread body type
 
enum  SlitType {
  none = -1 , Slot = 0 , Phillipse = 1 , Pozidriv = 2 ,
  Robertson = 3 , HexSocket = 4 , SecurityHexSocket = 5 , Torx = 6 ,
  SecurityTorx = 7 , TriWing = 8 , TorqSet = 9 , TripleSquare = 10 ,
  Polydrive = 11 , DoubleSquare = 12 , SplineDrive = 13 , DoubleHex = 14 ,
  Bristol = 15 , Pentalobular = 16 , Frearson = 17 , SnakeEyes = 18 ,
  TA = 19 , TP3 = 20 , MorTorq = 21 , ClutCHG = 22 ,
  ClutCHA = 23 , GroupEyes = 24
}
 enumeration the slit types
 
enum  BoltHeadType {
  BoltNone = -1 , BoltHexa = 0 , Countersunk = 1 , BoltRound = 2 ,
  Pan = 3 , Dome = 4 , Oval = 5 , Square = 6 ,
  TShaped = 7 , Cylinder = 8 , Lamb = 9 , Rim = 10 ,
  Eye = 11 , Bugle = 12 , Clop = 13
}
 enumeration the types of the bolt head
 
enum  NutType {
  NutNone = -1 , NutHexa = 0 , Quard = 1 , Acorn = 2 ,
  Lowacorn = 3 , NutFlange = 4 , Slits = 5 , Radial = 6 ,
  NutLamb = 7 , NutRim = 8 , Selflock = 9 , NutTShaped = 10 ,
  Clamplever = 11 , NtCount = 12
}
 enumeration the types of the nut
 
enum  ThreadSurface { ThreadCylinder , ThreadCone , ThreadEdge }
 

Functions

void start_main_menu (const char *id)
 strat the main menu root items, this command may be called only from the menu making script
 
void menu_item (const char *id)
 add the item to the menu, this command may be called only from the menu making script
 
void menu_info (const char *id)
 add the information item to the menu (without any action, just message), this command may be called only from the menu making script
 
bool menu_submenu (const char *id)
 add the submenu to the current menu, this command may be called only from the menu making script
 
void menu_exit ()
 finish the current submenu, this command may be called only from the menu making script
 
void menu_separator ()
 add the separator to the current menu, this command may be called only from the menu making script
 
void menu_hotkey (const char *id, int Shift, int Ctrl, int Alt)
 set the hotkey for the menu item, this command may be called only from the menu making script
 
bool iconic_submenu (const char *id, int size)
 start the menu that will be shown on the icon click, like the navigation menu
 
bool is_new_scene ()
 is the scene new/empty?
 
bool is_steam_app ()
 is it steam app?
 
bool is_medical ()
 check if the app is medical
 
bool is_ppp ()
 chack if there are any ppp objects in scene
 
bool is_proxy ()
 check if current sculpt object is in proxy mode
 
bool is_multires ()
 check if the current sculpt object is on some multiresolution level
 
bool is_surface ()
 check if the current sculpt object is in surface mode
 
bool IsInRoom (const char *name)
 check if you are in some room
 
bool RoomExists (const char *name)
 check if the room exists
 
bool CheckIfExists (const char *path)
 check if the file exists
 
bool UseRecordScript ()
 check is scripts recording available
 
bool is_mv ()
 check if mv objects available in scene
 
bool is_ptex ()
 check if ptex is used in the current scene
 
void show_rmb_panel ()
 show the rmb panel
 
void show_space_panel (const char *Subset, int NumColumns)
 show the space panel (with limitations if need)
 
bool gltf_support ()
 gltf export supported
 
int tex_approach ()
 returns the texturing approach index (from the Textures menu)
 
void menu_insert_extensions (const char *id)
 insert extension into the main menu (may be called only from the menu making script)
 
void extensions_main_menu ()
 insert extension menu into the main menu
 
void insert_extensions ()
 insert extensions into the toolset (may be used only from the toolset.py)
 
void set_space_panel_columns_count (int num)
 set the space panel columns count (only for the toolset.py)
 
void SetAutoSnapDefaults (bool value)
 set the default value for auto-snapping, usually for the retopo/modeling rooms (in toolset.py)
 
bool menu_property (const char *id)
 returns boolean property value
 
void tools_section (const char *id)
 start the tools section in the toolset.py
 
void tools_item (const char *id)
 add the item to the tools section (toolset.py)
 
void page_suffix (const char *suffix)
 set the additional suffix for the page in the toolset.py
 
void default_tool (const char *tool)
 set the default tool for the toolset.py
 
bool IsDebug ()
 is Debug mode (for developers only)
 
void start_rmb_panel ()
 start the RNB panel. This command may be called only from the RMB response making script (curves.py, rmb.py)
 
void menu_sort ()
 sort items in the current menu
 
bool IsRecordScript ()
 is the script recording enabled?
 
bool IsInTool (const char *ToolID)
 check if we are in some tool
 
bool voxtree_item_picked ()
 check if the VoxTree item is picked
 
bool retopo_object_picked ()
 the retopo object is picked
 
bool empty_space_picked ()
 check if no object is picked
 
bool voxtree_object_picked ()
 check if the sculpt object is picked in the viewport
 
int GetCurrentToolSubmode (const char *id)
 get the current tool submode (usually for the uv/retopo tools)
 
void tools_comment (const char *id)
 comment in toolset.py for auto-documentation (legacy)
 
bool doc_mode ()
 check if script is in auto-documenting mode (legacy)
 
void PureIconic ()
 enable the radial menu mode for the space panel
 
bool lock_ui_changes ()
 check if UI changes locked (for specialized applications, like printing)
 
bool ue5_support ()
 returns if ue5 support enabled
 

Detailed Description

The coat namespace used for most 3DCoat API calls except low-level internal structures.

Enumeration Type Documentation

◆ BoolOpType

Boolean operations type.

Enumerator
BOOL_MERGE 

just merge, no booleans, it may be used only in surface mode

BOOL_ADD 

boolean add

BOOL_SUBTRACT 

boolean subtract

BOOL_INTERSECT 

boolean intersect

◆ SpiralProfile

enum class coat::SpiralProfile
strong

The profile type of the spiral.

Enumerator
CIRCLE 

circle

RECTANGLE 

rectangle

Function Documentation

◆ CheckIfExists()

bool coat::CheckIfExists ( const char * path)

check if the file exists

Parameters
paththe file path, full or relative to Coat's documents
Returns
True if exists

◆ default_tool()

void coat::default_tool ( const char * tool)

set the default tool for the toolset.py

Parameters
toolthe tool identifier

◆ doc_mode()

bool coat::doc_mode ( )

check if script is in auto-documenting mode (legacy)

Returns
the state

◆ empty_space_picked()

bool coat::empty_space_picked ( )

check if no object is picked

Returns
True if no object is picked

◆ GetCurrentToolSubmode()

int coat::GetCurrentToolSubmode ( const char * id)

get the current tool submode (usually for the uv/retopo tools)

Parameters
idthe submode identifier
Returns
the value

◆ gltf_support()

bool coat::gltf_support ( )

gltf export supported

Returns
True if supported

◆ iconic_submenu()

bool coat::iconic_submenu ( const char * id,
int size )

start the menu that will be shown on the icon click, like the navigation menu

Parameters
idthe text identifier
sizethe size of the icon
Returns
always True to structure the script

◆ is_medical()

bool coat::is_medical ( )

check if the app is medical

Returns
True if it is

◆ is_multires()

bool coat::is_multires ( )

check if the current sculpt object is on some multiresolution level

Returns
True if it is

◆ is_mv()

bool coat::is_mv ( )

check if mv objects available in scene

Returns
True if available

◆ is_new_scene()

bool coat::is_new_scene ( )

is the scene new/empty?

Returns
True if empty

◆ is_ppp()

bool coat::is_ppp ( )

chack if there are any ppp objects in scene

Returns
True if there are

◆ is_proxy()

bool coat::is_proxy ( )

check if current sculpt object is in proxy mode

Returns
True if it is

◆ is_ptex()

bool coat::is_ptex ( )

check if ptex is used in the current scene

Returns
True if used

◆ is_steam_app()

bool coat::is_steam_app ( )

is it steam app?

Returns
True if it is

◆ is_surface()

bool coat::is_surface ( )

check if the current sculpt object is in surface mode

Returns
True if it is

◆ IsDebug()

bool coat::IsDebug ( )

is Debug mode (for developers only)

Returns
True if debug

◆ IsInRoom()

bool coat::IsInRoom ( const char * name)

check if you are in some room

Parameters
namethe room name
Returns
True if you are in that room

◆ IsInTool()

bool coat::IsInTool ( const char * ToolID)

check if we are in some tool

Parameters
ToolIDthe tool identifier
Returns
True if in that tool

◆ IsRecordScript()

bool coat::IsRecordScript ( )

is the script recording enabled?

Returns
True if enabled

◆ lock_ui_changes()

bool coat::lock_ui_changes ( )

check if UI changes locked (for specialized applications, like printing)

Returns
the lock state

◆ menu_hotkey()

void coat::menu_hotkey ( const char * id,
int Shift,
int Ctrl,
int Alt )

set the hotkey for the menu item, this command may be called only from the menu making script

Parameters
idthe item id, see examples in the UserPrefs/Rooms/menu.py or cpp
Shiftset true if Shift should be pressed
Ctrlset true if Ctrl should be pressed
Altset true if Alt should be pressed

◆ menu_info()

void coat::menu_info ( const char * id)

add the information item to the menu (without any action, just message), this command may be called only from the menu making script

Parameters
idthe item text identifier

◆ menu_insert_extensions()

void coat::menu_insert_extensions ( const char * id)

insert extension into the main menu (may be called only from the menu making script)

Parameters
idthe extension id

◆ menu_item()

void coat::menu_item ( const char * id)

add the item to the menu, this command may be called only from the menu making script

Parameters
idthe item id, see examples in the UserPrefs/Rooms/menu.py or cpp. If you want to trigger some script by this menu item you may use '$execute:path/to/your/script.py' as the id.

◆ menu_property()

bool coat::menu_property ( const char * id)

returns boolean property value

Parameters
idthe property id, available values: RMBObjectInCache, RMBObjectIsSurface, ObjectHasNodes, IsCurvePrimitive, IsCurveClosed, OverSculptObject
Returns
the property value

◆ menu_submenu()

bool coat::menu_submenu ( const char * id)

add the submenu to the current menu, this command may be called only from the menu making script

Parameters
idthe submenu id/text
Returns
always True, just for structuring the script

◆ page_suffix()

void coat::page_suffix ( const char * suffix)

set the additional suffix for the page in the toolset.py

Parameters
suffixusually "S" or "V"

◆ retopo_object_picked()

bool coat::retopo_object_picked ( )

the retopo object is picked

Returns
True if picked

◆ RoomExists()

bool coat::RoomExists ( const char * name)

check if the room exists

Parameters
namethe room name/identifier
Returns
True if the room exists

◆ set_space_panel_columns_count()

void coat::set_space_panel_columns_count ( int num)

set the space panel columns count (only for the toolset.py)

Parameters
numamount of columns

◆ SetAutoSnapDefaults()

void coat::SetAutoSnapDefaults ( bool value)

set the default value for auto-snapping, usually for the retopo/modeling rooms (in toolset.py)

Parameters
valuethe default value

◆ show_space_panel()

void coat::show_space_panel ( const char * Subset,
int NumColumns )

show the space panel (with limitations if need)

Parameters
Subsetthe subset, if need
NumColumnsamount of columns

◆ start_main_menu()

void coat::start_main_menu ( const char * id)

strat the main menu root items, this command may be called only from the menu making script

Parameters
idthe menu id, see examples in the UserPrefs/Rooms/menu.py or cpp

◆ tex_approach()

int coat::tex_approach ( )

returns the texturing approach index (from the Textures menu)

Returns
the index

◆ tools_comment()

void coat::tools_comment ( const char * id)

comment in toolset.py for auto-documentation (legacy)

Parameters
idthe text of the comment

◆ tools_item()

void coat::tools_item ( const char * id)

add the item to the tools section (toolset.py)

Parameters
idthe tool identifier

◆ tools_section()

void coat::tools_section ( const char * id)

start the tools section in the toolset.py

Parameters
idthe section id

◆ ue5_support()

bool coat::ue5_support ( )

returns if ue5 support enabled

Returns
True if enabled

◆ UseRecordScript()

bool coat::UseRecordScript ( )

check is scripts recording available

Returns
True if available

◆ voxtree_item_picked()

bool coat::voxtree_item_picked ( )

check if the VoxTree item is picked

Returns
true if picked

◆ voxtree_object_picked()

bool coat::voxtree_object_picked ( )

check if the sculpt object is picked in the viewport

Returns
True if picked