Merge branch 'blender-v2.91-release' into master
This commit is contained in:
commit
a3a6443bfd
|
@ -188,6 +188,9 @@ void BKE_mesh_material_index_clear(struct Mesh *me);
|
||||||
void BKE_mesh_material_remap(struct Mesh *me, const unsigned int *remap, unsigned int remap_len);
|
void BKE_mesh_material_remap(struct Mesh *me, const unsigned int *remap, unsigned int remap_len);
|
||||||
void BKE_mesh_smooth_flag_set(struct Mesh *me, const bool use_smooth);
|
void BKE_mesh_smooth_flag_set(struct Mesh *me, const bool use_smooth);
|
||||||
|
|
||||||
|
/* Needed after converting a mesh with subsurf optimal display to mesh. */
|
||||||
|
void BKE_mesh_edges_set_draw_render(struct Mesh *me);
|
||||||
|
|
||||||
const char *BKE_mesh_cmp(struct Mesh *me1, struct Mesh *me2, float thresh);
|
const char *BKE_mesh_cmp(struct Mesh *me1, struct Mesh *me2, float thresh);
|
||||||
|
|
||||||
struct BoundBox *BKE_mesh_boundbox_get(struct Object *ob);
|
struct BoundBox *BKE_mesh_boundbox_get(struct Object *ob);
|
||||||
|
|
|
@ -980,6 +980,14 @@ void BKE_mesh_from_pointcloud(const PointCloud *pointcloud, Mesh *me)
|
||||||
CustomData_free_layer(&me->vdata, CD_PROP_FLOAT3, me->totvert, layer_idx);
|
CustomData_free_layer(&me->vdata, CD_PROP_FLOAT3, me->totvert, layer_idx);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void BKE_mesh_edges_set_draw_render(Mesh *mesh)
|
||||||
|
{
|
||||||
|
MEdge *med = mesh->medge;
|
||||||
|
for (int i = 0; i < mesh->totedge; i++, med++) {
|
||||||
|
med->flag |= ME_EDGEDRAW | ME_EDGERENDER;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void BKE_pointcloud_to_mesh(Main *bmain, Depsgraph *depsgraph, Scene *UNUSED(scene), Object *ob)
|
void BKE_pointcloud_to_mesh(Main *bmain, Depsgraph *depsgraph, Scene *UNUSED(scene), Object *ob)
|
||||||
{
|
{
|
||||||
BLI_assert(ob->type == OB_POINTCLOUD);
|
BLI_assert(ob->type == OB_POINTCLOUD);
|
||||||
|
|
|
@ -2686,6 +2686,8 @@ static int object_convert_exec(bContext *C, wmOperator *op)
|
||||||
Object *ob_eval = DEG_get_evaluated_object(depsgraph, ob);
|
Object *ob_eval = DEG_get_evaluated_object(depsgraph, ob);
|
||||||
Mesh *me_eval = mesh_get_eval_final(depsgraph, scene_eval, ob_eval, &CD_MASK_MESH);
|
Mesh *me_eval = mesh_get_eval_final(depsgraph, scene_eval, ob_eval, &CD_MASK_MESH);
|
||||||
me_eval = BKE_mesh_copy_for_eval(me_eval, false);
|
me_eval = BKE_mesh_copy_for_eval(me_eval, false);
|
||||||
|
/* Full (edge-angle based) draw calculation should ideally be performed. */
|
||||||
|
BKE_mesh_edges_set_draw_render(me_eval);
|
||||||
BKE_mesh_nomain_to_mesh(me_eval, newob->data, newob, &CD_MASK_MESH, true);
|
BKE_mesh_nomain_to_mesh(me_eval, newob->data, newob, &CD_MASK_MESH, true);
|
||||||
BKE_object_free_modifiers(newob, 0); /* after derivedmesh calls! */
|
BKE_object_free_modifiers(newob, 0); /* after derivedmesh calls! */
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue