Axiom.Components.Paging.Grid2PageStrategy.GetPageID C# (CSharp) 메소드

GetPageID() 공개 메소드

public GetPageID ( Axiom.Math.Vector3 worldPos, PagedWorldSection section ) : PageID
worldPos Axiom.Math.Vector3
section PagedWorldSection
리턴 PageID
        public override PageID GetPageID(Vector3 worldPos, PagedWorldSection section)
        {
            Grid2DPageStrategyData stratData = (Grid2DPageStrategyData)section.StrategyData;

            Vector2 gridpos = Vector2.Zero;
            stratData.ConvetWorldToGridSpace(worldPos, ref gridpos);
            int row = 0, col = 0;
            stratData.DetermineGridLocation(gridpos, ref row, ref col);
            return stratData.CalculatePageID(row, col);
        }
    }