C# Class Axiom.Components.Paging.PagedWorldSection

Represents a section of the PagedWorld which uses a given PageStrategy, and which is made up of a generally localised set of Page instances.
Afficher le fichier Open project: WolfgangSt/axiom Class Usage Examples

Méthodes publiques

Свойство Type Description
CHUNK_ID uint
CHUNK_VERSION ushort

Protected Properties

Свойство Type Description
mAABB Axiom.Math.AxisAlignedBox
mName string
mPageProvider PageProvider
mPages Page>.Dictionary
mParent PageWorld
mSceneMgr Axiom.Core.SceneManager
mStrategy Axiom.Components.Paging.PageStrategy
mStrategyData IPageStrategyData

Méthodes publiques

Méthode Description
AttachPage ( Page page ) : void

Attach a page to this section.

DetachPage ( Page page ) : void

Detach a page to this section.

FrameEnd ( float timeElapsed ) : void

Called when the frame ends

FrameStart ( float timeSinceLastFrame ) : void

Called when the frame starts

GetPage ( PageID pageID ) : Page

Retrieves a Page.

GetPageID ( Vector3 worldPos ) : PageID

Get the page ID for a given world position.

HoldPage ( PageID pageID ) : void

Ask for a page to be kept in memory if it's loaded.

Load ( StreamSerializer stream ) : bool

Load this section from a stream (returns true if successful)

LoadOrCreatePage ( Vector3 worldPos ) : Page

Load or create a page against this section covering the given world space position.

LoadPage ( PageID pageID ) : void

Ask for a page to be loaded with the given (section-relative) PageID

LoadPage ( PageID pageID, bool forceSynchronous ) : void

Ask for a page to be loaded with the given (section-relative) PageID

LoadProcedualPage ( Page page ) : bool

Give a section the opportunity to load page content procedurally

NotifyCamerea ( Camera cam ) : void

Notify a section of the current camera

PagedWorldSection ( PageWorld parent ) : System

Construct a new instance, specifying just the parent (expecting to load).

PagedWorldSection ( string name, PageWorld parent, Axiom.Components.Paging.PageStrategy strategy, SceneManager sm ) : System

PrepareProcedualePage ( Page page ) : bool

Give a section the opportunity to prepare page content procedurally.

ReadPageStream ( PageID pageID ) : StreamSerializer

Get a serialiser set up to read Page data for the given PageID.

RemoveAllPages ( ) : void

Remove all pages immediately.

Save ( StreamSerializer stream ) : void

Save this section to a stream

SetSceneManager ( SceneManager sm ) : void

Change the SceneManager.

SetSceneManager ( string smName ) : void

Change the SceneManager.

SetStrategy ( string stratName ) : void

ToString ( ) : string

UnloadPage ( Page page, bool sync ) : void

UnloadPage ( PageID pageId ) : void

Ask for a page to be unloaded with the given (section-relative) PageID

UnloadPage ( PageID pageID, bool forceSynchonous ) : void

Ask for a page to be unloaded with the given (section-relative) PageID

UnloadProcedualPage ( Page page ) : bool

Give a section the opportunity to unload page content procedurally.

UnprepareProcedualPage ( Page page ) : bool

Give a section the opportunity to unprepare page content procedurally.

This method indicates that a page should be retained if it's already in memory, but if it's not then it won't trigger a load. This is useful for retaining pages that have just gone out of range, but which you don't want to unload just yet because it's quite possible they may come back into the active set again very quickly / easily. But at the same time, if they've already been purged you don't want to force them to load. This is the 'maybe' region of pages.

WritePageStream ( PageID pageID ) : StreamSerializer

Get a serialiser set up to write Page data for the given PageID.

Method Details

AttachPage() public méthode

Attach a page to this section.
public AttachPage ( Page page ) : void
page Page
Résultat void

DetachPage() public méthode

Detach a page to this section.
public DetachPage ( Page page ) : void
page Page
Résultat void

FrameEnd() public méthode

Called when the frame ends
public FrameEnd ( float timeElapsed ) : void
timeElapsed float
Résultat void

FrameStart() public méthode

Called when the frame starts
public FrameStart ( float timeSinceLastFrame ) : void
timeSinceLastFrame float
Résultat void

GetPage() public méthode

Retrieves a Page.
public GetPage ( PageID pageID ) : Page
pageID PageID
Résultat Page

GetPageID() public méthode

Get the page ID for a given world position.
public GetPageID ( Vector3 worldPos ) : PageID
worldPos Vector3
Résultat PageID

HoldPage() public méthode

Ask for a page to be kept in memory if it's loaded.
public HoldPage ( PageID pageID ) : void
pageID PageID
Résultat void

Load() public méthode

Load this section from a stream (returns true if successful)
public Load ( StreamSerializer stream ) : bool
stream Axiom.Serialization.StreamSerializer
Résultat bool

LoadOrCreatePage() public méthode

Load or create a page against this section covering the given world space position.
public LoadOrCreatePage ( Vector3 worldPos ) : Page
worldPos Vector3
Résultat Page

LoadPage() public méthode

