Refactor: change light linking object storage be dynamically allocated #108090
|
@ -770,7 +770,7 @@ Mesh *curve_to_mesh_sweep(const CurvesGeometry &main,
|
|||
mesh->tag_loose_verts_none();
|
||||
if (!offsets.any_single_point_profile) {
|
||||
/* If there are no single point profiles, every combination will have faces. */
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -271,7 +271,7 @@ void BKE_mesh_calc_edges(Mesh *mesh, bool keep_existing_edges, const bool select
|
|||
|
||||
if (!keep_existing_edges) {
|
||||
/* All edges are rebuilt from the faces, so there are no loose edges. */
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
}
|
||||
|
||||
/* Explicitly clear edge maps, because that way it can be parallelized. */
|
||||
|
|
|
@ -190,7 +190,7 @@ void Mesh::tag_loose_verts_none() const
|
|||
try_tag_verts_no_face_none(*this);
|
||||
}
|
||||
|
||||
void Mesh::loose_edges_tag_none() const
|
||||
void Mesh::tag_loose_edges_none() const
|
||||
{
|
||||
using namespace blender::bke;
|
||||
this->runtime->loose_edges_cache.ensure([&](LooseEdgeCache &r_data) {
|
||||
|
@ -317,17 +317,17 @@ void BKE_mesh_tag_edges_split(struct Mesh *mesh)
|
|||
if (mesh->runtime->loose_edges_cache.is_cached() &&
|
||||
mesh->runtime->loose_edges_cache.data().count != 0)
|
||||
{
|
||||
mesh->runtime->loose_edges_cache.tag_dirty();
|
||||
mesh->runtime->loose_edges_cache.tag_dirty();
|
||||
}
|
||||
if (mesh->runtime->loose_verts_cache.is_cached() &&
|
||||
mesh->runtime->loose_verts_cache.data().count != 0)
|
||||
{
|
||||
mesh->runtime->loose_verts_cache.tag_dirty();
|
||||
mesh->runtime->loose_verts_cache.tag_dirty();
|
||||
}
|
||||
if (mesh->runtime->verts_no_face_cache.is_cached() &&
|
||||
mesh->runtime->verts_no_face_cache.data().count != 0)
|
||||
{
|
||||
mesh->runtime->verts_no_face_cache.tag_dirty();
|
||||
mesh->runtime->verts_no_face_cache.tag_dirty();
|
||||
}
|
||||
mesh->runtime->subsurf_face_dot_tags.clear_and_shrink();
|
||||
mesh->runtime->subsurf_optimal_display_edges.clear_and_shrink();
|
||||
|
|
|
@ -1208,7 +1208,7 @@ Mesh *BKE_subdiv_to_mesh(Subdiv *subdiv,
|
|||
result->tag_loose_verts_none();
|
||||
}
|
||||
if (coarse_mesh->loose_edges().count == 0) {
|
||||
result->loose_edges_tag_none();
|
||||
result->tag_loose_edges_none();
|
||||
}
|
||||
|
||||
if (subdiv->settings.is_simple) {
|
||||
|
|
|
@ -1344,7 +1344,7 @@ static void bm_to_mesh_edges(const BMesh &bm,
|
|||
});
|
||||
|
||||
if (!any_loose_edge) {
|
||||
mesh.loose_edges_tag_none();
|
||||
mesh.tag_loose_edges_none();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1158,7 +1158,7 @@ static void execute_realize_mesh_tasks(const RealizeInstancesOptions &options,
|
|||
material_indices.finish();
|
||||
|
||||
if (all_meshes_info.no_loose_edges_hint) {
|
||||
dst_mesh->loose_edges_tag_none();
|
||||
dst_mesh->tag_loose_edges_none();
|
||||
}
|
||||
if (all_meshes_info.no_loose_verts_hint) {
|
||||
dst_mesh->tag_loose_verts_none();
|
||||
|
|
|
@ -324,12 +324,12 @@ typedef struct Mesh {
|
|||
* \note To allow setting this status on meshes without changing them, this does not tag the
|
||||
* cache dirty. If the mesh was changed first, the relevant dirty tags should be called first.
|
||||
*/
|
||||
void loose_edges_tag_none() const;
|
||||
void tag_loose_edges_none() const;
|
||||
/**
|
||||
* Set the number of vertices not connected to edges to zero. Similar to #loose_edges_tag_none().
|
||||
* Set the number of vertices not connected to edges to zero. Similar to #tag_loose_edges_none().
|
||||
* There may still be vertices only used by loose edges though.
|
||||
*
|
||||
* \note If both #loose_edges_tag_none() and #tag_loose_verts_none() are called,
|
||||
* \note If both #tag_loose_edges_none() and #tag_loose_verts_none() are called,
|
||||
* all vertices are used by faces, so #verts_no_faces() will be tagged empty as well.
|
||||
*/
|
||||
void tag_loose_verts_none() const;
|
||||
|
|
|
@ -548,7 +548,7 @@ static void duplicate_faces(GeometrySet &geometry_set,
|
|||
}
|
||||
|
||||
new_mesh->tag_loose_verts_none();
|
||||
new_mesh->loose_edges_tag_none();
|
||||
new_mesh->tag_loose_edges_none();
|
||||
|
||||
copy_face_attributes_without_id(edge_mapping,
|
||||
vert_mapping,
|
||||
|
|
|
@ -417,7 +417,7 @@ static void tag_mesh_added_faces(Mesh &mesh)
|
|||
mesh.tag_loose_verts_none();
|
||||
}
|
||||
if (no_loose_edge_hint) {
|
||||
mesh.loose_edges_tag_none();
|
||||
mesh.tag_loose_edges_none();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -154,7 +154,7 @@ static Mesh *create_circle_mesh(const float radius,
|
|||
std::iota(corner_verts.begin(), corner_verts.end(), 0);
|
||||
std::iota(corner_edges.begin(), corner_edges.end(), 0);
|
||||
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
}
|
||||
else if (fill_type == GEO_NODE_MESH_CIRCLE_FILL_TRIANGLE_FAN) {
|
||||
for (const int i : poly_offsets.index_range()) {
|
||||
|
|
|
@ -724,7 +724,7 @@ Mesh *create_cylinder_or_cone_mesh(const float radius_top,
|
|||
calculate_selection_outputs(config, attribute_outputs, mesh->attributes_for_write());
|
||||
|
||||
mesh->tag_loose_verts_none();
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
mesh->bounds_set_eager(calculate_bounds_cylinder(config));
|
||||
|
||||
return mesh;
|
||||
|
|
|
@ -150,7 +150,7 @@ Mesh *create_grid_mesh(const int verts_x,
|
|||
}
|
||||
|
||||
mesh->tag_loose_verts_none();
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
|
||||
const float3 bounds = float3(size_x * 0.5f, size_y * 0.5f, 0.0f);
|
||||
mesh->bounds_set_eager({-bounds, bounds});
|
||||
|
|
|
@ -331,7 +331,7 @@ static Mesh *create_uv_sphere_mesh(const float radius,
|
|||
});
|
||||
|
||||
mesh->tag_loose_verts_none();
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
mesh->bounds_set_eager(calculate_bounds_uv_sphere(radius, segments, rings));
|
||||
|
||||
BLI_assert(BKE_mesh_is_valid(mesh));
|
||||
|
|
|
@ -80,7 +80,7 @@ static void geometry_set_points_to_vertices(
|
|||
}
|
||||
}
|
||||
|
||||
mesh->loose_edges_tag_none();
|
||||
mesh->tag_loose_edges_none();
|
||||
|
||||
geometry_set.replace_mesh(mesh);
|
||||
geometry_set.keep_only_during_modify({GEO_COMPONENT_TYPE_MESH});
|
||||
|
|
Loading…
Reference in New Issue