unreal.PCGSplineSamplerParams

class unreal.PCGSplineSamplerParams(dimension: PCGSplineSamplingDimension = Ellipsis, mode: PCGSplineSamplingMode = Ellipsis, fill: PCGSplineSamplingFill = Ellipsis, subdivisions_per_segment: int = 0, distance_increment: float = 0.0, num_samples: int = 0, num_planar_subdivisions: int = 0, num_height_subdivisions: int = 0, compute_direction_delta: bool = False, next_direction_delta_attribute: Name = 'None', compute_curvature: bool = False, curvature_attribute: Name = 'None', compute_segment_index: bool = False, segment_index_attribute: Name = 'None', compute_subsegment_index: bool = False, subsegment_index_attribute: Name = 'None', compute_tangents: bool = False, arrive_tangent_attribute: Name = 'None', leave_tangent_attribute: Name = 'None', compute_alpha: bool = False, alpha_attribute: Name = 'None', compute_distance: bool = False, distance_attribute: Name = 'None', compute_input_key: bool = False, input_key_attribute: Name = 'None', unbounded: bool = False, interior_sample_spacing: float = 0.0, interior_border_sample_spacing: float = 0.0, treat_spline_as_polyline: bool = False, interior_orientation: PCGSplineSamplingInteriorOrientation = Ellipsis, point_steepness: float = 0.0, seed_from_local_position: bool = False, seed_from2d_position: bool = False)

Bases: StructBase

PCGSpline Sampler Params

C++ Source:

  • Plugin: PCG

  • Module: PCG

  • File: PCGSplineSampler.h

Editor Properties: (see get_editor_property/set_editor_property)

  • alpha_attribute (Name): [Read-Write] Attribute that will contain a value in [0,1] representing how far along the point is to the end of the line. Each segment on the line represents a same-size interval. For example, if there are three segments, each segment will take up 0.333… of the interval.

  • arrive_tangent_attribute (Name): [Read-Write] Attribute that will contain the arrive tangent vector. For control points, this will be the actual arrive tangent. For non-control points, this will only be the normalized tangent at this point. Only applies to Subdivision mode.

  • compute_alpha (bool): [Read-Write]

  • compute_curvature (bool): [Read-Write]

  • compute_direction_delta (bool): [Read-Write]

  • compute_distance (bool): [Read-Write]

  • compute_input_key (bool): [Read-Write]

  • compute_segment_index (bool): [Read-Write]

  • compute_subsegment_index (bool): [Read-Write]

  • compute_tangents (bool): [Read-Write]

  • curvature_attribute (Name): [Read-Write] Attribute that will contain the curvature. Note that the radius of curvature is defined as 1/Curvature, and might need you to scale to world units

  • dimension (PCGSplineSamplingDimension): [Read-Write]

  • distance_attribute (Name): [Read-Write] Attribute that will contain the distance along the spline at the sample point.

  • distance_increment (float): [Read-Write]

  • fill (PCGSplineSamplingFill): [Read-Write]

  • input_key_attribute (Name): [Read-Write] Attribute that will contain the spline input key, a float value between [0, N], where N is the number of control points. Each range [i, i+1] represents an interpolation from 0 to 1 across spline segment i.

  • interior_border_sample_spacing (float): [Read-Write] The space between each sample point on the spline boundary. Used for computation; lower spacing is more expensive but more accurate.

  • interior_density_falloff_curve (RuntimeFloatCurve): [Read-Write] Defines the density for each sample based on its distance from the spline. X axis is normalized distance to boundary (0-1), Y axis is density value.

  • interior_orientation (PCGSplineSamplingInteriorOrientation): [Read-Write] Determines the orientation of interior points.

  • interior_sample_spacing (float): [Read-Write] The space between each sample point

  • leave_tangent_attribute (Name): [Read-Write] Attribute that will contain the leave tangent vector. For control points, this will be the actual leave tangent. For non-control points, this will only be the normalized tangent at this point. Only applies to Subdivision mode.

  • mode (PCGSplineSamplingMode): [Read-Write]

  • next_direction_delta_attribute (Name): [Read-Write] Attribute that will contain the delta angle to the next point on the spline w.r.t to the current’s point Up vector.

  • num_height_subdivisions (int32): [Read-Write]

  • num_planar_subdivisions (int32): [Read-Write]

  • num_samples (int32): [Read-Write]

  • point_steepness (float): [Read-Write] Each PCG point represents a discretized, volumetric region of world space. The points’ Steepness value [0.0 to 1.0] establishes how “hard” or “soft” that volume will be represented. From 0, it will ramp up linearly increasing its influence over the density from the point’s center to up to two times the bounds. At 1, it will represent a binary box function with the size of the point’s bounds.

  • project_onto_surface (bool): [Read-Write] Project sample points onto one possible surface given by the spline boundary.

  • seed_from2d_position (bool): [Read-Write] Controls whether we will seed the sampled points using the 3D position or the 2D (XY) position

  • seed_from_local_position (bool): [Read-Write] Controls whether we will seed the sampled points using the final world position or the local position

  • segment_index_attribute (Name): [Read-Write] Attribute that will contain the spline segment index.

  • subdivisions_per_segment (int32): [Read-Write]

  • subsegment_index_attribute (Name): [Read-Write] Attribute that will contain the sub-segment index of a point on the spline. When the sub-segment index is 0, the point is a control point on the actual spline. Only applies to Subdivision mode.

  • treat_spline_as_polyline (bool): [Read-Write] Use the spline points to form a polyline, instead of computing many sample points along the spline. This is more accurate if your spline is linear.

  • unbounded (bool): [Read-Write] If no Bounding Shape input is provided, the actor bounds are used to limit the sample generation domain. This option allows ignoring the actor bounds and generating over the entire spline. Use with caution as this may generate a lot of points.

