Skip to content

RuleMark3D

ClassChartGuruChartGuru.3D
public sealed class RuleMark3D : ChartMark3D, IChart3DMark, IChart3DDataMark, IChartMark

A 3D rule mark: a thin line running from RuleMark3D.Start to RuleMark3D.End. Used for reference lines, drop-down guides from surface vertices, anchor-to-axis lollipops. Swift Charts equivalent: RuleMark(x:y:z:). A rule up to the default width of 0.008 plot units draws as a line in its own color, like the axis lines; a wider rule draws as a lit tube.

public RuleMark3D(DataPoint3D start, DataPoint3D end)

Creates a rule from start to end in data coordinates, 0.008 plot units wide; its ChartMark3D.DataPoint3D, which tooltips report, is their midpoint.

Parameters

NameType
startChartGuru.DataPoint3D
endChartGuru.DataPoint3D

RuleMark3D(PlottableValueRef, PlottableValueRef, PlottableValueRef)

Section titled “RuleMark3D(PlottableValueRef, PlottableValueRef, PlottableValueRef)”
public RuleMark3D(PlottableValueRef x, PlottableValueRef y, PlottableValueRef z)

Swift Charts-style constructor: RuleMark(x: .Value(…), y: .Value(…), z: .Value(…)). Creates a point-to-origin rule along the Y axis at the given X/Z position.

Parameters

NameType
xChartGuru.PlottableValueRef
yChartGuru.PlottableValueRef
zChartGuru.PlottableValueRef

public static RuleMark3D Along(Vector3 origin, RuleMark3D.Axis axis, float extent)

Axis-aligned rule: pins two of the three components and varies the third.

Parameters

NameType
originUnityEngine.Vector3
axisChartGuru.RuleMark3D.Axis
extentSystem.Single

Returns

ChartGuru.RuleMark3D

public RuleMark3D Width(float w)

Sets the rule’s width in plot units, at least 0.0005: up to the default 0.008 it draws as an unlit line in its color, like the axis lines, and wider as a lit tube of that diameter.

Parameters

NameType
wSystem.Single

Returns

ChartGuru.RuleMark3D

public override void BuildMesh(Chart3DMeshContext ctx)

Write triangles / instanced draws for this mark into the context registry.

Parameters

NameType
ctxChartGuru.Chart3DMeshContext
public override IChartMark Clone()

Creates an independent copy of this rule with its ends, width and style; later changes to either mark do not affect the other.

Returns

ChartGuru.IChartMark

public DataPoint3D End { get; }

Returns

ChartGuru.DataPoint3D

public float LineWidth { get; }

Returns

System.Single

public override ChartType MarkType { get; }

Returns

ChartGuru.ChartType