added material rendering

This commit is contained in:
2026-04-27 15:56:33 +03:00
parent 457b455042
commit cbcfdce047
16 changed files with 178 additions and 29 deletions

View File

@@ -2,6 +2,7 @@
#define FUNNY_MATERIALS_H
#include "datamap.h"
#include "stdint.h"
#include "cglm/mat4.h"
#define TEXTURE_INVALID 0
#define TEXTURE_NO_TEXTURE -1
@@ -35,6 +36,11 @@ namespace FMat
XMFLOAT4 row4;
};
}
struct MaterialData_t
{
FMat::XMFLOAT4 m_vAlbedoColor;
uint32_t m_uAlbedo;
};
class CBaseMaterial
{
@@ -44,6 +50,7 @@ public:
virtual const char *GetShaderPath() { return NULL; };
virtual void *GetDataPtr() { return 0; };
virtual size_t GetDataSize() { return 0; };
virtual void SetUpMesh( MaterialData_t *pData ) {};
uint64_t m_uHash;
};