/* ----------------------------------------------------------------------------- This source file is part of OGRE (Object-oriented Graphics Rendering Engine) For the latest info, see http://www.ogre3d.org/ Copyright (c) 2000-2012 Torus Knot Software Ltd Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ----------------------------------------------------------------------------- */ #ifndef __Ogre_PageFileFormats_H__ #define __Ogre_PageFileFormats_H__ #include "OgrePagingPrerequisites.h" /** \addtogroup Optional Components * @{ */ /** \addtogroup Paging * Some details on paging component */ /*@{*/ /** @file The paging file format is a composite one - a single file / stream can contain data which is not necessarily all read by a single class. Instead, data chunks can be read by different classes, allowing the format to be extended to different types smoothly. @par Paging world files have by default an extension ".world", but that is not a requirement. Internally, the only thing that matters is the data chunks and their identifiers, which are 4-character codes embedded in a uint32 as calculated by StreamSerialiser::makeIdentifier. All data will be read and written using DataStream and the StreamSerialiser class. @par Data types are expressed at the lowest level exposed by the StreamSerialiser class, which is used to read / write this file. @par Chunk Definitions @par PagedWorld (Identifier 'PWLD')\n [Version 1]
Name Type Description
World Name char* The name of the world - should be unique
PagedWorldSection List Chunk List A variable-length list of nested PagedWorldSection chunks
@par PagedWorldSection (Identifier 'PWSC')\n [Version 1]
Name Type Description
World Section Name char* The name of the world section - should be unique within world
Bounding box AABB AABB of this world section in world space
PageStrategy name char* The name of the PageStrategy class this world section uses to manage pages
Page Strategy Data Nested Chunk PageStrategy specific data for this world section
@par PagedStrategyData (Identifier defined by subclass)\n [Version 1]
Name Type Description
PageStrategy defined ??? This chunk will contain data as defined by the specific PageStrategyData used by the parent PagedWorldSection
@par Page (Identifier 'PAGE')\n [Version 1]
Name Type Description
Page ID uint32 The identifier of the page
PageContentCollection list Nested chunk list 1-n nested chunks of type PageContentCollection
@par PageContentCollection (Identifier 'PGCC')\n [Version 1]
Name Type Description
Factory name char* The name of the content collection factory
PageContentCollectionData chunk Nested chunk Data required to initialise & configure the content collection
@par PageContentCollectionData (Identifier defined by subclass)\n [Version 1]
Name Type Description
PageContentCollection subclass defined ??? This chunk will contain data as defined by the specific PageContentCollection subclass
@par PageContent (Identifier 'PGCN')\n [Version 1]
Name Type Description
Factory name char* The name of the content factory
PageContentData chunk Nested chunk Data required to initialise & configure the content
@par PageContentData (Identifier defined by subclass)\n [Version 1]
Name Type Description
PageContent subclass defined ??? This chunk will contain data as defined by the specific PageContent subclass
*/ /*@}*/ /*@}*/ #endif