documentation:entity
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
documentation:entity [2011/06/06 22:32] – created mhgamework | documentation:entity [2024/08/26 13:25] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 10: | Line 10: | ||
A **MeshPart** represents a single piece of geometry (which can be rendered with one DrawPrimitive call). It does not contain any material info. | A **MeshPart** represents a single piece of geometry (which can be rendered with one DrawPrimitive call). It does not contain any material info. | ||
- | \\TODO: rename to Geometry or smth? EDIT: <color red>Now that this is also shared, this should be renamed.</ | + | \\ TODO: rename to Geometry or smth? EDIT: <color red>Now that this is also shared, this should be renamed.</ |
{{ : | {{ : | ||
- | ===== Classes ===== | + | ===== Classes |
+ | |||
+ | < | ||
+ | digraph { | ||
+ | node [shape = box]; | ||
+ | IMesh -> MeshCoreData -> IMeshPart; | ||
+ | IMesh -> MeshCollisionData; | ||
+ | IMeshPart -> MeshPartGeometryData; | ||
+ | } | ||
+ | </ | ||
==== IMesh, IEntity, IObject, IMeshPart ==== | ==== IMesh, IEntity, IObject, IMeshPart ==== | ||
Line 62: | Line 71: | ||
Represents the core geometry of the model. | Represents the core geometry of the model. | ||
Note: could be made uniform GeometryData | Note: could be made uniform GeometryData | ||
+ | |||
+ | |||
+ | ===== Classes : Client ===== | ||
+ | |||
+ | **IMPORTANT!** This design is similar to the design of the other Client Modules like ‘Terrain.Client’ and ‘Player.Client’ | ||
+ | |||
+ | **TODO:** Implement the creation of the actor by using a Factory passed by the constructor. This moves the creation/ | ||
+ | |||
+ | ==== EntityPhysicsActorBuilder ==== | ||
+ | |||
+ | This class uses an EntityFullData as input to produce a PhysX actor object that represents collision for the given entity. | ||
+ | | ||
+ | This should be extended later on to allow simplified versions of the model or a collision model composed of boxes, spheres, convexmesh. | ||
+ | These simplified versions should be build in the editor | ||
+ | |||
+ | Currently there is one PhysX actor per entity, and one PhysX shape per model. | ||
+ | |||
+ | There is some serious unwinding done concerning the scaling of entities or models. The scaling of model and entity is done directly on the model’s vertices for the TriangleMesh. So is the models local matrix. Remainder of the entity transform is stored in the global pose of the actor. | ||
+ | |||
+ | ==== EntityClientPhysics ==== | ||
+ | |||
+ | This class implements the IClientPhysics interface, thus representing a client physics entity. These objects are static by default. Support for dynamic entities should be implemented at a later time. | ||
+ | ===== Classes : AL ===== | ||
+ | |||
+ | ==== EntityWizardsEditorExtension (AL) ==== | ||
+ | |||
+ | This is the main class for the application logic. It holds gui stuff and loads everything else. It also holds the data system. | ||
+ | |||
+ | ===== Classes : Data System ===== | ||
+ | |||
+ | There are no more FullData-classes. Data should be split in coherent pieces. The EditorObject performs the function of the FullData, by holding all the pieces (for editor use) | ||
+ | |||
+ | ==== EditorObject (AL?) ==== | ||
+ | |||
+ | This class is still used in the old system. It should however become the Object DataObject for the Editor Data System | ||
+ | |||
+ | TODO: Editor meshes currently have no spatial information stored with them in the EditorObject | ||
+ | |||
+ | ==== EditorMesh (AL?) ==== | ||
+ | |||
+ | Represents a single renderable model, containing parts for different materials. | ||
+ | |||
+ | <color red> | ||
+ | |||
+ | ==== EditorMeshPart (AL?) ==== | ||
+ | |||
+ | Represents a single material part of a Mesh | ||
+ | |||
+ | |||
+ | |||
+ | ===== Classes : Mesh rendering===== | ||
+ | |||
+ | ==== ColladaMeshImporter (AL) ==== | ||
+ | |||
+ | Is responsible for converting a collada file, to a The Wizards Mesh, using Editor functionality. | ||
+ | |||
+ | Note: this class could be adjusted that it simply loads a colladaMesh as a mesh in the WorldDatabase, | ||
+ | |||
+ | <color red> | ||
+ | |||
+ | ==== EditorMeshPartRenderData (AL) ==== | ||
+ | |||
+ | This class is responsible for loading, building resources and rendering an EditorMeshPart. | ||
+ | |||
+ | Note that this is a **shared resource**, it can be used in different meshes at the same time | ||
+ | |||
+ | ==== EditorMeshRenderData (AL) ==== | ||
+ | |||
+ | This class is responsible for loading, building resources and rendering an EditorMeshPart. | ||
+ | |||
+ | Note that this is a **shared resource**, it can be used in different meshes at the same time | ||
+ | |||
+ | This class also requires material creation, so it should have access to some methods of the render system. | ||
+ | |||
+ | |||
+ | |||
documentation/entity.1307399537.txt.gz · Last modified: 2024/08/26 13:57 (external edit)