Navigation SDK Documentation |
Functions for accessing and searching address layer data (POIs)
SDK_ERROR SDK_API SDK_POIAddPath | ( | const SDK_WCHAR_T * | pAddrPath, |
char ** | poiHashes, | ||
SDK_INT4 | amountHashes | ||
) |
Add an additional path to search for POI data.
[in] | pAddrPath | New search path for POI data to be added. If NULL then all paths are removed. All .dat files within this directory will be scanned and used if they are valid POI information files. |
SDK_ERROR SDK_API SDK_SearchPOI | ( | SDK_INT4 | LayerID, |
const SDK_POISearchRequest * | pSearchRequest, | ||
SDK_INT4 | MaxSearchResult, | ||
SDK_UINT4 * | pSearchRequestIndex, | ||
SDK_INT4 * | pFoundSearchResult, | ||
SDK_ProgressCBFuncT | pCallBackFunc | ||
) |
Searches for one or more entries in the POI database.
The result is not delivered, but an index to the result. To get the actual result, you have to use SDK_GetPOIResult() with the returned index. The memory allocated by the API has to be freed by calling SDK_DestroyPOISearchResult() with the approriate index.
[in] | LayerID | unique (during runtime) identifier to a POI layer (see SDK_GetPOILayerCount for more details). If -1 is specified then all layers are being used. Note that this may fail if the POI data files have been generated with a goalconv.dll earlier than 2006-11-07! POIs generated by POIImporter are fine. |
[in] | pSearchRequest | a parameter of type SDK_POISearchRequest * |
[in] | MaxSearchResult | Number of the maximum returned results. |
[out] | pSearchRequestIndex | Index of the search result, use SDK_GetPOIResult() to retrieve a particular result row. |
[out] | pFoundSearchResult | Will be set to the number of search results Has to be freed by calling SDK_DestroyPOISearchResult() |
[in] | pCallBackFunc | Optional pointer to a callback function May be NULL or of type SDK_ProgressCBFuncT. |
SDK_ERROR SDK_API SDK_GetPOIResult | ( | SDK_UINT4 | SearchRequestIndex, |
SDK_UINT4 | SearchResultIndex, | ||
SDK_POISearchResult * | pSearchResult | ||
) |
Get a single result row from the POIsearch result.
Retrieve a particular search result row from a search given by SearchRequestIndex.
[in] | SearchRequestIndex | Index of the search result |
[in] | SearchResultIndex | Index of the wanted result row |
[out] | pSearchResult | POISearch result for the given row |
Get the result count for a particular poi search result identified by searchRequestIndex.
[in] | SearchRequestIndex | Index of the search. |
[out] | Count | The number of search results in the search given by searchRequestIndex. |
Releases memory for POISearch results.
[in] | SearchRequestIndex | Index of the result to destroy |
Determine the total number of available POI layers.
POI layers are found in the same directory as the executable and the path specified within the pAddrPath parameter of SDK_Initialize().
To each POI layer an ID between 0 and SDK_GetPOILayerCount()-1 gets assigned. Use SDK_GetPOILayerName() and SDK_GetPOIItemCount() to retrieve more information about the POI layer.
[out] | pCount | Number of available POI layers (>=0) |
SDK_ERROR SDK_API SDK_GetPOILayerName | ( | SDK_INT4 | LayerID, |
SDK_WCHAR_T const ** | ppLayerName | ||
) |
Receives the name of a specific POI layer.
[in] | LayerID | The ID of the POI layer. |
[out] | ppLayerName | Will be set to pointer to the name of the requested layer. This memory must not be modified or released. |
SDK_ERROR SDK_API SDK_GetPOILayerImageName | ( | SDK_INT4 | LayerID, |
SDK_WCHAR_T const ** | ppLayerImageName | ||
) |
Receives the name of the image of a specific POI layer.
[in] | LayerID | The ID of the POI layer. |
[out] | ppLayerImageName | Will be set to pointer to the name of the requested layer. This memory must not be modified or released. |
Determine the number of POIs stored in a specific layer.
[in] | LayerID | The ID of the POI layer. |
[out] | pCount | The number of POIs stored in the layer. |
Interface to activate/deactivate POI layers for rendering within the map.
[in] | LayerID | The ID of the POI layer. |
[in] | bShow | Use SDK_TRUE to activate POI layer, SDK_FALSE to disable |
Get whether a POI layer is active or not.
[in] | LayerID | The ID of the POI layer. |
[out] | bShow | SDK_TRUE when active, SDK_FALSE otherwise |
SDK_ERROR SDK_API SDK_GetPOILayerByName | ( | const SDK_WCHAR_T * | name, |
SDK_INT4 * | layerID | ||
) |
Find the index (layerID) of a POI layer given its name (which is the filename without the extension).
[in] | name | the name of the layer for which we want to know the ID |
[out] | layerID | search result: the id that corresponds to the layer with the given name. |
SDK_ERROR SDK_API SDK_EnablePOILayerLineSearchAbility | ( | SDK_INT4 | LayerID, |
SDK_BOOL | bActivate, | ||
SDK_UINT4 | CorridorWidth, | ||
SDK_UINT4 | CorridorLength | ||
) |
Interface to activate/deactivate the line searchability for a POI layer.
Activating this feature lets you search POIs on a corridor around the current route trace. To search for POIs in a layer, the procedure is as follows:
[in] | LayerID | The ID of the POI layer. |
[in] | bActivate | Use SDK_TRUE to activate the line search ability, SDK_FALSE to disable |
[in] | CorridorWidth | The width of the corridor around the current route trace |
[in] | CorridorLength | The length of the corridor around the current route trace |
Search for POIs in a given corridor around the full length current route trace incrementally.
Searches in the given corridor for POIs which have the line search ability set. For performance reasons, this function searches not the whole trace at once, but only a certain length of the trace (20km) at every call. Every further call will increment the start position of the search until the end of the trace is reached. So tho get all POIs on the whole trace, call this function multiple times. It is save to call this function in a long time loop, because if the end of the trace is reached, the function will do nothing anymore. (see SDK_EnablePOILayerLineSearchAbility for more details).
[in] | filterId | Id of the filter (the group of layers) for which the search should take place |
SDK_ERROR SDK_API SDK_SearchPOIOnCurrentTraceResetAll | ( | ) |
Reset all POI line searches.
Reset and clear all active POI line searches.
SDK_ERROR SDK_API SDK_AddPOILineSearchFilter | ( | SDK_POISearchFilter | filter, |
SDK_INT4 * | pFilterId | ||
) |
Add a search filter for a POI line search.
It is mandatory to add at least one filter for a POI line search. The filter describes which layers are searched for POIs. You can add multiple filters to the search, so you can search for certain groups of POIs. See SDK_POISearchFilter for details about the filter spec
[in] | filter | An SDK_POISearchFilter struct that describes the filter |
[out] | pFilterId | The returned Id of the newly set filter |
Remove a POI line search filter.
Remove the poi line search filter given by filterId from the POI line search.
[in] | filterId | Id of the filter to remove |
SDK_ERROR SDK_API SDK_GetPOILineSearchResultByFilter | ( | SDK_INT4 | filterId, |
SDK_UINT4 | SearchResultIndex, | ||
SDK_POISearchResult * | pSearchResult | ||
) |
Get a POI line search result restricted to a certain poi layer.
Get one result from the last POI line search.
[in] | layerID | the layer that you want to restrict the search result to |
[in] | SearchResultIndex | Index of the wanted result. See SDK_GetPOILineSearchResultCount() |
[in,out] | pSearchResult | The result |
SDK_ERROR SDK_API SDK_GetPOILineSearchResultCountByFilter | ( | SDK_INT4 | filterId, |
SDK_INT4 * | pResultCount | ||
) |
Get line search result count (restricted to a certain poi layer)
Get the result count from the last POI line search.
[in] | layerID | the layer that you want to restrict the search result to |
[in,out] | pResultCount | The result count |
SDK_ERROR SDK_API SDK_GetPOILineSearchResultByFilterAhead | ( | SDK_INT4 | filterId, |
SDK_UINT4 | SearchResultIndex, | ||
SDK_POISearchResult * | pSearchResult | ||
) |
Get the next POI line search result ahead from the current position on trace, restricted to a certain poi layer.
This function returns the nearest POI in front of the current position.
[in] | layerID | the layer that you want to restrict the search result to |
[in] | SearchResultIndex | Index of the wanted result. See SDK_GetPOILineSearchResultCount() |
[in,out] | pSearchResult | The result |
SDK_ERROR SDK_API SDK_GetPOILineSearchResultCountByFilterAhead | ( | SDK_INT4 | filterId, |
SDK_INT4 * | pResultCount | ||
) |
Get line search result count (restricted to a certain poi layer)
Get the result count from the last POI line search.
[in] | layerID | the layer that you want to restrict the search result to |
[in,out] | pResultCount | The result count |
Initialize the POI-Warner.
Setup the POI-Warner layer if existent. Only the layer with name "SafetyLayer" will be used. Only Pois in a corridor given by SearchWidth and SearchLength around the route will be checked.
[in] | SearchWidth | Width of the search corridor. |
[in] | SearchLength | Length of the search corridor. |
Show the POI-Warner layer on the map.
[in] | ShowPOIWarner | If true, show the layer |
SDK_ERROR SDK_API SDK_ResetPOIWarner | ( | ) |
Reset the POI-Warner search.
Call this function when the POI-Warner line search needs to be restarted, e.g. in a Rerouting situation or similar events.
SDK_ERROR SDK_API SDK_GetPOIWarnerInfo | ( | SDK_POIWarner * | PoiWarnerInfo, |
SDK_INT4 | Length, | ||
SDK_INT4 | Velocity, | ||
SDK_BOOL * | FoundPOI | ||
) |
Retrieve actual information about poiwarner pois on the road.
[out] | PoiWarner | Information about the next current poi on the road. |
[in] | Length | from the current position to look for pois. |
[in] | Current | velocity, needed to determine the correct warning distances. |
[out] | True,if | a poi was found. |
SDK_ERROR SDK_API SDK_SetPOIWarnerDistanceNear | ( | SDK_INT4 | DistanceSlow, |
SDK_INT4 | DistanceMiddle, | ||
SDK_INT4 | DistanceFast | ||
) |
Set the near warning distance ranges for the poi warner.
The near warning distance will be calculated like this: current velocity < 50 km/h -> DistanceSlow current velocity >= 50 km/h && current velocity <= 100 km/h -> DistanceMiddle current velocity > 100 km/h -> DistanceFast
[in] | DistanceSlow | |
[in] | DistanceMiddle | |
[in] | DistanceFast |
SDK_ERROR SDK_API SDK_SetPOIWarnerDistanceFar | ( | SDK_INT4 | DistanceSlow, |
SDK_INT4 | DistanceMiddle, | ||
SDK_INT4 | DistanceFast | ||
) |
Set the far warning distance ranges for the poi warner The far warning distance will be calculated like this: current velocity < 50 km/h -> DistanceSlow current velocity >= 50 km/h && current velocity <= 100 km/h -> DistanceMiddle current velocity > 100 km/h -> DistanceFast.
[in] | DistanceSlow | |
[in] | DistanceMiddle | |
[in] | DistanceFast |
© PTV Group 2019 | Generated on Thu Mar 28 2019 02:27:02 for NavigationSDK by 1.8.8 |