public void MaximalPlanCoverage() { var bound = new BoundingWorldExtent3D(); bound.IsMaximalPlanConverage.Should().BeFalse(); bound.SetMaximalCoverage(); bound.IsMaximalPlanConverage.Should().BeTrue(); }
/// <summary> /// Performs the donkey work of the request analysis /// </summary> protected void PerformScanning() { TotalNumberOfSubGridsToRequest = 0; TotalNumberOfSubGridsAnalysed = 0; TotalNumberOfCandidateSubGrids = 0; var FilterRestriction = new BoundingWorldExtent3D(); // Compute a filter spatial restriction on the world extents of the request if (WorldExtents.IsValidPlanExtent) { FilterRestriction.Assign(WorldExtents); } else { FilterRestriction.SetMaximalCoverage(); } Pipeline.FilterSet.ApplyFilterAndSubsetBoundariesToExtents(FilterRestriction); // Combine the overall existence map with the existence maps from any surface design filter aspects in // the filter set supplied with the request. foreach (var filter in Pipeline.FilterSet.Filters) { if (filter != null && filter.SpatialFilter.IsDesignMask) { _log.LogDebug($"Has Design {filter.SpatialFilter.SurfaceDesignMaskDesignUid}, ANDing with OverallExistMap"); var mask = GetExistenceMaps().GetSingleExistenceMap(Pipeline.DataModelID, Consts.EXISTENCE_MAP_DESIGN_DESCRIPTOR, filter.SpatialFilter.SurfaceDesignMaskDesignUid); if (mask != null) { Pipeline.OverallExistenceMap.SetOp_AND(mask); } else { throw new Exception($"{nameof(RequestAnalyser)}: Failed to get existence map for surface design ID:{filter.SpatialFilter.SurfaceDesignMaskDesignUid}"); } } } ScanningFullWorldExtent = !WorldExtents.IsValidPlanExtent || WorldExtents.IsMaximalPlanConverage; if (ScanningFullWorldExtent) { Pipeline.OverallExistenceMap.ScanSubGrids(Pipeline.OverallExistenceMap.FullCellExtent(), SubGridEvent); } else { Pipeline.OverallExistenceMap.ScanSubGrids(FilterRestriction, SubGridEvent); } }