Exemplo n.º 1
0
        public override void FillMissingHeight(EFillMethod pMethod, int pKernelMultiplier)
        {
            if (MinZ != null)
            {
                ExpectedGroundZ = (float)MinZ;
                return;
            }

            int maxSteps = 1;

            switch (pMethod)
            {
            case EFillMethod.ClosestDefined:
                float?avgMinZ = GetAverageHeightFromClosestDefined(10 * maxSteps, false, EHeight.MinZ);
                if (avgMinZ != null)
                {
                    ExpectedGroundZ = (float)avgMinZ;
                }

                break;

            case EFillMethod.FromNeighbourhood:
                CDebug.Error("Unsupported method");
                break;
            }
        }
Exemplo n.º 2
0
        public virtual void FillMissingHeight(EFillMethod pMethod, int pParam = -1)
        {
            if (IsDetail && Equals(63, 75))
            {
                CDebug.WriteLine();
            }

            //if(IsDefined()) { return; }
            if (MaxFilledHeight != null)
            {
                return;
            }

            int maxSteps = 1;

            switch (pMethod)
            {
            case EFillMethod.ClosestDefined:
                MaxFilledHeight = GetAverageHeightFromClosestDefined(10 * maxSteps, false, EHeight.Smooth);
                break;

            case EFillMethod.FromNeighbourhood:
                MaxFilledHeight = GetAverageHeightFromNeighbourhood(pParam);
                //MaxFilledHeight = GetMaxHeightFromNeigbourhood();
                break;
            }
        }
Exemplo n.º 3
0
        public override void FillMissingHeight(EFillMethod pMethod, int pKernelMultiplier)
        {
            if (IsDefined())
            {
                return;
            }

            int maxSteps = 1;

            switch (pMethod)
            {
            case EFillMethod.ClosestDefined:
                MaxFilledHeight = GetAverageHeightFromClosestDefined(10 * maxSteps, false, EHeight.MaxZ);
                break;

            case EFillMethod.FromNeighbourhood:
                MaxFilledHeight = GetAverageHeightFromNeighbourhood(pKernelMultiplier);
                break;
            }
        }
Exemplo n.º 4
0
        public override void FillMissingHeight(EFillMethod pMethod, int pParam)
        {
            if (IsDetail && Equals(192, 177))
            {
                CDebug.WriteLine();
            }

            if (heightFilled)
            {
                return;
            }

            float?maxNeighbour = GetMaxHeightFromNeigbourhood();
            float?height       = GetHeight();

            if ((height == null || maxNeighbour == null) ||
                maxNeighbour > height && maxNeighbour - height > 0.3f)
            {
                heightFilled = false;
            }
            else
            {
                heightFilled = true;
                return;
            }

            if (MaxFilledHeight != null)
            {
                return;
            }

            switch (pMethod)
            {
            case EFillMethod.FromNeighbourhood:
                //MaxFilledHeight = GetAverageHeightFromNeighbourhood(pKernelMultiplier);
                MaxFilledHeight = GetKRankHeightFromNeigbourhood(pParam);
                break;
            }
        }