Skip to content

Commit 7259082

Browse files
authored
Merge pull request #13 from libxengine/develop
V2.6.0.1001 Merge
2 parents c015605 + ba12593 commit 7259082

37 files changed

+1022
-109
lines changed

CHANGELOG

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,25 @@
1+
XEngine_StreamMedia V2.6.0.1001
2+
3+
增加:ts拉流支持
4+
增加:其他推流协议转换成SRT拉流协议
5+
增加:m3u8文件录像的支持并且支持时间设置
6+
增加:webrtc初始代码
7+
增加:webrtc的stun网络协议支持
8+
优化:日志打印信息
9+
修改:hls的TS流如果视频数据是关键帧,就添加PAT和PMT信息
10+
修改:hls支持设置关闭后删除录制流
11+
修正:srt发送数据不正确的问题
12+
13+
added:ts stream pull supported
14+
added:other protocols convert to srt stream
15+
added:m3u8 file record supported and time set
16+
added:webrtc code file
17+
added:stun network of the webrtc support
18+
improved:log print
19+
modify:hls ts stream if the video is key frame,then add to pat and pmt
20+
modify:hls supported delete file when stream closed
21+
fixed:srt send message is incorrect
22+
=======================================================
123
XEngine_StreamMedia V2.5.0.1001
224

325
增加:RTCP协议解析支持

README.en.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,17 @@ feature:
2121
5. Support Transparent transmission(planning)
2222
6. Support HTTP API Management interface
2323
7. Support HTTP HOOK(planning)
24+
8. Support for the transfer of all streaming media protocols
2425

2526
Publish Stream:
2627

2728
| ProtocolName | VideoCodec | AudioCodec | Status |
2829
| -------- | --------- | -------- | -------- |
29-
| RTMP | H264,H265 | AAC | Completed |
30+
| RTMP | H264 | AAC | Completed |
3031
| SRT | H264,H265 | AAC | Completed |
31-
| WEBRTC | H264,H265 | AAC | Process |
32-
| GB28181 | H264,H265 | AAC | Not Start |
33-
| JT1078 | H264,H265 | AAC | Completed |
32+
| WEBRTC | H264 | AAC | Not Start |
33+
| GB28181 | H264 | AAC | Not Start |
34+
| JT1078 | H264 | AAC | Completed |
3435
| XStream | H264,H265 | AAC | Completed |
3536

3637
Play Stream:
@@ -39,12 +40,12 @@ Play Stream:
3940
| -------- | --------- | -------- | -------- |
4041
| RTMP | H264 | AAC | Completed |
4142
| RTSP | H264 | AAC | Completed |
42-
| TS | H264,H265 | AAC | Process |
43+
| M3U8 | H264,H265 | AAC | Completed |
4344
| SRT | H264,H265 | AAC | Completed |
44-
| WEBRTC | H264,H265 | AAC | Not Start |
45+
| WEBRTC | H264 | AAC | Processing |
4546
| HTTP-FLV | H264 | AAC | Completed |
4647
| XStream | H264,H265 | AAC | Completed |
47-
48+
| TS | H264,H265 | AAC | Completed |
4849

4950
## install
5051

@@ -102,6 +103,7 @@ xstream://127.0.0.1:5601
102103

103104
#### Pull Stream
104105
http://127.0.0.1:5600/api?stream=play&sms=live/qyt&type=flv(http-flv)
106+
http://127.0.0.1:5600/api?stream=play&sms=live/qyt&type=ts
105107
rtsp://127.0.0.1:5600/api?stream=play&sms=live/qyt&type=rtsp
106108
rtmp://127.0.0.1/live/qyt
107109
srt://127.0.0.1:5603?streamid=#!::r=live/qyt,m=request

README.md

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,17 @@ c c++ streammedia server
2424
5. 支持透传数据(planning)
2525
6. 支持HTTP API管理接口
2626
7. 支持HTTP HOOK(planning)
27+
8. 支持全流媒体协议互转
2728

2829
推流协议:
2930

3031
| 协议名称 | 视频格式 | 音频格式 | 当前状态 |
3132
| -------- | --------- | -------- | -------- |
32-
| RTMP | H264,H265 | AAC | 已完成 |
33+
| RTMP | H264 | AAC | 已完成 |
3334
| SRT | H264,H265 | AAC | 已完成 |
34-
| WEBRTC | H264,H265 | AAC | 进行中 |
35-
| GB28181 | H264,H265 | AAC | 未开始 |
36-
| JT1078 | H264,H265 | AAC | 已完成 |
35+
| WEBRTC | H264 | AAC | 未开始 |
36+
| GB28181 | H264 | AAC | 未开始 |
37+
| JT1078 | H264 | AAC | 已完成 |
3738
| XStream | H264,H265 | AAC | 已完成 |
3839

