RoveSoSimulator
Loading...
Searching...
No Matches
ULidarScannerLibrary Class Reference

Blueprintable library to simulate Lidar Scanning for Autonomy. More...

#include <LidarScannerLibrary.h>

Inheritance diagram for ULidarScannerLibrary:
Collaboration diagram for ULidarScannerLibrary:

Static Public Member Functions

static TArray< FVector > ScanForLidarPoints (UObject *WorldContextObject, FVector2D ScanBoundsMin, FVector2D ScanBoundsMax, float TraceZ_Start, float TraceZ_End, float Density)
static TArray< FLidarPointScanAndGeoreferencePoints (UObject *WorldContextObject, FVector2D ScanBoundsMin, FVector2D ScanBoundsMax, float TraceZ_Start, float TraceZ_End, float Density)
static bool ExportLidarDataToCSV (const TArray< FLidarPoint > &LidarPoints, const FString &FilePath)
static void ScanWorldInChunks (UObject *WorldContextObject, FVector2D ScanBoundsMin, FVector2D ScanBoundsMax, float TraceZ_Start, float TraceZ_End, float Density, float ChunkSizeMeters, const FString &OutputDirectory)

Detailed Description

Blueprintable library to simulate Lidar Scanning for Autonomy.

Member Function Documentation

◆ ExportLidarDataToCSV()

bool ULidarScannerLibrary::ExportLidarDataToCSV ( const TArray< FLidarPoint > & LidarPoints,
const FString & FilePath )
static

Exports an array of LidarPoint data to a simple CSV text file.

Parameters
LidarPointsThe array of points to export.
FilePathThe full path where the file will be saved (e.g., "C:/LidarScans/MyScan.csv").
Returns
True if the file was written successfully, false otherwise.

◆ ScanAndGeoreferencePoints()

TArray< FLidarPoint > ULidarScannerLibrary::ScanAndGeoreferencePoints ( UObject * WorldContextObject,
FVector2D ScanBoundsMin,
FVector2D ScanBoundsMax,
float TraceZ_Start,
float TraceZ_End,
float Density )
static

Performs a grid-based ray trace over a specified area to generate a georeferenced point cloud.

Parameters
WorldContextObjectThe world context.
ScanBoundsMinThe minimum corner of the 2D scan area (X, Y).
ScanBoundsMaxThe maximum corner of the 2D scan area (X, Y).
TraceZ_StartThe Z-height to start traces from.
TraceZ_EndThe Z-height to end traces at.
DensityThe desired number of points per square meter.
Returns
An array of FLidarPoint structs containing georeferenced coordinates and classification.

◆ ScanForLidarPoints()

TArray< FVector > ULidarScannerLibrary::ScanForLidarPoints ( UObject * WorldContextObject,
FVector2D ScanBoundsMin,
FVector2D ScanBoundsMax,
float TraceZ_Start,
float TraceZ_End,
float Density )
static

Performs a grid-based ray trace over a specified area to generate a point cloud.

Parameters
WorldContextObjectThe world context.
ScanBoundsMinThe minimum corner of the 2D scan area (X, Y).
ScanBoundsMaxThe maximum corner of the 2D scan area (X, Y).
TraceZ_StartThe Z-height to start traces from.
TraceZ_EndThe Z-height to end traces at.
DensityThe desired number of points per square meter.
Returns
An array of FVectors representing the hit locations.

◆ ScanWorldInChunks()

void ULidarScannerLibrary::ScanWorldInChunks ( UObject * WorldContextObject,
FVector2D ScanBoundsMin,
FVector2D ScanBoundsMax,
float TraceZ_Start,
float TraceZ_End,
float Density,
float ChunkSizeMeters,
const FString & OutputDirectory )
static

Scans a large area in manageable chunks and exports each chunk's data to separate CSV files.

Parameters
WorldContextObjectThe world context.
ScanBoundsMinThe minimum corner of the overall 2D scan area (X, Y).
ScanBoundsMaxThe maximum corner of the overall 2D scan area (X, Y).
TraceZ_StartThe Z-height to start traces from.
TraceZ_EndThe Z-height to end traces at.
DensityThe desired number of points per square meter.
ChunkSizeMetersThe size of each chunk in meters (e.g., 200 for 200x200m chunks).
OutputDirectoryThe directory where all chunk files will be saved.

The documentation for this class was generated from the following files: