Update api spec (#218)
* YOYO NEW API SPEC! * I have generated the latest API! --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
cc0bb86a53
commit
8c56b88113
File diff suppressed because it is too large
Load Diff
@ -219,38 +219,6 @@ class default_camera_zoom(BaseModel):
|
|||||||
model_config = ConfigDict(protected_namespaces=())
|
model_config = ConfigDict(protected_namespaces=())
|
||||||
|
|
||||||
|
|
||||||
class default_camera_enable_sketch_mode(BaseModel):
|
|
||||||
"""Enable sketch mode, where users can sketch 2D geometry. Users choose a plane to sketch on."""
|
|
||||||
|
|
||||||
animated: bool
|
|
||||||
|
|
||||||
distance_to_plane: float
|
|
||||||
|
|
||||||
origin: Point3d
|
|
||||||
|
|
||||||
ortho: bool
|
|
||||||
|
|
||||||
type: Literal["default_camera_enable_sketch_mode"] = (
|
|
||||||
"default_camera_enable_sketch_mode"
|
|
||||||
)
|
|
||||||
|
|
||||||
x_axis: Point3d
|
|
||||||
|
|
||||||
y_axis: Point3d
|
|
||||||
|
|
||||||
model_config = ConfigDict(protected_namespaces=())
|
|
||||||
|
|
||||||
|
|
||||||
class default_camera_disable_sketch_mode(BaseModel):
|
|
||||||
"""Disable sketch mode, from the default camera."""
|
|
||||||
|
|
||||||
type: Literal["default_camera_disable_sketch_mode"] = (
|
|
||||||
"default_camera_disable_sketch_mode"
|
|
||||||
)
|
|
||||||
|
|
||||||
model_config = ConfigDict(protected_namespaces=())
|
|
||||||
|
|
||||||
|
|
||||||
class export(BaseModel):
|
class export(BaseModel):
|
||||||
"""Export the scene to a file."""
|
"""Export the scene to a file."""
|
||||||
|
|
||||||
@ -787,22 +755,6 @@ class mouse_click(BaseModel):
|
|||||||
model_config = ConfigDict(protected_namespaces=())
|
model_config = ConfigDict(protected_namespaces=())
|
||||||
|
|
||||||
|
|
||||||
class sketch_mode_enable(BaseModel):
|
|
||||||
"""Enable sketch mode on the given plane. If you want to sketch on a face, use `enable_sketch_mode` instead."""
|
|
||||||
|
|
||||||
animated: bool
|
|
||||||
|
|
||||||
disable_camera_with_plane: Optional[Point3d] = None
|
|
||||||
|
|
||||||
ortho: bool
|
|
||||||
|
|
||||||
plane_id: str
|
|
||||||
|
|
||||||
type: Literal["sketch_mode_enable"] = "sketch_mode_enable"
|
|
||||||
|
|
||||||
model_config = ConfigDict(protected_namespaces=())
|
|
||||||
|
|
||||||
|
|
||||||
class sketch_mode_disable(BaseModel):
|
class sketch_mode_disable(BaseModel):
|
||||||
"""Disable sketch mode. If you are sketching on a face, be sure to not disable sketch mode until you have extruded. Otherwise, your object will not be fused with the face."""
|
"""Disable sketch mode. If you are sketching on a face, be sure to not disable sketch mode until you have extruded. Otherwise, your object will not be fused with the face."""
|
||||||
|
|
||||||
@ -844,6 +796,8 @@ class enable_sketch_mode(BaseModel):
|
|||||||
|
|
||||||
ortho: bool
|
ortho: bool
|
||||||
|
|
||||||
|
planar_normal: Optional[Point3d] = None
|
||||||
|
|
||||||
type: Literal["enable_sketch_mode"] = "enable_sketch_mode"
|
type: Literal["enable_sketch_mode"] = "enable_sketch_mode"
|
||||||
|
|
||||||
model_config = ConfigDict(protected_namespaces=())
|
model_config = ConfigDict(protected_namespaces=())
|
||||||
@ -1244,8 +1198,6 @@ ModelingCmd = RootModel[
|
|||||||
default_camera_look_at,
|
default_camera_look_at,
|
||||||
default_camera_perspective_settings,
|
default_camera_perspective_settings,
|
||||||
default_camera_zoom,
|
default_camera_zoom,
|
||||||
default_camera_enable_sketch_mode,
|
|
||||||
default_camera_disable_sketch_mode,
|
|
||||||
export,
|
export,
|
||||||
entity_get_parent_id,
|
entity_get_parent_id,
|
||||||
entity_get_num_children,
|
entity_get_num_children,
|
||||||
@ -1289,7 +1241,6 @@ ModelingCmd = RootModel[
|
|||||||
set_tool,
|
set_tool,
|
||||||
mouse_move,
|
mouse_move,
|
||||||
mouse_click,
|
mouse_click,
|
||||||
sketch_mode_enable,
|
|
||||||
sketch_mode_disable,
|
sketch_mode_disable,
|
||||||
get_sketch_mode_plane,
|
get_sketch_mode_plane,
|
||||||
curve_set_constraint,
|
curve_set_constraint,
|
||||||
|
122
spec.json
122
spec.json
@ -19048,79 +19048,6 @@
|
|||||||
"type"
|
"type"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"description": "Enable sketch mode, where users can sketch 2D geometry. Users choose a plane to sketch on.",
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"animated": {
|
|
||||||
"description": "Should we animate or snap for the camera transition?",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
"distance_to_plane": {
|
|
||||||
"description": "How far to the sketching plane?",
|
|
||||||
"type": "number",
|
|
||||||
"format": "float"
|
|
||||||
},
|
|
||||||
"origin": {
|
|
||||||
"description": "What's the origin of the sketching plane?",
|
|
||||||
"allOf": [
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Point3d"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"ortho": {
|
|
||||||
"description": "Should the camera use orthographic projection? In other words, should an object's size in the rendered image stay constant regardless of its distance from the camera.",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"enum": [
|
|
||||||
"default_camera_enable_sketch_mode"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"x_axis": {
|
|
||||||
"description": "Which 3D axis of the scene should be the X axis of the sketching plane?",
|
|
||||||
"allOf": [
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Point3d"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"y_axis": {
|
|
||||||
"description": "Which 3D axis of the scene should be the Y axis of the sketching plane?",
|
|
||||||
"allOf": [
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Point3d"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"animated",
|
|
||||||
"distance_to_plane",
|
|
||||||
"origin",
|
|
||||||
"ortho",
|
|
||||||
"type",
|
|
||||||
"x_axis",
|
|
||||||
"y_axis"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"description": "Disable sketch mode, from the default camera.",
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"enum": [
|
|
||||||
"default_camera_disable_sketch_mode"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"type"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"description": "Export the scene to a file.",
|
"description": "Export the scene to a file.",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
@ -20446,46 +20373,6 @@
|
|||||||
"window"
|
"window"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"description": "Enable sketch mode on the given plane. If you want to sketch on a face, use `enable_sketch_mode` instead.",
|
|
||||||
"type": "object",
|
|
||||||
"properties": {
|
|
||||||
"animated": {
|
|
||||||
"description": "Animate the transition to sketch mode.",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
"disable_camera_with_plane": {
|
|
||||||
"nullable": true,
|
|
||||||
"description": "Disable the camera entirely for sketch mode and sketch on a plane (this would be the normal of that plane).",
|
|
||||||
"allOf": [
|
|
||||||
{
|
|
||||||
"$ref": "#/components/schemas/Point3d"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"ortho": {
|
|
||||||
"description": "Use an orthographic camera.",
|
|
||||||
"type": "boolean"
|
|
||||||
},
|
|
||||||
"plane_id": {
|
|
||||||
"description": "Sketch on this plane.",
|
|
||||||
"type": "string",
|
|
||||||
"format": "uuid"
|
|
||||||
},
|
|
||||||
"type": {
|
|
||||||
"type": "string",
|
|
||||||
"enum": [
|
|
||||||
"sketch_mode_enable"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"required": [
|
|
||||||
"animated",
|
|
||||||
"ortho",
|
|
||||||
"plane_id",
|
|
||||||
"type"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"description": "Disable sketch mode. If you are sketching on a face, be sure to not disable sketch mode until you have extruded. Otherwise, your object will not be fused with the face.",
|
"description": "Disable sketch mode. If you are sketching on a face, be sure to not disable sketch mode until you have extruded. Otherwise, your object will not be fused with the face.",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
@ -20576,6 +20463,15 @@
|
|||||||
"description": "Should the camera use orthographic projection? In other words, should an object's size in the rendered image stay constant regardless of its distance from the camera.",
|
"description": "Should the camera use orthographic projection? In other words, should an object's size in the rendered image stay constant regardless of its distance from the camera.",
|
||||||
"type": "boolean"
|
"type": "boolean"
|
||||||
},
|
},
|
||||||
|
"planar_normal": {
|
||||||
|
"nullable": true,
|
||||||
|
"description": "If provided, ensures that the normal of the sketch plane must be aligned with this supplied normal (otherwise the camera position will be used to infer the normal to point towards the viewer)",
|
||||||
|
"allOf": [
|
||||||
|
{
|
||||||
|
"$ref": "#/components/schemas/Point3d"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
"type": {
|
"type": {
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"enum": [
|
"enum": [
|
||||||
|
Reference in New Issue
Block a user