Fixing Clang warnings 2
This commit is contained in:
parent
0ff0444dcc
commit
b85de89751
22 changed files with 70 additions and 107 deletions
|
@ -653,7 +653,7 @@ inline bool intersect_ray_all_hits(
|
|||
std::vector<igl::Hit> &hits)
|
||||
{
|
||||
auto ray_intersector = detail::RayIntersectorHits<VertexType, IndexedFaceType, TreeType, VectorType> {
|
||||
vertices, faces, tree,
|
||||
vertices, faces, {tree},
|
||||
origin, dir, VectorType(dir.cwiseInverse())
|
||||
};
|
||||
if (! tree.empty()) {
|
||||
|
|
|
@ -12,7 +12,7 @@ class Surface;
|
|||
class FillRectilinear : public Fill
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillRectilinear(*this); };
|
||||
Fill* clone() const override { return new FillRectilinear(*this); }
|
||||
~FillRectilinear() override = default;
|
||||
Polylines fill_surface(const Surface *surface, const FillParams ¶ms) override;
|
||||
|
||||
|
@ -32,18 +32,18 @@ protected:
|
|||
class FillAlignedRectilinear : public FillRectilinear
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillAlignedRectilinear(*this); };
|
||||
Fill* clone() const override { return new FillAlignedRectilinear(*this); }
|
||||
~FillAlignedRectilinear() override = default;
|
||||
|
||||
protected:
|
||||
// Always generate infill at the same angle.
|
||||
virtual float _layer_angle(size_t idx) const { return 0.f; }
|
||||
virtual float _layer_angle(size_t idx) const override { return 0.f; }
|
||||
};
|
||||
|
||||
class FillMonotonic : public FillRectilinear
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillMonotonic(*this); };
|
||||
Fill* clone() const override { return new FillMonotonic(*this); }
|
||||
~FillMonotonic() override = default;
|
||||
Polylines fill_surface(const Surface *surface, const FillParams ¶ms) override;
|
||||
bool no_sort() const override { return true; }
|
||||
|
@ -52,7 +52,7 @@ public:
|
|||
class FillGrid : public FillRectilinear
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillGrid(*this); };
|
||||
Fill* clone() const override { return new FillGrid(*this); }
|
||||
~FillGrid() override = default;
|
||||
Polylines fill_surface(const Surface *surface, const FillParams ¶ms) override;
|
||||
|
||||
|
@ -64,7 +64,7 @@ protected:
|
|||
class FillTriangles : public FillRectilinear
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillTriangles(*this); };
|
||||
Fill* clone() const override { return new FillTriangles(*this); }
|
||||
~FillTriangles() override = default;
|
||||
Polylines fill_surface(const Surface *surface, const FillParams ¶ms) override;
|
||||
|
||||
|
@ -76,7 +76,7 @@ protected:
|
|||
class FillStars : public FillRectilinear
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillStars(*this); };
|
||||
Fill* clone() const override { return new FillStars(*this); }
|
||||
~FillStars() override = default;
|
||||
Polylines fill_surface(const Surface *surface, const FillParams ¶ms) override;
|
||||
|
||||
|
@ -88,7 +88,7 @@ protected:
|
|||
class FillCubic : public FillRectilinear
|
||||
{
|
||||
public:
|
||||
Fill* clone() const override { return new FillCubic(*this); };
|
||||
Fill* clone() const override { return new FillCubic(*this); }
|
||||
~FillCubic() override = default;
|
||||
Polylines fill_surface(const Surface *surface, const FillParams ¶ms) override;
|
||||
|
||||
|
@ -98,6 +98,6 @@ protected:
|
|||
};
|
||||
|
||||
|
||||
}; // namespace Slic3r
|
||||
} // namespace Slic3r
|
||||
|
||||
#endif // slic3r_FillRectilinear_hpp_
|
||||
|
|
|
@ -213,7 +213,7 @@ inline bool liang_barsky_line_clipping_interval(
|
|||
double t0 = 0.0;
|
||||
double t1 = 1.0;
|
||||
// Traverse through left, right, bottom, top edges.
|
||||
auto clip_side = [&x0, &v, &bbox, &t0, &t1](double p, double q) -> bool {
|
||||
auto clip_side = [&t0, &t1](double p, double q) -> bool {
|
||||
if (p == 0) {
|
||||
if (q < 0)
|
||||
// Line parallel to the bounding box edge is fully outside of the bounding box.
|
||||
|
|
|
@ -297,7 +297,7 @@ template<class Rst> class Grid {
|
|||
case SquareTag::full:
|
||||
case SquareTag::none: {
|
||||
Coord crd{tl(cell) + Coord{m_cellsize.r / 2, m_cellsize.c / 2}};
|
||||
return {{crd, Dir::none, m_rst}, crd};
|
||||
return {{crd, Dir::none, m_rst}, {crd}};
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@ template<> struct _ccr<true>
|
|||
static void for_each(It from, It to, Fn &&fn, size_t granularity = 1)
|
||||
{
|
||||
tbb::parallel_for(tbb::blocked_range{from, to, granularity},
|
||||
[&fn, from](const auto &range) {
|
||||
[&fn](const auto &range) {
|
||||
loop_(range, std::forward<Fn>(fn));
|
||||
});
|
||||
}
|
||||
|
|
|
@ -424,7 +424,7 @@ public:
|
|||
void clear() override;
|
||||
bool empty() const override { return m_objects.empty(); }
|
||||
// List of existing PrintObject IDs, to remove notifications for non-existent IDs.
|
||||
std::vector<ObjectID> print_object_ids() const;
|
||||
std::vector<ObjectID> print_object_ids() const override;
|
||||
ApplyStatus apply(const Model &model, DynamicPrintConfig config) override;
|
||||
void set_task(const TaskParams ¶ms) override;
|
||||
void process() override;
|
||||
|
|
|
@ -1582,7 +1582,7 @@ PrintObjectSupportMaterial::MyLayersPtr PrintObjectSupportMaterial::bottom_conta
|
|||
});
|
||||
|
||||
Polygons &layer_support_area = layer_support_areas[layer_id];
|
||||
task_group.run([this, &projection, &projection_raw, &layer, &layer_support_area, layer_id] {
|
||||
task_group.run([this, &projection, &projection_raw, &layer, &layer_support_area] {
|
||||
// Remove the areas that touched from the projection that will continue on next, lower, top surfaces.
|
||||
// Polygons trimming = union_(to_polygons(layer.slices), touching, true);
|
||||
Polygons trimming = offset(layer.lslices, float(SCALED_EPSILON));
|
||||
|
@ -1736,7 +1736,7 @@ void PrintObjectSupportMaterial::trim_top_contacts_by_bottom_contacts(
|
|||
const PrintObject &object, const MyLayersPtr &bottom_contacts, MyLayersPtr &top_contacts) const
|
||||
{
|
||||
tbb::parallel_for(tbb::blocked_range<int>(0, int(top_contacts.size())),
|
||||
[this, &object, &bottom_contacts, &top_contacts](const tbb::blocked_range<int>& range) {
|
||||
[&bottom_contacts, &top_contacts](const tbb::blocked_range<int>& range) {
|
||||
int idx_bottom_overlapping_first = -2;
|
||||
// For all top contact layers, counting downwards due to the way idx_higher_or_equal caches the last index to avoid repeated binary search.
|
||||
for (int idx_top = range.end() - 1; idx_top >= range.begin(); -- idx_top) {
|
||||
|
@ -1965,7 +1965,7 @@ void PrintObjectSupportMaterial::generate_base_layers(
|
|||
BOOST_LOG_TRIVIAL(debug) << "PrintObjectSupportMaterial::generate_base_layers() in parallel - start";
|
||||
tbb::parallel_for(
|
||||
tbb::blocked_range<size_t>(0, intermediate_layers.size()),
|
||||
[this, &object, &bottom_contacts, &top_contacts, &intermediate_layers, &layer_support_areas](const tbb::blocked_range<size_t>& range) {
|
||||
[&object, &bottom_contacts, &top_contacts, &intermediate_layers, &layer_support_areas](const tbb::blocked_range<size_t>& range) {
|
||||
// index -2 means not initialized yet, -1 means intialized and decremented to 0 and then -1.
|
||||
int idx_top_contact_above = -2;
|
||||
int idx_bottom_contact_overlapping = -2;
|
||||
|
@ -2328,32 +2328,6 @@ PrintObjectSupportMaterial::MyLayersPtr PrintObjectSupportMaterial::generate_int
|
|||
return interface_layers;
|
||||
}
|
||||
|
||||
static inline void fill_expolygons_generate_paths(
|
||||
ExtrusionEntitiesPtr &dst,
|
||||
const ExPolygons &expolygons,
|
||||
Fill *filler,
|
||||
float density,
|
||||
ExtrusionRole role,
|
||||
const Flow &flow)
|
||||
{
|
||||
FillParams fill_params;
|
||||
fill_params.density = density;
|
||||
fill_params.dont_adjust = true;
|
||||
for (const ExPolygon &expoly : expolygons) {
|
||||
Surface surface(stInternal, expoly);
|
||||
Polylines polylines;
|
||||
try {
|
||||
polylines = filler->fill_surface(&surface, fill_params);
|
||||
} catch (InfillFailedException &) {
|
||||
}
|
||||
extrusion_entities_append_paths(
|
||||
dst,
|
||||
std::move(polylines),
|
||||
role,
|
||||
flow.mm3_per_mm(), flow.width, flow.height);
|
||||
}
|
||||
}
|
||||
|
||||
static inline void fill_expolygons_generate_paths(
|
||||
ExtrusionEntitiesPtr &dst,
|
||||
ExPolygons &&expolygons,
|
||||
|
|
|
@ -246,7 +246,7 @@ private:
|
|||
bool m_can_merge_support_regions;
|
||||
|
||||
coordf_t m_support_layer_height_min;
|
||||
coordf_t m_support_layer_height_max;
|
||||
// coordf_t m_support_layer_height_max;
|
||||
|
||||
coordf_t m_gap_xy;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue