Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2020-06-18 16:18:26 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2020-06-19 13:02:21 +0300
commit3f5b29508435dd5ace14e3460fa9f51c46e8c64e (patch)
tree4f16bc40fadb51aa6ba36da8fc12abc660b5c957 /source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
parent7ae9227794cb68be7af5cc3b10997fca93a2a76a (diff)
Freestyle: Fix compilation error with C++17
AutoPtr class became a sub-class of unique_ptr with some special magic to mimic behavior of auto_ptr for copy constructor. The code was already there, but for some reason visual studio did not set __cplusplus correctly for some reason. The other change is remove of binary function usage, which is not needed in the Freestyle code.
Diffstat (limited to 'source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp')
-rw-r--r--source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp b/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
index 40ab3ada777..c3c43ce6722 100644
--- a/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
+++ b/source/blender/freestyle/intern/view_map/ViewMapBuilder.cpp
@@ -2273,10 +2273,10 @@ void ViewMapBuilder::ComputeIntersections(ViewMap *ioViewMap,
#endif
}
-struct less_SVertex2D : public binary_function<SVertex *, SVertex *, bool> {
+struct less_SVertex2D {
real epsilon;
- less_SVertex2D(real eps) : binary_function<SVertex *, SVertex *, bool>()
+ less_SVertex2D(real eps)
{
epsilon = eps;
}
@@ -2303,10 +2303,10 @@ struct less_SVertex2D : public binary_function<SVertex *, SVertex *, bool> {
typedef Segment<FEdge *, Vec3r> segment;
typedef Intersection<segment> intersection;
-struct less_Intersection : public binary_function<intersection *, intersection *, bool> {
+struct less_Intersection {
segment *edge;
- less_Intersection(segment *iEdge) : binary_function<intersection *, intersection *, bool>()
+ less_Intersection(segment *iEdge)
{
edge = iEdge;
}