1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- #ifndef DEFINES_H
- # define DEFINES_H
-
- #undef DEBUG
- //#define DEBUG 1
-
- #define VERSION_ID "1.00"
- #define BUILD_ID GIT_BUILD_ID
-
- #define SERVER_SIGNATURE "tsiproxy"
- #define COPYRIGHT "Copyright (c) 2020 Georgi Chorbadzhiiyski <georgi@unixsol.net>"
-
- /*
- This define is used to compensate for servers clock drift.
- It allows to watch URLs which otherwise will be active after
- upto URL_START_TOLERANCE seconds in the future. If the server
- clock is more than URL_START_TOLERANCE late or the URL is
- generated too far in the future, the client will get
- not-active video.
- */
- #define URL_START_TOLERANCE 180
-
- /*
- This define is used to set after how many seconds with no
- traffic the client will be disconnected.
- */
- #define NO_TRAFFIC_SECONDS 30
-
- /*
- How many seconds after start of connection NEW message will be logged.
- The check is > NO_LOG_START_SECONDS
- */
- #define NO_LOG_START_SECONDS 3
-
- /*
- How many seconds minimum should LOG{} be emitted.
- The check is > NO_LOG_END_SECONDS
- */
- #define NO_LOG_END_SECONDS 3
-
- /* How much miliseconds to wait for connection to be established with config server */
- #define CONFIG_CONNECT_TIMEOUT 10*1000
-
- #define CONFIG_LOAD_TIMEOUT 60
-
-
-
-
- /* How much to wait for connection to be established with channel source (miliseconds) */
- #define PROXY_CONNECT_TIMEOUT 1000
-
- /*
- The total time it takes to return no-signal is equal to
- PROXY_CONNECT_RETRIES * PROXY_RETRY_TIMEOUT
- */
-
- /* How many times to try to connect to channel */
- #define PROXY_CONNECT_RETRIES 5
-
- /* Seconds to sleep between retries (miliseconds) */
- #define PROXY_RETRY_TIMEOUT 1000
-
- #define FRAME_PACKET_SIZE 1316
-
- #define NEW_DURATION_WEIGHT 0.5
- #define TIME_ADJUSTMENT_FACTOR 0.8
- #define MAX_PLAYOUT_BUFFER_DURATION 0.1 // (seconds)
- #define PCR_PERIOD_VARIATION_RATIO 0.5
-
- #define unused(x) (void)x
-
- #define BUF 1536
-
- #endif
|