Quote:
Original post by havythoai
#include <stdlib.h>#include <math.h>
These should be <cstdlib> and <cmath> if you're using C++. Also, you appear to be using this file (constructive.c) as a header, so it should be called constructive
.h. The definitions for the functions will need to be moved out to a proper source file.
Quote:
Original post by havythoai
class CMaSim{public:...void Subtract();void RenderCutter();void RenderObject();...}void CMaSim::Subtract(){sub( RenderCutter, RenderObject); // <----- this line got error}
RenderCutter is a member function pointer, not a regular function pointer. If you want to treat these things interchangeably (regular function pointers and member function pointers) you'll probably want to use
functors to abstract the underlying mechanics. They're different types of pointers and can't be swapped as-is.