mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-10-15 13:29:41 -07:00
opengl render backend
This commit is contained in:
1 parent
1b7a57914e
commit
48b8c41713
19 files changed
+1598
-38
No files matched your search
@@ -6,6 +6,33 @@
|
||||
|
||||
#include "generated/render.meta.c"
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Helpers
|
||||
|
||||
internal Mat4x4F32
|
||||
r_sample_channel_map_from_tex2dformat(R_Tex2DFormat fmt)
|
||||
{
|
||||
Mat4x4F32 result =
|
||||
{
|
||||
{
|
||||
{1, 0, 0, 0},
|
||||
{0, 1, 0, 0},
|
||||
{0, 0, 1, 0},
|
||||
{0, 0, 0, 1},
|
||||
}
|
||||
};
|
||||
switch(fmt)
|
||||
{
|
||||
default:{}break;
|
||||
case R_Tex2DFormat_R8:
|
||||
{
|
||||
MemoryZeroArray(result.v[0]);
|
||||
result.v[0][0] = result.v[0][1] = result.v[0][2] = result.v[0][3] = 1.f;
|
||||
}break;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
////////////////////////////////
|
||||
//~ rjf: Basic Type Functions
|
||||
|
||||
|
||||
Reference in new issue
Block a user