![]() |
Class for ImageManager This class loads the image from file and converts it to a ID2D1Bitmap image It also manage chroma-key and composite images More...
#include <ImageManager.h>
Public Member Functions | |
ImageManager (wchar_t *filename, Graphics *EngineGFX) | |
Constructor that Gets the bitmap image from file More... | |
ImageManager (wchar_t *filename, Graphics *EngineGFX, int NPC_Width, int NPC_Height) | |
Constructor that Gets the NPC sprite bitmap image from file More... | |
ImageManager (wchar_t *filename, Graphics *EngineGFX, int ChromaValue) | |
Constructor that Gets the bitmap to chroma-key image from file More... | |
~ImageManager () | |
Destructor that destroys bitmap object when no longer needed More... | |
void | Draw (float x, float y) |
Draws the bitmap More... | |
void | DrawNPC (int index, float X_Position, float Y_Position) |
Draws the NPCs bitmap More... | |
void | DrawChromaKeyedImage (float X_Position, float Y_Position) |
Draws the chroma-keyed bitmap More... | |
Private Attributes | |
Graphics * | EngineGFX |
Setting up a graphic object More... | |
ComPtr< ID2D1DeviceContext > | m_d2dContext |
ComPtr< ID2D1Effect > | chromakeyEffect |
This is a effect interface that should also be release at the end More... | |
ID2D1Bitmap * | GameBmpAsset |
Instantiating bitmap object More... | |
int | NPC_Width |
Variables for NPCs bitmap information More... | |
int | NPC_Height |
int | NPC_Accross |
int | ChomaKeyImg_Width |
Variables for chroma-key bitmap information More... | |
int | ChomaKeyImg_Height |
Class for ImageManager This class loads the image from file and converts it to a ID2D1Bitmap image It also manage chroma-key and composite images
ImageManager::ImageManager | ( | wchar_t * | filename, |
Graphics * | EngineGFX | ||
) |
Constructor that Gets the bitmap image from file
Constructor for loading bitmaps from file
: ImageManager.cpp : Brian Hinds : 18-01-2017 : 1.0.2 <method name="ImagaeManager"></method>
wchar_t * filename, Graphics * EngineGFX |
Setting up objects to process bitmap image
Create factory needed for the bitmap image
Gets the bitmap image from file
Read the image frame
Create a converter for the bitmap image
Setup the converter for the bitmap image
Creates a D2D1Bitmap image
Releases the factory objects
ImageManager::ImageManager | ( | wchar_t * | filename, |
Graphics * | EngineGFX, | ||
int | NPC_Width, | ||
int | NPC_Height | ||
) |
Constructor that Gets the NPC sprite bitmap image from file
Constructor for loading NPCs from file
<method name="ImagaeManager"></method>
wchar_t * filename, Graphics * EngineGFX, int NPC_Width, int NPC_Height |
ImageManager::ImageManager | ( | wchar_t * | filename, |
Graphics * | EngineGFX, | ||
int | ChromaValue | ||
) |
Constructor that Gets the bitmap to chroma-key image from file
Constructor for chroma-key bitmap from file
<method name="ImagaeManager"></method>
wchar_t * filename, Graphics * EngineGFX, int ChromaValue |
ImageManager::~ImageManager | ( | ) |
Destructor that destroys bitmap object when no longer needed
Destructor for bitmap
<method name="~ImageManager"></method>
None |
void ImageManager::Draw | ( | float | X_Position, |
float | Y_Position | ||
) |
Draws the bitmap
Draws the bitmap image
<method name="Draw"></method>
None |
void ImageManager::DrawChromaKeyedImage | ( | float | X_Position, |
float | Y_Position | ||
) |
Draws the chroma-keyed bitmap
Draws chroma-keyed assets
<method name="DrawChromaKeyedImage"></method>
int index, float X_Position, float Y_Position |
void ImageManager::DrawNPC | ( | int | index, |
float | X_Position, | ||
float | Y_Position | ||
) |
Draws the NPCs bitmap
Draws animated none playable characters
<method name="DrawNPC"></method>
int index, float X_Position, float Y_Position |
|
private |
Variables for chroma-key bitmap information
|
private |
This is a effect interface that should also be release at the end
|
private |
Setting up a graphic object
|
private |
Instantiating bitmap object
|
private |
Variables for NPCs bitmap information