Toggle navigation
Toggle navigation
此项目
正在载入...
Sign in
胡斌
/
srs
转到一个项目
Toggle navigation
项目
群组
代码片段
帮助
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
winlin
2014-06-19 11:22:24 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
46611ac0627b410468d4f43ce2a13944273dab6c
46611ac0
1 parent
46c1367f
refine configure, add cubieboard. use IProtocolStatistic in kbps.
隐藏空白字符变更
内嵌
并排对比
正在显示
3 个修改的文件
包含
41 行增加
和
10 行删除
trunk/auto/options.sh
trunk/src/app/srs_app_kbps.cpp
trunk/src/app/srs_app_kbps.hpp
trunk/auto/options.sh
查看文件 @
46611ac
...
...
@@ -62,6 +62,8 @@ SRS_MIPS_UBUNTU12=NO
SRS_DEV
=
NO
# raspberry-pi, open hls/ssl/static
SRS_PI
=
NO
# cubieboard, donot open ffmpeg/nginx.
SRS_CUBIE
=
NO
# the most fast compile, nothing, only support vp6 RTMP.
SRS_FAST
=
NO
# only support RTMP with ssl.
...
...
@@ -141,8 +143,9 @@ Options:
Presets:
--x86-x64 [default] for x86/x64 cpu, common pc and servers.
--pi for raspberry-pi(directly build), open features hls/ssl/static.
--arm alias for --with-arm-ubuntu12
--mips alias for --with-mips-ubuntu12
--cubie for cubieboard(directly build), open features except ffmpeg/nginx.
--arm alias for --with-arm-ubuntu12, for ubuntu12, arm crossbuild
--mips alias for --with-mips-ubuntu12, for ubuntu12, mips crossbuild
--fast the most fast compile, nothing, only support vp6 RTMP.
--pure-rtmp only support RTMP with ssl.
--rtmp-hls only support RTMP+HLS with ssl.
...
...
@@ -227,6 +230,7 @@ function parse_user_option() {
--arm
)
SRS_ARM_UBUNTU12
=
YES
;;
--mips
)
SRS_MIPS_UBUNTU12
=
YES
;;
--pi
)
SRS_PI
=
YES
;;
--cubie
)
SRS_CUBIE
=
YES
;;
--dev
)
SRS_DEV
=
YES
;;
--fast
)
SRS_FAST
=
YES
;;
--disable-all
)
SRS_DISABLE_ALL
=
YES
;;
...
...
@@ -281,8 +285,10 @@ function apply_user_presets() {
if
[
$SRS_ARM_UBUNTU12
=
NO
]
;
then
if
[
$SRS_MIPS_UBUNTU12
=
NO
]
;
then
if
[
$SRS_PI
=
NO
]
;
then
if
[
$SRS_X86_X64
=
NO
]
;
then
SRS_X86_X64
=
YES;
opt
=
"--x86-x64
$opt
"
;
if
[
$SRS_CUBIE
=
NO
]
;
then
if
[
$SRS_X86_X64
=
NO
]
;
then
SRS_X86_X64
=
YES;
opt
=
"--x86-x64
$opt
"
;
fi
fi
fi
fi
...
...
@@ -552,6 +558,31 @@ function apply_user_presets() {
SRS_GPROF
=
NO
SRS_STATIC
=
NO
fi
# if cubieboard specified, open features except ffmpeg/nginx.
if
[
$SRS_CUBIE
=
YES
]
;
then
SRS_HLS
=
YES
SRS_DVR
=
YES
SRS_NGINX
=
NO
SRS_SSL
=
YES
SRS_FFMPEG_TOOL
=
YES
SRS_TRANSCODE
=
YES
SRS_INGEST
=
YES
SRS_HTTP_PARSER
=
YES
SRS_HTTP_CALLBACK
=
YES
SRS_HTTP_SERVER
=
YES
SRS_HTTP_API
=
YES
SRS_LIBRTMP
=
YES
SRS_BWTC
=
NO
SRS_RESEARCH
=
NO
SRS_UTEST
=
NO
SRS_GPERF
=
NO
SRS_GPERF_MC
=
NO
SRS_GPERF_MP
=
NO
SRS_GPERF_CP
=
NO
SRS_GPROF
=
NO
SRS_STATIC
=
NO
fi
}
apply_user_presets
...
...
trunk/src/app/srs_app_kbps.cpp
查看文件 @
46611ac
...
...
@@ -106,7 +106,7 @@ SrsKbps::~SrsKbps()
{
}
void
SrsKbps
::
set_io
(
ISrsProtocol
Reader
*
in
,
ISrsProtocolWriter
*
out
)
void
SrsKbps
::
set_io
(
ISrsProtocol
Statistic
*
in
,
ISrsProtocolStatistic
*
out
)
{
// set input stream
// now, set start time.
...
...
trunk/src/app/srs_app_kbps.hpp
查看文件 @
46611ac
...
...
@@ -30,8 +30,8 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#include <srs_core.hpp>
class
ISrsProtocolReader
;
class
ISrsProtocolWriter
;
class
ISrsProtocolStatistic
;
class
ISrsProtocolStatistic
;
/**
* a kbps sample, for example, 1minute kbps,
...
...
@@ -65,8 +65,8 @@ class SrsKbpsSlice
{
private
:
union
slice_io
{
ISrsProtocolReader
*
in
;
ISrsProtocolWriter
*
out
;
ISrsProtocolStatistic
*
in
;
ISrsProtocolStatistic
*
out
;
};
public
:
slice_io
io
;
...
...
@@ -121,7 +121,7 @@ public:
* @param out the output stream statistic. can be NULL.
* @remark if in/out is NULL, use the cached data for kbps.
*/
virtual
void
set_io
(
ISrsProtocol
Reader
*
in
,
ISrsProtocolWriter
*
out
);
virtual
void
set_io
(
ISrsProtocol
Statistic
*
in
,
ISrsProtocolStatistic
*
out
);
public
:
/**
* get total kbps, duration is from the startup of io.
...
...
请
注册
或
登录
后发表评论