Even more documentation, RTMP Connector compiles again, but still extremely buggy. Will create RTMP debugging tool soon. Something wrong with RTMP Connector reading FLV::Tags... needs more investigation.
This commit is contained in:
parent
b592442d6b
commit
6db6829545
29 changed files with 1451 additions and 1437 deletions
|
@ -1,6 +1,12 @@
|
|||
/// \file Connector_RAW/main.cpp
|
||||
/// Contains the main code for the RAW connector.
|
||||
|
||||
#include <iostream>
|
||||
#include "../util/ddv_socket.h"
|
||||
|
||||
/// Contains the main code for the RAW connector.
|
||||
/// Expects a single commandline argument telling it which stream to connect to,
|
||||
/// then outputs the raw stream to stdout.
|
||||
int main(int argc, char ** argv) {
|
||||
if (argc < 2){
|
||||
std::cout << "Usage: " << argv[0] << " stream_name" << std::endl;
|
||||
|
@ -8,11 +14,14 @@ int main(int argc, char ** argv) {
|
|||
}
|
||||
std::string input = "/tmp/shared_socket_";
|
||||
input += argv[1];
|
||||
//connect to the proper stream
|
||||
DDV::Socket S(input);
|
||||
if (!S.connected()){
|
||||
std::cout << "Could not open stream " << argv[1] << std::endl;
|
||||
return 1;
|
||||
}
|
||||
//transport ~50kb at a time
|
||||
//this is a nice tradeoff between CPU usage and speed
|
||||
char buffer[50000];
|
||||
while(std::cout.good() && S.read(buffer,50000)){std::cout.write(buffer,50000);}
|
||||
S.close();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue