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, start_offset: float = 0.0, end_offset: float = 0.0, max_random_offset_normalized: float = 0.0, fit_to_curve: 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, project_onto_surface: bool = False, interior_density_falloff_curve: RuntimeFloatCurve = [], 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, point_steepness: float = 0.0, seeding_mode: PCGSplineSamplingSeedingMode = Ellipsis, seed_from_local_position: bool = False, seed_from2d_position: bool = False)¶
Bases:
StructBasePCGSpline 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.compute_alpha(bool): [Read-Write] Compute an alpha value along the spline and write it to an attribute.compute_curvature(bool): [Read-Write] Compute curvature along the spline and write it to an attribute.compute_direction_delta(bool): [Read-Write] Compute the delta angle to the next point on the spline and write it to an attribute.compute_distance(bool): [Read-Write] Compute distance along the spline and write it to an attribute.compute_input_key(bool): [Read-Write] Compute an input key for each point along the spline and write the key to an attribute.compute_segment_index(bool): [Read-Write] Compute the spline segment index and write it to an attribute.compute_subsegment_index(bool): [Read-Write] Compute the sub-segment index of a point on the spline and write it to an attribute.compute_tangents(bool): [Read-Write] Compute arrive and leave tangents along the spline and write them to attributes.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]end_offset(float): [Read-Write] Distance (in cm) from the end of the spline at which sampling will end.fill(PCGSplineSamplingFill): [Read-Write]fit_to_curve(bool): [Read-Write] If the length of the spline does not divide evenly into the DistanceIncrement, the final sample point will not land on the end of the spline. Enable this to force the DistanceIncrement to be rounded up to the nearest value which would yield evenly spaced samples across the entire length of the spline.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 pointleave_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.max_random_offset_normalized(float): [Read-Write] Normalized value for the maximum possible offset for each sample point. 0.0 means no offset, and 1.0 means DistanceIncrement / 2.0.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.seeding_mode(PCGSplineSamplingSeedingMode): [Read-Write] Controls the mode for computing a sample point’s seed.segment_index_attribute(Name): [Read-Write] Attribute that will contain the spline segment index.start_offset(float): [Read-Write] Distance (in cm) along the spline at which sampling will begin.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.
- Type:
(Name)
- property compute_alpha: bool¶
[Read-Write] Compute an alpha value along the spline and write it to an attribute.
- Type:
(bool)
- property compute_curvature: bool¶
[Read-Write] Compute curvature along the spline and write it to an attribute.
- Type:
(bool)
- property compute_direction_delta: bool¶
[Read-Write] Compute the delta angle to the next point on the spline and write it to an attribute.
- Type:
(bool)
- property compute_distance: bool¶
[Read-Write] Compute distance along the spline and write it to an attribute.
- Type:
(bool)
- property compute_input_key: bool¶
[Read-Write] Compute an input key for each point along the spline and write the key to an attribute.
- Type:
(bool)
- property compute_segment_index: bool¶
[Read-Write] Compute the spline segment index and write it to an attribute.
- Type:
(bool)
- property compute_subsegment_index: bool¶
[Read-Write] Compute the sub-segment index of a point on the spline and write it to an attribute.
- Type:
(bool)
- property compute_tangents: bool¶
[Read-Write] Compute arrive and leave tangents along the spline and write them to attributes.
- 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:
- property distance_attribute: Name¶
[Read-Write] Attribute that will contain the distance along the spline at the sample point.
- Type:
(Name)
- property end_offset: float¶
[Read-Write] Distance (in cm) from the end of the spline at which sampling will end.
- Type:
(float)
- property fill: PCGSplineSamplingFill¶
[Read-Write]
- Type:
- property fit_to_curve: bool¶
[Read-Write] If the length of the spline does not divide evenly into the DistanceIncrement, the final sample point will not land on the end of the spline. Enable this to force the DistanceIncrement to be rounded up to the nearest value which would yield evenly spaced samples across the entire length of the spline.
- Type:
(bool)
- 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_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.
- Type:
- property interior_orientation: PCGSplineSamplingInteriorOrientation¶
[Read-Write] Determines the orientation of interior points.
- 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.
- Type:
(Name)
- property max_random_offset_normalized: float¶
[Read-Write] Normalized value for the maximum possible offset for each sample point. 0.0 means no offset, and 1.0 means DistanceIncrement / 2.0.
- Type:
(float)
- property mode: PCGSplineSamplingMode¶
[Read-Write]
- Type:
- 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 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 project_onto_surface: bool¶
[Read-Write] Project sample points onto one possible surface given by the spline boundary.
- Type:
(bool)
- 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 seeding_mode: PCGSplineSamplingSeedingMode¶
[Read-Write] Controls the mode for computing a sample point’s seed.
- Type:
- property segment_index_attribute: Name¶
[Read-Write] Attribute that will contain the spline segment index.
- Type:
(Name)
- property start_offset: float¶
[Read-Write] Distance (in cm) along the spline at which sampling will begin.
- Type:
(float)
- 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)