3940
拉流协议:
@@ -42,11 +43,12 @@ c c++ streammedia server
4243
| -------- | --------- | -------- | -------- |
4344
| RTMP | H264 | AAC | 已完成 |
4445
| RTSP | H264 | AAC | 已完成 |
45-
| TS | H264,H265 | AAC | 进行中 |
46+
| M3U8 | H264,H265 | AAC | 已完成 |
4647
| SRT | H264,H265 | AAC | 已完成 |
47-
| WEBRTC | H264,H265 | AAC | 未开始 |
48+
| WEBRTC | H264 | AAC | 进行中 |
4849
| HTTP-FLV | H264 | AAC | 已完成 |
4950
| XStream | H264,H265 | AAC | 已完成 |
51+
| TS | H264,H265 | AAC | 已完成 |
5052

5153
## 安装教程
5254

@@ -66,7 +68,8 @@ macos执行:./XEngine_LINEnv.sh -i 3
6668
#### Windows
6769

6870
使用VS打开并且编译,你需要优先配置XEngine环境才能使用
69-
还需要libsrt库,通过vcpkg安装
71+
还需要libsrt库,通过vcpkg安装
72+
vcpkg.exe install libsrt:x86-windows libsrt:x64-windows
7073

7174
#### Linux
7275
配置完XEngine后需要安装srt库
@@ -111,6 +114,7 @@ xstream://127.0.0.1:5601
111114

112115
#### 拉流示例
113116
http://127.0.0.1:5600/api?stream=play&sms=live/qyt&type=flv(http-flv)
117+
http://127.0.0.1:5600/api?stream=play&sms=live/qyt&type=ts
114118
rtsp://127.0.0.1:5600/api?stream=play&sms=live/qyt&type=rtsp
115119
rtmp://127.0.0.1/live/qyt
116120
srt://127.0.0.1:5603?streamid=#!::r=live/qyt,m=request

XEngine_Docment/Docment_en.docx

1.73 KB
Binary file not shown.

XEngine_Docment/Docment_zh.docx

1.47 KB
Binary file not shown.

XEngine_Release/XEngine_Config/HttpCode.types

