Elaztek Developer Hub
Blamite Game Engine - blam!  00406.12.10.23.1457.blamite
The core library for the Blamite Game Engine.
textures.cpp File Reference
#include "components/rendering/rendering.h"
#include <OGRE/OgreHlmsManager.h>
#include <OGRE/Hlms/Pbs/OgreHlmsPbs.h>
#include <OGRE/OgreTextureGpuManager.h>
#include <OGRE/OgreTextureFilters.h>
#include <OGRE/OgreStagingTexture.h>
#include <OGRE/OgreRoot.h>
#include <Strings/components/classes/map/map.h>
#include "components/content/tags/classes/bitmap.h"
#include "components/diagnostics/logger/logger.h"
+ Include dependency graph for textures.cpp:

Classes

struct  ogre_texture_info_data
 Data structure used to group together information about a texture. More...
 

Functions

Ogre::PixelFormatGpu determine_gpu_pixel_format (bitmap::format_enum tag_format)
 Converts a bitmap pixel format enum value to the equivalent OGRE pixel format. More...
 
Ogre::TextureGpu * build_ogre_texture_data (ogre_texture_info_data *texture_info)
 Loads a texture into OGRE from a texture information structure. More...
 

Variables

BlamMap< std::string, ogre_texture_info_data * > ogre_texture_map = BlamMap<std::string, ogre_texture_info_data*>()
 Map containing information on all loaded textures. More...
 

Function Documentation

◆ build_ogre_texture_data()

Ogre::TextureGpu* build_ogre_texture_data ( ogre_texture_info_data texture_info)

Loads a texture into OGRE from a texture information structure.

Parameters
texture_info- The texture information structure to build a texture from.
Returns
Pointer to the newly loaded OGRE texture, or nullptr if the texture could not be loaded.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ determine_gpu_pixel_format()

Ogre::PixelFormatGpu determine_gpu_pixel_format ( bitmap::format_enum  tag_format)

Converts a bitmap pixel format enum value to the equivalent OGRE pixel format.

Parameters
tag_format- The bitmap pixel format value to convert.
Returns
The equivalent OGRE pixel format. If no matching format is found, then Ogre::PixelFormatGpu::PFG_UNKNOWN is returned.
+ Here is the caller graph for this function:

Variable Documentation

◆ ogre_texture_map

BlamMap<std::string, ogre_texture_info_data*> ogre_texture_map = BlamMap<std::string, ogre_texture_info_data*>()

Map containing information on all loaded textures.

Each key contains the tag path of the texture's bitmap tag, and each value stores the texture information structure.