A texture of Direct3D created from an image in memory.
More...
#include <renderer.h>
|
| D3DTEXTUREHANDLE | GetTextureHandle () const |
| bool | CreateD3DTexture (IDirect3DDevice2 *pDevice, void *pImage, int nWidth, int nHeight, int nPixelFormatId, DWORD dwColorKey) |
| | Create the texture from an image.
|
| bool | CreateD3DTextureDefault (IDirect3DDevice2 *pDevice, void *pImage, int nWidth, int nHeight, int nPixelFormatId) |
| | Create the texture from an image with no transparent colour.
|
| bool | UploadSurfaceToTexture (const void *pImage, int nWidth, int nHeight) |
| | Copy an image into the surface in system memory and load the texture surface from it.
|
| bool | LoadSysMemTextureToDevice () |
| | Restore the texture surface and load it from the surface in system memory.
|
| void | ReleaseD3DTextureInterfaces () |
| | Release the interfaces of the texture and clear its handle.
|
A texture of Direct3D created from an image in memory.
◆ GetTextureHandle()
- Returns
- The texture handle for the device.
◆ CreateD3DTexture()
| bool D3DTexture::CreateD3DTexture |
( |
IDirect3DDevice2 * | pDevice, |
|
|
void * | pImage, |
|
|
int | nWidth, |
|
|
int | nHeight, |
|
|
int | nPixelFormatId, |
|
|
DWORD | dwColorKey ) |
Create the texture from an image.
A device of hardware gets a texture surface in video memory loaded from a surface in system memory, and a device of software uses one surface in system memory for both.
- Parameters
-
| pDevice | The device the texture belongs to. |
| pImage | The pixels of the image, in the pixel format of the texture. |
| nWidth | The width of the texture. |
| nHeight | The height of the texture. |
| nPixelFormatId | The pixel format of the texture. |
| dwColorKey | The colour that is transparent, or 0 for none. |
- Returns
- Whether the texture was created.
- Ghidra address:
- BRD3D: 0x10009c40
◆ CreateD3DTextureDefault()
| bool D3DTexture::CreateD3DTextureDefault |
( |
IDirect3DDevice2 * | pDevice, |
|
|
void * | pImage, |
|
|
int | nWidth, |
|
|
int | nHeight, |
|
|
int | nPixelFormatId ) |
Create the texture from an image with no transparent colour.
- Parameters
-
| pDevice | The device the texture belongs to. |
| pImage | The pixels of the image. |
| nWidth | The width of the texture. |
| nHeight | The height of the texture. |
| nPixelFormatId | The pixel format of the texture. |
- Returns
- Whether the texture was created.
- Ghidra address:
- BRD3D: 0x10009ea0
◆ UploadSurfaceToTexture()
| bool D3DTexture::UploadSurfaceToTexture |
( |
const void * | pImage, |
|
|
int | nWidth, |
|
|
int | nHeight ) |
Copy an image into the surface in system memory and load the texture surface from it.
- Parameters
-
| pImage | The pixels, packed row after row. |
| nWidth | The width of the image. |
| nHeight | The height of the image. |
- Returns
- Whether the image was copied and loaded.
- Ghidra address:
- BRD3D: 0x10009ed0
◆ LoadSysMemTextureToDevice()
| bool D3DTexture::LoadSysMemTextureToDevice |
( |
| ) |
|
Restore the texture surface and load it from the surface in system memory.
- Returns
- Whether the texture was loaded, true at once when one surface serves both.
- Ghidra address:
- BRD3D: 0x1000a020
◆ ReleaseD3DTextureInterfaces()
| void D3DTexture::ReleaseD3DTextureInterfaces |
( |
| ) |
|
Release the interfaces of the texture and clear its handle.
- Ghidra address:
- BRD3D: 0x1000a0b0
The documentation for this class was generated from the following file: