00001
00007 #ifndef _XyConstrainedLayer_h
00008 #define _XyConstrainedLayer_h
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #include "MultivariateFunctionLayer.h"
00019 #include "PointControl.h"
00020 #include "XyConstraintsLayer.h"
00021 #include "XyResultLayer.h"
00022
00023
00024
00025
00026
00027 class XyConstrainedLayer
00028 : public XyResultLayer
00029 {
00030 public:
00031
00032
00035 XyConstrainedLayer(
00036 const PlotControl& plotControl,
00037 const Result& result,
00038 CountedPtr<PlotLayer> cpFunctionLayer,
00039 std::auto_ptr<XyConstraintsLayer> apConstraintsLayer,
00040 std::auto_ptr<MultivariateFunctionLayer> apPenaltyLayer);
00041
00044 XyConstrainedLayer(const XyConstrainedLayer& from);
00045
00048 ~XyConstrainedLayer(void);
00049
00050
00051
00052
00053 virtual void Draw(wxDC& dc) const;
00054
00055 virtual vector<ToolbarTool> CreateTools(PlotControl* pPlotControl);
00056
00059 static std::auto_ptr<ResultLayer> Create(
00060 const PlotControl& plotControl,
00061 const Result& result,
00062 CountedPtr<PlotLayer> cpFunctionLayer);
00063
00064
00065
00066 virtual Region IterationBoundingBox(unsigned iterationNumber) const;
00067
00068
00069
00070 protected:
00071 private:
00072
00073 void DrawIteration(wxDC& dc,
00074 unsigned iterationNumber,
00075 bool highlight) const;
00076
00077 void DrawFirstIteration(wxDC& dc,
00078 unsigned iterationNumber,
00079 bool highlight) const;
00080
00081
00082
00083 CountedPtr<XyConstraintsLayer> mcpConstraintsLayer;
00084 CountedPtr<MultivariateFunctionLayer> mcpPenaltyLayer;
00085
00086 const static void* mRegistrationDummy;
00087 };
00088
00089
00090
00091
00092
00093
00094
00095 #endif // _XyConstrainedLayer_h