holoride
Search Results for

    Show / Hide Table of Contents
    ❮ Background Fading (Built-In Render Pipeline)
    Vehicle Camera Pass-Through (AR) ❯

    Trajectory Estimation

    The Trajectory Estimation package provides prediction models and components to estimate short-horizon vehicle poses. It lets developers place or move GameObjects along the predicted future path of the vehicle.


    Installation

    1. Open the Unity Package Manager.
    2. Add the package com.holoride.elasticsdk.trajectoryestimation to your project.

    Getting Started

    Creating a Trajectory Parent

    The package includes a prefab that can be added via the Hierarchy context menu:

    1. Right-click inside your active Hierarchy window (or open the top menu GameObject).
    2. Select holoride -> Trajectory Parent.
    3. This instantiates the TrajectoryParent prefab. Attach GameObjects under this parent transform to move them along the predicted trajectory.

    Component Reference

    TrajectoryParent

    The TrajectoryParent MonoBehaviour computes the trajectory prediction. It queries the active StateReceiver sensors, calculates the constant yaw rate and longitudinal acceleration, and updates the GameObject's position and rotation on LateUpdate.

    Serialized Properties

    Property Inspector Name Description Default
    SecondsAhead Seconds Ahead The time horizon in seconds to predict the future vehicle pose. 2.0
    TurnRateFactor Turn Rate Factor The multiplier applied to the vehicle's yaw rate. 1.0
    Offset Offset The local translation offset (Vector3) relative to the vehicle's heading rotation where the prediction starts. (0,0,0)
    SmoothingFactor Smoothing Factor The visual smoothing strength. 0 disables smoothing (instant snap), larger values provide heavier smoothing. 1.0

    Scene View Gizmos

    Trajectory Estimation Debug Gizmo

    When selecting the TrajectoryParent GameObject, a debug visualization is rendered in the Scene view:

    1. The Magenta Line: Draws a straight line from the vehicle's center position to the configured local Offset position.
    2. The Cyan Curved Line: Traces the raw predicted trajectory from the offset position to the SecondsAhead time horizon.
    3. The Gray Sphere: Represents the vehicle's current real-world origin position.
    4. The Yellow Line: Connects the raw estimated target position to the smoothed GameObject position, showing the interpolation offset from the SmoothingFactor parameter.
    5. The Green Sphere: Represents the smoothed position of the TrajectoryParent GameObject.

    ❮ Background Fading (Built-In Render Pipeline)
    Vehicle Camera Pass-Through (AR) ❯
    In This Article

    Back to top
    ©   holoride
    Privacy   Imprint