Defines lane detector module based on LaneNet, i.e., DNN based lane detector.
|
| DW_API_PUBLIC dwStatus | dwLaneDetector_getCUDAStream (cudaStream_t *stream, dwLaneDetectorHandle_t obj) |
| | Gets CUDA stream used by the lane detection. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_getDetectionROI (dwRect *roi, dwLaneDetectorHandle_t obj) |
| | Get detection Region of Interest (ROI) for the detector. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_getLaneDetections (dwLaneDetection *lanes, dwLaneDetectorHandle_t obj) |
| | Gets the latest computed results in image coordinates. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_initializeLaneNet (dwLaneDetectorHandle_t *obj, uint32_t frameWidth, uint32_t frameHeight, dwContextHandle_t ctx) |
| | Initializes a lane detector module based on LaneNet. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_interpretHost (dwLaneDetectorHandle_t obj) |
| | Runs the interpretation of the processed results on the CPU. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_processDeviceAsync (const dwImageCUDA *frame, dwLaneDetectorHandle_t obj) |
| | Processes the given frame on the GPU asynchronously. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_release (dwLaneDetectorHandle_t *obj) |
| | Releases the detector module. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_reset (dwLaneDetectorHandle_t obj) |
| | Resets the lane detector module. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_setCameraExtrinsics (dwTransformation cam2rig, dwLaneDetectorHandle_t obj) |
| | Set the transformation from camera to rig. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_setCameraHandle (dwCalibratedCameraHandle_t cam, dwLaneDetectorHandle_t obj) |
| | Set the handle to the calibrated front looking camera. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_setCUDAStream (cudaStream_t stream, dwLaneDetectorHandle_t obj) |
| | Sets the CUDA stream for CUDA related operations. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_setDetectionROI (const dwRect *roi, dwLaneDetectorHandle_t obj) |
| | Set detection Region of Interest (ROI) for the detector. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetector_setMaxLaneDistance (float32_t maxDistance, dwLaneDetectorHandle_t obj) |
| | Set the maximum distance in meters at which lane markings can be detected. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetectorLaneNet_getDNNMetaData (dwDNNMetaData *metaData, dwLaneDetectorHandle_t obj) |
| | Returns the DNN metadata. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetectorLaneNet_getTemporalSmoothFactor (float32_t *factor, dwLaneDetectorHandle_t obj) |
| | Gets the temporal smoothing factor for the LaneNet based detector. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetectorLaneNet_setDetectionThreshold (float32_t threshold, dwLaneDetectorHandle_t obj) |
| | Sets the detection confidence threshold for the LaneNet based detector. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetectorLaneNet_setHorizontalFOV (float32_t hfov, dwLaneDetectorHandle_t obj) |
| | Sets the input camera horizontal Field Of View (FOV) in degree for the LaneNet-based detector. More...
|
| |
| DW_API_PUBLIC dwStatus | dwLaneDetectorLaneNet_setTemporalSmoothFactor (float32_t factor, dwLaneDetectorHandle_t obj) |
| | Sets the temporal smoothing factor for the LaneNet-based detector. More...
|
| |
◆ dwLaneDetection
◆ dwLaneMarking
◆ DW_LANEMARK_MAX_COUNT
| #define DW_LANEMARK_MAX_COUNT 16 |
◆ DW_LANEMARK_POINT_MAX_COUNT
| #define DW_LANEMARK_POINT_MAX_COUNT 128 |
◆ dwLaneDetectorHandle_t
◆ dwLaneMarkType
Type of a lane mark.
| Enumerator |
|---|
| DW_LANEMARK_TYPE_UNDEFINED | all detected lane markings are treated the same type
|
Definition at line 65 of file LaneDetector.h.
◆ dwLanePositionType
Defintion of the position of a lane marking in respect to the ego lane.
| Enumerator |
|---|
| DW_LANEMARK_POSITION_ADJACENT_LEFT | lane marking on the left side next to ego lane
|
| DW_LANEMARK_POSITION_EGO_LEFT | left lane marking of the ego lane
|
| DW_LANEMARK_POSITION_EGO_RIGHT | right lane marking of the ego lane
|
| DW_LANEMARK_POSITION_ADJACENT_RIGHT | lane marking on the right side next to ego lane
|
| DW_LANEMARK_POSITION_UNDEFINED | lane marking has been identifed but has not been categorized
|
Definition at line 71 of file LaneDetector.h.
◆ dwLaneDetector_getCUDAStream()
Gets CUDA stream used by the lane detection.
- Parameters
-
| [out] | stream | The CUDA stream currently used. |
| [in] | obj | A handle to the lane detection module. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_SUCCESS
◆ dwLaneDetector_getDetectionROI()
Get detection Region of Interest (ROI) for the detector.
- Parameters
-
| [out] | roi | ROI of frame to be processed by the detector, default to full frame |
| [in] | obj | A lane detector handle |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_getLaneDetections()
Gets the latest computed results in image coordinates.
This method has to be executed after dwLaneDetector_interpretHost() to get the current output of the detector.
- Parameters
-
| [out] | lanes | A user pointer to be filled with information about detected lanes. |
| [in] | obj | A lane detector handle. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
- Note
- Lanes are ordered from bottom to top of the image.
◆ dwLaneDetector_initializeLaneNet()
Initializes a lane detector module based on LaneNet.
- Parameters
-
| [out] | obj | A pointer to the LaneNet handle for the created module. |
| [in] | frameWidth | Width of camera frames to apply lane detector later. |
| [in] | frameHeight | Height of camera frames to apply lane detector later. |
| [in] | ctx | Specifies the handler to the context to create LaneNet. |
- Returns
- DW_INVALID_ARGUMENT - If provided context handle is invalid.
DW_SUCCESS
◆ dwLaneDetector_interpretHost()
Runs the interpretation of the processed results on the CPU.
To get the actual output of the detector, this method must be executed after dwLaneDetector_processDeviceAsync().
- Parameters
-
| [in] | obj | A lane detector handle. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_processDeviceAsync()
Processes the given frame on the GPU asynchronously.
- Parameters
-
| [in] | frame | CUDA frame to be processed for detection. |
| [in] | obj | A lane detector handle. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_release()
Releases the detector module.
- Parameters
-
| [in] | obj | A pointer to the object handle to release. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
- Note
- This method renders the handle unusable.
◆ dwLaneDetector_reset()
Resets the lane detector module.
- Parameters
-
| [in] | obj | Specifies the detector to reset. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_setCameraExtrinsics()
Set the transformation from camera to rig.
Only set after dwLaneDetector_setCameraHandle
- Parameters
-
| [in] | cam2rig | Specifies the transformation from camera to rig. |
| [in] | obj | A lane detector handle. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_setCameraHandle()
Set the handle to the calibrated front looking camera.
- Parameters
-
| [in] | cam | Specifies the handle to the calibrated front looking camera. |
| [in] | obj | A lane detector handle. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_setCUDAStream()
Sets the CUDA stream for CUDA related operations.
- Note
- The ownership of the stream remains by the callee.
- Parameters
-
| [in] | stream | The CUDA stream to be used. Default is the one passed during initialization. |
| [in] | obj | A handle to the lane detector module for which to set CUDA stream. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_SUCCESS
◆ dwLaneDetector_setDetectionROI()
Set detection Region of Interest (ROI) for the detector.
- Parameters
-
| [in] | roi | ROI of frame to be processed by the detector, default to full frame |
| [in] | obj | A lane detector handle |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetector_setMaxLaneDistance()
Set the maximum distance in meters at which lane markings can be detected.
- Parameters
-
| [in] | maxDistance | Maximum distance in meters at which lane markings can be detected. |
| [in] | obj | A lane detector handle. |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetectorLaneNet_getDNNMetaData()
Returns the DNN metadata.
- Parameters
-
| [out] | metaData | Pointer to metaData struct. |
| [in] | obj | Specifies the LaneNet handle. |
- Returns
- DW_SUCCESS, DW_INVALID_HANDLE, DW_BAD_CAST, DW_INVALID_ARGUMENT
◆ dwLaneDetectorLaneNet_getTemporalSmoothFactor()
Gets the temporal smoothing factor for the LaneNet based detector.
- Parameters
-
| [out] | factor | Average previous and current lane sample points, which is calculated as: smoothed point = factor*previous point + (1.0-factor)*current point |
| [in] | obj | A lane detector handle (must be of type LaneNet) |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetectorLaneNet_setDetectionThreshold()
Sets the detection confidence threshold for the LaneNet based detector.
- Parameters
-
| [in] | threshold | Confidence threshold above which the DNN result is considered valid lane information. |
| [in] | obj | A lane detector handle (must be of type LaneNet). |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetectorLaneNet_setHorizontalFOV()
Sets the input camera horizontal Field Of View (FOV) in degree for the LaneNet-based detector.
- Parameters
-
| [in] | hfov | Input camera horizontal FOV in degrees. Default: 60.0 degrees. |
| [in] | obj | A lane detector handle (must be of type LaneNet) |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS
◆ dwLaneDetectorLaneNet_setTemporalSmoothFactor()
Sets the temporal smoothing factor for the LaneNet-based detector.
- Parameters
-
| [in] | factor | Average previous and current lane sample points, which is calculated as: smoothed point = factor*previous point + (1.0-factor)*current point Set to 0 to turn off temporal smoothing. |
| [in] | obj | A lane detector handle (must be of type LaneNet) |
- Returns
- DW_INVALID_HANDLE - If the given context handle is invalid.
DW_BAD_CAST - If cannot cast the given handle to the expected type.
DW_SUCCESS