agg_conv_bspline.h 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. //----------------------------------------------------------------------------
  2. // Anti-Grain Geometry - Version 2.4
  3. // Copyright (C) 2002-2005 Maxim Shemanarev (http://www.antigrain.com)
  4. //
  5. // Permission to copy, use, modify, sell and distribute this software
  6. // is granted provided this copyright notice appears in all copies.
  7. // This software is provided "as is" without express or implied
  8. // warranty, and with no claim as to its suitability for any purpose.
  9. //
  10. //----------------------------------------------------------------------------
  11. // Contact: mcseem@antigrain.com
  12. // mcseemagg@yahoo.com
  13. // http://www.antigrain.com
  14. //----------------------------------------------------------------------------
  15. #ifndef AGG_CONV_BSPLINE_INCLUDED
  16. #define AGG_CONV_BSPLINE_INCLUDED
  17. #include "agg_basics.h"
  18. #include "agg_vcgen_bspline.h"
  19. #include "agg_conv_adaptor_vcgen.h"
  20. namespace agg
  21. {
  22. //---------------------------------------------------------conv_bspline
  23. template<class VertexSource>
  24. struct conv_bspline : public conv_adaptor_vcgen<VertexSource, vcgen_bspline>
  25. {
  26. typedef conv_adaptor_vcgen<VertexSource, vcgen_bspline> base_type;
  27. conv_bspline(VertexSource& vs) :
  28. conv_adaptor_vcgen<VertexSource, vcgen_bspline>(vs) {}
  29. void interpolation_step(double v) { base_type::generator().interpolation_step(v); }
  30. double interpolation_step() const { return base_type::generator().interpolation_step(); }
  31. private:
  32. conv_bspline(const conv_bspline<VertexSource>&);
  33. const conv_bspline<VertexSource>&
  34. operator = (const conv_bspline<VertexSource>&);
  35. };
  36. }
  37. #endif