LDKGrassBladePreset
typedef enum LDKGrassBladePreset{
LDK_GRASS_BLADE_PRESET_THIN=0,
LDK_GRASS_BLADE_PRESET_CROSSED,
LDK_GRASS_BLADE_PRESET_TUFT,
LDK_GRASS_BLADE_PRESET_FLAT_TOP,
LDK_GRASS_BLADE_PRESET_THORNY
}LDKGrassBladePreset;
typedef enum LDKGrassBladePreset{
LDK_GRASS_BLADE_PRESET_THIN=0,
LDK_GRASS_BLADE_PRESET_CROSSED,
LDK_GRASS_BLADE_PRESET_TUFT,
LDK_GRASS_BLADE_PRESET_FLAT_TOP,
LDK_GRASS_BLADE_PRESET_THORNY
}LDKGrassBladePreset;
One sample of the normalized blade profile. Height is in [0, 1]. Width is the full ribbon width, or the radial diameter, at that height.
typedef struct LDKGrassProfilePoint{
float height;
float width;
}LDKGrassProfilePoint;
typedef u32 LDKGrassTypeId;
#define LDK_GRASS_PROFILE_POINT_COUNT 4u
#define LDK_GRASS_TYPE_COUNT 16u
#define LDK_GRASS_TYPE_ID_INVALID UINT32_MAX
Initialize a useful default grass type description.
LDK_API void ldk_grass_type_desc_defaults(LDKGrassTypeDesc *out_desc);
LDKGrassTypeDesc *out_descCopy one configured type from the active GrassSystem.
LDK_API bool ldk_grass_type_get(
LDKGrassTypeId type_id,
LDKGrassTypeDesc *out_desc
);
LDKGrassTypeId type_idLDKGrassTypeDesc *out_descTrue if the operation succeeds; false otherwise.
True when type_id names a configured slot in the active GrassSystem.
LDK_API bool ldk_grass_type_is_valid(LDKGrassTypeId type_id);
LDKGrassTypeId type_idTrue when the queried condition holds; false otherwise.
Register an additional type in the first free runtime slot. Names must be unique. Returns INVALID when the system is inactive, the description is invalid, the name already exists, or all 16 slots are occupied.
LDK_API LDKGrassTypeId ldk_grass_type_register(const LDKGrassTypeDesc *desc);
const LDKGrassTypeDesc *descThe requested value.