docs: document smoothing processing core

This commit is contained in:
梁薄云
2026-08-04 14:29:51 +08:00
parent 4a7dd875a4
commit 8f6e97e88f
17 changed files with 153 additions and 11 deletions
@@ -18,13 +18,18 @@ public sealed class PathSmoothingPreprocessor
{
}
/// <summary>创建使用指定重采样器的预处理器。</summary>
/// <summary>创建使用指定确定性弧长重采样器的预处理器。</summary>
/// <param name="resampler">同一方向段内按 m 为单位弧长重采样的组件,不能为 <see langword="null"/>。</param>
public PathSmoothingPreprocessor(ArcLengthResampler resampler)
{
_resampler = resampler ?? throw new ArgumentNullException(nameof(resampler));
}
/// <summary>将一条粗路径请求校验、按方向拆分并按配置间距重采样。</summary>
/// <summary>校验粗路径契约、保留换向拓扑,并按配置间距拆分和重采样方向段。</summary>
/// <param name="request">不可变平滑请求;粗路径位置/弧长单位为 m、航向为 rad,且必须携带地图、车辆和配置。</param>
/// <param name="preparedPath">成功时为包含只读、同方向严格递增弧长段的预处理路径;失败时为 <see langword="null"/>。</param>
/// <param name="reason">失败时说明输入、拓扑或采样间距约束;成功时为空字符串。</param>
/// <returns>所有输入、方向分段、换向锚点和重采样检查通过时为 <see langword="true"/>;否则为 <see langword="false"/> 且不产生部分路径。</returns>
public bool TryPrepare(PathSmoothingRequest request, out PreparedPath preparedPath, out string reason)
{
preparedPath = null;