Workbench: Clay renderer was not accessible anymore
issue was the factoring of the workspace engine that was removed. the logic implied that the clay could not be rendered as clay will be a draw mode we placed it already there so it is accessible in any engine. Should eventually fix the clay engine by migrating it to the workbench engine.
This commit is contained in:
@@ -912,6 +912,10 @@ static void drw_engines_enable_from_engine(RenderEngineType *engine_type, int dr
|
||||
}
|
||||
break;
|
||||
|
||||
case OB_CLAY:
|
||||
use_drw_engine(&draw_engine_clay_type);
|
||||
break;
|
||||
|
||||
case OB_TEXTURE:
|
||||
case OB_MATERIAL:
|
||||
case OB_RENDER:
|
||||
|
||||
@@ -442,6 +442,7 @@ enum {
|
||||
OB_MATERIAL = 4,
|
||||
OB_TEXTURE = 5,
|
||||
OB_RENDER = 6,
|
||||
OB_CLAY = 7,
|
||||
};
|
||||
|
||||
/* dtx: flags (short) */
|
||||
|
||||
@@ -176,6 +176,7 @@ static const EnumPropertyItem autosnap_items[] = {
|
||||
const EnumPropertyItem rna_enum_viewport_shade_items[] = {
|
||||
{OB_WIRE, "WIREFRAME", ICON_WIRE, "Wireframe", "Display the object as wire edges"},
|
||||
{OB_SOLID, "SOLID", ICON_SOLID, "Solid", "Display the object solid"},
|
||||
{OB_CLAY, "MATCAP", ICON_SOLID, "Clay", "Display using Clay"},
|
||||
{OB_TEXTURE, "TEXTURED", ICON_POTATO, "Texture", "Display the object solid, with a texture"},
|
||||
{OB_MATERIAL, "MATERIAL", ICON_MATERIAL_DATA, "Material", "Display objects solid, with GLSL material"},
|
||||
{OB_RENDER, "RENDERED", ICON_SMOOTH, "Rendered", "Display render preview"},
|
||||
@@ -691,6 +692,7 @@ static const EnumPropertyItem *rna_SpaceView3D_viewport_shade_itemf(
|
||||
int totitem = 0;
|
||||
|
||||
RNA_enum_items_add_value(&item, &totitem, rna_enum_viewport_shade_items, OB_SOLID);
|
||||
RNA_enum_items_add_value(&item, &totitem, rna_enum_viewport_shade_items, OB_CLAY);
|
||||
|
||||
if (BKE_scene_uses_blender_eevee(scene)) {
|
||||
RNA_enum_items_add_value(&item, &totitem, rna_enum_viewport_shade_items, OB_RENDER);
|
||||
|
||||
Reference in New Issue
Block a user