Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

31 rinda
882B

  1. // RFC7741 RTP Payload Format for VP8 Video
  2. // RTP Payload Format for VP9 Video draft-ietf-payload-vp9-11
  3. #include <stdio.h>
  4. #include <stdint.h>
  5. #include <stdlib.h>
  6. #include <string.h>
  7. #include <assert.h>
  8. #include "sdp-payload.h"
  9. #include "rtp-profile.h"
  10. int sdp_vp8(uint8_t* data, int bytes, const char* proto, unsigned short port, int payload)
  11. {
  12. // 6.2. SDP Parameters
  13. static const char* pattern =
  14. "m=video %hu %s %d\n"
  15. "a=rtpmap:%d VP8/90000\n";
  16. return snprintf((char*)data, bytes, pattern, port, proto && *proto ? proto : "RTP/AVP", payload, payload);
  17. }
  18. int sdp_vp9(uint8_t* data, int bytes, const char* proto, unsigned short port, int payload)
  19. {
  20. // 6.2. SDP Parameters
  21. static const char* pattern =
  22. "m=video %hu %s %d\n"
  23. "a=rtpmap:%d VP8/90000\n";
  24. return snprintf((char*)data, bytes, pattern, port, proto && *proto ? proto : "RTP/AVP", payload, payload);
  25. }