moved GizmoColor/GizmoShape to Gizmo.h
This commit is contained in:
parent
390bd14c7c
commit
69b9556ca1
2
CMCore
2
CMCore
@ -1 +1 @@
|
|||||||
Subproject commit 913bcfcfb2fbee1b0bc748e2e979e8d5c66ec09e
|
Subproject commit dcbb9ed7a29021cc75bfdd9fb38abaea273257b6
|
@ -4,6 +4,31 @@
|
|||||||
|
|
||||||
VK_NAMESPACE_BEGIN
|
VK_NAMESPACE_BEGIN
|
||||||
|
|
||||||
|
enum class GizmoColor:uint
|
||||||
|
{
|
||||||
|
Black=0,
|
||||||
|
White,
|
||||||
|
|
||||||
|
Red,
|
||||||
|
Green,
|
||||||
|
Blue,
|
||||||
|
|
||||||
|
Yellow,
|
||||||
|
|
||||||
|
ENUM_CLASS_RANGE(Black,Yellow)
|
||||||
|
};
|
||||||
|
|
||||||
|
enum class GizmoShape:uint
|
||||||
|
{
|
||||||
|
Plane=0, //平面
|
||||||
|
Cube, //立方体
|
||||||
|
Sphere, //球
|
||||||
|
Cone, //圆锥
|
||||||
|
Cylinder, //圆柱
|
||||||
|
|
||||||
|
ENUM_CLASS_RANGE(Plane,Cylinder)
|
||||||
|
};
|
||||||
|
|
||||||
bool InitGizmoResource(GPUDevice *);
|
bool InitGizmoResource(GPUDevice *);
|
||||||
void FreeGizmoResource();
|
void FreeGizmoResource();
|
||||||
|
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#include<hgl/graph/VKMaterialInstance.h>
|
#include"Gizmo.h"
|
||||||
|
#include<hgl/graph/VKMaterialInstance.h>
|
||||||
#include<hgl/graph/VKPipeline.h>
|
#include<hgl/graph/VKPipeline.h>
|
||||||
#include<hgl/graph/VKPrimitive.h>
|
#include<hgl/graph/VKPrimitive.h>
|
||||||
#include<hgl/graph/VertexDataManager.h>
|
#include<hgl/graph/VertexDataManager.h>
|
||||||
@ -13,35 +14,14 @@ VK_NAMESPACE_BEGIN
|
|||||||
|
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
enum class GizmoColor:uint
|
|
||||||
{
|
|
||||||
Black=0,
|
|
||||||
White,
|
|
||||||
|
|
||||||
Red,
|
|
||||||
Green,
|
|
||||||
Blue,
|
|
||||||
|
|
||||||
Yellow,
|
|
||||||
|
|
||||||
ENUM_CLASS_RANGE(Black,Yellow)
|
|
||||||
};
|
|
||||||
|
|
||||||
static Color4f GizmoColorRGB[size_t(GizmoColor::RANGE_SIZE)];
|
static Color4f GizmoColorRGB[size_t(GizmoColor::RANGE_SIZE)];
|
||||||
|
|
||||||
enum class GizmoShape:uint
|
|
||||||
{
|
|
||||||
Plane=0, //平面
|
|
||||||
Cube, //立方体
|
|
||||||
Sphere, //球
|
|
||||||
Cone, //圆锥
|
|
||||||
Cylinder, //圆柱
|
|
||||||
|
|
||||||
ENUM_CLASS_RANGE(Plane,Cylinder)
|
|
||||||
};
|
|
||||||
|
|
||||||
static RenderResource * gizmo_rr =nullptr;
|
static RenderResource * gizmo_rr =nullptr;
|
||||||
|
|
||||||
|
static Material * gizmo_mtl_line =nullptr;
|
||||||
|
static MaterialInstance * gizmo_mi_line =nullptr;
|
||||||
|
static Pipeline * gizmo_pipeline_line =nullptr;
|
||||||
|
|
||||||
static Material * gizmo_mtl_triangles =nullptr;
|
static Material * gizmo_mtl_triangles =nullptr;
|
||||||
static MaterialInstance * gizmo_mi_triangles[size_t(GizmoColor::RANGE_SIZE)]{};
|
static MaterialInstance * gizmo_mi_triangles[size_t(GizmoColor::RANGE_SIZE)]{};
|
||||||
static Pipeline * gizmo_pipeline_triangles =nullptr;
|
static Pipeline * gizmo_pipeline_triangles =nullptr;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user