Cleanup: make ButterworthCoefficients a private struct

As the coefficient members are specific to the implementation,
there is no need for the struct to be public.
This commit is contained in:
Campbell Barton
2023-07-14 22:31:56 +10:00
parent c38a52885b
commit b85c7ade70
2 changed files with 7 additions and 6 deletions

View File

@@ -390,6 +390,11 @@ void blend_to_default_fcurve(PointerRNA *id_ptr, FCurve *fcu, const float factor
/* ---------------- */
struct ButterworthCoefficients {
double *A, *d1, *d2;
int filter_order;
};
ButterworthCoefficients *ED_anim_allocate_butterworth_coefficients(const int filter_order)
{
ButterworthCoefficients *bw_coeff = static_cast<ButterworthCoefficients *>(

View File

@@ -15,6 +15,7 @@ extern "C" {
#endif
struct BezTriple;
struct ButterworthCoefficients;
struct FCurve;
struct Scene;
struct bAnimContext;
@@ -436,12 +437,7 @@ void breakdown_fcurve_segment(struct FCurve *fcu, struct FCurveSegment *segment,
*/
void ED_ANIM_get_1d_gauss_kernel(const float sigma, int kernel_size, double *r_kernel);
typedef struct ButterworthCoefficients {
double *A, *d1, *d2;
int filter_order;
} ButterworthCoefficients;
ButterworthCoefficients *ED_anim_allocate_butterworth_coefficients(const int filter_order);
struct ButterworthCoefficients *ED_anim_allocate_butterworth_coefficients(const int filter_order);
void ED_anim_free_butterworth_coefficients(struct ButterworthCoefficients *bw_coeff);
void ED_anim_calculate_butterworth_coefficients(float cutoff,
float sampling_frequency,