Remove rtsp_options from output/rtsp
This commit is contained in:
parent
df67c0272e
commit
328198745b
@ -12,6 +12,7 @@ extern option_t all_options[];
|
|||||||
extern camera_options_t camera_options;
|
extern camera_options_t camera_options;
|
||||||
extern http_server_options_t http_options;
|
extern http_server_options_t http_options;
|
||||||
extern http_method_t http_methods[];
|
extern http_method_t http_methods[];
|
||||||
|
extern rtsp_options_t rtsp_options;
|
||||||
|
|
||||||
camera_t *camera;
|
camera_t *camera;
|
||||||
|
|
||||||
@ -41,7 +42,7 @@ int main(int argc, char *argv[])
|
|||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rtsp_options.port > 0 && rtsp_server() < 0) {
|
if (rtsp_options.port > 0 && rtsp_server(&rtsp_options) < 0) {
|
||||||
goto error;
|
goto error;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -204,7 +204,7 @@ static void *rtsp_server_thread(void *opaque)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern "C" int rtsp_server()
|
extern "C" int rtsp_server(rtsp_options_t *options)
|
||||||
{
|
{
|
||||||
// Begin by setting up our usage environment:
|
// Begin by setting up our usage environment:
|
||||||
TaskScheduler* scheduler = BasicTaskScheduler::createNew();
|
TaskScheduler* scheduler = BasicTaskScheduler::createNew();
|
||||||
@ -220,12 +220,12 @@ extern "C" int rtsp_server()
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
RTSPServer* rtspServer;
|
RTSPServer* rtspServer;
|
||||||
rtspServer = DynamicRTSPServer::createNew(*env, rtsp_options.port, authDB);
|
rtspServer = DynamicRTSPServer::createNew(*env, options->port, authDB);
|
||||||
if (rtspServer == NULL) {
|
if (rtspServer == NULL) {
|
||||||
LOG_ERROR(NULL, "Failed to create RTSP server: %s", env->getResultMsg());
|
LOG_ERROR(NULL, "Failed to create RTSP server: %s", env->getResultMsg());
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
LOG_INFO(NULL, "Running RTSP server on '%d'", rtsp_options.port);
|
LOG_INFO(NULL, "Running RTSP server on '%d'", options->port);
|
||||||
|
|
||||||
// if (rtspServer->setUpTunnelingOverHTTP(80) || rtspServer->setUpTunnelingOverHTTP(8000) || rtspServer->setUpTunnelingOverHTTP(8080)) {
|
// if (rtspServer->setUpTunnelingOverHTTP(80) || rtspServer->setUpTunnelingOverHTTP(8000) || rtspServer->setUpTunnelingOverHTTP(8080)) {
|
||||||
// LOG_INFO(NULL, "Running RTSP-over-HTTP tunneling on '%d'", rtspServer->httpServerPortNum());
|
// LOG_INFO(NULL, "Running RTSP-over-HTTP tunneling on '%d'", rtspServer->httpServerPortNum());
|
||||||
|
@ -4,9 +4,7 @@ typedef struct rtsp_options_s {
|
|||||||
uint port;
|
uint port;
|
||||||
} rtsp_options_t;
|
} rtsp_options_t;
|
||||||
|
|
||||||
extern rtsp_options_t rtsp_options;
|
int rtsp_server(rtsp_options_t *options);
|
||||||
|
|
||||||
int rtsp_server();
|
|
||||||
bool rtsp_h264_needs_buffer();
|
bool rtsp_h264_needs_buffer();
|
||||||
void rtsp_h264_capture(struct buffer_s *buf);
|
void rtsp_h264_capture(struct buffer_s *buf);
|
||||||
void rtsp_h264_low_res_capture(struct buffer_s *buf);
|
void rtsp_h264_low_res_capture(struct buffer_s *buf);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user