Polyphase Game Engine
Loading...
Searching...
No Matches
C3dUtils.h
Go to the documentation of this file.
1#pragma once
2
3#if API_C3D
4
6
7#include "Assets/Material.h"
9#include "Maths.h"
10
11class StaticMesh;
12class Primitive3D;
13
14void CopyMatrixGlmToC3d(C3D_Mtx* dst, const glm::mat4& src);
15
16void BindVertexShader(ShaderId shaderId);
17void BindStaticMesh(StaticMesh* mesh, const void* instanceColors);
18void BindMaterial(MaterialLite* material, Primitive3D* primitive, bool useVertexColor, bool useBakedLighting);
19void SetupLighting(uint8_t lightingChannels, bool bakedLighting);
20void SetupLightEnv(LightEnv& lightEnv, uint8_t lightingChannels, bool bakedLighting);
21void PrepareForwardRendering();
22void PrepareUiRendering();
23
24void UploadUvOffsetScale(int8_t uniformLoc, MaterialLite* material, uint32_t uvIndex);
25
26void ResetTexEnv();
27void ResetLightingEnv();
28
29void QueueLinearFree(void* data);
30void QueueTexFree(C3D_Tex tex);
31void ProcessQueuedFrees();
32
33uint32_t GlmColorToRGBA8(glm::vec4 color);
34uint32_t GlmColorToRGB8(glm::vec4 color);
35
36void ConfigTev(C3D_TexEnv* env, uint32_t slot, TevMode mode, bool vertexColorBlend);
37void ApplyWidgetRotation(C3D_Mtx& mtx, Widget* widget);
38
39#endif
TevMode
Definition EngineTypes.h:125
Definition MaterialLite.h:38
Definition Primitive3d.h:46
Definition StaticMesh.h:18
Definition Widget.h:53