Addsy

shape.hpp

Apr 13th, 2015
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.43 KB | None | 0 0
  1. #if !defined SHAPE_HPP
  2. #define SHAPE_HPP
  3.  
  4. #include "vector_2d.hpp"
  5. #include <prg_interactive.hpp>
  6. #include <vector>
  7.  
  8. class Shape {
  9. public:
  10.     Shape() = default;
  11.     Shape(const Vector2D& location);
  12.  
  13.     void scale (float s);
  14.  
  15.     void render(prg::Canvas& canvas) const;
  16.  
  17.     void update();
  18.  
  19. protected:
  20.     float rotation_angle_ {0.F};
  21.     Vector2D location_;
  22.     std::vector<Vector2D> vertices_;
  23.  
  24. };
  25. #endif // SHAPE_HPP
Advertisement
Add Comment
Please, Sign In to add comment