25#ifndef OCCTL_HPP_BOOL_HPP
26#define OCCTL_HPP_BOOL_HPP
45 double fuzzy_value = 0.0;
46 bool run_parallel =
false;
47 bool simplify_result =
false;
48 double simplify_angular_tolerance = 1.0e-2;
49 bool build_history =
true;
67 const ::occtl_node_id_t*,
69 const ::occtl_node_id_t*,
71 const ::occtl_bool_options_t*,
74inline NodeId run(
const EntryFn theFn,
76 const std::vector<NodeId>& theObjects,
77 const std::vector<NodeId>& theTools,
78 const BoolOptions& theOpts)
80 std::vector<::occtl_node_id_t> aObjIds;
81 aObjIds.reserve(theObjects.size());
82 for (
const NodeId& aId : theObjects)
84 aObjIds.emplace_back(aId.get());
87 std::vector<::occtl_node_id_t> aToolIds;
88 aToolIds.reserve(theTools.size());
89 for (
const NodeId& aId : theTools)
91 aToolIds.emplace_back(aId.get());
98 aObjIds.empty() ?
nullptr : aObjIds.data(),
100 aToolIds.empty() ? nullptr : aToolIds.data(),
105 return NodeId(aRoot);
111 const std::vector<NodeId>& theObjects,
112 const std::vector<NodeId>& theTools,
120 const std::vector<NodeId>& theObjects,
121 const std::vector<NodeId>& theTools,
124 return detail::run(&
::occtl_bool_cut, theGraph, theObjects, theTools, theOpts);
129 const std::vector<NodeId>& theObjects,
130 const std::vector<NodeId>& theTools,
138 const std::vector<NodeId>& theObjects,
139 const std::vector<NodeId>& theTools,
147 const std::vector<NodeId>& theObjects,
148 const std::vector<NodeId>& theTools,
RAII handle for a topology graph. Mirrors occtl_graph_t.
Definition topo.hpp:1444
::occtl_graph_t * get() const noexcept
Borrows-it pointer to the underlying C handle, for direct ABI calls.
Definition topo.hpp:1494
Session-local identity of a graph node. Mirrors occtl_node_id_t.
Definition topo.hpp:52
C++ veneer for the core module.
void check(const ::occtl_status_t theStatus)
Throw on non-OK; otherwise a no-op.
Definition core.hpp:85
Boolean-operation veneer namespace; trailing underscore avoids the C++ keyword.
NodeId cut(Graph &theGraph, const std::vector< NodeId > &theObjects, const std::vector< NodeId > &theTools, const BoolOptions &theOpts={})
Boolean Cut. See occtl_bool_cut.
Definition bool.hpp:119
NodeId section(Graph &theGraph, const std::vector< NodeId > &theObjects, const std::vector< NodeId > &theTools, const BoolOptions &theOpts={})
Boolean Section. See occtl_bool_section.
Definition bool.hpp:137
NodeId common(Graph &theGraph, const std::vector< NodeId > &theObjects, const std::vector< NodeId > &theTools, const BoolOptions &theOpts={})
Boolean Common (intersection). See occtl_bool_common.
Definition bool.hpp:128
NodeId fuse(Graph &theGraph, const std::vector< NodeId > &theObjects, const std::vector< NodeId > &theTools, const BoolOptions &theOpts={})
Boolean Fuse of two argument groups. See occtl_bool_fuse.
Definition bool.hpp:110
NodeId split(Graph &theGraph, const std::vector< NodeId > &theObjects, const std::vector< NodeId > &theTools, const BoolOptions &theOpts={})
Boolean Split. See occtl_bool_split.
Definition bool.hpp:146
OCCT-Light: boolean operations module public API.
occtl_status_t occtl_bool_common(occtl_graph_t *graph, const occtl_node_id_t *objects, size_t n_objects, const occtl_node_id_t *tools, size_t n_tools, const occtl_bool_options_t *opts, occtl_node_id_t *out_root)
occtl_status_t occtl_bool_fuse(occtl_graph_t *graph, const occtl_node_id_t *objects, size_t n_objects, const occtl_node_id_t *tools, size_t n_tools, const occtl_bool_options_t *opts, occtl_node_id_t *out_root)
occtl_status_t occtl_bool_split(occtl_graph_t *graph, const occtl_node_id_t *objects, size_t n_objects, const occtl_node_id_t *tools, size_t n_tools, const occtl_bool_options_t *opts, occtl_node_id_t *out_root)
occtl_status_t occtl_bool_cut(occtl_graph_t *graph, const occtl_node_id_t *objects, size_t n_objects, const occtl_node_id_t *tools, size_t n_tools, const occtl_bool_options_t *opts, occtl_node_id_t *out_root)
#define OCCTL_BOOL_OPTIONS_INIT
Definition occtl_bool.h:82
occtl_status_t occtl_bool_section(occtl_graph_t *graph, const occtl_node_id_t *objects, size_t n_objects, const occtl_node_id_t *tools, size_t n_tools, const occtl_bool_options_t *opts, occtl_node_id_t *out_root)
enum occtl_status occtl_status_t
#define OCCTL_NODE_ID_INVALID
Definition occtl_topo_types.h:138
struct occtl_graph occtl_graph_t
Definition occtl_topo_types.h:152
PascalCase mirror of occtl_bool_options_t with idiomatic defaults.
Definition bool.hpp:44
::occtl_bool_options_t to_c() const noexcept
Project into the C ABI options struct.
Definition bool.hpp:52
Definition occtl_bool.h:67
int32_t simplify_result
Definition occtl_bool.h:72
double simplify_angular_tolerance
Definition occtl_bool.h:73
int32_t run_parallel
Definition occtl_bool.h:71
int32_t build_history
Definition occtl_bool.h:75
double fuzzy_value
Definition occtl_bool.h:70
Definition occtl_topo_types.h:50
C++ veneer for the topo module.