45 #ifndef DW_FEATURES_FEATURES_H__ 46 #define DW_FEATURES_FEATURES_H__ 48 #include <dw/core/Config.h> 172 const uint32_t maxFeatureCount,
const uint32_t historyCapacity,
173 const uint32_t imageWidth, uint32_t imageHeight);
294 uint32_t *d_invalidIndexCount, uint32_t *d_invalidIndexes,
295 dwConstFeatureListHandle_t obj);
314 const uint32_t *d_validIndexCount,
const uint32_t *d_validIndexes,
315 const uint32_t *d_invalidIndexCount,
const uint32_t *d_invalidIndexes);
467 const uint32_t level, dwConstPyramidHandle_t obj);
483 dwPyramidHandle_t obj);
498 dwConstPyramidHandle_t obj);
617 const uint32_t maskStrideBytes,
618 const uint32_t maskWidth,
const uint32_t maskHeight,
619 dwFeatureTrackerHandle_t obj);
634 dwConstPyramidHandle_t pyramid,
635 dwFeatureTrackerHandle_t obj);
655 dwConstPyramidHandle_t previousPyramid,
656 dwConstPyramidHandle_t currentPyramid,
658 dwFeatureTrackerHandle_t obj);
692 #endif // DW_FEATURES_FEATURES_H__ uint32_t interationsLK
Upper bound on number of Lucas-Kanade iterations per level.
DW_API_PUBLIC dwStatus dwFeatureTracker_setMask(const uint8_t *d_mask, const uint32_t maskStrideBytes, const uint32_t maskWidth, const uint32_t maskHeight, dwFeatureTrackerHandle_t obj)
Sets a mask to ignore areas of the image.
NVIDIA DriveWorks API: Core Types
float float32_t
Specifies POD types.
dwFeatureStatus
Defines the possible status of a feature.
dwTrivialDataType
Specifies a type indicator of the underlying trivial data type.
DW_API_PUBLIC dwStatus dwFeatureList_getDataBasePointer(void **d_basePointer, size_t *size, dwFeatureListHandle_t obj)
Returns the start position of the data buffer that stores all of the feature list information (in GPU...
uint32_t width
Width of level 0.
DW_API_PUBLIC dwStatus dwPyramid_getCUDAStream(cudaStream_t *stream, dwConstPyramidHandle_t obj)
Gets the CUDA stream used by the pyramid.
struct dwFeatureTrackerObject const * dwConstFeaturesTrackerHandle_t
Handle representing a const feature tracker.
Defines a two-element floating-point vector.
uint32_t maxFeatureCount
Upper bound on number of features handled.
DW_API_PUBLIC dwStatus dwFeatureTracker_initialize(dwFeatureTrackerHandle_t *obj, dwContextHandle_t context, cudaStream_t stream, const dwFeatureTrackerConfig config)
Creates and initializes a feature tracker.
struct dwFeatureListObject * dwFeatureListHandle_t
Handle representing a list of 2D features.
DW_API_PUBLIC dwStatus dwFeatureTracker_release(dwFeatureTrackerHandle_t *obj)
Releases the feature tracker.
DW_API_PUBLIC dwStatus dwPyramid_initialize(dwPyramidHandle_t *obj, dwContextHandle_t context, cudaStream_t stream, const dwPyramidConfig config)
Creates and initializes an image pyramid.
NVIDIA DriveWorks API: Core Methods
DW_API_PUBLIC dwStatus dwFeatureList_setCurrentTimeIdx(uint32_t currentTimeIdx, dwFeatureListHandle_t obj)
Sets the current time index of the feature-history circular buffer.
Holds the configuration parameters for a pyramid.
struct dwFeatureListObject const * dwConstFeatureListHandle_t
Handle representing a const list of 2D features.
DW_API_PUBLIC dwStatus dwPyramid_reset(dwPyramidHandle_t obj)
Resets a pyramid.
DW_API_PUBLIC dwStatus dwFeatureList_initialize(dwFeatureListHandle_t *obj, dwContextHandle_t context, cudaStream_t stream, const uint32_t maxFeatureCount, const uint32_t historyCapacity, const uint32_t imageWidth, uint32_t imageHeight)
Creates and initializes a feature list.
DW_API_PUBLIC dwStatus dwPyramid_getLevelSize(uint32_t *width, uint32_t *height, const uint32_t level, dwConstPyramidHandle_t obj)
Gets the size of a level in the pyramid.
NVIDIA DriveWorks API: Core Exports
dwTrivialDataType dataType
Data Type of pyramid.
uint32_t height
Height of level 0.
NVIDIA DriveWorks API: Image Conversion and Streaming Functionality
The feature was succesfully tracked in the current frame.
DW_API_PUBLIC dwStatus dwFeatureList_proximityFilter(dwFeatureListHandle_t list)
Invalidates features that are too close to each other.
dwStatus
Status definition.
DW_API_PUBLIC dwStatus dwFeatureList_getFeatureListSize(uint32_t *maxFeatureCount, uint32_t *historyCapacity, dwFeatureListHandle_t obj)
Returns the maximum feature count and history capacity of the feature list.
Holds configuration parameters for a feature tracker.
DW_API_PUBLIC dwStatus dwPyramid_setCUDAStream(cudaStream_t stream, dwPyramidHandle_t obj)
Sets the CUDA stream for CUDA related operations.
DW_API_PUBLIC dwStatus dwFeatureTracker_setCUDAStream(cudaStream_t stream, dwFeatureTrackerHandle_t obj)
Sets the CUDA stream for CUDA related operations.
uint32_t levelCount
Number of levels in the pyramid.
uint32_t * ages
Age of each feature.
A feature with this entry is garbage.
struct dwFeatureTrackerObject * dwFeatureTrackerHandle_t
Handle representing a feature tracker.
DW_API_PUBLIC dwStatus dwFeatureList_reset(dwFeatureListHandle_t obj)
Resets the feature list.
The feature was just detected in the current frame.
DW_API_PUBLIC dwStatus dwFeatureTracker_reset(dwFeatureTrackerHandle_t obj)
Resets a feature tracker.
struct dwPyramidObject const * dwConstPyramidHandle_t
Handle representing a const image pyramid.
float32_t detectorScoreThreshold
Higher thresholds detect less features.
DW_API_PUBLIC dwStatus dwFeatureList_release(dwFeatureListHandle_t *obj)
Releases the feature list.
DW_API_PUBLIC dwStatus dwPyramid_getLevelData(uint8_t **d_data, size_t *strideBytes, const uint32_t level, dwPyramidHandle_t obj)
Gets the data of a level in the pyramid.
DW_API_PUBLIC dwStatus dwFeatureList_getCurrentTimeIdx(uint32_t *currentTimeIdx, dwFeatureListHandle_t obj)
Returns the current time index of feature-history circular buffer.
DW_API_PUBLIC dwStatus dwFeatureTracker_trackFeatures(dwFeatureListHandle_t list, dwConstPyramidHandle_t previousPyramid, dwConstPyramidHandle_t currentPyramid, const float32_t *d_predictedPositions, dwFeatureTrackerHandle_t obj)
Tracks features from the internal list between the previous and current images.
struct dwContextObject * dwContextHandle_t
Context handle.
DW_API_PUBLIC dwStatus dwFeatureList_setCUDAStream(cudaStream_t stream, dwFeatureListHandle_t obj)
Sets the CUDA stream for CUDA related operations.
dwVector2f * locationHistory
Location history of feature points.
DW_API_PUBLIC dwStatus dwFeatureList_compact(dwFeatureListHandle_t featureList, const uint32_t *d_validIndexCount, const uint32_t *d_validIndexes, const uint32_t *d_invalidIndexCount, const uint32_t *d_invalidIndexes)
Removes features from the list.
uint32_t * featureCount
Total number of feature points.
DW_API_PUBLIC dwStatus dwFeatureTracker_detectNewFeatures(dwFeatureListHandle_t list, dwConstPyramidHandle_t pyramid, dwFeatureTrackerHandle_t obj)
Detects new features and adds them to the feature list.
DW_API_PUBLIC dwStatus dwPyramid_build(const dwImageCUDA *image, dwPyramidHandle_t obj)
Builds the pyramid from the level 0 image.
DW_API_PUBLIC dwStatus dwPyramid_getLevelImageCUDA(const dwImageCUDA **img, const uint32_t level, dwConstPyramidHandle_t obj)
Gets the data of a level in the const pyramid as a dwImageCUDA.
DW_API_PUBLIC dwStatus dwFeatureList_getDataPointers(dwFeatureListPointers *pointers, void *basePointer, dwFeatureListHandle_t obj)
Returns the pointers to the actual data of a feature list given the base pointer. ...
Holds pointers to the data exposed by a feature list.
DW_API_PUBLIC dwStatus dwFeatureTracker_getCUDAStream(cudaStream_t *stream, dwFeatureTrackerHandle_t obj)
Gets the CUDA stream used by the feature tracker.
struct dwPyramidObject * dwPyramidHandle_t
Handle representing an image pyramid.
dwFeatureStatus * statuses
Status of each feature.
DW_API_PUBLIC dwStatus dwPyramid_getLevelCount(uint32_t *levelCount, dwConstPyramidHandle_t obj)
Gets the number of levels in the pyramid.
DW_API_PUBLIC dwStatus dwPyramid_release(dwPyramidHandle_t *obj)
Releases the pyramid.
DW_API_PUBLIC dwStatus dwFeatureList_getCUDAStream(cudaStream_t *stream, dwFeatureListHandle_t obj)
Gets the CUDA stream used by the feature list.
DW_API_PUBLIC dwStatus dwFeatureList_selectValid(uint32_t *d_validIndexCount, uint32_t *d_validIndexes, uint32_t *d_invalidIndexCount, uint32_t *d_invalidIndexes, dwConstFeatureListHandle_t obj)
Creates a list of indexes of those features with a status of detected or tracked, and list of indexes...
uint32_t windowSizeLK
Window size used in the Lucas-Kanade tracker.