Link Search Menu Expand Document

πŸ– Edge Direction (Edge)

PCGEx | Cluster Filter : Edge Direction (Edge)

Check if the edge direction is within a given range.

The Edge Direction filter compares the direction of of the edge using a dot product.


Edge Filter
A single cluster filter definition

Table of content


WIP

details/cluster-filters/filter-edge-edge-direction-lead.png

Properties


Property Description
Settings (Operand A)
Direction Settings Used to determine which edge endpoint is either the start or end.
See below.
Comparison Quality Defines the method used for comparison.
- Dot is precise (easily returns false)
- Hash method is approximative (easily returns true)
Operand B
Compare Against Type of operand B. Can be a per-edge point Attribute, or an easily overridable Constant.
Direction
FVector
Attribute to read the direction vector to compare the edge direction against.
Direction Constant Constant direction vector to compare the edge direction against.
Transform Direction If enabled, the direction to compare will be adjusted by the current edge point’ transform.
If disabled, the direction is in world space.

Direction Settings


Property Description
Direction Method Defines which endpoints β€œorder” will be used to define the direction reference for the ouputs.
Direction Choice Further refines the direction method, based on the above selection.
-Smallest to Greatest will order direction reference metrics in ascending order.
-Greatest to Smallest will order direction reference metrics in descending order.
Really it’s how the endpoint reference value is sorted, but I couldn’t call that Direction’ direction.
Dir Source Attribute The attribute that will be used by the selected method.

If the selected method is Edge Dot Attribute, the attribute will be read from Edges as an FVector direction.

Method

The Direction method, combined with the Direction Choice determine which endpoint should be considered the Start & End of the edge. The β€œdirection” of the edge used for computing outputs & properties is the safe normal going from the start to the end of the edge.

Mode Description
Endpoints order Will use the endpoints’ as ordered during cluster construction.
Endpoints indices Will use the endpoints’ point index.
Endpoints Sort Enables the use of any number of Sorting Rules to determine direction.
This method, while more expensive, is the most efficient.
Edge Dot Attribute Will use an attribute (converted to an FVector) from the edges’ and do a Dot Product with the edge’ direction.
This method, combined with Direction Choice offers full control over direction.

explainers/edge-direction-method.png


Comparison Quality


details/settings/comparison-quality.png

Dot Comparison Details

Only if Dot method is selected

Property Description
Comparison Which comparison to use.
See Numeric comparisons.
Dot Units Let you choose to work either with normalized dot range (-1 / 1) or degrees.
This affects how the attribute Dot value will be interpreted as well.
Unsigned Dot When enabled, the comparison will occur against an absolute dot value.
This is especially useful when testing against undirected lines.
Dot Value The type of value used for this probe’ search radius; either a Constant value or fetched from anAttribute
(Dot or Degrees) Constant Constant to compare against.
(Dot or Degrees) Attribute Constant to compare against.
(Dot or Degrees) Tolerance Comparison tolerance, if the selected comparison is an approximative (~) one.

Hash Comparison Details

Only if Hash method is selected

Property Description
Hash Tolerance Value Where to read the tolerance from. Can be a per-point Attribute, or an easily overridable Constant.
Hash Tolerance Attribute Attribute to read tolerance from.
Hash Tolerance Constant Constant hash tolerance value.