bpm.h 797 B

12345678910111213141516171819202122232425
  1. #ifndef BPM_H
  2. #define BPM_H
  3. #ifdef __cplusplus
  4. extern "C" {
  5. #endif
  6. /* BPM callback. Allocation of BPM metrics data happens automatically
  7. * with the first invokation of the callback associated with the output.
  8. * Deallocation must be done explicitly with bpm_destroy(), after the
  9. * callback is removed.
  10. *
  11. * BPM is designed to operate at the packet level. The bpm_inject()
  12. * callback function must be registered and unregistered with
  13. * obs_output_add_packet_callback() and obs_output_remove_packet_callback(),
  14. * respectively.
  15. */
  16. void bpm_inject(obs_output_t *output, struct encoder_packet *pkt, struct encoder_packet_time *pkt_time, void *param);
  17. /* BPM function to destroy all allocations for a given output. */
  18. void bpm_destroy(obs_output_t *output);
  19. #ifdef __cplusplus
  20. }
  21. #endif
  22. #endif