Lines changed: 54 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22
100:HTTP/1.1 100 Continue
33
101:HTTP/1.1 101 Switching Protocols
44
102:HTTP/1.1 102 Processing
5+
103:HTTP/1.1 103 Early Hints
6+
110:HTTP/1.1 110 (obsoleted) Response is Stale
7+
111:HTTP/1.1 111 (obsoleted) Revalidation Failed
8+
112:HTTP/1.1 112 (obsoleted) Disconnected Operation
9+
113:HTTP/1.1 113 (obsoleted) Heuristic Expiration
10+
199:HTTP/1.1 199 (obsoleted) Miscellaneous Warning
511
//CodeSuccess
612
200:HTTP/1.1 200 OK
713
201:HTTP/1.1 201 Created
@@ -10,18 +16,25 @@
1016
204:HTTP/1.1 204 No Content
1117
205:HTTP/1.1 205 Reset Content
1218
206:HTTP/1.1 206 Partial Content
19+
207:HTTP/1.1 207 Multi-Status
20+
208:HTTP/1.1 208 Already Reported
21+
214:HTTP/1.1 214 (obsoleted) Transformation Applied
22+
226:HTTP/1.1 226 IM Used
23+
299:HTTP/1.1 299 (obsoleted) Miscellaneous Persistent Warning
1324
//CodeRedirect
1425
300:HTTP/1.1 300 Multiple Choices
1526
301:HTTP/1.1 301 Moved Permanently
16-
302:HTTP/1.1 302 Move temporarily
27+
302:HTTP/1.1 302 Moved temporarily
1728
303:HTTP/1.1 303 See Other
1829
304:HTTP/1.1 304 Not Modified
1930
305:HTTP/1.1 305 Use Proxy
2031
306:HTTP/1.1 306 Switch Proxy
32+
307:HTTP/1.1 307 Temporary Redirect
33+
308:HTTP/1.1 308 Permanent Redirect
2134
//CodeRequestFail
2235
400:HTTP/1.1 400 Bad Request
23-
401:HTTP/1.1 401 Payment Required
24-
402:HTTP/1.1 402 Unauthorized
36+
401:HTTP/1.1 401 Unauthorized
37+
402:HTTP/1.1 402 Payment Required
2538
403:HTTP/1.1 403 Forbidden
2639
404:HTTP/1.1 404 Not Found
2740
405:HTTP/1.1 405 Method Not Allowed
@@ -37,14 +50,32 @@
3750
415:HTTP/1.1 415 Unsupported Media Type
3851
416:HTTP/1.1 416 Requested Range Not Satisfiable
3952
417:HTTP/1.1 417 Expectation Failed
53+
418:HTTP/1.1 418 I'm a teapot
54+
419:HTTP/1.1 419 (Unofficial) Page Expired
55+
420:HTTP/1.1 420 (Unofficial) Method Failure
4056
421:HTTP/1.1 421 too many connections
4157
422:HTTP/1.1 422 Unprocessable Entity
4258
423:HTTP/1.1 423 Locked
4359
424:HTTP/1.1 424 Failed Dependency
4460
425:HTTP/1.1 425 Unordered Collection
4561
426:HTTP/1.1 426 Upgrade Required
46-
449:HTTP/1.1 449 Retry With
47-
451:HTTP/1.1 451 Unavailable For Legal Reasons
62+
428:HTTP/1.1 428 Precondition Required
63+
429:HTTP/1.1 429 Too Many Requests
64+
430:HTTP/1.1 430 (Unofficial) Request Header Fields Too Large
65+
431:HTTP/1.1 431 Request Header Fields Too Large
66+
440:HTTP/1.1 440 (IIS) Login Time-out
67+
444:HTTP/1.1 444 (nginx) No Response
68+
449:HTTP/1.1 449 (IIS) Retry With
69+
450:HTTP/1.1 450 (Unofficial) Blocked by Windows Parental Controls
70+
451:HTTP/1.1 451 (IIS) Redirect
71+
460:HTTP/1.1 460 (AWS)
72+
463:HTTP/1.1 463 (AWS)
73+
494:HTTP/1.1 494 (nginx) Request header too large
74+
495:HTTP/1.1 495 (nginx) SSL Certificate Error
75+
496:HTTP/1.1 496 (nginx) SSL Certificate Required
76+
497:HTTP/1.1 497 (nginx) HTTP Request Sent to HTTPS Port
77+
498:HTTP/1.1 498 (Unofficial) Invalid Token
78+
499:HTTP/1.1 499 (nginx) Token Required
4879
//CodeServerFail
4980
500:HTTP/1.1 500 Internal Server Error
5081
501:HTTP/1.1 501 Not Implemented
@@ -54,8 +85,24 @@
5485
505:HTTP/1.1 505 HTTP Version Not Supported
5586
506:HTTP/1.1 506 Variant Also Negotiates
5687
507:HTTP/1.1 507 Insufficient Storage
57-
508:HTTP/1.1 509 Bandwidth Limit Exceeded
88+
508:HTTP/1.1 508 Loop Detected
89+
509:HTTP/1.1 509 (Unofficial) Bandwidth Limit Exceeded
90+
510:HTTP/1.1 510 Not Extended
91+
511:HTTP/1.1 511 Network Authentication Required
92+
520:HTTP/1.1 520 (Cloudflare) Web Server Returned an Unknown Error
93+
521:HTTP/1.1 521 (Cloudflare) Web Server Is Down
94+
522:HTTP/1.1 522 (Cloudflare) Connection Timed Out
95+
523:HTTP/1.1 523 (Cloudflare) Origin Is Unreachable
96+
524:HTTP/1.1 524 (Cloudflare) A Timeout Occurred
97+
525:HTTP/1.1 525 (Cloudflare) SSL Handshake Failed
98+
526:HTTP/1.1 526 (Cloudflare) Invalid SSL Certificate
99+
527:HTTP/1.1 527 (Cloudflare) Railgun Error
100+
529:HTTP/1.1 529 (Unofficial) Site is overloaded
101+
530:HTTP/1.1 530 (Cloudflare) Site is frozen
102+
561:HTTP/1.1 561 (AWS) Unauthorized
103+
598:HTTP/1.1 598 (Unofficial) Network read timeout error
104+
599:HTTP/1.1 599 (Unofficial) Network Connect Timeout Error
58105
600:HTTP/1.1 600 Unparseable Response Headers
59-
//CodeUser
106+
//XEngine Code
60107
1001:HTTP/1.1 1001 XEngine Auth Ok
61108
1002:HTTP/1.1 1002 XEngine Auth Failed

XEngine_Release/XEngine_Config/HttpMime.types

Lines changed: 31 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,56 @@
11
text/html html htm shtml
22
text/css css
33
text/xml xml
4-
image/gif gif
5-
image/jpeg jpeg jpg
6-
application/javascript js
7-
application/atom+xml atom
8-
application/rss+xml rss
9-
104
text/mathml mml
115
text/plain txt
126
text/vnd.sun.j2me.app-descriptor jad
137
text/vnd.wap.wml wml
148
text/x-component htc
159

10+
image/gif gif
11+
image/jpeg jpeg jpg
12+
image/avif avif
1613
image/png png
1714
image/tiff tif tiff
15+
image/webp webp
1816
image/vnd.wap.wbmp wbmp
17+
image/svg+xml svg svgz
1918
image/x-icon ico
2019
image/x-jng jng
2120
image/x-ms-bmp bmp
22-
image/svg+xml svg svgz
23-
image/webp webp
2421

