port.inc 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. const
  2. PW_DIRECTION_INPUT = SPA_DIRECTION_INPUT;
  3. type
  4. Ppw_port = ^Tpw_port;
  5. Ppw_port_events = ^Tpw_port_events;
  6. Ppw_port_info = ^Tpw_port_info;
  7. Ppw_port_methods = ^Tpw_port_methods;
  8. Tpw_port = record
  9. {undefined structure}
  10. end;
  11. Tpw_port_info = record
  12. id: Tuint32_t;
  13. direction: Tspa_direction;
  14. change_mask: Tuint64_t;
  15. props: Pspa_dict;
  16. params: Pspa_param_info;
  17. n_params: Tuint32_t;
  18. end;
  19. Tpw_port_events = record
  20. version: Tuint32_t;
  21. info: procedure(object_: pointer; info: Ppw_port_info); cdecl;
  22. param: procedure(object_: pointer; seq: longint; id: Tuint32_t; index: Tuint32_t; Next: Tuint32_t; param: Pspa_pod); cdecl;
  23. end;
  24. Tpw_port_methods = record
  25. version: Tuint32_t;
  26. add_listener: function(object_: pointer; listener: Pspa_hook; events: Ppw_port_events; Data: pointer) : longint; cdecl;
  27. subscribe_params: function(object_: pointer; ids: Puint32_t; n_ids: Tuint32_t) : longint; cdecl;
  28. enum_params: function(object_: pointer; seq: longint; id: Tuint32_t; start: Tuint32_t; num: Tuint32_t; filter: Pspa_pod) : longint; cdecl;
  29. end;
  30. function pw_direction_as_string(direction: Tspa_direction) : PChar; cdecl; external libpipewirename Name 'pw_direction_as_string';
  31. function pw_port_info_update(info: Ppw_port_info; update: Ppw_port_info) : Ppw_port_info; cdecl; external libpipewirename Name 'pw_port_info_update';
  32. function pw_port_info_merge(info: Ppw_port_info; update: Ppw_port_info; reset: T_Bool) : Ppw_port_info; cdecl; external libpipewirename Name 'pw_port_info_merge';
  33. procedure pw_port_info_free(info: Ppw_port_info); cdecl; external libpipewirename Name 'pw_port_info_free';