Created: 06/08/2022
By: Vanea Young
Support: Help Desk
Version: v1.0 [06/08/2022]
Thank you for purchasing my item. If you have any questions that are beyond the scope of this help file, please feel free to email via my user page contact form here. Thanks so much!
[includes]
[content]
[cr-turnserver]
[vy-livestream]
*vy-livestream-cmd.php
# Installer
RewriteRule ^install/?$ install.php [L,QSA]
# Live Plugin
RewriteRule ^livestream$ vy-livestream-cmd.php [QSA]
RewriteRule ^watchstream$ vy-livestream-cmd.php?cmd=watchstream [QSA]
Redirect 301 /live /livestream
RewriteRule ^livestream/g/([^\/]+)(\/|)$ vy-livestream-cmd.php?group_id=$1 [NC,QSA]
RewriteRule ^livestream/p/([^\/]+)(\/|)$ vy-livestream-cmd.php?page_id=$1 [NC,QSA]
RewriteRule ^livestream/up$ vy-livestream-cmd.php?cmd=blueimpupload [NC,QSA]
RewriteRule ^livestream/u/(.*)$ vy-livestream-cmd.php?cmd=openuser&id=$1 [NC,QSA]
# Live plugin
location = /live { return 301 /livestream; }
rewrite ^/livestream$ /vy-livestream-cmd.php;
rewrite ^/watchstream$ /vy-livestream-cmd.php?cmd=watchstream;
rewrite ^/livestream/g/([^\/]+)(\/|)$ /vy-livestream-cmd.php?group_id=$1;
rewrite ^/livestream/p/([^\/]+)(\/|)$ /vy-livestream-cmd.php?page_id=$1;
rewrite ^/livestream/up$ /vy-livestream-cmd.php?cmd=blueimpupload;
rewrite ^/livestream/u/(.*)$ /vy-livestream-cmd.php?cmd=openuser&id=$1;
/content/themes/default/templates/_js_files.tpl
{/strip}
{if $user->_logged_in}
{include file='../../../../vy-livestream/assets.html'}
{/if}
{elseif $_post['post_type'] == "live" && $_post['live']}
{elseif $_post['post_type'] == "live" && $_post['vy-live'] == 'yes'}
{include file="__feed_vy_livestream.tpl"}
/* assign variables */
$smarty->assign('ads_master', $ads_master);
// include Live stream
$vy = array();
$vy['user'] = $user->_data;
require_once('includes/vaneayoung/LiveStream/classes/class.LiveStream.php');
$smarty->assign(["wo" => $vy, "vy" => $vy, "GLOBALS" => $GLOBALS, "live_stream" => new LIVE_STREAM]);
$agora = $this->agora_token_builder(false, $post['live']['agora_channel_name']);
$post['live']['agora_audience_uid'] = $agora['uid'];
$post['live']['agora_audience_token'] = $agora['token'];
/*
$agora = $this->agora_token_builder(false, $post['live']['agora_channel_name']);
$post['live']['agora_audience_uid'] = $agora['uid'];
$post['live']['agora_audience_token'] = $agora['token'];
*/
;<?php die('Direct access not allowed ;') ?>
;The above is for security, do not remove
[purchase code]
st__PURCHASE_KEY = YOUR_LICENSE_KEY
[THEME]
st__ORIGINAL_THEME_NAME = "default";
[TIMEZONE]
timezone = "Europe/Berlin"
[sngine tables]
tbl_users = "`users`";
tbl_comments = "`posts_comments`";
tbl_notif = "`notifications`";
tbl_pages = "`pages`";
tbl_groups = "`groups`";
tbl_posts = "`posts`";
tbl_posts_live = "`posts_live`";
tbl_followers = "`followings`";
[live tables]
tbl_vy_lv_broadcasts = "`vy_live_broadcasts`";
tbl_vy_lv_config = "`vy_live_conf`";
[server url]
st__APP_SERVER_URL = ""; # your domain name where running nodejs application
[ports]
st__SERVER_PORT = ""; # port number
st__RTMP_PORT_TLS = ""; # port number
st__RTMP_PORT = "";# port number
st__RTMP_HTTP = "";# port number
st__RTMP_HTTPS = "";# port number
st__MEDIA_SERVER = "";# port number
st__MEDIA_SERVER_TLS = "";# port number
[plugin location]
st__PLUGIN_ASSETS = "/vy-livestream" ;
[default blank cover]
st__DEFAULT_BLANK = "/vy-livestream/blank.png";
[ffmpeg]
st__ffmpeg_path = "/usr/bin/ffmpeg"; # define ffmpeg location [ $ whereis ffmpeg ]
[sounds]
st__success = "sounds/success.mp3";
st__countdown2 = "sounds/countdown2.mp3";
st__countdown = "sounds/countdown.mp3";
st__clickuibut = "sounds/clickuibut.mp3";
st__openpopup = "sounds/openpopup.mp3";
[storage]
st__STORAGE_DIR = "content/uploads/vy-streams-media"; # the path where to save all the broadcast records
st__recording = 1; # record bool true|false
st__record_type = ".mp4"; # allowed format > [.mp4 or .webm], record video format webm or mp4 [this is only for local device streaming not for OBS]
st_mp4_high_quality = 0; # this only works if record_type option is set to .mp4 value,
# if you enable this to true the video size will increase x4,
# for example a 1 minute video size will be almost 100MB
[settings]
st__reconnecting_notif = 1; # by enabling this users with low network connection will face issue
st__rtmp_enabled = 1; # RTMP ENABLED TRUE / FALSE
st__away_desktop = 0; # IF USER STREAMING FROM PC (DESKTOP) enable disable Away feature ( by default away feature is enabled only for mobiles )
st__audioBitsPerSecond = 128000; # AUDIO BITS PER SECOND
st__videoBitsPerSecond = 2500000;# VIDEO BITS PER SECOND
st__fr_miliseconds = 1000;# the number of milliseconds to record into each Blob
st__stream_secret = "22r2m6p13rra1w2022"; # stream secret, any word
st__stream_prefix = "VY"; # stream key prefix
st__app_name = "live"; # define app name, you can leave it as default
st__hls = 1; # hls bool true/false
st__hlsFlags = "[hls_time=2:hls_list_size=3:hls_flags=delete_segments]"; # hls options
st__dash = 1; # dash bool true/false
st__dashFlags = "[f=dash:window_size=3:extra_window_size=5]"; # dash options
st__mp4Flags = "[movflags=faststart]"; # mp4 options
{
"urls":"turn:YOUR_TURN_SERVER_URL:PORT",
"username":"YOUR_TURN_SERVER_USERNAME",
"credential":"YOUR_TURN_SERVER_CREDENTIAL"
}
database.sql
https://liveplugin.kontackt.de/setup.html