Skip to main content
Open topic with navigation

HasDetectedObject

CAPL Functions » ADAS » HasDetectedObject Valid for: CANoe DE

Note

This CAPL function is also available in C#.

Function Syntax

C#
bool HasDetectedObject.Call(int trackingId);
CAPL
int HasDetectedObject.Call(int trackingId);

Description

This function can be used to query whether a detected object of a sensor with a specific tracking Id is present.

Parameters

  • groundTruthId: Id of the object

Return Values

C#
  • true: The object is available
  • false: The object is not available
CAPL
  • 1: The object is available
  • 0: The object is not available

Example

In the examples it is assumed in each case that a DO object of the type IScenarioManager was created.

CAPL

int result = radar.HasDetectedObject.Call(5);

C#

bool result = radar.HasDetectedObject.Call(5);