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.

34 lines
471B

  1. #pragma once
  2. #include "common.hpp"
  3. #include "engine/Module.hpp"
  4. #include "engine/Param.hpp"
  5. namespace rack {
  6. namespace engine {
  7. /** A weak handle to a Param. Managed by Engine */
  8. struct ParamHandle {
  9. /** Do not set these directly.
  10. They are handled by Engine methods.
  11. */
  12. int moduleId;
  13. int paramId;
  14. Module *module;
  15. ParamHandle() {
  16. reset();
  17. }
  18. void reset() {
  19. moduleId = -1;
  20. paramId = 0;
  21. module = NULL;
  22. }
  23. };
  24. } // namespace engine
  25. } // namespace rack