property alpha_attribute: Name

[Read-Write] Attribute that will contain a value in [0,1] representing how far along the point is to the end of the line. Each segment on the line represents a same-size interval. For example, if there are three segments, each segment will take up 0.333… of the interval.

Type:

(Name)

property arrive_tangent_attribute: Name

[Read-Write] Attribute that will contain the arrive tangent vector. For control points, this will be the actual arrive tangent. For non-control points, this will only be the normalized tangent at this point. Only applies to Subdivision mode.

Type:

(Name)

property compute_alpha: bool

[Read-Write]

Type:

(bool)

property compute_curvature: bool

[Read-Write]

Type:

(bool)

property compute_direction_delta: bool

[Read-Write]

Type:

(bool)

property compute_distance: bool

[Read-Write]

Type:

(bool)

property compute_input_key: bool

[Read-Write]

Type:

(bool)

property compute_segment_index: bool

[Read-Write]

Type:

(bool)

property compute_subsegment_index: bool

[Read-Write]

Type:

(bool)

property compute_tangents: bool

[Read-Write]

Type:

(bool)

property curvature_attribute: Name

[Read-Write] Attribute that will contain the curvature. Note that the radius of curvature is defined as 1/Curvature, and might need you to scale to world units

Type:

(Name)

property dimension: PCGSplineSamplingDimension

[Read-Write]

Type:

(PCGSplineSamplingDimension)

property distance_attribute: Name

[Read-Write] Attribute that will contain the distance along the spline at the sample point.

Type:

(Name)

property distance_increment: float

[Read-Write]

Type:

(float)

property fill: PCGSplineSamplingFill

[Read-Write]

Type:

(PCGSplineSamplingFill)

property input_key_attribute: Name

[Read-Write] Attribute that will contain the spline input key, a float value between [0, N], where N is the number of control points. Each range [i, i+1] represents an interpolation from 0 to 1 across spline segment i.

Type:

(Name)

property interior_border_sample_spacing: float

[Read-Write] The space between each sample point on the spline boundary. Used for computation; lower spacing is more expensive but more accurate.

Type:

(float)

property interior_orientation: PCGSplineSamplingInteriorOrientation

[Read-Write] Determines the orientation of interior points.

Type:

(PCGSplineSamplingInteriorOrientation)

property interior_sample_spacing: float

[Read-Write] The space between each sample point

Type:

(float)

property leave_tangent_attribute: Name

[Read-Write] Attribute that will contain the leave tangent vector. For control points, this will be the actual leave tangent. For non-control points, this will only be the normalized tangent at this point. Only applies to Subdivision mode.

Type:

(Name)

property mode: PCGSplineSamplingMode

[Read-Write]

Type:

(PCGSplineSamplingMode)

property next_direction_delta_attribute: Name

[Read-Write] Attribute that will contain the delta angle to the next point on the spline w.r.t to the current’s point Up vector.

Type:

(Name)

property num_height_subdivisions: int

[Read-Write]

Type:

(int32)

property num_planar_subdivisions: int

[Read-Write]

Type:

(int32)

property num_samples: int

[Read-Write]

Type:

(int32)

property point_steepness: float

[Read-Write] Each PCG point represents a discretized, volumetric region of world space. The points’ Steepness value [0.0 to 1.0] establishes how “hard” or “soft” that volume will be represented. From 0, it will ramp up linearly increasing its influence over the density from the point’s center to up to two times the bounds. At 1, it will represent a binary box function with the size of the point’s bounds.

Type:

(float)

property seed_from2d_position: bool

[Read-Write] Controls whether we will seed the sampled points using the 3D position or the 2D (XY) position

Type:

(bool)

property seed_from_local_position: bool

[Read-Write] Controls whether we will seed the sampled points using the final world position or the local position

Type:

(bool)

property segment_index_attribute: Name

[Read-Write] Attribute that will contain the spline segment index.

Type:

(Name)

property subdivisions_per_segment: int

[Read-Write]

Type:

(int32)

property subsegment_index_attribute: Name

[Read-Write] Attribute that will contain the sub-segment index of a point on the spline. When the sub-segment index is 0, the point is a control point on the actual spline. Only applies to Subdivision mode.

Type:

(Name)

property treat_spline_as_polyline: bool

[Read-Write] Use the spline points to form a polyline, instead of computing many sample points along the spline. This is more accurate if your spline is linear.

Type:

(bool)

property unbounded: bool

[Read-Write] If no Bounding Shape input is provided, the actor bounds are used to limit the sample generation domain. This option allows ignoring the actor bounds and generating over the entire spline. Use with caution as this may generate a lot of points.

Type:

(bool)