Elaztek Developer Hub
Blamite Game Engine - blam!  00398.09.22.23.2015.blamite
The core library for the Blamite Game Engine.
rendering.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <d3d11_1.h>
4 #include <d2d1_1.h>
5 #include <dwrite.h>
6 
7 #include <sdl2/SDL.h>
8 #include <sdl2/SDL_events.h>
9 
10 #include <OGRE/Hlms/Pbs/OgreHlmsPbsDatablock.h>
11 #include <OGRE/Hlms/Unlit/OgreHlmsUnlitDatablock.h>
12 #include <Strings/components/classes/map/map.h>
13 
14 #include <string>
15 #include <vector>
16 
20 #include "api/v1/types/tags.h"
21 
22 #ifndef BLAM
23 #define BLAM
24 #endif
25 
26 struct material;
27 struct bitmap;
29 
38 {
43 };
44 
46 {
48  std::string referencing_tag_path = "";
49  Ogre::HlmsDatablock* instance_datablock = nullptr;
50  material* tag_instance = nullptr;
51  bool needs_reload = false;
52  bool persistent_reload = false;
53 };
54 
56 {
57 public:
58  std::string tag_path = "";
59  Ogre::HlmsDatablock* datablock = nullptr;
60  bool needs_reload = false;
61  bool persistent_reload = false;
62  Ogre::HlmsTypes hlms_type = Ogre::HlmsTypes::HLMS_UNLIT;
63 
64  BlamMap<std::string, ogre_material_instance_data*> instances = BlamMap<std::string, ogre_material_instance_data*>();
65 
67 };
68 
72 namespace BlamRendering
73 {
79  namespace DirectX
80  {
84  namespace D2D
85  {
91  BLAM ID2D1DeviceContext* GetD2DRenderTarget();
92 
98  BLAM ID2D1Factory* GetD2DFactory();
99 
105  BLAM IDWriteFactory* GetDWriteFactory();
106 
115  BLAM HRESULT LoadFontFromFile(std::string id, std::string file_path);
116  }
117 
121  namespace WIC
122  {
128  BLAM IWICImagingFactory* GetWICFactory();
129 
141  BLAM HRESULT CreateD2DBitmapFromResource(int res_id, const char* res_type, ID2D1Bitmap **bitmap_pointer);
142 
151  BLAM HRESULT CreateD2DBitmapFromFile(std::wstring path, ID2D1Bitmap **bitmap_pointer);
152 
161  BLAM HRESULT CreateWICBitmapFromFile(std::wstring path, IWICBitmap** bitmap_pointer);
162 
172  BLAM HRESULT CreateWICBitmapFromMemory(void* data, int size, IWICBitmap** bitmap_pointer);
173 
182  BLAM HRESULT ConvertWICBitmapToD2D(IWICBitmap* wic_bitmap, ID2D1Bitmap** d2d_bitmap);
183 
193  BLAM HRESULT ConvertWICBitmapToD2D(IWICBitmap* wic_bitmap, ID2D1Bitmap** d2d_bitmap, ID2D1RenderTarget* render_target);
194 
203  BLAM HRESULT ConvertWICBitmapTo32bppPBGRA(IWICBitmap* source, IWICBitmap** destination);
204 
213  BLAM HRESULT Initialize();
214 
221  BLAM void Shutdown();
222  }
223 
229  BLAM ID3D11Device* GetD3DDevice();
230 
236  BLAM ID3D11DeviceContext* GetD3DContext();
237 
248  BLAM IDXGISwapChain* GetDXGISwapChain();
249 
255  BLAM ID3D11RenderTargetView* GetD3DRenderTargetView();
256 
262  BLAM DXGI_SWAP_CHAIN_DESC GetSwapChainDesc();
263 
274  BLAM HRESULT Initialize(HWND hWnd);
275 
282  BLAM void Cleanup();
283 
295  BLAM HRESULT HandleWindowResize(LPARAM lParam);
296 
304  BLAM bool* RenderTargetClearing();
305 
316  BLAM void RenderLoop(bool debug);
317 
325  BLAM void ShutdownRenderThread();
326 
337  BLAM void RenderThread(bool debug);
338 
348 
355 
362 
371  BLAM HRESULT UpdateResolution(int x, int y);
372 
378  BLAM ID3D11Texture2D** GetLastFrameTexture();
379 
386  BLAM HRESULT GetLastFrameTextureAlt(ID3D11Texture2D* texture);
387 
394  BLAM void ScreenshotDone();
395 
402  BLAM HRESULT GetLastFrameHResult();
403 
413  BLAM void DisplayDetailedCrashScreen(const char* expression, const char* file, int line, std::string details);
414 
420 
425  BLAM void DisplaySignalCrashScreen(int signal);
426  }
427 
433  namespace BGFX
434  {
435  BLAM void SetPlatformData();
436 
437  BLAM void Initialize();
438  BLAM void RenderLoop();
439  BLAM void Shutdown();
440 
441  BLAM void HandleWindowReisze(int width, int height);
442 
443  BLAM void SetViewClearFlags(int new_flags);
444 
447 
448  BLAM int GetRenderWidth();
449  BLAM int GetRenderHeight();
450  }
451 
455  namespace OGRE
456  {
457  BLAM bool Initialize();
458  BLAM void RenderLoop();
459  BLAM void RenderThread();
460  BLAM void Shutdown();
461 
462  BLAM void ProcessSDLEvents(SDL_Event* event);
463 
465 
466  BLAM void HandleWindowReisze(int width, int height);
467 
468  BLAM int GetRenderWidth();
469  BLAM int GetRenderHeight();
470 
471  BLAM Ogre::Window* GetRenderWindow();
472 
473  BLAM double GetDeltaTime();
474 
475  BLAM void TakeScreenshot();
476  BLAM void WriteScreenshot();
477 
478  BLAM Ogre::SceneManager* Get2DSceneManager();
479  BLAM Ogre::Camera* Get2DCamera();
480 
481  BLAM void DisplayBasicCrashScreen(std::string additional_info = "");
482  BLAM void DisplayDetailedCrashScreen(std::string expression, std::string file, int line, std::string message);
483 
484  BLAM bool GetImGuiHiddenState();
485 
489  namespace Materials
490  {
491  BLAM void RebuildDatablocks();
492  BLAM bool BuildDatablockFromTag(material* material_tag, std::string tag_path);
494  BLAM Ogre::HlmsDatablock* GetDatablockFromTag(std::string tag_path);
495 
496  BLAM ogre_material_instance_data* GetDatablockInstanceFromTag(std::string tag_path, std::string referencing_tag_path);
497  BLAM ogre_material_instance_data* CreateDatablockInstance(std::string tag_path, std::string referencing_tag_path);
498 
499  BLAM bool LoadPBSDatablockFromMaterialTag(Ogre::HlmsPbsDatablock* datablock, material* material_tag);
500  BLAM bool LoadUnlitDatablockFromMaterialTag(Ogre::HlmsUnlitDatablock* datablock, material* material_tag);
501 
502  BLAM Ogre::HlmsUnlitDatablock* CreateDefaultUnlitDatablock(std::string id);
503  BLAM Ogre::HlmsUnlitDatablock* CreateDefaultUnlitDatablockForPrimitives(std::string id);
504  BLAM Ogre::HlmsPbsDatablock* CreateDefaultPbsDatablock(std::string id);
505  BLAM Ogre::HlmsPbsDatablock* CreateDefaultPbsDatablockForPrimitives(std::string id);
506  }
507 
511  namespace Textures
512  {
513  BLAM void BuildTextureFromTag(bitmap* bitmap_tag, std::string tag_path);
514  BLAM Ogre::TextureGpu* GetTextureFromTag(std::string tag_path);
515  BLAM void ReloadPendingBitmaps();
516 
517  BLAM Ogre::TextureGpu* LoadTexture2D(std::string id, void* pixel_data, int width, int height, Ogre::PixelFormatGpu format, int bytes_per_line);
518  }
519 
523  namespace Utils {}
524 
525  /*namespace ColibriUI
526  {
527  void Initialize();
528  void RenderLoop();
529  void Shutdown();
530  }*/
531  }
532 
534  // Abstract/Shared Functions, these will usually interface with the active graphics API themselves //
536 
543 
550 
557 
566  BLAM void ShowCrashScreen(const char* exc, const char* file, int line, std::string message);
567 
578  BLAM HRESULT SetDisplayRes(int x, int y); //Sets screen resolution
579 
580 
581  BLAM void HandleWindowResize(int width, int height, WPARAM wParam);
582 }
583 
584 namespace Blam
585 {
592  BLAM void TakeScreenshot();
593 }
BlamRendering::OGRE::Materials::CreateDefaultPbsDatablock
BLAM Ogre::HlmsPbsDatablock * CreateDefaultPbsDatablock(std::string id)
Definition: materials.cpp:935
Blam
Namespace surrounding all major engine components.
Definition: blam_api.h:28
ogre_texture_info_data::texture
Ogre::TextureGpu * texture
Definition: textures.cpp:18
BlamRendering::SetClearColor
BLAM void SetClearColor(ImVec4 color)
Changes the color to used to clear the render target.
Definition: rendering_abstraction.cpp:27
BlamRendering::DirectX::WIC::ConvertWICBitmapToD2D
BLAM HRESULT ConvertWICBitmapToD2D(IWICBitmap *wic_bitmap, ID2D1Bitmap **d2d_bitmap)
Converts a WIC bitmap to a D2D bitmap.
Definition: wic.cpp:91
BlamUserDataFolder::Screenshots
@ Screenshots
Directory used to store engine screenshots. Defaults to {DataRoot}/screenshots/.
BlamRendering::OGRE::Materials::CreateDefaultUnlitDatablockForPrimitives
BLAM Ogre::HlmsUnlitDatablock * CreateDefaultUnlitDatablockForPrimitives(std::string id)
Definition: materials.cpp:916
Blam::Settings::Config::GetEngineConfiguration
BLAM BlamConfigurationFile * GetEngineConfiguration()
Definition: config.cpp:58
BlamRendering::DirectX::GetClearColor
BLAM ImVec4 * GetClearColor()
Retrieves the current color used to clear the render target.
Definition: render_manage.cpp:613
parse_ogre_filter_mode
Ogre::FilterOptions parse_ogre_filter_mode(material_filter_modes filter_mode)
Definition: materials.cpp:85
material_filter_modes::inherit_from_bitmap
@ inherit_from_bitmap
Demo::GraphicsSystem::getRenderWindow
Ogre::Window * getRenderWindow(void) const
Definition: GraphicsSystem.h:145
ogre_material_instance_data::needs_reload
bool needs_reload
Definition: rendering.h:51
BlamRendering::OGRE::DisplayBasicCrashScreen
BLAM void DisplayBasicCrashScreen(std::string additional_info="")
Definition: ogre.cpp:405
BlamRendering::BGFX::SetViewClearFlags
BLAM void SetViewClearFlags(int new_flags)
Definition: bgfx.cpp:170
BlamRendering::OGRE::Materials::LoadPBSDatablockFromMaterialTag
BLAM bool LoadPBSDatablockFromMaterialTag(Ogre::HlmsPbsDatablock *datablock, material *material_tag)
Definition: materials.cpp:322
ogre_texture_map
BlamMap< std::string, ogre_texture_info_data * > ogre_texture_map
Definition: textures.cpp:22
ogre_material_instance_data::tag_instance
material * tag_instance
Definition: rendering.h:50
Blam::Logger::LogEvent
BLAM void LogEvent(std::string message)
Logs a message to the log and/or console.
Definition: aliases.cpp:142
BlamRendering::DirectX::ShutdownRenderThread
BLAM void ShutdownRenderThread()
Instructs the rendering thread to stop running.
Definition: render_manage.cpp:331
BlamRendering::DirectX::GetLastFrameTextureAlt
BLAM HRESULT GetLastFrameTextureAlt(ID3D11Texture2D *texture)
Retrieves the last frame that was rendered.
Definition: render_manage.cpp:647
width
int width
Definition: bgfx.cpp:19
BlamRendering::DirectX::WIC::ConvertWICBitmapTo32bppPBGRA
BLAM HRESULT ConvertWICBitmapTo32bppPBGRA(IWICBitmap *source, IWICBitmap **destination)
Converts a WIC bitmap to a WIC bitmap, with the 32 bits-per-pixe, PBGRA format.
Definition: wic.cpp:58
BlamRendering::OGRE::DisplayDetailedCrashScreen
BLAM void DisplayDetailedCrashScreen(std::string expression, std::string file, int line, std::string message)
Definition: ogre.cpp:421
BlamRendering::OGRE::Materials::GetDatablockFromTag
BLAM Ogre::HlmsDatablock * GetDatablockFromTag(std::string tag_path)
Definition: materials.cpp:834
get_ogre_texture_type_from_material_type
Ogre::PbsTextureTypes get_ogre_texture_type_from_material_type(material::pbr_material_entry::textures_entry::texture_type_enum texture_type)
Definition: materials.cpp:24
color
BlamColor color
Typedef for a color field, used in tag definitions.
Definition: tags.h:359
ogre_texture_info_data::bitmap_tag
bitmap * bitmap_tag
Definition: textures.cpp:16
material_wrap_modes
material_wrap_modes
Definition: material.h:31
BlamRendering::OGRE::Shutdown
BLAM void Shutdown()
Definition: ogre.cpp:302
logger.h
ogre_material_info_data::hlms_type
Ogre::HlmsTypes hlms_type
Definition: rendering.h:62
BlamRendering::GetCurrentRenderingEngine
BLAM BlamRenderingEngine GetCurrentRenderingEngine()
Retrieves the current rendering engine being used.
Definition: rendering_abstraction.cpp:104
bitmap.h
ogre_material_instance_data::referencing_tag_path
std::string referencing_tag_path
Definition: rendering.h:48
BlamRendering::OGRE::Initialize
BLAM bool Initialize()
Definition: ogre.cpp:76
tag_reference::GetTagPath
std::string GetTagPath()
Retrieves the path of the tag that this tagref refers to.
Definition: tag_reference.cpp:45
BlamRendering::OGRE::Materials::ReloadPendingMaterials
BLAM void ReloadPendingMaterials()
Definition: materials.cpp:776
BlamRendering::OGRE::GetGraphicsSystem
BLAM Demo::GraphicsSystem * GetGraphicsSystem()
Definition: ogre.cpp:343
BlamRendering::HandleWindowResize
BLAM void HandleWindowResize(int width, int height, WPARAM wParam)
Definition: rendering_abstraction.cpp:81
version_data.h
imgui.h
BlamRendering::DirectX::D2D::GetDWriteFactory
BLAM IDWriteFactory * GetDWriteFactory()
Retrieves the DirectWrite factory.
Definition: render_manage.cpp:573
OGRE
@ OGRE
Definition: rendering.h:41
ImVec4
Definition: imgui.h:192
material_comparison_function::less_than_or_equal
@ less_than_or_equal
BlamRenderingEngine
BlamRenderingEngine
Enumerator listing possible rendering APIs/engines.
Definition: rendering.h:37
BlamRendering::DirectX::D2D::GetD2DRenderTarget
BLAM ID2D1DeviceContext * GetD2DRenderTarget()
Retrieves the Direct2D render target.
Definition: render_manage.cpp:598
ogre_material_info_data
Definition: rendering.h:55
BlamRendering::ShowCrashScreen
BLAM void ShowCrashScreen(const char *exc, const char *file, int line, std::string message)
Displays the engine crash screen.
Definition: rendering_abstraction.cpp:62
BlamRendering::SetDisplayRes
BLAM HRESULT SetDisplayRes(int x, int y)
Changes the game's display resolution.
Definition: rendering_abstraction.cpp:8
BlamRendering::DirectX::DisplaySignalCrashScreen
BLAM void DisplaySignalCrashScreen(int signal)
Displays a signal-based engine crash screen.
Definition: render_manage.cpp:464
BlamRendering::DirectX::SetClearColor
BLAM void SetClearColor(ImVec4 color)
Changes the color to used to clear the render target.
Definition: render_manage.cpp:567
BlamRendering::OGRE::Textures::BuildTextureFromTag
BLAM void BuildTextureFromTag(bitmap *bitmap_tag, std::string tag_path)
Definition: textures.cpp:58
set_pbs_datablock_texture
void set_pbs_datablock_texture(Ogre::HlmsPbsDatablock *datablock, Ogre::PbsTextureTypes texture_type, tag_reference tagref)
Definition: materials.cpp:163
BlamRendering::DirectX::DisplayDetailedCrashScreen
BLAM void DisplayDetailedCrashScreen(const char *expression, const char *file, int line, std::string details)
Displays a detailed engine crash screen.
Definition: render_manage.cpp:443
bitfield8::flag2
bool flag2
Definition: tags.h:279
BlamRendering::OGRE::GetDeltaTime
BLAM double GetDeltaTime()
Definition: ogre.cpp:385
BlamRendering::OGRE::Textures::ReloadPendingBitmaps
BLAM void ReloadPendingBitmaps()
Definition: textures.cpp:89
USER_DATA_PATH
#define USER_DATA_PATH(path)
Macro to quickly access a user data folder.
Definition: config.h:43
BlamRendering::DirectX::WIC::CreateWICBitmapFromMemory
BLAM HRESULT CreateWICBitmapFromMemory(void *data, int size, IWICBitmap **bitmap_pointer)
Creates a WIC bitmap from a block of memory.
Definition: wic.cpp:173
material_wrap_modes::wrap
@ wrap
y
font DisplayOffset y
Definition: README.txt:68
BlamRendering::OGRE::Materials::GetDatablockInstanceFromTag
BLAM ogre_material_instance_data * GetDatablockInstanceFromTag(std::string tag_path, std::string referencing_tag_path)
Definition: materials.cpp:846
BlamRendering::BGFX::HandleWindowReisze
BLAM void HandleWindowReisze(int width, int height)
Definition: bgfx.cpp:150
ogre_texture_info_data::tag_path
std::string tag_path
Definition: textures.cpp:17
rendering.h
BlamRendering::DirectX::GetLastFrameHResult
BLAM HRESULT GetLastFrameHResult()
Unused.
Definition: render_manage.cpp:642
BlamRendering::DirectX::Initialize
BLAM HRESULT Initialize(HWND hWnd)
Initializes DirectX 11.
Definition: render_manage.cpp:74
parse_texture_addressing_mode
Ogre::TextureAddressingMode parse_texture_addressing_mode(material_wrap_modes wrap_mode)
Definition: materials.cpp:102
BlamRendering::DirectX::UpdateResolution
BLAM HRESULT UpdateResolution(int x, int y)
Changes the DirectX render target resolution.
Definition: resolution.cpp:9
BlamRendering::OGRE::GetImGuiHiddenState
BLAM bool GetImGuiHiddenState()
Definition: ogre.cpp:437
BlamRendering::OGRE::Get2DCamera
BLAM Ogre::Camera * Get2DCamera()
Definition: ogre.cpp:400
BlamRendering::GetClearColor
BLAM ImVec4 * GetClearColor()
Retrieves the color used for render target clearing.
Definition: rendering_abstraction.cpp:46
BlamRendering::BGFX::Shutdown
BLAM void Shutdown()
Definition: bgfx.cpp:143
bitmap_filtering_mode::point
@ point
BlamRendering::BGFX::GetRenderHeight
BLAM int GetRenderHeight()
Definition: bgfx.cpp:190
bitmap::bytes_per_line
int16_t bytes_per_line
The amount of bytes needed for a single line/row of pixels for this bitmap.
Definition: bitmap.h:80
BlamRendering::DirectX::WIC::Initialize
BLAM HRESULT Initialize()
Initializes the Windows Imaging Component (WIC).
Definition: wic.cpp:12
BlamRendering::DirectX::GetLastFrameTexture
BLAM ID3D11Texture2D ** GetLastFrameTexture()
Retrieves the last frame that was rendered.
Definition: render_manage.cpp:626
BlamRendering::OGRE::Get2DSceneManager
BLAM Ogre::SceneManager * Get2DSceneManager()
Definition: ogre.cpp:395
material_filter_modes::anisotropic
@ anisotropic
uint64_t
unsigned long long uint64_t
Definition: stdint.h:18
ogre_texture_info_data
Definition: textures.cpp:14
BlamRendering::DirectX::D2D::LoadFontFromFile
BLAM HRESULT LoadFontFromFile(std::string id, std::string file_path)
Loads a TrueType font from the specified file into the list of loaded font collections.
Definition: render_manage.cpp:555
errors.h
BlamRendering::DirectX::GetSwapChainDesc
BLAM DXGI_SWAP_CHAIN_DESC GetSwapChainDesc()
Retrieves the current Direct3D Swap Chain description.
Definition: render_manage.cpp:618
bitmap_filtering_mode::anisotropic
@ anisotropic
tick.h
BlamRendering::OGRE::Materials::LoadUnlitDatablockFromMaterialTag
BLAM bool LoadUnlitDatablockFromMaterialTag(Ogre::HlmsUnlitDatablock *datablock, material *material_tag)
Definition: materials.cpp:180
ogre_material_info_data::CreateNewInstance
ogre_material_instance_data * CreateNewInstance(BlamTagData *referencing_tag)
Definition: ogre_material_info_data.cpp:5
ENGINE_VERSION
#define ENGINE_VERSION
Definition: version_data.h:31
BlamRendering::DirectX::HandleWindowResize
BLAM HRESULT HandleWindowResize(LPARAM lParam)
Handles a window resize event.
Definition: render_manage.cpp:306
bitmap::filtering_mode_mag
bitmap_filtering_mode filtering_mode_mag
Definition: bitmap.h:48
bitmap::size
vector2 size
The resolution of the bitmap.
Definition: bitmap.h:79
material_comparison_function::less_than
@ less_than
material_filter_modes::linear
@ linear
ogre_material_info_data::instances
BlamMap< std::string, ogre_material_instance_data * > instances
Definition: rendering.h:64
Blam::Tick::GetTotalRuntimeTicks
BLAM uint64_t GetTotalRuntimeTicks()
Gets the total amount of ticks that have elapsed during program runtime.
Definition: tick.cpp:177
Blam::TakeScreenshot
BLAM void TakeScreenshot()
Captures the current frame and saves it to a file.
Definition: screenshot.cpp:101
material.h
format
ARPHIC PUBLIC LICENSE Ltd Yung Chi Taiwan All rights reserved except as specified below Everyone is permitted to copy and distribute verbatim copies of this license but changing it is forbidden Preamble The licenses for most software are designed to take away your freedom to share and change it By the ARPHIC PUBLIC LICENSE specifically permits and encourages you to use this provided that you give the recipients all the rights that we gave you and make sure they can get the modifications of this software Legal Terms Font means the TrueType fonts AR PL Mingti2L AR PL KaitiM AR PL KaitiM and the derivatives of those fonts created through any modification including modifying reordering converting format
Definition: ARPHICPL.TXT:16
BlamRendering::DirectX::D2D::GetD2DFactory
BLAM ID2D1Factory * GetD2DFactory()
Retrieves the Direct2D factory.
Definition: render_manage.cpp:603
BlamRendering::OGRE::Materials::RebuildDatablocks
BLAM void RebuildDatablocks()
Definition: materials.cpp:619
BlamRendering::OGRE::RenderLoop
BLAM void RenderLoop()
Definition: ogre.cpp:219
BlamRendering::BGFX::RenderLoop
BLAM void RenderLoop()
Definition: bgfx.cpp:65
material_comparison_function::always_pass
@ always_pass
BlamRendering::OGRE::Materials::CreateDefaultUnlitDatablock
BLAM Ogre::HlmsUnlitDatablock * CreateDefaultUnlitDatablock(std::string id)
Definition: materials.cpp:905
BlamRendering::BGFX::SetPlatformData
BLAM void SetPlatformData()
material_comparison_function::always_fail
@ always_fail
bitmap::filtering_mode_mip
bitmap_filtering_mode filtering_mode_mip
Definition: bitmap.h:49
tag_reference
Structure representing a tag reference.
Definition: tags.h:215
BlamRendering::DirectX::ScreenshotDone
BLAM void ScreenshotDone()
Informs DirectX that the screenshot has finished being captured.
Definition: render_manage.cpp:664
material_wrap_modes::border
@ border
build_ogre_texture_data
Ogre::TextureGpu * build_ogre_texture_data(ogre_texture_info_data *texture_info)
Definition: textures.cpp:34
BlamRendering::OGRE::GetRenderHeight
BLAM int GetRenderHeight()
Definition: ogre.cpp:375
BlamRendering::OGRE::ProcessSDLEvents
BLAM void ProcessSDLEvents(SDL_Event *event)
Definition: ogre.cpp:327
material
Definition: material.h:53
parse_material_comparison_function
Ogre::CompareFunction parse_material_comparison_function(material_comparison_function comparison_function)
Definition: materials.cpp:119
material_filter_modes
material_filter_modes
Definition: material.h:23
tag_reference::class_name
char class_name[4]
The tag class identifier. Will be the short class name.
Definition: tags.h:219
uint32_t
unsigned int uint32_t
Definition: stdint.h:17
Blam::Content::Tags::GetTagData
BLAM BlamTagData * GetTagData(std::string tag_path)
Retrieves information for a given tag.
Definition: tags.cpp:80
Blam::Content::Tags::GetBitmapTag
BLAM bitmap * GetBitmapTag(std::string tag_path)
Definition: bitmap.cpp:16
ogre_material_info_data::needs_reload
bool needs_reload
Definition: rendering.h:60
ogre_material_instance_data::instance_datablock
Ogre::HlmsDatablock * instance_datablock
Definition: rendering.h:49
material::id
ascii id
Definition: material.h:57
BlamRendering::DirectX::WIC::CreateD2DBitmapFromResource
BLAM HRESULT CreateD2DBitmapFromResource(int res_id, const char *res_type, ID2D1Bitmap **bitmap_pointer)
Creates a Direct2D bitmap from an application resource.
Definition: wic.cpp:262
ogre_material_instance_data
Definition: rendering.h:45
bitmap_filtering_mode::none
@ none
BlamRendering::DirectX::GetD3DRenderTargetView
BLAM ID3D11RenderTargetView * GetD3DRenderTargetView()
Retrieves the current Direct3D Render Target.
Definition: render_manage.cpp:593
BlamRendering::DirectX::GetDXGISwapChain
BLAM IDXGISwapChain * GetDXGISwapChain()
Retrieves the current DXGI Swap Chain.
Definition: render_manage.cpp:588
bitmap_filtering_mode::linear
@ linear
BlamRendering::OGRE::Textures::GetTextureFromTag
BLAM Ogre::TextureGpu * GetTextureFromTag(std::string tag_path)
Definition: textures.cpp:70
BlamRendering::DirectX::DisplayBasicCrashScreen
BLAM void DisplayBasicCrashScreen()
Displays a basic engine crash screen.
Definition: render_manage.cpp:456
bitfield8::flag1
bool flag1
Definition: tags.h:278
BlamRendering::DirectX::GetD3DDevice
BLAM ID3D11Device * GetD3DDevice()
Retrieves the current Direct3D device.
Definition: render_manage.cpp:578
NotReady
@ NotReady
Definition: rendering.h:42
file
sock planetquake com All rights reserved Quake III Arena is a registered trademark of id Inc This level may be electronically distributed only at NO CHARGE to the recipient in its current MUST include this txt file
Definition: chiropteraDM.txt:95
BlamRendering::DirectX::WIC::CreateWICBitmapFromFile
BLAM HRESULT CreateWICBitmapFromFile(std::wstring path, IWICBitmap **bitmap_pointer)
Creates a WIC bitmap from a file.
Definition: wic.cpp:141
data_reference::data_address
void * data_address
The address of the referenced data.
Definition: tags.h:265
material_wrap_modes::mirror
@ mirror
bitmap::pixel_data
data_reference pixel_data
The raw pixel data for the bitmap.
Definition: bitmap.h:78
bitmap::flags
bitfield8 flags
Definition: bitmap.h:50
BlamRendering::OGRE::Materials::CreateDefaultPbsDatablockForPrimitives
BLAM Ogre::HlmsPbsDatablock * CreateDefaultPbsDatablockForPrimitives(std::string id)
Definition: materials.cpp:946
BlamRendering::BGFX::GetRenderWidth
BLAM int GetRenderWidth()
Definition: bgfx.cpp:185
parse_ogre_bitmap_filter_mode
Ogre::FilterOptions parse_ogre_bitmap_filter_mode(bitmap_filtering_mode filter_mode)
Definition: materials.cpp:68
material_comparison_function::greater_than_or_equal
@ greater_than_or_equal
DirectX11
@ DirectX11
Definition: rendering.h:39
height
int height
Definition: bgfx.cpp:20
BlamRendering
Namespace for things relating to rendering.
Definition: primitives.h:24
GraphicsSystem.h
Demo::GraphicsSystem
Definition: GraphicsSystem.h:26
determine_gpu_pixel_format
Ogre::PixelFormatGpu determine_gpu_pixel_format(bitmap::format_enum tag_format)
Definition: textures.cpp:24
x
config GlyphExtraSpacing x
Definition: README.txt:30
BlamRendering::OGRE::GetRenderWidth
BLAM int GetRenderWidth()
Definition: ogre.cpp:370
BlamRendering::OGRE::RenderThread
BLAM void RenderThread()
Definition: ogre.cpp:289
BlamRendering::DirectX::RenderLoop
BLAM void RenderLoop(bool debug)
Renders everything to the screen.
Definition: render_manage.cpp:370
material_comparison_function::disabled
@ disabled
BlamRendering::DirectX::GetD3DContext
BLAM ID3D11DeviceContext * GetD3DContext()
Retrieves the current Direct3D context.
Definition: render_manage.cpp:583
BlamRendering::DirectX::WIC::GetWICFactory
BLAM IWICImagingFactory * GetWICFactory()
Retrieves the WIC Imaging Factory.
Definition: wic.cpp:53
material_comparison_function::not_equal
@ not_equal
ogre_texture_info_data::load_pending
bool load_pending
Definition: textures.cpp:19
BlamRendering::OGRE::Materials::CreateDatablockInstance
BLAM ogre_material_instance_data * CreateDatablockInstance(std::string tag_path, std::string referencing_tag_path)
Definition: materials.cpp:867
bitmap_filtering_mode
bitmap_filtering_mode
Definition: bitmap.h:23
BlamRendering::BGFX::Get3DViewID
BLAM uint16_t Get3DViewID()
Definition: bgfx.cpp:175
bitmap
Definition: bitmap.h:33
bitfield8::flag0
bool flag0
Definition: tags.h:277
BLAM
#define BLAM
Definition: rendering.h:23
config.h
tags.h
BlamRendering::OGRE::HandleWindowReisze
BLAM void HandleWindowReisze(int width, int height)
Definition: ogre.cpp:348
BlamRendering::DirectX::WIC::Shutdown
BLAM void Shutdown()
Shuts down the Windows Imaging Component (WIC).
Definition: wic.cpp:47
BlamRendering::DirectX::Cleanup
BLAM void Cleanup()
Cleans up all DirectX data.
Definition: render_manage.cpp:237
BlamTagData
Class used to contain and access tag data.
Definition: tags.h:68
ogre_material_info_data::persistent_reload
bool persistent_reload
Definition: rendering.h:61
ogre_material_info_data::tag_path
std::string tag_path
Definition: rendering.h:58
Blam::Content::Tags::GetMaterialTag
BLAM material * GetMaterialTag(std::string tag_path)
Definition: material.cpp:16
BlamRendering::BGFX::Initialize
BLAM void Initialize()
Definition: bgfx.cpp:28
set_unlit_datablock_texture
void set_unlit_datablock_texture(Ogre::HlmsUnlitDatablock *datablock, Ogre::UnlitTextureTypes texture_type, tag_reference tagref)
Definition: materials.cpp:146
SDL_Event
Definition: SdlEmulationLayer.h:735
material_comparison_function::equal
@ equal
ogre_material_map
BlamMap< std::string, ogre_material_info_data * > ogre_material_map
The map containing all available OGRE materials.
Definition: materials.cpp:22
BlamRendering::DirectX::HasRenderThreadStopped
BLAM bool HasRenderThreadStopped()
Determines whether or not the render thread has finished stopping.
Definition: render_manage.cpp:326
ogre_material_instance_data::original_material
ogre_material_info_data * original_material
Definition: rendering.h:47
material_filter_modes::none
@ none
BlamRendering::OGRE::Textures::LoadTexture2D
BLAM Ogre::TextureGpu * LoadTexture2D(std::string id, void *pixel_data, int width, int height, Ogre::PixelFormatGpu format, int bytes_per_line)
Definition: textures.cpp:117
BlamRendering::BGFX::Get2DViewID
BLAM uint16_t Get2DViewID()
Definition: bgfx.cpp:180
ogre_material_instance_data::persistent_reload
bool persistent_reload
Definition: rendering.h:52
Demo::GraphicsSystem::getRoot
Ogre::Root * getRoot(void) const
Definition: GraphicsSystem.h:144
BlamRendering::DirectX::RenderTargetClearing
BLAM bool * RenderTargetClearing()
Retrieves whether or not to enable render target clearing.
Definition: render_manage.cpp:608
bitmap::filtering_mode_min
bitmap_filtering_mode filtering_mode_min
Definition: bitmap.h:47
material_comparison_function::greater_than
@ greater_than
BGFX
@ BGFX
Definition: rendering.h:40
uint16_t
unsigned short uint16_t
Definition: stdint.h:16
material_filter_modes::point
@ point
material_comparison_function
material_comparison_function
Definition: material.h:38
BlamRendering::DirectX::WIC::CreateD2DBitmapFromFile
BLAM HRESULT CreateD2DBitmapFromFile(std::wstring path, ID2D1Bitmap **bitmap_pointer)
Creates a Direct2D bitmap from a file.
Definition: wic.cpp:216
BlamRendering::OGRE::Materials::BuildDatablockFromTag
BLAM bool BuildDatablockFromTag(material *material_tag, std::string tag_path)
Definition: materials.cpp:706
ogre_material_info_data::datablock
Ogre::HlmsDatablock * datablock
Definition: rendering.h:59
BlamRendering::OGRE::TakeScreenshot
BLAM void TakeScreenshot()
Definition: ogre.cpp:390
InternalUI::Colors::transparent
UI_API ImVec4 transparent()
Definition: debug_ui_colors.cpp:35
BlamRendering::OGRE::GetRenderWindow
BLAM Ogre::Window * GetRenderWindow()
Definition: ogre.cpp:380
BlamRendering::DirectX::RenderThread
BLAM void RenderThread(bool debug)
Instructs the engine to start rendering on a separate thread.
Definition: render_manage.cpp:337
BlamRendering::OGRE::WriteScreenshot
BLAM void WriteScreenshot()
Definition: utils.cpp:24
details
const char * details
Definition: error_notice.cpp:17
source
const CharType(& source)[N]
Definition: pointer.h:1272
material_wrap_modes::clamp
@ clamp