YetAnotherCoupler 3.5.2
Loading...
Searching...
No Matches
clipping.h
Go to the documentation of this file.
1// Copyright (c) 2024 The YAC Authors
2//
3// SPDX-License-Identifier: BSD-3-Clause
4
5#ifndef CLIPPING_H
6#define CLIPPING_H
7
8#include "grid_cell.h"
9
19struct yac_circle;
20
46void yac_cell_clipping (size_t N,
47 struct yac_grid_cell * source_cell,
48 struct yac_grid_cell target_cell,
49 struct yac_grid_cell * overlap_buffer);
50
71void yac_cell_lat_clipping (size_t N,
72 struct yac_grid_cell * cells,
73 double lat_bounds[2],
74 struct yac_grid_cell * overlap_buffer);
75
108void yac_compute_overlap_areas (size_t N,
109 struct yac_grid_cell * source_cell,
110 struct yac_grid_cell target_cell,
111 double * partial_areas);
112
141void yac_compute_overlap_info (size_t N,
142 struct yac_grid_cell * source_cell,
143 struct yac_grid_cell target_cell,
144 double * overlap_areas,
145 double (*overlap_barycenters)[3]);
146
151
161void yac_correct_weights (size_t N, double * weight);
162
173 double const * a, double const * b, enum yac_edge_type type,
174 int edge_ordering, struct yac_circle * circle);
175
184int yac_circle_compare(void const * a, void const * b);
185
191int yac_circle_contains_north_pole(struct yac_circle * circle);
192
204 double const point[3], struct yac_circle * circle);
205
216 double const a[3], double const b[3], struct yac_circle * circle);
217
218#endif // CLIPPING_H
int yac_circle_point_is_inside(double const point[3], struct yac_circle *circle)
Definition clipping.c:471
void yac_cell_lat_clipping(size_t N, struct yac_grid_cell *cells, double lat_bounds[2], struct yac_grid_cell *overlap_buffer)
cell clipping to get the cells describing the intersections
Definition clipping.c:1327
void yac_cell_clipping(size_t N, struct yac_grid_cell *source_cell, struct yac_grid_cell target_cell, struct yac_grid_cell *overlap_buffer)
cell clipping to get the cells describing the intersections
Definition clipping.c:1090
void yac_compute_overlap_info(size_t N, struct yac_grid_cell *source_cell, struct yac_grid_cell target_cell, double *overlap_areas, double(*overlap_barycenters)[3])
calculates partial areas for all overlapping parts of the source cells with arbitrary target cells,...
Definition clipping.c:119
void yac_compute_overlap_areas(size_t N, struct yac_grid_cell *source_cell, struct yac_grid_cell target_cell, double *partial_areas)
calculates partial areas for all overlapping parts of the source cells with arbitrary target cells,...
Definition clipping.c:276
int yac_circle_compare(void const *a, void const *b)
Definition clipping.c:344
void yac_correct_weights(size_t N, double *weight)
correct interpolation weights
Definition clipping.c:1447
int yac_circle_contains_north_pole(struct yac_circle *circle)
Definition clipping.c:563
void yac_circle_generate(double const *a, double const *b, enum yac_edge_type type, int edge_ordering, struct yac_circle *circle)
Definition clipping.c:415
void yac_compute_overlap_buf_free()
Definition clipping.c:88
int yac_circle_compare_distances(double const a[3], double const b[3], struct yac_circle *circle)
Definition clipping.c:509
yac_edge_type
Definition grid_cell.h:12
enum callback_type type