# SDP协议 **Repository Path**: xiaochengtech/sdp ## Basic Information - **Project Name**: SDP协议 - **Description**: Go实现的RFC4566-SDP协议。 - **Primary Language**: Go - **License**: MIT - **Default Branch**: master - **Homepage**: https://tools.ietf.org/html/rfc4566 - **GVP Project**: No ## Statistics - **Stars**: 23 - **Forks**: 8 - **Created**: 2020-04-05 - **Last Updated**: 2025-04-16 ## Categories & Tags **Categories**: web-dev-toolkits **Tags**: None ## README # sdp 这是使用Go实现的RFC4566-SDP协议。多用于SIP、WebRTC等多媒体会话场景。 主要结构体为`Message`,对应一条完整的SDP信息。 ### 使用方法 在Go中引用本库: ```go import "gitee.com/xiaochengtech/sdp" ``` 生成一个消息对象,解析外部收到的字符串: ```go sdpMsg, err := sdp.NewMessage(transferString) ``` 将消息对象转换为字符串用于传输: ```go transferString := sdpMsg.String() ``` ### TODO - [ ] 增加完整的字段支持。 ### 参考资料 * [RFC4566-IETF](https://tools.ietf.org/html/rfc4566) * [RFC4566-中文版](http://www.docin.com/p-52701644.html)