mirror of
https://github.com/godotengine/godot.git
synced 2025-01-22 10:32:54 -05:00
Fix union order to simplify empty initializers.
This commit is contained in:
parent
0e3a5eda86
commit
0e06eb80bc
3 changed files with 17 additions and 17 deletions
|
@ -100,6 +100,8 @@ public:
|
|||
|
||||
struct ShaderSpecialization {
|
||||
union {
|
||||
uint32_t packed_0;
|
||||
|
||||
struct {
|
||||
uint32_t use_forward_gi : 1;
|
||||
uint32_t use_light_projector : 1;
|
||||
|
@ -114,19 +116,17 @@ public:
|
|||
uint32_t directional_soft_shadow_samples : 6;
|
||||
uint32_t directional_penumbra_shadow_samples : 6;
|
||||
};
|
||||
|
||||
uint32_t packed_0;
|
||||
};
|
||||
|
||||
union {
|
||||
uint32_t packed_1;
|
||||
|
||||
struct {
|
||||
uint32_t multimesh : 1;
|
||||
uint32_t multimesh_format_2d : 1;
|
||||
uint32_t multimesh_has_color : 1;
|
||||
uint32_t multimesh_has_custom_data : 1;
|
||||
};
|
||||
|
||||
uint32_t packed_1;
|
||||
};
|
||||
|
||||
uint32_t packed_2;
|
||||
|
@ -134,11 +134,11 @@ public:
|
|||
|
||||
struct UbershaderConstants {
|
||||
union {
|
||||
uint32_t packed_0;
|
||||
|
||||
struct {
|
||||
uint32_t cull_mode : 2;
|
||||
};
|
||||
|
||||
uint32_t packed_0;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -59,6 +59,8 @@ public:
|
|||
|
||||
struct ShaderSpecialization {
|
||||
union {
|
||||
uint32_t packed_0;
|
||||
|
||||
struct {
|
||||
uint32_t use_light_projector : 1;
|
||||
uint32_t use_light_soft_shadows : 1;
|
||||
|
@ -82,11 +84,11 @@ public:
|
|||
uint32_t soft_shadow_samples : 6;
|
||||
uint32_t penumbra_shadow_samples : 6;
|
||||
};
|
||||
|
||||
uint32_t packed_0;
|
||||
};
|
||||
|
||||
union {
|
||||
uint32_t packed_1;
|
||||
|
||||
struct {
|
||||
uint32_t directional_soft_shadow_samples : 6;
|
||||
uint32_t directional_penumbra_shadow_samples : 6;
|
||||
|
@ -96,32 +98,30 @@ public:
|
|||
uint32_t directional_lights : 4;
|
||||
uint32_t decals : 4;
|
||||
};
|
||||
|
||||
uint32_t packed_1;
|
||||
};
|
||||
|
||||
union {
|
||||
uint32_t packed_2;
|
||||
|
||||
struct {
|
||||
uint32_t directional_light_blend_splits : 8;
|
||||
uint32_t padding_1 : 24;
|
||||
};
|
||||
|
||||
uint32_t packed_2;
|
||||
};
|
||||
|
||||
union {
|
||||
float luminance_multiplier;
|
||||
float packed_3;
|
||||
float luminance_multiplier;
|
||||
};
|
||||
};
|
||||
|
||||
struct UbershaderConstants {
|
||||
union {
|
||||
uint32_t packed_0;
|
||||
|
||||
struct {
|
||||
uint32_t cull_mode : 2;
|
||||
};
|
||||
|
||||
uint32_t packed_0;
|
||||
};
|
||||
|
||||
uint32_t padding_1;
|
||||
|
|
|
@ -116,11 +116,11 @@ class RendererCanvasRenderRD : public RendererCanvasRender {
|
|||
|
||||
struct ShaderSpecialization {
|
||||
union {
|
||||
uint32_t packed_0;
|
||||
|
||||
struct {
|
||||
uint32_t use_lighting : 1;
|
||||
};
|
||||
|
||||
uint32_t packed_0;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue