Graphics namespace
All the graphics system: rendering, shaders, models, lighting, textures,...
Contents
- Reference
This namespace includes classes related to graphics rendering in the game. Some things included are models, textures and materials.
This namespace is deeply related with the RenderWare namespace; elements in Graphics are high-level representations, easy to use, whereas RenderWare elements are low-level representations which are not needed to modify in most cases.
- Graphics::
Model represents a 3D model made of triangulated meshes. It uses objects like RenderWare:: VertexBuffer, RenderWare:: IndexBuffer, RenderWare:: Animations,... - Graphics::
Texture represents a game texture, which can be 2D or 3D (cube textures). It uses RenderWare:: Raster. - Graphics::
Material contains the information of how a model mesh must be painted, that is, which shaders and textures it uses. It uses RenderWare:: CompiledState
Namespaces
- namespace ActiveState
- namespace GlobalState
- namespace Renderer_addresses
- namespace RenderUtils
- This namespace contains most internal stuff related with rendering, such as Direct3D Device and shaders, shader data, etc.
Classes
- class cBufferDraw
- class cFrustumCull
- class cImageData
- class cImageDataRaw
- class cLayerGroup
- An implementation of ILayer that renders a sequence of layers.
- class cLightingConfig
- class cMaterialInfo
- class cMaterialManager
- The implementation of IMaterialManager; this should only be used for extending and detouring.
- class cMeshData
- class cMITextureSet
- class cModelInstance
- class cModelInstanceAnimations
- class cModelManager
- The implementation of IModelManager; this should only be used for extending and detouring.
- class cModelWorld
- struct cMWHull
- class cMWModelInternal
- struct cMWTransformedHull
-
template<typename T>class CompiledShader
- struct cPlane
- struct cRenderJobInfo
- class cRenderTargetManager
-
template<typename ObjClass, uint32_t TYPE_ID>class cRwDirectResource
- struct cScreenInfo
- class cTextureManager
- The implementation of ITextureManager; this should only be used for extending and detouring.
- struct FilterSettings
-
template<typename Vertex>class GeneratedMesh
- class GmdlRenderAsset
- class IAmbientOccluder
- class IGraphicsManager
- class ILayer
- This interfaces defines a layer that is rendered every game loop, by callings its ILayer::
DrawLayer() method. - class ILightingManager
- This manager handles the lighting configurations in the game.
- class ILightingWorld
- A lighting world is a space with a specific lighting configuration.
- class IMaterialManager
- This manager stores the information of materials, which are used to control the visual appearance of game objects.
- class IModelManager
- This manager stores the model worlds in the game; for more info, check the IModelWorld class.
- class IModelWorld
- A model world is a space where models can be rendered in the game.
- class IRawImage
- class IRenderer
- This class manages the rendering process in the game.
- class IRenderTargetManager
- class IShadowWorld
- class ITextureManager
- class IThumbnailManager
- class LambdaLayer
- struct Light
- class Material
- Represents a material that controls the visual appearance of game objects.
- class MaterialShader
- class Model
- struct MorphHandleInfo
- struct NamedShaderDataUniform
- class PlanetThumbnailRequest
- struct PosNormalVertex
- struct PosUvVertex
- struct RenderStatistics
- struct RenderTargetID
- class ShaderBuilder
- struct ShaderBuilderEntry
- struct ShaderDataInformation
- struct ShaderDataUniform
- struct ShadowMapInfo
- class StandardShader
- struct StandardVertex
- struct StandardVertexCompact
- class Texture
- High level representation of a game texture.
- class TextureContainer
- class UnkMatManager
Enums
- enum class ModelGroups: uint32_t { DeformHandle = 0x1BA53EA, DeformHandleOverdraw = 0x1BA53EB, Background = 0x223E8E0, Overdraw = 0x22FFF11, EffectsMask = 0x23008D4, TestEnv = 0x26F3933, PartsPaintEnv = 0xFE39DE0, Skin = 0xFEB8DF2, RotationRing = 0x31390732, RotationBall = 0x31390733, SocketConnector = 0x4FF4AF74, AnimatedCreature = 0x509991E6, TestMode = 0x509AA7C9, Vertebra = 0x513CDFC1, PaletteSkin = 0x71257E8B, ExcludeFromPinning = 0x900C6ADD, Palette = 0x900C6AE5, BallConnector = 0x900C6CDD, Rigblock = 0x9138FD8D, RigblockEffect = 0x4FE3913, GameBackground = 0x64AC354 }
- enum class LayerIndices { ClearScene = 0, Planets = 7, PlanetRings = 8, TerrainRTT = 9, Terrain = 10, PlanetRibbons1 = 11, TerrainModels = 12, Level = 13, BlobShadows = 14, PreMain = 15, Main = 16, CreatureAnim = 17, PostMain = 18, CreatureFXAnim = 19, EffectsMask = 20, UI = 30 }
- The available layer indices that can be used for adding renderers.
- enum class LayerIndices2 { Clear = 1, EffectsBackground = 3, Unk4 = 4, Unk5 = 5, Unk6 = 6, TerrainRTT = 7, Terrain = 8, PlanetNationalBoundaries = 9, UnkA = 0xA, BlobShadows = 0xB, UnkC = 0xC, UnkD = 0xD, UnkE = 0xE, UnkF = 0x0F, Unk11 = 0x11, Unk12 = 0x12, Unk14 = 0x14, Unk15 = 0x15, EffectsForeground = 0x16, PlanetTradeRoutes = 0x19, Unk1A = 0x1A, Unk1B = 0x1B, Unk1E = 0x1E, Unk20 = 0x20, Unk21 = 0x21, Unk25 = 0x25 }
- enum TextureMessages { kMsgTextureExtractCompleted = 0x522264D }
- enum class CollisionMode: uint8_t { BoundingBox = 0, TightBoundingBox = 1, HullKDTree = 2, Lod0KDTree = 3, Unk4 = 4 }
- enum ModelFlags { kModelFlagUseColor = 0x2, kModelFlagObjectTypeColor = 0x8, kModelFlagOverrideRaycastMode = 0x100, kModelFlagHighRes = 0x2000, kModelFlagIsLoaded = 0x4000, kModelFlagVisible = 0x8000, kModelFlagOverrideBoundingBox = 0x10000, kModelFlagOverrideBoundingRadius = 0x20000, kModelFlagNeedsBake = 0x40000 }
- enum TextureFlags { kTextureFlagIsLoading = 1, kTextureFlagForceLoad = 2, kTextureFlagSetLOD = 4, kTextureFlagModified = 8 }
Typedefs
- using VertexShader = CompiledShader<IDirect3DVertexShader9>
- using PixelShader = CompiledShader<IDirect3DPixelShader9>
-
using cRwRasterDirectResource = cRwDirectResource<RenderWare::
Raster, 0x2F4E681C> - using TextureFilterCallback_t = bool(*)(Texture*)
- using ModelPredicate_t = bool(*)(Model*, void*)
- using BoneCallback_t = void(*)(int, Matrix4&, Vector3&, void*)
Functions
- auto Addresses(ActiveState) -> namespace
- ASSERT_SIZE(cBufferDraw, 0x1B4)
- auto Addresses(cBufferDraw) -> namespace
- ASSERT_SIZE(cPlane, 0x28)
- ASSERT_SIZE(cFrustumCull, 0xF0)
- auto Addresses(cFrustumCull) -> namespace
- ASSERT_SIZE(cImageData, 0x14)
- ASSERT_SIZE(cImageDataRaw, 0x2C)
- ASSERT_SIZE(cLayerGroup, 0x20)
- ASSERT_SIZE(cLightingConfig, 0x144)
- ASSERT_SIZE(cMaterialInfo, 0x1C)
- auto Addresses(cMaterialManager) -> namespace
- ASSERT_SIZE(cMeshData, 0x58)
-
ASSERT_SIZE(cMITextureSet::
Entry, 0x10) - ASSERT_SIZE(cMITextureSet, 0x70)
- ASSERT_SIZE(cModelInstance, 0x100)
- ASSERT_SIZE(cModelInstanceAnimations, 0xA0)
- ASSERT_SIZE(cModelManager, 0x60)
- auto Addresses(cModelWorld) -> namespace
- ASSERT_SIZE(PixelShader, 0x130)
- auto Addresses(CompiledShader) -> namespace
- auto GetVertexShaders() -> eastl::vector<VertexShader>&
- auto GetPixelShaders() -> eastl::vector<PixelShader>&
-
void ReadCompiledVertexShaders(IO::
IStream* pStream) -
void ReadCompiledPixelShaders(IO::
IStream* pStream) - ASSERT_SIZE(cRenderTargetManager, 0x2C)
- auto GenerateScreenPlane(float z = 0.0) -> GeneratedMesh<PosUvVertex>*
- auto Addresses(GlobalState) -> namespace
- auto Addresses(IGraphicsManager) -> namespace
- auto Addresses(ILightingManager) -> namespace
- ASSERT_SIZE(Material, 0x48)
- auto Addresses(IMaterialManager) -> namespace
- auto Addresses(IModelManager) -> namespace
- ASSERT_SIZE(cMWHull, 0x1C)
- ASSERT_SIZE(cMWTransformedHull, 0x28)
- ASSERT_SIZE(MorphHandleInfo, 0x5C)
- auto Addresses(IModelWorld) -> namespace
- ASSERT_SIZE(cRenderJobInfo, 11* 4)
- void GetMousePosition(int& mouseX, int& mouseY)
- auto Addresses(IRenderManager) -> namespace
- auto Addresses(IRenderer) -> namespace
- auto Addresses(IRenderTargetManager) -> namespace
-
auto GetMainColorRTT() -> RenderWare::
Raster* -
auto GetMainDepthRTT() -> RenderWare::
Raster* - auto Addresses(IShadowManager) -> namespace
- auto Addresses(IShadowWorld) -> namespace
- auto Addresses(ITextureManager) -> namespace
- ASSERT_SIZE(PlanetThumbnailRequest, 0x2C)
- auto Addresses(IThumbnailManager) -> namespace
- ASSERT_SIZE(MaterialShader, 0x48)
- auto Addresses(MaterialShader) -> namespace
- ASSERT_SIZE(Model, 0x94)
- ASSERT_SIZE(cMWModelInternal, 0x13C)
- auto Addresses(Model) -> namespace
- ASSERT_SIZE(RenderStatistics, 0x2C)
- auto Addresses(RenderUtils) -> namespace
- ASSERT_SIZE(ShaderBuilder, 0x2C8)
- auto Addresses(ShaderBuilder) -> namespace
- ASSERT_SIZE(StandardShader, 0x348)
- auto Addresses(StandardShader) -> namespace
Enum documentation
enum class Graphics:: ModelGroups: uint32_t
#include <Spore/Graphics/IModelManager.h>
enum class Graphics:: LayerIndices
#include <Spore/Graphics/IRenderer.h>
The available layer indices that can be used for adding renderers.
Most of these have been copied from Darkspore globals.lua, so they might not match for Spore.
enum class Graphics:: LayerIndices2
#include <Spore/Graphics/IRenderer.h>
Enumerators | |
---|---|
Clear |
|
EffectsBackground |
Used by effects renderer. |
Unk4 |
|
Unk5 |
|
Unk6 |
|
TerrainRTT |
Renders RTTs used by the planet: water reflection & refraction and scatter map. |
Terrain |
Renders planet land, water, atmosphere, etc. Terrain:: |
PlanetNationalBoundaries |
Renders the national boundaries in a planet. Used by |
UnkA |
|
BlobShadows |
Used by Simulator BlobShadowManager. |
UnkC |
|
UnkD |
|
UnkE |
|
UnkF |
|
Unk11 |
|
Unk12 |
|
Unk14 |
|
Unk15 |
|
EffectsForeground |
Used by effects renderer, renders foreground screen effects. |
PlanetTradeRoutes |
Renders the trade route ribbons in a planet. Used by |
Unk1A |
|
Unk1B |
|
Unk1E |
|
Unk20 |
|
Unk21 |
|
Unk25 |
|
enum Graphics:: TextureMessages
#include <Spore/Graphics/ITextureManager.h>
enum class Graphics:: CollisionMode: uint8_t
#include <Spore/Graphics/Model.h>
Enumerators | |
---|---|
BoundingBox |
Just intersect with the bounding box. |
TightBoundingBox |
|
HullKDTree |
Check intersection with the hull mesh. |
Lod0KDTree |
Check intersection with the LOD0 mesh. |
Unk4 |
|
enum Graphics:: ModelFlags
#include <Spore/Graphics/Model.h>
enum Graphics:: TextureFlags
#include <Spore/Graphics/Texture.h>
Enumerators | |
---|---|
kTextureFlagIsLoading |
Tells the texture is still loading. |
kTextureFlagForceLoad |
Forces the texture to load. If no .raster exists, this will look for rw4 as well. |
kTextureFlagSetLOD |
If enabled, SetLOD() will be called to the texture with the current level of detail. |
kTextureFlagModified |
Tells that the texture has been modified and the changes have not been saved. |
Typedef documentation
typedef CompiledShader<IDirect3DVertexShader9> Graphics:: VertexShader
#include <Spore/Graphics/CompiledShader.h>
typedef CompiledShader<IDirect3DPixelShader9> Graphics:: PixelShader
#include <Spore/Graphics/CompiledShader.h>
typedef cRwDirectResource<RenderWare:: Raster, 0x2F4E681C> Graphics:: cRwRasterDirectResource
#include <Spore/Graphics/cRwDirectResource.h>
typedef bool(*Graphics:: TextureFilterCallback_t)(Texture*)
#include <Spore/Graphics/IMaterialManager.h>
typedef bool(*Graphics:: ModelPredicate_t)(Model*, void*)
#include <Spore/Graphics/IModelWorld.h>
typedef void(*Graphics:: BoneCallback_t)(int, Matrix4&, Vector3&, void*)
#include <Spore/Graphics/IModelWorld.h>
Function documentation
namespace Graphics:: Addresses(ActiveState)
#include <Spore/Graphics/ActiveState.h>
Graphics:: ASSERT_SIZE(cBufferDraw,
0x1B4)
#include <Spore/Graphics/BufferDraw.h>
namespace Graphics:: Addresses(cBufferDraw)
#include <Spore/Graphics/BufferDraw.h>
Graphics:: ASSERT_SIZE(cPlane,
0x28)
#include <Spore/Graphics/cFrustumCull.h>
Graphics:: ASSERT_SIZE(cFrustumCull,
0xF0)
#include <Spore/Graphics/cFrustumCull.h>
namespace Graphics:: Addresses(cFrustumCull)
#include <Spore/Graphics/cFrustumCull.h>
Graphics:: ASSERT_SIZE(cImageData,
0x14)
#include <Spore/Graphics/cImageDataRaw.h>
Graphics:: ASSERT_SIZE(cImageDataRaw,
0x2C)
#include <Spore/Graphics/cImageDataRaw.h>
Graphics:: ASSERT_SIZE(cLayerGroup,
0x20)
#include <Spore/Graphics/cLayerGroup.h>
Graphics:: ASSERT_SIZE(cLightingConfig,
0x144)
#include <Spore/Graphics/cLightingConfig.h>
Graphics:: ASSERT_SIZE(cMaterialInfo,
0x1C)
#include <Spore/Graphics/cMaterialInfo.h>
namespace Graphics:: Addresses(cMaterialManager)
#include <Spore/Graphics/cMaterialManager.h>
Graphics:: ASSERT_SIZE(cMeshData,
0x58)
#include <Spore/Graphics/cMeshData.h>
Graphics:: ASSERT_SIZE(cMITextureSet:: Entry,
0x10)
#include <Spore/Graphics/cMITextureSet.h>
Graphics:: ASSERT_SIZE(cMITextureSet,
0x70)
#include <Spore/Graphics/cMITextureSet.h>
Graphics:: ASSERT_SIZE(cModelInstance,
0x100)
#include <Spore/Graphics/cModelInstance.h>
Graphics:: ASSERT_SIZE(cModelInstanceAnimations,
0xA0)
Graphics:: ASSERT_SIZE(cModelManager,
0x60)
#include <Spore/Graphics/cModelManager.h>
namespace Graphics:: Addresses(cModelWorld)
#include <Spore/Graphics/cModelWorld.h>
Graphics:: ASSERT_SIZE(PixelShader,
0x130)
#include <Spore/Graphics/CompiledShader.h>
namespace Graphics:: Addresses(CompiledShader)
#include <Spore/Graphics/CompiledShader.h>
eastl::vector<VertexShader>& Graphics:: GetVertexShaders()
#include <Spore/Graphics/CompiledShader.h>
eastl::vector<PixelShader>& Graphics:: GetPixelShaders()
#include <Spore/Graphics/CompiledShader.h>
void Graphics:: ReadCompiledVertexShaders(IO:: IStream* pStream)
#include <Spore/Graphics/CompiledShader.h>
void Graphics:: ReadCompiledPixelShaders(IO:: IStream* pStream)
#include <Spore/Graphics/CompiledShader.h>
Graphics:: ASSERT_SIZE(cRenderTargetManager,
0x2C)
GeneratedMesh<PosUvVertex>* Graphics:: GenerateScreenPlane(float z = 0.0)
#include <Spore/Graphics/GeneratedMesh.h>
namespace Graphics:: Addresses(GlobalState)
#include <Spore/Graphics/GlobalState.h>
namespace Graphics:: Addresses(IGraphicsManager)
#include <Spore/Graphics/IGraphicsManager.h>
namespace Graphics:: Addresses(ILightingManager)
#include <Spore/Graphics/ILightingManager.h>
Graphics:: ASSERT_SIZE(Material,
0x48)
#include <Spore/Graphics/IMaterialManager.h>
namespace Graphics:: Addresses(IMaterialManager)
#include <Spore/Graphics/IMaterialManager.h>
namespace Graphics:: Addresses(IModelManager)
#include <Spore/Graphics/IModelManager.h>
Graphics:: ASSERT_SIZE(cMWHull,
0x1C)
#include <Spore/Graphics/IModelWorld.h>
Graphics:: ASSERT_SIZE(cMWTransformedHull,
0x28)
#include <Spore/Graphics/IModelWorld.h>
Graphics:: ASSERT_SIZE(MorphHandleInfo,
0x5C)
#include <Spore/Graphics/IModelWorld.h>
namespace Graphics:: Addresses(IModelWorld)
#include <Spore/Graphics/IModelWorld.h>
Graphics:: ASSERT_SIZE(cRenderJobInfo,
11* 4)
#include <Spore/Graphics/IRenderer.h>
void Graphics:: GetMousePosition(int& mouseX,
int& mouseY)
#include <Spore/Graphics/IRenderer.h>
namespace Graphics:: Addresses(IRenderManager)
#include <Spore/Graphics/IRenderer.h>
namespace Graphics:: Addresses(IRenderer)
#include <Spore/Graphics/IRenderer.h>
namespace Graphics:: Addresses(IRenderTargetManager)
RenderWare:: Raster* Graphics:: GetMainColorRTT()
RenderWare:: Raster* Graphics:: GetMainDepthRTT()
namespace Graphics:: Addresses(IShadowManager)
#include <Spore/Graphics/IShadowWorld.h>
namespace Graphics:: Addresses(IShadowWorld)
#include <Spore/Graphics/IShadowWorld.h>
namespace Graphics:: Addresses(ITextureManager)
#include <Spore/Graphics/ITextureManager.h>
Graphics:: ASSERT_SIZE(PlanetThumbnailRequest,
0x2C)
#include <Spore/Graphics/IThumbnailManager.h>
namespace Graphics:: Addresses(IThumbnailManager)
#include <Spore/Graphics/IThumbnailManager.h>
Graphics:: ASSERT_SIZE(MaterialShader,
0x48)
#include <Spore/Graphics/MaterialShader.h>
namespace Graphics:: Addresses(MaterialShader)
#include <Spore/Graphics/MaterialShader.h>
Graphics:: ASSERT_SIZE(Model,
0x94)
#include <Spore/Graphics/Model.h>
Graphics:: ASSERT_SIZE(cMWModelInternal,
0x13C)
#include <Spore/Graphics/Model.h>
namespace Graphics:: Addresses(Model)
#include <Spore/Graphics/Model.h>
Graphics:: ASSERT_SIZE(RenderStatistics,
0x2C)
#include <Spore/Graphics/RenderStatistics.h>
namespace Graphics:: Addresses(RenderUtils)
#include <Spore/Graphics/RenderUtils.h>
Graphics:: ASSERT_SIZE(ShaderBuilder,
0x2C8)
#include <Spore/Graphics/ShaderBuilder.h>
namespace Graphics:: Addresses(ShaderBuilder)
#include <Spore/Graphics/ShaderBuilder.h>
Graphics:: ASSERT_SIZE(StandardShader,
0x348)
#include <Spore/Graphics/StandardShader.h>
namespace Graphics:: Addresses(StandardShader)
#include <Spore/Graphics/StandardShader.h>