FFmpeg
|
multiple format streaming server based on the FFmpeg libraries More...
#include "config.h"
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include "libavformat/avformat.h"
#include "libavformat/ffm.h"
#include "libavformat/network.h"
#include "libavformat/os_support.h"
#include "libavformat/rtpdec.h"
#include "libavformat/rtpproto.h"
#include "libavformat/rtsp.h"
#include "libavformat/rtspcodes.h"
#include "libavformat/avio_internal.h"
#include "libavformat/internal.h"
#include "libavformat/url.h"
#include "libavutil/avassert.h"
#include "libavutil/avstring.h"
#include "libavutil/lfg.h"
#include "libavutil/dict.h"
#include "libavutil/intreadwrite.h"
#include "libavutil/mathematics.h"
#include "libavutil/random_seed.h"
#include "libavutil/parseutils.h"
#include "libavutil/opt.h"
#include "libavutil/time.h"
#include <stdarg.h>
#include <fcntl.h>
#include <sys/ioctl.h>
#include <errno.h>
#include <sys/wait.h>
#include <signal.h>
#include "cmdutils.h"
#include "ffserver_config.h"
#include "cmdutils_common_opts.h"
Go to the source code of this file.
Data Structures | |
struct | RTSPActionServerSetup |
struct | DataRateData |
struct | HTTPContext |
struct | FeedData |
Macros | |
#define | closesocket close |
#define | IOBUFFER_INIT_SIZE 8192 |
#define | HTTP_REQUEST_TIMEOUT (15 * 1000) |
#define | RTSP_REQUEST_TIMEOUT (3600 * 24 * 1000) |
#define | SYNC_TIMEOUT (10 * 1000) |
#define | CHECK_CODEC(x) (ccf->x != ccs->x) |
Variables | |
const char | program_name [] = "ffserver" |
program name, defined by the program for show_version(). | |
const int | program_birth_year = 2000 |
program birth year, defined by the program for show_banner() | |
static const OptionDef | options [] |
static const char *const | http_state [] |
static HTTPContext * | first_http_ctx |
static FFServerConfig | config |
static const char * | my_program_name |
static int | no_launch |
static int | need_to_start_children |
static unsigned int | nb_connections |
static uint64_t | current_bandwidth |
static int64_t | cur_time |
static AVLFG | random_state |
static FILE * | logfile = NULL |
multiple format streaming server based on the FFmpeg libraries
Definition in file ffserver.c.
#define closesocket close |
Definition at line 28 of file ffserver.c.
Referenced by close_connection(), ff_listen_bind(), http_server(), new_connection(), sctp_close(), sctp_open(), socket_open_listen(), tcp_close(), tcp_open(), udp_close(), udp_open(), udp_socket_create(), unix_close(), and unix_open().
#define IOBUFFER_INIT_SIZE 8192 |
Definition at line 110 of file ffserver.c.
Referenced by new_connection(), and rtp_new_connection().
#define HTTP_REQUEST_TIMEOUT (15 * 1000) |
Definition at line 113 of file ffserver.c.
Referenced by start_wait_request().
#define RTSP_REQUEST_TIMEOUT (3600 * 24 * 1000) |
Definition at line 114 of file ffserver.c.
Referenced by start_wait_request().
#define SYNC_TIMEOUT (10 * 1000) |
Definition at line 116 of file ffserver.c.
#define CHECK_CODEC | ( | x | ) | (ccf->x != ccs->x) |
Referenced by build_feed_streams().
enum HTTPState |
Definition at line 79 of file ffserver.c.
enum RedirType |
Definition at line 1301 of file ffserver.c.
|
static |
Definition at line 734 of file ffserver.c.
Referenced by http_server().
|
static |
Definition at line 785 of file ffserver.c.
Referenced by handle_connection(), http_server(), and rtsp_cmd_interrupt().
|
static |
Definition at line 872 of file ffserver.c.
Referenced by http_server().
|
static |
Definition at line 1749 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 2014 of file ffserver.c.
Referenced by http_parse_request(), http_prepare_data(), rtsp_cmd_setup(), and start_multicast().
|
static |
Definition at line 1311 of file ffserver.c.
Referenced by handle_connection().
|
static |
Definition at line 2347 of file ffserver.c.
Referenced by handle_connection().
|
static |
Definition at line 2467 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 2529 of file ffserver.c.
Referenced by handle_connection().
|
static |
Definition at line 2717 of file ffserver.c.
Referenced by handle_connection().
|
static |
Definition at line 2864 of file ffserver.c.
Referenced by rtsp_parse_request().
|
static |
Definition at line 2854 of file ffserver.c.
Referenced by rtsp_parse_request().
|
static |
Definition at line 2938 of file ffserver.c.
Referenced by rtsp_parse_request().
|
static |
Definition at line 3119 of file ffserver.c.
Referenced by rtsp_parse_request().
|
static |
Definition at line 3145 of file ffserver.c.
Referenced by rtsp_parse_request().
|
static |
Definition at line 2806 of file ffserver.c.
Referenced by http_parse_request(), and rtsp_cmd_describe().
|
static |
Definition at line 3179 of file ffserver.c.
Referenced by rtsp_cmd_setup(), and start_multicast().
|
static |
Definition at line 3246 of file ffserver.c.
Referenced by rtsp_cmd_setup(), and start_multicast().
|
static |
Definition at line 259 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 267 of file ffserver.c.
Referenced by build_feed_streams(), and http_start_receive_data().
|
static |
Definition at line 278 of file ffserver.c.
Referenced by http_receive_data(), and http_start_receive_data().
|
static |
Definition at line 292 of file ffserver.c.
Referenced by http_prepare_data().
|
static |
Definition at line 300 of file ffserver.c.
Referenced by http_vlog().
|
static |
Definition at line 314 of file ffserver.c.
Referenced by http_av_log(), and http_log().
|
static |
Definition at line 334 of file ffserver.c.
Referenced by build_feed_streams(), build_file_streams(), http_av_log(), http_parse_request(), http_prepare_data(), http_receive_data(), http_server(), http_start_receive_data(), log_connection(), main(), new_connection(), open_input_stream(), rtp_new_av_stream(), start_children(), and start_multicast().
Definition at line 342 of file ffserver.c.
Referenced by main().
|
static |
Definition at line 354 of file ffserver.c.
Referenced by http_server().
|
static |
Definition at line 364 of file ffserver.c.
Referenced by http_receive_data(), and http_send_data().
|
static |
Definition at line 378 of file ffserver.c.
Referenced by compute_status().
|
static |
Definition at line 387 of file ffserver.c.
Referenced by http_server().
|
static |
Definition at line 451 of file ffserver.c.
Referenced by http_server().
Definition at line 488 of file ffserver.c.
Referenced by http_server().
|
static |
Definition at line 549 of file ffserver.c.
Referenced by main().
|
static |
Definition at line 701 of file ffserver.c.
Referenced by handle_connection(), and new_connection().
|
static |
Definition at line 715 of file ffserver.c.
Referenced by new_connection().
|
static |
Definition at line 1049 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 1096 of file ffserver.c.
Referenced by modify_current_stream().
|
static |
Definition at line 1134 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 1172 of file ffserver.c.
Referenced by http_parse_request(), and rtsp_parse_request().
|
static |
Definition at line 1190 of file ffserver.c.
Referenced by validate_acl().
|
static |
Definition at line 1227 of file ffserver.c.
Referenced by validate_acl().
|
static |
Definition at line 1239 of file ffserver.c.
Referenced by validate_acl().
|
static |
Definition at line 1256 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 1277 of file ffserver.c.
Referenced by http_parse_request().
|
static |
Definition at line 1739 of file ffserver.c.
Referenced by compute_status().
|
static |
Definition at line 2093 of file ffserver.c.
Referenced by http_send_data().
|
static |
Definition at line 2101 of file ffserver.c.
Referenced by http_send_data().
|
static |
Definition at line 2116 of file ffserver.c.
Referenced by http_send_data().
|
static |
Definition at line 2690 of file ffserver.c.
Referenced by rtsp_cmd_describe(), rtsp_cmd_interrupt(), rtsp_cmd_play(), rtsp_cmd_setup(), and rtsp_reply_error().
|
static |
Definition at line 2711 of file ffserver.c.
Referenced by rtsp_cmd_describe(), rtsp_cmd_interrupt(), rtsp_cmd_play(), rtsp_cmd_setup(), and rtsp_parse_request().
|
static |
Definition at line 2911 of file ffserver.c.
Referenced by find_rtp_session_with_url(), and rtsp_cmd_setup().
|
static |
Definition at line 2925 of file ffserver.c.
Referenced by rtsp_cmd_setup().
|
static |
Definition at line 3085 of file ffserver.c.
Referenced by rtsp_cmd_interrupt(), and rtsp_cmd_play().
|
static |
Definition at line 3345 of file ffserver.c.
Referenced by add_av_stream(), and build_file_streams().
|
static |
Definition at line 3374 of file ffserver.c.
Referenced by build_feed_streams().
|
static |
Definition at line 3416 of file ffserver.c.
Referenced by build_file_streams().
|
static |
Definition at line 3429 of file ffserver.c.
Referenced by build_file_streams().
Definition at line 3481 of file ffserver.c.
Referenced by main().
Definition at line 3538 of file ffserver.c.
Referenced by main().
Definition at line 3685 of file ffserver.c.
Referenced by main().
|
static |
Definition at line 3708 of file ffserver.c.
Referenced by main().
Definition at line 3735 of file ffserver.c.
void show_help_default | ( | const char * | opt, |
const char * | arg | ||
) |
Per-fftool specific help handler.
Implemented in each fftool, called by show_help().
Definition at line 3741 of file ffserver.c.
Referenced by show_help().
int main | ( | int | argc, |
char ** | argv | ||
) |
Definition at line 3757 of file ffserver.c.
const char program_name[] = "ffserver" |
program name, defined by the program for show_version().
Definition at line 74 of file ffserver.c.
Referenced by compute_status(), expand_filename_template(), init_report(), main(), print_program_info(), show_help_default(), show_license(), and show_usage().
const int program_birth_year = 2000 |
program birth year, defined by the program for show_banner()
Definition at line 75 of file ffserver.c.
Referenced by ffprobe_show_program_version(), and print_program_info().
|
static |
Definition at line 77 of file ffserver.c.
|
static |
Definition at line 94 of file ffserver.c.
Referenced by compute_status().
|
static |
Definition at line 198 of file ffserver.c.
Referenced by close_connection(), compute_status(), http_server(), new_connection(), and rtp_new_connection().
|
static |
Definition at line 200 of file ffserver.c.
Referenced by dshow_cycle_formats(), dshow_set_audio_buffer_size(), dxva2_create_decoder(), parse_dsd_prop(), parse_fmtp_config(), and wavpack_encode_init().
|
static |
Definition at line 243 of file ffserver.c.
Referenced by main(), and start_children().
|
static |
Definition at line 245 of file ffserver.c.
Referenced by start_children().
|
static |
Definition at line 246 of file ffserver.c.
Referenced by handle_child_exit(), and http_server().
|
static |
Definition at line 249 of file ffserver.c.
Referenced by close_connection(), compute_status(), http_send_too_busy_reply(), new_connection(), and rtp_new_connection().
|
static |
Definition at line 251 of file ffserver.c.
Referenced by close_connection(), compute_status(), http_parse_request(), and rtp_new_connection().
|
static |
Definition at line 253 of file ffserver.c.
Referenced by audio_read_packet(), check_keyboard_interaction(), compute_datarate(), get_server_clock(), handle_connection(), http_prepare_data(), http_server(), open_input_stream(), output_segment_list(), print_report(), start_wait_request(), transcode(), update_datarate(), and video_refresh().
|
static |
Definition at line 255 of file ffserver.c.
|
static |
Definition at line 257 of file ffserver.c.
Referenced by http_vlog(), and main().