Initial commit
This commit is contained in:
@@ -0,0 +1,59 @@
|
||||
/*
|
||||
* Copyright 2016 The Cartographer Authors
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
namespace CartographerSharp.Models.Mapping;
|
||||
|
||||
/// <summary>
|
||||
/// Protocol buffer representation of submaps options for 2D.
|
||||
/// </summary>
|
||||
public struct SubmapsOptions2D
|
||||
{
|
||||
/// <summary>
|
||||
/// Number of range data before adding a new submap. Each submap will get twice
|
||||
/// the number of range data inserted: First for initialization without being
|
||||
/// matched against, then while being matched.
|
||||
/// </summary>
|
||||
[JsonPropertyName("num_range_data")]
|
||||
public int NumRangeData { get; set; }
|
||||
|
||||
[JsonPropertyName("grid_options_2d")]
|
||||
public GridOptions2D GridOptions2D { get; set; }
|
||||
|
||||
[JsonPropertyName("range_data_inserter_options")]
|
||||
public RangeDataInserterOptions RangeDataInserterOptions { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Optional high resolution grid options for fine-grained Ceres scan matching.
|
||||
/// When set, a second grid at higher resolution is maintained per submap and
|
||||
/// passed to CeresScanMatcher2D for more precise wall alignment.
|
||||
/// </summary>
|
||||
[JsonPropertyName("high_res_grid_options_2d")]
|
||||
public GridOptions2D? HighResGridOptions2D { get; set; }
|
||||
|
||||
public SubmapsOptions2D(
|
||||
int numRangeData,
|
||||
GridOptions2D gridOptions2D,
|
||||
RangeDataInserterOptions rangeDataInserterOptions,
|
||||
GridOptions2D? highResGridOptions2D = null)
|
||||
{
|
||||
NumRangeData = numRangeData;
|
||||
GridOptions2D = gridOptions2D;
|
||||
RangeDataInserterOptions = rangeDataInserterOptions;
|
||||
HighResGridOptions2D = highResGridOptions2D;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user