25-
application/font-woff woff
22+
font/woff woff
23+
font/woff2 woff2
24+
25+
application/pdf pdf
26+
27+
application/vnd.google-earth.kml+xml kml
28+
application/vnd.google-earth.kmz kmz
29+
30+
application/msword doc
31+
application/vnd.ms-excel xls
32+
application/vnd.ms-powerpoint ppt
33+
application/vnd.ms-fontobject eot
34+
application/vnd.oasis.opendocument.graphics odg
35+
application/vnd.oasis.opendocument.presentation odp
36+
application/vnd.oasis.opendocument.spreadsheet ods
37+
application/vnd.oasis.opendocument.text odt
38+
application/vnd.openxmlformats-officedocument.wordprocessingml.document docx
39+
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet xlsx
40+
application/vnd.openxmlformats-officedocument.presentationml.presentation pptx
41+
42+
application/javascript js
43+
application/atom+xml atom
44+
application/rss+xml rss
2645
application/java-archive jar war ear
2746
application/json json
2847
application/mac-binhex40 hqx
29-
application/msword doc
30-
application/pdf pdf
3148
application/postscript ps eps ai
3249
application/rtf rtf
3350
application/vnd.apple.mpegurl m3u8
34-
application/vnd.ms-excel xls
35-
application/vnd.ms-fontobject eot
36-
application/vnd.ms-powerpoint ppt
3751
application/vnd.wap.wmlc wmlc
38-
application/vnd.google-earth.kml+xml kml
39-
application/vnd.google-earth.kmz kmz
52+
application/wasm wasm
53+
4054
application/x-7z-compressed 7z
4155
application/x-cocoa cco
4256
application/x-java-archive-diff jardiff
@@ -62,10 +76,6 @@ application/octet-stream dmg
6276
application/octet-stream iso img
6377
application/octet-stream msi msp msm
6478

65-
application/vnd.openxmlformats-officedocument.wordprocessingml.document docx
66-
application/vnd.openxmlformats-officedocument.spreadsheetml.sheet xlsx
67-
application/vnd.openxmlformats-officedocument.presentationml.presentation pptx
68-
6979
audio/midi mid midi kar
7080
audio/mpeg mp3
7181
audio/ogg ogg
@@ -83,4 +93,4 @@ video/x-m4v m4v
8393
video/x-mng mng
8494
video/x-ms-asf asx asf
8595
video/x-ms-wmv wmv
86-
video/x-msvideo avi
96+
video/x-msvideo avi

XEngine_Release/XEngine_Config/XEngine_Config.json

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,21 @@
4141
"nARTPPort":56003,
4242
"nARTCPPort":56004
4343
},
44+
"RTC":{
45+
"bEnable":true,
46+
"nSTUNPort":56010
47+
},
48+
"SRT":{
49+
"bEnable":true
50+
},
51+
"TS":{
52+
"bEnable":true
53+
},
4454
"HLS":{
45-
"bEnable":false
55+
"bEnable":false,
56+
"bClear":false,
57+
"nTime":15,
58+
"tszHLSPath":"./XEngine_File"
4659
}
4760
},
4861
"XLog":{
@@ -51,6 +64,7 @@
5164
"LogLeave":32
5265
},
5366
"XVer":[
67+
"V2.6.0.1001 Build20240201",
5468
"V2.5.0.1001 Build20231222",
5569
"V2.4.0.1001 Build20231026",
5670
"V2.3.0.1001 Build20231007",

XEngine_Release/XEngine_File/.gitignore

Whitespace-only changes.

XEngine_Source/XEngine_ModuleConfigure/ModuleConfig_Define.h

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,19 @@ typedef struct tag_XEngine_ServiceConfig
6666
}st_PullFlv;
6767
struct
6868
{
69+
XCHAR tszHLSPath[MAX_PATH];
70+
int nTime;
6971
bool bEnable;
72+
bool bClear;
7073
}st_PullHls;
74+
struct
75+
{
76+
bool bEnable;
77+
}st_PullSrt;
78+
struct
79+
{
80+
bool bEnable;
81+
}st_PullTs;
7182
struct
7283
{
7384
bool bEnable;
@@ -76,6 +87,11 @@ typedef struct tag_XEngine_ServiceConfig
7687
int nARTPPort;
7788
int nARTCPPort;
7889
}st_PullRtsp;
90+
struct
91+
{
92+
bool bEnable;
93+
int nSTUNPort;
94+
}st_PullWebRtc;
7995
}st_XPull;
8096
struct
8197
{

0 commit comments

Comments
 (0)