Files
modeling-app/docs/kcl-std/functions/std-planes-xAxis.md
2025-07-01 13:56:16 -05:00

80 KiB

title, subtitle, excerpt, layout
title subtitle excerpt layout
planes::xAxis Function in std::planes Find X axis of a plane. manual

Find X axis of a plane.

planes::xAxis(@plane: Plane): Point3d

Arguments

Name Type Description Required
plane Plane The solid whose face is being queried. Yes

Returns

Point3d - A point in three dimensional space.

Examples

mySolid = startSketchOn(XZ)
  |> polygon(numSides = 3, radius = 1, center = [3, 2])
  |> extrude(length = 5)

target = planeOf(mySolid, face = END)

xTarget = planes::xAxis(target)
assert(xTarget[0], isEqualTo = 1)
assert(xTarget[1], isEqualTo = 0)
assert(xTarget[2], isEqualTo = 0)

Rendered example of planes::xAxis 0