winlin

remove the libfreetype for it fullfill with bugs and always cause build failed. 0.9.139

@@ -35,9 +35,6 @@ gtest-1.6.0.zip @@ -35,9 +35,6 @@ gtest-1.6.0.zip
35 gperftools-2.1.zip 35 gperftools-2.1.zip
36 google性能分析和测试工具。 36 google性能分析和测试工具。
37 编译和使用参考压缩文件中的README和doc目录。 37 编译和使用参考压缩文件中的README和doc目录。
38 -  
39 -freetype-2.4.0  
40 - ffmpeg用到的字体库,在加文字水印需要用到。  
41 38
42 links: 39 links:
43 nginx: 40 nginx:
@@ -49,9 +46,6 @@ links: @@ -49,9 +46,6 @@ links:
49 ffmpeg: 46 ffmpeg:
50 http://ffmpeg.org/ 47 http://ffmpeg.org/
51 http://ffmpeg.org/releases/ffmpeg-2.1.1.tar.gz 48 http://ffmpeg.org/releases/ffmpeg-2.1.1.tar.gz
52 - freetype:  
53 - http://www.freetype.org/index.html  
54 - http://download.savannah.gnu.org/releases/freetype/freetype-2.4.0.tar.bz2  
55 x264: 49 x264:
56 http://www.videolan.org/ 50 http://www.videolan.org/
57 ftp://ftp.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-20131129-2245-stable.tar.bz2 51 ftp://ftp.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-20131129-2245-stable.tar.bz2
@@ -69,23 +69,6 @@ else @@ -69,23 +69,6 @@ else
69 ret=$?; if [[ 0 -ne ${ret} ]]; then echo "build speex-1.2rc1 failed"; exit 1; fi 69 ret=$?; if [[ 0 -ne ${ret} ]]; then echo "build speex-1.2rc1 failed"; exit 1; fi
70 fi 70 fi
71 71
72 -# freetype-2.4.0  
73 -# remark: we must ensure the pkg-config tool installed.  
74 -if [[ -f ${ff_release_dir}/lib/libfreetype.a ]]; then  
75 - echo "libfreetype is ok"  
76 -else  
77 - echo "build freetype-2.4.0"  
78 - cd $ff_current_dir &&  
79 - rm -rf freetype-2.4.0 && unzip -q ${ff_src_dir}/freetype-2.4.0.zip &&  
80 - cd freetype-2.4.0 && ./configure --prefix=${ff_release_dir} --enable-static && make ${SRS_JOBS} && make install  
81 - ret=$?; if [[ 0 -ne ${ret} ]]; then echo "build freetype-2.4.0 failed"; exit 1; fi  
82 -fi  
83 -# add pc to pkg-config  
84 -pkg-config --exists --print-errors freetype2 >/dev/null 2>&1  
85 -ret=$?; if [[ 0 -ne ${ret} ]]; then export PKG_CONFIG_PATH=${PKG_CONFIG_PATH}:$ff_current_dir/freetype-2.4.0/builds/unix; fi  
86 -pkg-config --exists --print-errors freetype2 >/dev/null 2>&1  
87 -ret=$?; if [[ 0 -ne ${ret} ]]; then echo "oops... pkg-config cannot find the freetype, please report bug."; exit 1; fi  
88 -  
89 # x264 core.138 72 # x264 core.138
90 if [[ -f ${ff_release_dir}/lib/libx264.a ]]; then 73 if [[ -f ${ff_release_dir}/lib/libx264.a ]]; then
91 echo "x264 is ok" 74 echo "x264 is ok"
@@ -122,7 +105,6 @@ else @@ -122,7 +105,6 @@ else
122 --extra-ldflags='-L${ffmpeg_exported_release_dir}/lib -lm -ldl' \ 105 --extra-ldflags='-L${ffmpeg_exported_release_dir}/lib -lm -ldl' \
123 --disable-ffplay --disable-ffprobe --disable-ffserver --disable-doc \ 106 --disable-ffplay --disable-ffprobe --disable-ffserver --disable-doc \
124 --enable-postproc --enable-bzlib --enable-zlib --enable-parsers \ 107 --enable-postproc --enable-bzlib --enable-zlib --enable-parsers \
125 - --enable-libfreetype \  
126 --enable-libx264 --enable-libmp3lame --enable-libaacplus --enable-libspeex \ 108 --enable-libx264 --enable-libmp3lame --enable-libaacplus --enable-libspeex \
127 --enable-pthreads --extra-libs=-lpthread \ 109 --enable-pthreads --extra-libs=-lpthread \
128 --enable-encoders --enable-decoders --enable-avfilter --enable-muxers --enable-demuxers && 110 --enable-encoders --enable-decoders --enable-avfilter --enable-muxers --enable-demuxers &&
@@ -102,14 +102,6 @@ function Ubuntu_prepare() @@ -102,14 +102,6 @@ function Ubuntu_prepare()
102 sudo apt-get install -y --force-yes zlib1g-dev; ret=$?; if [[ 0 -ne $ret ]]; then return $ret; fi 102 sudo apt-get install -y --force-yes zlib1g-dev; ret=$?; if [[ 0 -ne $ret ]]; then return $ret; fi
103 echo "install zlib1g-dev success" 103 echo "install zlib1g-dev success"
104 fi 104 fi
105 -  
106 - # for freetype2  
107 - pkg-config --help >/dev/null 2>&1; ret=$?; if [[ 0 -ne $ret ]]; then  
108 - echo "install pkg-config"  
109 - require_sudoer "sudo apt-get install -y --force-yes pkg-config"  
110 - sudo apt-get install -y --force-yes pkg-config; ret=$?; if [[ 0 -ne $ret ]]; then return $ret; fi  
111 - echo "install pkg-config success"  
112 - fi  
113 fi 105 fi
114 106
115 # for arm, install the cross build tool chain. 107 # for arm, install the cross build tool chain.
@@ -68,7 +68,8 @@ vhost demo.srs.com { @@ -68,7 +68,8 @@ vhost demo.srs.com {
68 engine ld { 68 engine ld {
69 enabled on; 69 enabled on;
70 vfilter { 70 vfilter {
71 - vf 'drawtext=text=SimpleRtmpServer(SRS):x=10:y=10:fontsize=30:fontcolor=#cccccc:fontfile=./doc/FreeSerifBold.ttf'; 71 + i ./doc/srs-logo.png;
  72 + filter_complex 'overlay=10:10';
72 } 73 }
73 vcodec libx264; 74 vcodec libx264;
74 vbitrate 300; 75 vbitrate 300;
@@ -135,7 +136,8 @@ vhost players { @@ -135,7 +136,8 @@ vhost players {
135 engine hls { 136 engine hls {
136 enabled on; 137 enabled on;
137 vfilter { 138 vfilter {
138 - vf 'drawtext=text=SRS(SimpleRtmpServer):x=10:y=10:fontcolor=#cccccc:fontfile=./doc/FreeSerifBold.ttf'; 139 + i ./doc/srs-logo.png;
  140 + filter_complex 'overlay=10:10';
139 } 141 }
140 vcodec libx264; 142 vcodec libx264;
141 vbitrate 300; 143 vbitrate 300;
@@ -513,36 +513,11 @@ vhost mirror.transcode.srs.com { @@ -513,36 +513,11 @@ vhost mirror.transcode.srs.com {
513 } 513 }
514 } 514 }
515 } 515 }
  516 +#
516 # the drawtext filter of ffmpeg, @see: http://ffmpeg.org/ffmpeg-filters.html#drawtext-1 517 # the drawtext filter of ffmpeg, @see: http://ffmpeg.org/ffmpeg-filters.html#drawtext-1
517 -vhost drawtext.transcode.srs.com {  
518 - transcode {  
519 - enabled on;  
520 - ffmpeg ./objs/ffmpeg/bin/ffmpeg;  
521 - engine drawtext {  
522 - enabled on;  
523 - vfilter {  
524 - vf 'drawtext=text=SimpleRtmpServer(SRS):x=10:y=10:fontcolor=#cccccc:fontfile=./doc/FreeSerifBold.ttf';  
525 - }  
526 - vcodec libx264;  
527 - vbitrate 300;  
528 - vfps 20;  
529 - vwidth 768;  
530 - vheight 320;  
531 - vthreads 2;  
532 - vprofile baseline;  
533 - vpreset superfast;  
534 - vparams {  
535 - }  
536 - acodec libaacplus;  
537 - abitrate 45;  
538 - asample_rate 44100;  
539 - achannels 2;  
540 - aparams {  
541 - }  
542 - output rtmp://127.0.0.1:[port]/[app]?vhost=[vhost]/[stream]_[engine];  
543 - }  
544 - }  
545 -} 518 +# remark: we remove the libfreetype which always cause build failed, you must add it manual if needed.
  519 +#
  520 +#######################################################################################################
546 # the crop filter of ffmpeg, @see: http://ffmpeg.org/ffmpeg-filters.html#crop 521 # the crop filter of ffmpeg, @see: http://ffmpeg.org/ffmpeg-filters.html#crop
547 vhost crop.transcode.srs.com { 522 vhost crop.transcode.srs.com {
548 transcode { 523 transcode {
不能预览此文件类型
@@ -4,11 +4,6 @@ ffmpeg-min.png @@ -4,11 +4,6 @@ ffmpeg-min.png
4 source.flv 4 source.flv
5 avatar预告片,400kbps。 5 avatar预告片,400kbps。
6 6
7 -FreeSerifBold.ttf  
8 - 字体文件,ffmpeg的drawtext filter需要使用。  
9 - 参考:http://ffmpeg.org/ffmpeg-filters.html#drawtext-1  
10 - 下载地址:http://www.fonts2u.com/free-serif.font  
11 -  
12 aac-iso-13818-7.pdf 7 aac-iso-13818-7.pdf
13 aac标准,aac的编码等。 8 aac标准,aac的编码等。
14 9
@@ -336,7 +336,7 @@ @@ -336,7 +336,7 @@
336 <div id="collapse2" class="accordion-body collapse"> 336 <div id="collapse2" class="accordion-body collapse">
337 <div class="accordion-inner"> 337 <div class="accordion-inner">
338 <a href="#" id="srs_publish_ld">rtmp://demo.srs.com/live/livestream_ld</a> <br/> 338 <a href="#" id="srs_publish_ld">rtmp://demo.srs.com/live/livestream_ld</a> <br/>
339 - <span>对原始流加了<a href="http://ffmpeg.org/ffmpeg-filters.html#drawtext-1">FFMPEG文字水印</a></span> 339 + <span>对原始流加了<a href="http://ffmpeg.org/ffmpeg-filters.html#overlay">FFMPEG图片水印</a></span>
340 </div> 340 </div>
341 </div> 341 </div>
342 </div> 342 </div>
@@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. @@ -31,7 +31,7 @@ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
31 // current release version 31 // current release version
32 #define VERSION_MAJOR "0" 32 #define VERSION_MAJOR "0"
33 #define VERSION_MINOR "9" 33 #define VERSION_MINOR "9"
34 -#define VERSION_REVISION "138" 34 +#define VERSION_REVISION "139"
35 #define RTMP_SIG_SRS_VERSION VERSION_MAJOR"."VERSION_MINOR"."VERSION_REVISION 35 #define RTMP_SIG_SRS_VERSION VERSION_MAJOR"."VERSION_MINOR"."VERSION_REVISION
36 // server info. 36 // server info.
37 #define RTMP_SIG_SRS_KEY "SRS" 37 #define RTMP_SIG_SRS_KEY "SRS"