FSteeringUtility

Choose your operating system:

Windows

macOS

Linux

References

Module

ChaosVehiclesCore

Header

/Engine/Source/Runtime/Experimental/ChaosVehicles/ChaosVehiclesCore/Public/SteeringUtility.h

Include

#include "SteeringUtility.h"

Syntax

struct FSteeringUtility

Variables

Name Description

Public variable

 

OutSteerB

Static void Akerman(float Input, float& OutSteerA, float& OutSteerB) { float l1 = 2.0f; float l2 = 0.15f; float Gamma = DegToRad(18.0f);

FMath::Sin + FMath::Sin;

float K1 = Sqr(l1 / l2 - 2.0f * FMath::Sin(Gamma));

/float PartSum = K1 - Sqr(FMath::Cos - FMath::Cos); //float Ans = FMath::Sqrt(PartSum); float Gamma = DegToRad(18.0f);

float t = 2.0f; // width between wheels float r = 0.15f; // track length float h = r * FMath::Cos(Gamma); // track depth float s = t - 2.0f * r * FMath::Sin(Gamma);

float Beta = FMath::Atan((t - s) / (2.0f * h));

float dev = Input * 0.5f; OutSteerA = RadToDeg(FMath::Atan((t - (s - dev)) / (2.0f * h))); /**

Functions

Name Description

Public function Static

void

 

AkermannSetup

(
    float T,
    float Beta,
    float R,
    float& OutH,
    float& OutS
)

Public function Static

void

 

CalcJointPositions

(
    float T,
    float Beta,
    float R,
    FVector2D& C1,
    float& R1,
    FVector2D& C2,
    float& R2
)

Public function Static

void

 

CalculateAkermannAngle

(
    bool Flip,
    float Input,
    FVector2D& C2,
    float R1,
    float R2,
    float& OutSteerAngle,
    FVector2D& OutC1,
    FVector2D& OutPt
)

Static void CalculateAkermannAngle(float Input, float& OutSteerLeft, float& OutSteerRight , FVector2D& OutPtLeft = FVector2D(), FVector2D& OutPtRight = FVector2D()) float RestAngle; FVector2D PtRest; CalculateAkermannAngle(false, 0.0f, PtRest, RestAngle); CalculateAkermannAngle(true, Input, OutSteerLeft, OutPtLeft); CalculateAkermannAngle(false, Input, OutSteerRight, OutPtRight); OutSteerLeft -= RestAngle; OutSteerRight -= RestAngle;

Public function Static

float

 

CalculateBetaDegrees

(
    float TrackWidth,
    float WheelBase
)

Public function

 

if()

Public function Static

bool

 

IntersectTwoCircles

(
    float R1,
    float R2,
    float D,
    FVector2D& OutIntersection
)

T - Track width W - Wheelbase H - Distance form steering rod to center of axle R - Rod End Length S - Steering Rod Length (Half)Intersection of two axis aligned circles Radius R1, R2 with a separation distance between centers of D