mrcp_unirtsp_sdp.h 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. /*
  2. * Copyright 2008-2014 Arsen Chaloyan
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License");
  5. * you may not use this file except in compliance with the License.
  6. * You may obtain a copy of the License at
  7. *
  8. * http://www.apache.org/licenses/LICENSE-2.0
  9. *
  10. * Unless required by applicable law or agreed to in writing, software
  11. * distributed under the License is distributed on an "AS IS" BASIS,
  12. * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  13. * See the License for the specific language governing permissions and
  14. * limitations under the License.
  15. *
  16. * $Id: mrcp_unirtsp_sdp.h 2136 2014-07-04 06:33:36Z achaloyan@gmail.com $
  17. */
  18. #ifndef MRCP_UNIRTSP_SDP_H
  19. #define MRCP_UNIRTSP_SDP_H
  20. /**
  21. * @file mrcp_unirtsp_sdp.h
  22. * @brief MRCP RTSP SDP Transformations
  23. */
  24. #include "mrcp_session_descriptor.h"
  25. APT_BEGIN_EXTERN_C
  26. /** Generate MRCP descriptor by RTSP request */
  27. MRCP_DECLARE(mrcp_session_descriptor_t*) mrcp_descriptor_generate_by_rtsp_request(
  28. const rtsp_message_t *request,
  29. const char *force_destination_ip,
  30. const apr_table_t *resource_map,
  31. apr_pool_t *pool,
  32. su_home_t *home);
  33. /** Generate MRCP descriptor by RTSP response */
  34. MRCP_DECLARE(mrcp_session_descriptor_t*) mrcp_descriptor_generate_by_rtsp_response(
  35. const rtsp_message_t *request,
  36. const rtsp_message_t *response,
  37. const char *force_destination_ip,
  38. const apr_table_t *resource_map,
  39. apr_pool_t *pool,
  40. su_home_t *home);
  41. /** Generate RTSP request by MRCP descriptor */
  42. MRCP_DECLARE(rtsp_message_t*) rtsp_request_generate_by_mrcp_descriptor(
  43. const mrcp_session_descriptor_t *descriptor,
  44. const apr_table_t *resource_map,
  45. apr_pool_t *pool);
  46. /** Generate RTSP response by MRCP descriptor */
  47. MRCP_DECLARE(rtsp_message_t*) rtsp_response_generate_by_mrcp_descriptor(
  48. const rtsp_message_t *request,
  49. const mrcp_session_descriptor_t *descriptor,
  50. const apr_table_t *resource_map,
  51. apr_pool_t *pool);
  52. /** Generate RTSP resource discovery request */
  53. MRCP_DECLARE(rtsp_message_t*) rtsp_resource_discovery_request_generate(
  54. const char *resource_name,
  55. const apr_table_t *resource_map,
  56. apr_pool_t *pool);
  57. /** Generate resource discovery descriptor by RTSP response */
  58. MRCP_DECLARE(mrcp_session_descriptor_t*) mrcp_resource_discovery_response_generate(
  59. const rtsp_message_t *request,
  60. const rtsp_message_t *response,
  61. const apr_table_t *resource_map,
  62. apr_pool_t *pool,
  63. su_home_t *home);
  64. /** Generate RTSP resource discovery response */
  65. MRCP_DECLARE(rtsp_message_t*) rtsp_resource_discovery_response_generate(
  66. const rtsp_message_t *request,
  67. const char *ip,
  68. const char *origin,
  69. apr_pool_t *pool);
  70. /** Get MRCP resource name by RTSP resource name */
  71. MRCP_DECLARE(const char*) mrcp_name_get_by_rtsp_name(const apr_table_t *resource_map, const char *rtsp_name);
  72. /** Get RTSP resource name by MRCP resource name */
  73. MRCP_DECLARE(const char*) rtsp_name_get_by_mrcp_name(const apr_table_t *resource_map, const char *mrcp_name);
  74. APT_END_EXTERN_C
  75. #endif /* MRCP_UNIRTSP_SDP_H */