Ask for a page to be loaded with the given (section-relative) PageID
public LoadPage ( PageID pageID ) : void
pageID PageID The page ID to load
Résultat void

LoadPage() public méthode

Ask for a page to be loaded with the given (section-relative) PageID
public LoadPage ( PageID pageID, bool forceSynchronous ) : void
pageID PageID The page ID to load
forceSynchronous bool If true, the page will always be loaded synchronously
Résultat void

LoadProcedualPage() public méthode

Give a section the opportunity to load page content procedurally
public LoadProcedualPage ( Page page ) : bool
page Page
Résultat bool

NotifyCamerea() public méthode

Notify a section of the current camera
public NotifyCamerea ( Camera cam ) : void
cam Axiom.Core.Camera
Résultat void

PagedWorldSection() public méthode

Construct a new instance, specifying just the parent (expecting to load).
public PagedWorldSection ( PageWorld parent ) : System
parent PageWorld
Résultat System

PagedWorldSection() public méthode

public PagedWorldSection ( string name, PageWorld parent, Axiom.Components.Paging.PageStrategy strategy, SceneManager sm ) : System
name string
parent PageWorld
strategy Axiom.Components.Paging.PageStrategy
sm Axiom.Core.SceneManager
Résultat System

PrepareProcedualePage() public méthode

Give a section the opportunity to prepare page content procedurally.
public PrepareProcedualePage ( Page page ) : bool
page Page
Résultat bool

ReadPageStream() public méthode

Get a serialiser set up to read Page data for the given PageID.
public ReadPageStream ( PageID pageID ) : StreamSerializer
pageID PageID
Résultat Axiom.Serialization.StreamSerializer

RemoveAllPages() public méthode

Remove all pages immediately.
public RemoveAllPages ( ) : void
Résultat void

Save() public méthode

Save this section to a stream
public Save ( StreamSerializer stream ) : void
stream Axiom.Serialization.StreamSerializer
Résultat void

SetSceneManager() public méthode

Change the SceneManager.
public SetSceneManager ( SceneManager sm ) : void
sm Axiom.Core.SceneManager The instance of the SceneManager
Résultat void

SetSceneManager() public méthode

Change the SceneManager.
public SetSceneManager ( string smName ) : void
smName string The instance name of the SceneManager
Résultat void

SetStrategy() public méthode

public SetStrategy ( string stratName ) : void
stratName string
Résultat void

ToString() public méthode

public ToString ( ) : string
Résultat string

UnloadPage() public méthode

public UnloadPage ( Page page, bool sync ) : void
page Page
sync bool
Résultat void

UnloadPage() public méthode

Ask for a page to be unloaded with the given (section-relative) PageID
public UnloadPage ( PageID pageId ) : void
pageId PageID The page ID to unload
Résultat void

UnloadPage() public méthode

Ask for a page to be unloaded with the given (section-relative) PageID
public UnloadPage ( PageID pageID, bool forceSynchonous ) : void
pageID PageID The page ID to unload
forceSynchonous bool If true, the page will always be unloaded synchronously
Résultat void

UnloadProcedualPage() public méthode

Give a section the opportunity to unload page content procedurally.
public UnloadProcedualPage ( Page page ) : bool
page Page
Résultat bool

UnprepareProcedualPage() public méthode

Give a section the opportunity to unprepare page content procedurally.
This method indicates that a page should be retained if it's already in memory, but if it's not then it won't trigger a load. This is useful for retaining pages that have just gone out of range, but which you don't want to unload just yet because it's quite possible they may come back into the active set again very quickly / easily. But at the same time, if they've already been purged you don't want to force them to load. This is the 'maybe' region of pages.
public UnprepareProcedualPage ( Page page ) : bool
page Page
Résultat bool

WritePageStream() public méthode

Get a serialiser set up to write Page data for the given PageID.
public WritePageStream ( PageID pageID ) : StreamSerializer
pageID PageID
Résultat Axiom.Serialization.StreamSerializer

Property Details

CHUNK_ID public_oe static_oe property

public static uint CHUNK_ID
Résultat uint

CHUNK_VERSION public_oe static_oe property

public static ushort CHUNK_VERSION
Résultat ushort

mAABB protected_oe property

protected AxisAlignedBox,Axiom.Math mAABB
Résultat Axiom.Math.AxisAlignedBox

mName protected_oe property

protected string mName
Résultat string

mPageProvider protected_oe property

protected PageProvider,Axiom.Components.Paging mPageProvider
Résultat PageProvider

mPages protected_oe property

protected Dictionary mPages
Résultat Page>.Dictionary

mParent protected_oe property

protected PageWorld,Axiom.Components.Paging mParent
Résultat PageWorld

mSceneMgr protected_oe property

protected SceneManager,Axiom.Core mSceneMgr
Résultat Axiom.Core.SceneManager

mStrategy protected_oe property

protected PageStrategy,Axiom.Components.Paging mStrategy
Résultat Axiom.Components.Paging.PageStrategy

mStrategyData protected_oe property

protected IPageStrategyData mStrategyData
Résultat IPageStrategyData