You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
463B

  1. #pragma once
  2. #include "app/common.hpp"
  3. #include "app/CircularShadow.hpp"
  4. namespace rack {
  5. /** A knob which rotates an SVG and caches it in a framebuffer */
  6. struct SVGKnob : Knob, FramebufferWidget {
  7. TransformWidget *tw;
  8. SVGWidget *sw;
  9. CircularShadow *shadow;
  10. /** Angles in radians */
  11. float minAngle, maxAngle;
  12. SVGKnob();
  13. void setSVG(std::shared_ptr<SVG> svg);
  14. void step() override;
  15. void onChange(event::Change &e) override;
  16. };
  17. } // namespace rack