Lagrange
Loading...
Searching...
No Matches
attribute_smoothing.h
1/*
2 * Copyright 2025 Adobe. All rights reserved.
3 * This file is licensed to you under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License. You may obtain a copy
5 * of the License at http://www.apache.org/licenses/LICENSE-2.0
6 *
7 * Unless required by applicable law or agreed to in writing, software distributed under
8 * the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS
9 * OF ANY KIND, either express or implied. See the License for the specific language
10 * governing permissions and limitations under the License.
11 */
12#pragma once
13
14#include <lagrange/SurfaceMesh.h>
15#include <lagrange/filtering/api.h>
16
17#include <string_view>
18
19namespace lagrange::filtering {
20
25{
34 double curvature_weight = 0.02;
35
44
52 double gradient_weight = 1e-4;
53
62};
63
82template <typename Scalar, typename Index>
83LA_FILTERING_API void scalar_attribute_smoothing(
85 std::string_view attribute_name = "",
86 const AttributeSmoothingOptions& options = {});
87
88} // namespace lagrange::filtering
A general purpose polygonal mesh class.
Definition SurfaceMesh.h:66
Options for controlling the attribute smoothing process.
Definition attribute_smoothing.h:25
double gradient_modulation_scale
Scale factor for gradient modulation.
Definition attribute_smoothing.h:61
double curvature_weight
Weight factor for curvature-based smoothing.
Definition attribute_smoothing.h:34
double normal_smoothing_weight
Weight factor for normal-based smoothing.
Definition attribute_smoothing.h:43
double gradient_weight
Weight factor for gradient-based smoothing.
Definition attribute_smoothing.h:52