Werkende RTMP connector! WHEEEE! Also, RTMPf weggegooit. Er is geen ruimte voor faal in dit bedrijf!

This commit is contained in:
Thulinma 2010-11-17 01:05:36 +01:00
parent fbd0520264
commit 273f30784b
22 changed files with 123 additions and 2015 deletions

View file

@ -70,7 +70,7 @@ int main( int argc, char * argv[] ) {
//invalidate the current buffer
ringbuf[current_buffer]->number = -1;
if ((epoll_wait(poller, events, 1, 100) > 0) && FLV_GetPacket(ringbuf[current_buffer]->FLV)){
loopcount ++;
loopcount++;
packtype = ringbuf[current_buffer]->FLV->data[0];
//store metadata, if available
if (packtype == 0x12){
@ -113,12 +113,14 @@ int main( int argc, char * argv[] ) {
}
//on keyframe set start point
if (packtype == 0x09){
if (((ringbuf[current_buffer]->FLV->data[11] & 0xf0) >> 4) == 1){lastproper = current_buffer;}
if (((ringbuf[current_buffer]->FLV->data[11] & 0xf0) >> 4) == 1){
lastproper = current_buffer;
}
}
//keep track of buffers
ringbuf[current_buffer]->number = loopcount;
current_buffer++;
current_buffer %= buffers;
ringbuf[current_buffer]->number = loopcount;
}
//check for new connections, accept them if there are any

View file

@ -5,5 +5,5 @@
#ffmpeg -y -i "$1" -ar 44100 -vcodec libx264 -b 1000k -g 150 -r 20 -f flv - | ./Buffer 500
ffmpeg -i "$1" -re -acodec aac -ar 11025 -vcodec libx264 -b 700k -vpre ultrafast -refs 1 -bf 0 -g 150 -f flv - 2> /dev/null | ./Buffer 500
ffmpeg -i "$1" -re -acodec aac -ar 11025 -vcodec libx264 -b 700k -vpre ultrafast -refs 1 -bf 0 -g 150 -f flv - 2> /dev/null | ./Buffer 500 $2