Cleanup: Fix typo in mesh sample function name
This commit is contained in:
@@ -141,9 +141,9 @@ float3 compute_bary_coord_in_triangle(Span<float3> vert_positions,
|
||||
const float3 &position);
|
||||
|
||||
template<typename T>
|
||||
inline T sample_corner_attrribute_with_bary_coords(const float3 &bary_weights,
|
||||
const MLoopTri &looptri,
|
||||
const Span<T> corner_attribute)
|
||||
inline T sample_corner_attribute_with_bary_coords(const float3 &bary_weights,
|
||||
const MLoopTri &looptri,
|
||||
const Span<T> corner_attribute)
|
||||
{
|
||||
return attribute_math::mix3(bary_weights,
|
||||
corner_attribute[looptri.tri[0]],
|
||||
@@ -152,9 +152,9 @@ inline T sample_corner_attrribute_with_bary_coords(const float3 &bary_weights,
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
inline T sample_corner_attrribute_with_bary_coords(const float3 &bary_weights,
|
||||
const MLoopTri &looptri,
|
||||
const VArray<T> &corner_attribute)
|
||||
inline T sample_corner_attribute_with_bary_coords(const float3 &bary_weights,
|
||||
const MLoopTri &looptri,
|
||||
const VArray<T> &corner_attribute)
|
||||
{
|
||||
return attribute_math::mix3(bary_weights,
|
||||
corner_attribute[looptri.tri[0]],
|
||||
|
||||
@@ -65,7 +65,7 @@ BLI_NOINLINE static void sample_corner_attribute(const Span<MLoopTri> looptris,
|
||||
{
|
||||
for (const int i : mask) {
|
||||
const MLoopTri &tri = looptris[looptri_indices[i]];
|
||||
dst[i] = sample_corner_attrribute_with_bary_coords(bary_coords[i], tri, src);
|
||||
dst[i] = sample_corner_attribute_with_bary_coords(bary_coords[i], tri, src);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -78,7 +78,7 @@ void sample_corner_normals(const Span<MLoopTri> looptris,
|
||||
{
|
||||
for (const int i : mask) {
|
||||
const MLoopTri &tri = looptris[looptri_indices[i]];
|
||||
const float3 value = sample_corner_attrribute_with_bary_coords(bary_coords[i], tri, src);
|
||||
const float3 value = sample_corner_attribute_with_bary_coords(bary_coords[i], tri, src);
|
||||
dst[i] = math::normalize(value);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -636,7 +636,7 @@ static void snap_curves_to_surface_exec_object(Object &curves_ob,
|
||||
const MLoopTri &tri = surface_looptris[looptri_index];
|
||||
const float3 bary_coords = bke::mesh_surface_sample::compute_bary_coord_in_triangle(
|
||||
surface_positions, corner_verts, tri, new_first_point_pos_su);
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coords, tri, surface_uv_map);
|
||||
surface_uv_coords[curve_i] = uv;
|
||||
}
|
||||
|
||||
@@ -306,7 +306,7 @@ struct AddOperationExecutor {
|
||||
const float3 bary_coords = bke::mesh_surface_sample::compute_bary_coord_in_triangle(
|
||||
surface_positions_eval_, surface_corner_verts_eval_, looptri, brush_pos_su);
|
||||
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coords, looptri, surface_uv_map_eval_);
|
||||
r_sampled_uvs.append(uv);
|
||||
}
|
||||
@@ -364,7 +364,7 @@ struct AddOperationExecutor {
|
||||
positions_su);
|
||||
|
||||
for (const int i : IndexRange(new_points)) {
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coords[i], surface_looptris_eval_[looptri_indices[i]], surface_uv_map_eval_);
|
||||
r_sampled_uvs.append(uv);
|
||||
}
|
||||
@@ -487,7 +487,7 @@ struct AddOperationExecutor {
|
||||
looptri_indices,
|
||||
positions_su);
|
||||
for (const int i : IndexRange(new_points)) {
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coords[i], surface_looptris_eval_[looptri_indices[i]], surface_uv_map_eval_);
|
||||
r_sampled_uvs.append(uv);
|
||||
}
|
||||
|
||||
@@ -386,7 +386,7 @@ struct DensityAddOperationExecutor {
|
||||
}
|
||||
|
||||
for (const int i : bary_coords.index_range()) {
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coords[i], surface_looptris_eval_[looptri_indices[i]], surface_uv_map_eval_);
|
||||
r_uvs.append(uv);
|
||||
}
|
||||
@@ -462,7 +462,7 @@ struct DensityAddOperationExecutor {
|
||||
}
|
||||
|
||||
for (const int i : bary_coords.index_range()) {
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float2 uv = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coords[i], surface_looptris_eval_[looptri_indices[i]], surface_uv_map_eval_);
|
||||
r_uvs.append(uv);
|
||||
}
|
||||
|
||||
@@ -35,7 +35,7 @@ float3 compute_surface_point_normal(const MLoopTri &looptri,
|
||||
const float3 &bary_coord,
|
||||
const Span<float3> corner_normals)
|
||||
{
|
||||
const float3 value = bke::mesh_surface_sample::sample_corner_attrribute_with_bary_coords(
|
||||
const float3 value = bke::mesh_surface_sample::sample_corner_attribute_with_bary_coords(
|
||||
bary_coord, looptri, corner_normals);
|
||||
return math::normalize(value);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user