Scene kit command

sculpt.stroke

Sculpt Stroke

Sculpts along `points` (or a `drag`) with a brush.

Kit
Scene 0.1.0 (.kscene)
Changes the document
yes

Parameters

Parameters of sculpt.stroke
NameTypeRequiredDescription
autoSmoothnumbernoSmoothing after each dab, 0 to 1
dragnumber[]noGrab and snake hook with world points: how far the last point drags, in metres [x, y, z]
falloff"smooth" | "sphere" | "root" | "sharp" | "linear" | "constant"noHow the brush fades to its edge
frontFacesOnlybooleannoOnly vertices facing the view
kind"draw" | "clayStrips" | "smooth" | "grab" | "inflate" | "crease" | "flatten" | "pinch" | "snakeHook" | "mask" | "drawFaceSets"noThe brush
pointsany[]yesThe stroke's path: [x, y] viewport pixels, or [x, y, z] world points on the surface
pressuresnumber[]noPen pressure at each point, 0 to 1
radiusnumbernoRadius in viewport pixels (50)
spacingnumbernoDistance between dabs as a share of the radius (0.1)
strengthnumbernoStrength at the centre, 0 to 1 (0.5; 1 for grab, snake hook, crease, mask, draw face sets)
subtractbooleannoThe other direction: in instead of out, unmask instead of mask
symmetryboolean[]noMirror dabs across the object's own [x, y, z] (x on)
usePressurebooleannoPen pressure scales the strength (true)
worldRadiusnumbernoWith world points: the radius in metres (0.25)

Call through scene_run

text
scene_run {
  "path": "<file>.kscene",
  "steps": [{ "command": "sculpt.stroke", "params": { "points": <any[]> } }]
}

The required parameters, with placeholders for their types: not a tested example. Optional: autoSmooth, drag, falloff, frontFacesOnly, kind, pressures, radius, spacing, strength, subtract, symmetry, usePressure, worldRadius. scene_run answers the step’s result in completed[i].result.

Result

The kit gives no result schema for this command.

Parameter schema

json
{
  "additionalProperties": false,
  "properties": {
    "autoSmooth": {
      "description": "Smoothing after each dab, 0 to 1",
      "type": "number"
    },
    "drag": {
      "description": "Grab and snake hook with world points: how far the last point drags, in metres [x, y, z]",
      "items": {
        "type": "number"
      },
      "type": "array"
    },
    "falloff": {
      "description": "How the brush fades to its edge",
      "enum": [
        "smooth",
        "sphere",
        "root",
        "sharp",
        "linear",
        "constant"
      ],
      "type": "string"
    },
    "frontFacesOnly": {
      "description": "Only vertices facing the view",
      "type": "boolean"
    },
    "kind": {
      "description": "The brush",
      "enum": [
        "draw",
        "clayStrips",
        "smooth",
        "grab",
        "inflate",
        "crease",
        "flatten",
        "pinch",
        "snakeHook",
        "mask",
        "drawFaceSets"
      ],
      "type": "string"
    },
    "points": {
      "description": "The stroke's path: [x, y] viewport pixels, or [x, y, z] world points on the surface",
      "items": {},
      "type": "array"
    },
    "pressures": {
      "description": "Pen pressure at each point, 0 to 1",
      "items": {
        "type": "number"
      },
      "type": "array"
    },
    "radius": {
      "description": "Radius in viewport pixels (50)",
      "type": "number"
    },
    "spacing": {
      "description": "Distance between dabs as a share of the radius (0.1)",
      "type": "number"
    },
    "strength": {
      "description": "Strength at the centre, 0 to 1 (0.5; 1 for grab, snake hook, crease, mask, draw face sets)",
      "type": "number"
    },
    "subtract": {
      "description": "The other direction: in instead of out, unmask instead of mask",
      "type": "boolean"
    },
    "symmetry": {
      "description": "Mirror dabs across the object's own [x, y, z] (x on)",
      "items": {
        "type": "boolean"
      },
      "type": "array"
    },
    "usePressure": {
      "description": "Pen pressure scales the strength (true)",
      "type": "boolean"
    },
    "worldRadius": {
      "description": "With world points: the radius in metres (0.25)",
      "type": "number"
    }
  },
  "required": [
    "points"
  ],
  "type": "object"
}

Generated from the command list of @kition/[email protected] and the kit itself (scene_commands through @kition/[email protected], built from KitionAI/kition-scene@4d06faf). As data: commands.jsonl.