PDR/1.Software/PDR 1.0/include/pdr_trackSmooth.h

61 lines
2.1 KiB
C
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

/******************** (C) COPYRIGHT 2020 Geek************************************
* File Name : simulator_location_pdr.h
* Department : Sensor Algorithm Team
* Current Version : V1.2
* Author : logzhan
* Date of Issued : 2020.7.4
* Comments : PDR 输出轨迹平滑的功能函数
********************************************************************************/
#ifndef _PDR_TRACK_SMOOTHING_H_
#define _PDR_TRACK_SMOOTHING_H_
#ifdef __cplusplus
extern "C" {
#endif
#include "pdr_linearFit.h"
#include "pdr_sensor.h"
#define FITTING_DOCK_SIZE 3
typedef struct DoublePair {
double x;
double y;
} DoublePair;
/**----------------------------------------------------------------------
* Function : trackSmoothingSlideWindowSet
* Description : 使用平滑模块时首先调用的函数,设定轨迹平滑窗口大小。也可以通过此函
* 数重新设定滑动窗口大小。
* Input : slideWindowSize: 滑动窗口的大小
* Output : size : 当前滑动窗口的大小一般大于0,当返回大小为0时说明设置滑动
* 窗口为0或是内存申请失败。
* Date : 2020/7/4 logzhan
*---------------------------------------------------------------------**/
int TrackSmoothSetWinSize(size_t slideWindowSize);
/**----------------------------------------------------------------------
* Function : trackSmoothing
* Description : 轨迹平滑模块关闭后需要使用此函数释放资源
* Input : lat: 输入纬度
* lon: 输入经度
* Output : outLat: 输出纬度存储变量指针
* outLon: 输出经度存储变量指针
* return: 返回处理状态
* Date : 2020/7/4 logzhan
*---------------------------------------------------------------------**/
int pdr_trackSmooth(double lat, double lon, double *outLat, double *outLon);
/**----------------------------------------------------------------------
* Function : trackSmoothSlideWindowFree
* Description : 轨迹平滑模块关闭后需要使用此函数释放资源
* Date : 2020/7/4 logzhan
*---------------------------------------------------------------------**/
int freeTrackSmooth(void);
#ifdef __cplusplus
}
#endif
#endif // !_TRACK_SMOOTHING_MODULE_H_