{"id":64519,"date":"2024-08-28T03:01:00","date_gmt":"2024-08-27T17:01:00","guid":{"rendered":"https:\/\/65.254.95.247\/ITblog\/?p=64519"},"modified":"2024-08-27T17:10:53","modified_gmt":"2024-08-27T07:10:53","slug":"ffmpeg-user-defined-video-editing-crontab-assisted-sharing-tutorial","status":"publish","type":"post","link":"https:\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-video-editing-crontab-assisted-sharing-tutorial\/","title":{"rendered":"Ffmpeg User Defined Video Editing Crontab Assisted Sharing Tutorial"},"content":{"rendered":"<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Ffmpeg User Defined Video Editing Crontab Assisted Sharing Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/ffmpeg\/ffmpeg_user_defined_moresharing.gif\" title=\"Ffmpeg User Defined Video Editing Crontab Assisted Sharing Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">Ffmpeg User Defined Video Editing Crontab Assisted Sharing Tutorial<\/p><\/div>\n<p>In yesterday&#8217;s <a title='Ffmpeg User Defined Video Editing Sharing Tutorial' href='#fudvest'>Ffmpeg User Defined Video Editing Sharing Tutorial<\/a> about sharing video data (that might have been edited by <a target=\"_blank\" title='ffmpeg' href='https:\/\/www.ffmpeg.org\/' rel=\"noopener\">ffmpeg<\/a> command line means) we warned &#8230;<\/p>\n<blockquote><p>\neven though it is only likely to work for shorter videos\n<\/p><\/blockquote>\n<p> &#8230; regarding the <i>data URI<\/i> hashtagged parts to SMS or email links that we were exclusively using &#8230; then.  But, with this in mind, what do &#8230;<\/p>\n<ol>\n<li>data URI based URLs (hashtagged in an email or SMS link) &#8230; and &#8230;<\/li>\n<li>absolute URL that points to a web server soft link file, itself pointing to <i>\/tmp\/<\/i> video data files ((we&#8217;re still hashtagging, but now, don&#8217;t really have to, apply) in an email or SMS link)<\/li>\n<\/ol>\n<p> &#8230; share?  We&#8217;d say, as far as sharing goes &#8230;<\/p>\n<blockquote><p>\nA sense of permanency.\n<\/p><\/blockquote>\n<p>But &#8230;<\/p>\n<ul>\n<li>the second one does not &#8220;push the barrow&#8221; as much as the first regarding the amount of data &#8230; whereas &#8230;<\/li>\n<li>the first is totally ephemeral and not asking anything more of the web server (ie. the RJM Programming associated one) regarding ongoing storage but is asking a lot of web browsers and client mail applications in the case of video data of any bulk<\/li>\n<\/ul>\n<p>In terms of sharing videos of any bulk, we&#8217;re now, with our web application &#8230;<\/p>\n<ul>\n<li>renaming the top button (that used to be &#8220;Display&#8221;) as &#8220;Display for a Day&#8221; and applying <i>absolute URL<\/i> (that point at web server soft links that, in turn, point at what can be sizeable video data files that might hang around in RJM Programming domain associated web server <i>\/tmp\/<\/i> location) logics which call on &#8220;crontab&#8221; &#8230; (<br \/>\n<code><br \/>\n*\/53 * * * * \/etc\/init.d\/every_hour.sh<br \/>\n<\/code><br \/>\n &#8230; now mentions &#8230;<br \/>\n<code><br \/>\nksh -c 'for i in `find \/tmp -name \"my_video_*.*\" -mmin -1440`; do rm -f $i; done'<br \/>\n<\/code><br \/>\n) &#8230; assistance to do with the tidy up we feel we need to  do on the web server so that large files do not hang around forever (and as you might surmise, at most a day, regarding the bulk of data requirements that are temporarily stored in <i>\/tmp\/<\/i> locations with user associated IP addresses part of the file naming paradigm) &#8230; whereas &#8230;<\/li>\n<li>the bottom button remains as &#8220;Display&#8221; and still uses <i>data URI<\/i> based logic<\/li>\n<\/ul>\n<p> &#8230; so that these bulky videos can be successfully shared (via clicks of that &#8220;Display for a Day&#8221; button) as long as the email or SMS link is attended to by the collaboration recipient within those 24 hours, further to yesterday&#8217;s <a title='Ffmpeg User Defined Video Editing Sharing Tutorial' href='#fudvest'>Ffmpeg User Defined Video Editing Sharing Tutorial<\/a>.<\/p>\n<p>As well, today, as a genericization measure, we stop seeing <i>govetts_leap<\/i> in any video file naming, replaced by <i>my_video<\/i> now that the input video control has become less rigid, and now can be controlled, to some extent, by the user in <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php---GETME\" rel=\"noopener\">our changed<\/a> <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php---GETME\" rel=\"noopener\">fourth draft<\/a> of <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\">Your Own Ffmpeg Video Changes<\/a>, which can be that much more useful in <a target=\"_blank\" href=\"https:\/\/65.254.95.247\/macos_ffmpeg_convert.php\" rel=\"noopener\">a new way<\/a> in the AlmaLinux web server environment.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=\"_blank\" href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-video-editing-crontab-assisted-sharing-tutorial\/' rel=\"noopener\">Ffmpeg User Defined Video Editing Crontab Assisted Sharing Tutorial<\/a>.<\/p-->\n<hr>\n<p id='fudvest'>Previous relevant <a target=\"_blank\" title='Ffmpeg User Defined Video Editing Sharing Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-video-editing-sharing-tutorial\/' rel=\"noopener\">Ffmpeg User Defined Video Editing Sharing Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Ffmpeg User Defined Video Editing Sharing Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/ffmpeg\/ffmpeg_user_defined_sharing.gif\" title=\"Ffmpeg User Defined Video Editing Sharing Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">Ffmpeg User Defined Video Editing Sharing Tutorial<\/p><\/div>\n<p>Sharing options for video based data are often more restrictive regarding email and SMS conduits, but we&#8217;ll still go ahead with a &#8230;<\/p>\n<ul>\n<li>&#8220;a&#8221; link &#8220;mailto:&#8221; (for emails) or &#8220;sms:&#8221; (for SMS) methodology &#8230;<\/li>\n<li>email subject containing ffmpeg command used for an output video mode of sharing &#8230; or &#8230;<\/li>\n<li>input video mode of sharing before any ffmpeg involvement &#8230; based on &#8230;<\/li>\n<li>email or SMS links where the video data URI (as necessary) is hashtagged<\/li>\n<\/ul>\n<p> &#8230; set of ideas to try out, even though it is only likely to work for shorter videos.  The other more obvious sharing mechanism is to download video data via right click options the web browser product you are using offers anyway.  And another sharing idea, independent, and working for input videos is to browse for a video using the helper web application from yesterday, and use its Share API based button below the browsing button to share that input video using one of &#8230;<\/p>\n<ul>\n<li>Mail<\/li>\n<li>Messages<\/li>\n<li>AirDrop<\/li>\n<li>Notes<\/li>\n<li>Simulator<\/li>\n<li>Freeform<\/li>\n<\/ul>\n<p> &#8230; on our macOS Safari web browser here on a MacBook Air.<\/p>\n<p>Further to yesterday&#8217;s <a title='Ffmpeg User Defined Browsed Video Editing Tutorial' href='#fudbvet'>Ffmpeg User Defined Browsed Video Editing Tutorial<\/a>, then, we have some new (PHP writes) Javascript functions &#8230;<\/p>\n<p>&lt;?php echo &#8221;<br \/>\n<code><br \/>\n  function smsit() {<br \/>\n    var smsno=prompt('Please enter SMS number.', '');<br \/>\n    if (smsno != null) {<br \/>\n      if (document.getElementById('cto').title.indexOf('data:') == 0) {<br \/>\n      document.getElementById('asms').href='sms:' + smsno + '&body=' + encodeURIComponent(document.URL.split('?')[0].split('#')[0] + '#vcont=' + document.getElementById('cto').title);<br \/>\n      } else {<br \/>\n      document.getElementById('asms').href='sms:' + smsno + '&body=' + encodeURIComponent(document.URL.split('?')[0].split('#')[0] + '#vcont=' + document.getElementById('resultav').value);<br \/>\n      }<br \/>\n      document.getElementById('asms').click();<br \/>\n    }<br \/>\n  }<br \/>\n      <br \/> <br \/>\n  function emailit() {<br \/>\n    var emailaddr=prompt('Please enter Email address.', '');<br \/>\n    if (emailaddr != null) {<br \/>\n      if (document.getElementById('cto').title.indexOf('data:') == 0) {<br \/>\n      document.getElementById('aemail').href='mailto:' + emailaddr + '?subject=Ffmpeg%20Video' + encodeURIComponent(' ... ' + document.getElementById('mysubtwo').value.replace(\/^Display$\/g,'')) + '&body=' + encodeURIComponent(document.URL.split('?')[0].split('#')[0] + '#vcont=' + document.getElementById('cto').title);<br \/>\n      } else {<br \/>\n      document.getElementById('aemail').href='mailto:' + emailaddr + '?subject=Ffmpeg%20Video' + encodeURIComponent(' ... ' + document.getElementById('mysubtwo').value.replace(\/^Display$\/g,'')) + '&body=' + encodeURIComponent(document.URL.split('?')[0].split('#')[0] + '#vcont=' + document.getElementById('resultav').value);<br \/>\n      }<br \/>\n      document.getElementById('aemail').click();<br \/>\n    }<br \/>\n  }<br \/>\n  <br \/>\n  function documentgetElementByIdmysubpclick() { \/\/ new arrangement for the programmatic click of form submit button<br \/>\n    if (eval('' + document.getElementById('resultav').value.length) &lt; 300) {<br \/>\n    document.getElementById('myiftwo').src=document.URL.split('?')[0].split('#')[0] + '?becomes=' + encodeURIComponent(document.getElementById('becomes').value) + '&browsed=' + encodeURIComponent(document.getElementById('resultav').value);<br \/>\n    } else {<br \/>\n    document.getElementById('mysubp').click();<br \/>\n    }<br \/>\n  }<br \/>\n<\/code><br \/>\n&#8220;; ?&gt;<\/p>\n<p> &#8230; in <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php--GETME\" rel=\"noopener\">our changed<\/a> <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php--GETME\" rel=\"noopener\">third draft<\/a> of <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\">Your Own Ffmpeg Video Changes<\/a>, which can be that much more useful in <a target=\"_blank\" href=\"https:\/\/65.254.95.247\/macos_ffmpeg_convert.php\" rel=\"noopener\">a new way<\/a> in the AlmaLinux web server environment.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=\"_blank\" href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-browsed-video-editing-sharing-tutorial\/' rel=\"noopener\">Ffmpeg User Defined Browsed Video Editing Sharing Tutorial<\/a>.<\/p-->\n<hr>\n<p id='fudbvet'>Previous relevant <a target=\"_blank\" title='Ffmpeg User Defined Browsed Video Editing Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-browsed-video-editing-tutorial\/' rel=\"noopener\">Ffmpeg User Defined Browsed Video Editing Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Ffmpeg User Defined Browsed Video Editing Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/ffmpeg\/ffmpeg_browsed_user_defined.gif\" title=\"Ffmpeg User Defined Browsed Video Editing Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">Ffmpeg User Defined Browsed Video Editing Tutorial<\/p><\/div>\n<p>Today&#8217;s work, onto yesterday&#8217;s <a title='Ffmpeg User Defined Video Editing Tutorial' href='#fudvet'>Ffmpeg User Defined Video Editing Tutorial<\/a>, is to loosen the restrictions regarding &#8220;input video file source&#8221; we had happening in that &#8220;first draft&#8221; incarnation of our Ffmpeg User Defined Video Editing web application.<\/p>\n<p>In order to achieve this, we called on a previous <a target=\"_blank\" href='https:\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-install-and-public-face-tutorial\/' title='Ffmpeg Install and Public Face Tutorial' rel=\"noopener\">Ffmpeg Install and Public Face Tutorial<\/a> inspired change to our inhouse macos_ffmpeg_convert.php PHP web application, which can serve as our conduit to either\/or &#8230;<\/li>\n<ul>\n<li>browse for a video file off the user local operating system environment &#8230; or &#8230;<\/li>\n<li>path to a web server placed video file &#8230; or &#8230;<\/li>\n<li>URL to a video file<\/li>\n<\/ul>\n<p> &#8230; extra means by which the user can define the &#8220;input video file source&#8221; that we&#8217;re loosening the shackles regarding usage.<\/p>\n<p>To do this, we look for user actions (via PHP writing out Javascript) &#8230;<\/p>\n<p>&lt;?php echo &#8221;<br \/>\n<code><br \/>\n  var lastpathc='';<br \/>\n  var lastopathc='';<br \/>\n  var lastvidc='';<br \/>\n  var lastvalue='.m4v';<br \/>\n  var exactvalue='';<br \/>\n  var vext='.mp4';<br \/>\n<br \/>\n  function lookfor() {<br \/>\n     vext='.mp4';<br \/>\n     var thisext='';<br \/>\n     if (document.getElementById('opath').value != '') {<br \/>\n       if (lastopathc != document.getElementById('opath').value && document.getElementById('opath').title != document.getElementById('opath').value) {<br \/>\n         lastopathc=document.getElementById('opath').value;<br \/>\n       }<br \/>\n     }<br \/>\n     if (document.getElementById('path').value != '') {<br \/>\n       if (lastpathc != document.getElementById('path').value) {<br \/>\n         lastpathc=document.getElementById('path').value;<br \/>\n         if (lastopathc == ' ') { lastopathc=document.getElementById('opath').value;   }<br \/>\n       }<br \/>\n     }<br \/>\n     if (lastopathc.trim() != '') {<br \/>\n       thisext=(lastopathc + '.').split('.')[1].split('.')[0].trim();<br \/>\n       if (thisext != '') {<br \/>\n       document.getElementById('opath').title=lastopathc;<br \/>\n       document.getElementById('path').title='video\/' + thisext + ';' + lastpathc + lastopathc;<br \/>\n       document.getElementById('resultav').value=lastpathc + lastopathc;<br \/>\n       lastopathc=' ';<br \/>\n       }<br \/>\n     }<br \/>\n     if (document.getElementById('resultav').value != '') {<br \/>\n       if (lastvidc != document.getElementById('resultav').value) {<br \/>\n         if ((document.getElementById('path').title + document.getElementById('resultav').value).indexOf('video\/') != -1) {<br \/>\n         if (document.getElementById('ifbrowse').src.indexOf('=') != -1) {<br \/>\n           document.getElementById('myaltin').value=decodeURIComponent(document.getElementById('ifbrowse').src.split('=')[1].split('&')[0].split('#')[0]);<br \/>\n         }<br \/>\n         if ((document.getElementById('path').title + document.getElementById('resultav').value).indexOf('video\/') != -1) {<br \/>\n         if (vext.indexOf((document.getElementById('path').title + document.getElementById('resultav').value).split('video\/')[1].split(';')[0].split(',')[0]) == -1) {<br \/>\n           vext='.' + document.getElementById('resultav').value.split('video\/')[1].split(';')[0].split(',')[0];<br \/>\n           document.getElementById('myaltin').value=document.getElementById('myaltin').value.split('.')[0] + vext;<br \/>\n           document.getElementById('becomes').value=document.getElementById('becomes').value.split('.')[0] + vext;<br \/>\n         }<br \/>\n         }<br \/>\n         lastvidc=document.getElementById('resultav').value;<br \/>\n         document.getElementById('resultav').title='rework';<br \/>\n         document.getElementById('mysubp').click();<br \/>\n         setTimeout(function(){<br \/>\n         if (1 == 1) {<br \/>\n         document.getElementById('divvid').innerHTML=\\\"&lt;video id=myinvideo style=width:95%; controls&gt;&lt;source id=myinsource type='video\/\\\" + vext.substring(1) + \\\"' src='\\\" + document.getElementById('resultav').value + \\\"'&gt;&lt;\/source&gt;&lt;\/video&gt;\\\";<br \/>\n         } else {<br \/>\n         document.getElementById('myinsource').src=document.getElementById('resultav').value;<br \/>\n         }<br \/>\n         }, 2000);<br \/>\n         \/\/setTimeout(function(){<br \/>\n         \/\/document.getElementById('resultav').value='';<br \/>\n         \/\/}, 20000);<br \/>\n         \/\/alert(lastvidc);<br \/>\n         setTimeout(lookfor, 23000);<br \/>\n         return '';<br \/>\n         }<br \/>\n         setTimeout(lookfor, 3000);<br \/>\n         return '';<br \/>\n       }<br \/>\n     }<br \/>\n     setTimeout(lookfor, 3000);<br \/>\n     return '';<br \/>\n  }<br \/>\n  <br \/>\n  setTimeout(lookfor, 3000);<br \/>\n<\/code><br \/>\n&#8220;; ?&gt;<\/p>\n<p> &#8230; and then arrange the <i>\/tmp\/<\/i> placed temporary video data via &#8230;<\/p>\n<p>&lt;?php<br \/>\n<code><br \/>\n  if (isset($_POST['browsed']) && isset($_POST['becomes'])) {<br \/>\n    $fgccont='';<br \/>\n    \/\/file_put_contents('xzm.xzm', '1');<br \/>\n    $outtmpfile=str_replace('+',' ',urldecode($_POST['becomes']));<br \/>\n    \/\/file_put_contents('xzm2.xzm2', $outtmpfile);<br \/>\n    $outext=explode('.', $outtmpfile)[-1 + sizeof(explode('.', $outtmpfile))];<br \/>\n    \/\/file_put_contents('xzm3.xzm3', str_replace(' ','+',urldecode($_POST['browsed'])));<br \/>\n    if (strpos(('xwq' . $_POST['browsed']), 'xwqdata') !== false) {<br \/>\n      file_put_contents(str_replace('+',' ',urldecode($_POST['becomes'])), base64_decode(explode(\";base64,\", str_replace(' ','+',urldecode($_POST['browsed'])))[1]));<br \/>\n    } else if (strpos(('xwq' . strtolower($_POST['browsed'])), 'xwqhttps') !== false) {<br \/>\n      $fgccont=file_get_contents('http' . substr(str_replace('+',' ',urldecode($_POST['browsed'])),5));<br \/>\n      if (trim($fgccont) != '') {<br \/>\n       file_put_contents(str_replace('+',' ',urldecode($_POST['becomes'])), $fgccont);<br \/>\n      }<br \/>\n    } else if (strpos(('xwq' . strtolower($_POST['browsed'])), 'xwqhttp') !== false) {<br \/>\n      $fgccont=file_get_contents('http' . substr(str_replace('+',' ',urldecode($_POST['browsed'])),4));<br \/>\n      if (trim($fgccont) != '') {<br \/>\n       file_put_contents(str_replace('+',' ',urldecode($_POST['becomes'])), $fgccont);<br \/>\n      }<br \/>\n    } else if (strpos(('xwq' . strtolower(str_replace('+',' ',urldecode($_POST['browsed'])))), 'xwq\/\/') !== false) {<br \/>\n      $fgccont=file_get_contents('http:' . substr(str_replace('+',' ',urldecode($_POST['browsed'])),0));<br \/>\n      if (trim($fgccont) != '') {<br \/>\n       file_put_contents(str_replace('+',' ',urldecode($_POST['becomes'])), $fgccont);<br \/>\n      }<br \/>\n    } else if (strpos(('xwq' . strtolower(str_replace('+',' ',urldecode($_POST['browsed'])))), 'xwqwww.') !== false) {<br \/>\n      $fgccont=file_get_contents('http:\/\/' . substr(str_replace('+',' ',urldecode($_POST['browsed'])),0));<br \/>\n      if (trim($fgccont) != '') {<br \/>\n       file_put_contents(str_replace('+',' ',urldecode($_POST['becomes'])), $fgccont);<br \/>\n      }<br \/>\n    } else if (file_exists(str_replace('+',' ',urldecode($_POST['browsed'])))) {<br \/>\n      file_put_contents(str_replace('+',' ',urldecode($_POST['becomes'])), file_get_contents(str_replace('+',' ',urldecode($_POST['browsed']))));<br \/>\n    }<br \/>\n    \/\/file_put_contents('xzm4.xzm4', explode(\";base64,\", str_replace(' ','+',urldecode($_POST['browsed'])))[1]);<br \/>\n    exit;<br \/>\n  }<br \/>\n<\/code><br \/>\n?&gt;<\/p>\n<p> &#8230; all the while being helped out by <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=http:\/\/www.rjmprogramming.com.au\/macos_ffmpeg_convert.php-----------GETME\" rel=\"noopener\">a tweaked<\/a> <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/macos_ffmpeg_convert.php-----------GETME\" rel=\"noopener\">macos_ffmpeg_convert.php<\/a> works <a target=\"_blank\" href=\"http:\/\/www.rjmprogramming.com.au\/macos_ffmpeg_convert.php\" rel=\"noopener\">Ffmpeg Converter Tool<\/a> PHP web application helper to <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/Geographicals\/diff.php?one=https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php-GETME\" rel=\"noopener\">our changed<\/a> <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php-GETME\" rel=\"noopener\">second draft<\/a> of <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\">Your Own Ffmpeg Video Changes<\/a>, which can be that much more useful in <a target=\"_blank\" href=\"https:\/\/65.254.95.247\/macos_ffmpeg_convert.php\" rel=\"noopener\">a new way<\/a> in the AlmaLinux web server environment.<\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=\"_blank\" href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-browsed-video-editing-tutorial\/' rel=\"noopener\">Ffmpeg User Defined Browsed Video Editing Tutorial<\/a>.<\/p-->\n<hr>\n<p id='fudvet'>Previous relevant <a target=\"_blank\" title='Ffmpeg User Defined Video Editing Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-video-editing-tutorial\/' rel=\"noopener\">Ffmpeg User Defined Video Editing Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Ffmpeg User Defined Video Editing Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/ffmpeg\/ffmpeg_user_defined.gif\" title=\"Ffmpeg User Defined Video Editing Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">Ffmpeg User Defined Video Editing Tutorial<\/p><\/div>\n<p>Today we&#8217;re combining video contents from &#8230;<\/p>\n<ul>\n<li>yesterday&#8217;s <a title='Ffmpeg Helps iPhone Video to YouTube Tutorial' href='#fhpvytt'>Ffmpeg Helps iPhone Video to YouTube Tutorial<\/a> &#8230; with &#8230;<\/li>\n<li>our newly created public interface to <a target=\"_blank\" title='ffmpeg' href='https:\/\/www.ffmpeg.org\/' rel=\"noopener\">ffmpeg<\/a> with the &#8220;soon to be DNS version of rjmprogramming.com.au <font size=1>&#8230; but not yet<\/font>&#8221; AlmaLinux Apache\/PHP\/MySql web server install we talked about at <a target=\"_blank\" href='https:\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-install-and-public-face-tutorial\/' title='Ffmpeg Install and Public Face Tutorial' rel=\"noopener\">Ffmpeg Install and Public Face Tutorial<\/a> &#8230; and &#8230;<\/li>\n<li>IP address redirecting, as needed, <i>ifconfig<\/i> (via PHP shell_exec and $_SERVER[&#8216;SERVER_ADDR&#8217;]) based logic &#8230;<br \/>\n&lt;?php<br \/>\n<code><br \/>\n  $whereplace=shell_exec(\"ifconfig | grep -Eo 'inet (addr:)?([0-9]*\\.){3}[0-9]*' | grep -Eo '([0-9]*\\.){3}[0-9]*' | grep -v '127.0.0.1'\");<br \/>\n  if (strpos(($whereplace . ' ' . $_SERVER['SERVER_ADDR']), '65.254.92.213') !== false) {<br \/>\n     $sv='\/usr\/bin\/ffmpeg';<br \/>\n     header('Location: https:\/\/65.254.95.247\/PHP\/tmp_ffmpeg.php'); \/\/$smallpath='https:\/\/65.254.95.247\/PHP\/'; \/\/header('Location: https:\/\/65.254.95.247\/PHP\/tmp_ffmpeg.php');<br \/>\n     exit; \/\/exit;<br \/>\n  }<br \/>\n<\/code><br \/>\n?&gt;<br \/>\n &#8230; we talked about at <a target=\"_blank\" href='https:\/\/www.rjmprogramming.com.au\/ITblog\/almalinux-landing-page-wordpress-content-update-solution-tutorial\/' title='AlmaLinux Landing Page WordPress Content Update Solution Tutorial' rel=\"noopener\">AlmaLinux Landing Page WordPress Content Update Solution Tutorial<\/a> &#8230; as well as &#8230;<\/li>\n<li>user definable form navigation &#8230; using &#8230;<\/li>\n<li>optional dropdown ideas incorporating ideas from <a target=\"_blank\" href='https:\/\/www.rjmprogramming.com.au\/ITblog\/sepia-video-via-ffmpeg-primer-tutorial\/' title='Sepia Video via ffmpeg Primer Tutorial' rel=\"noopener\">Sepia Video via ffmpeg Primer Tutorial<\/a> &#8230; and using &#8230;<\/li>\n<li>temporary storage places to place output video &#8230; and making use of &#8230;<\/li>\n<li>soft links regarding URLs we talked about at <a target=\"_blank\" href='https:\/\/www.rjmprogramming.com.au\/ITblog\/linux-web-server-soft-link-url-tutorial\/' title='Linux Web Server Soft Link URL Tutorial' rel=\"noopener\">Linux Web Server Soft Link URL Tutorial<\/a> (saving us having to use <i>&#8216;data:video\/mp4;base64,&#8217; . base64_encode(file_get_contents(trim($endout)))<\/i> style PHP interventions <font size=1>(which were testing friendships)<\/font>)<\/li>\n<\/ul>\n<p> &#8230; to start down this road towards <i>public facing<\/i> ffmpeg video editing around here <font size=1>(which we have been hankering for for several years now)<\/font>.<\/p>\n<p>In this <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php_GETME\" rel=\"noopener\">first draft<\/a> of <a target=\"_blank\" href=\"https:\/\/www.rjmprogramming.com.au\/PHP\/tmp_ffmpeg.php\" rel=\"noopener\">Your Own Ffmpeg Video Changes<\/a> (via command line ffmpeg) we&#8217;re really buttoning down <font size=1>(via not allowing the forward slash character in amongst the user defined ffmpeg command <i>innards<\/i>)<\/font> what happens regarding &#8230;<\/p>\n<ul>\n<li>output video file source location &#8230; and &#8230;<\/li>\n<li>input video file source &#8230;<br \/>\n<video style=width:98%; controls><source type=video\/mp4 src='http:\/\/www.rjmprogramming.com.au\/ffmpeg\/govetts_leap.mp4'><\/source><\/video>\n<\/li>\n<\/ul>\n<p> &#8230; but <a target=\"_blank\" title='?' href='https:\/\/www.youtube.com\/watch?v=sYOUFGfK4bU' rel=\"noopener\">who<\/a> knows what the future holds?!  <\/p>\n<p><!--p>You can also see this play out at WordPress 4.1.1's <a target=\"_blank\" href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-helps-iphone-video-to-youtube-tutorial\/' rel=\"noopener\">Ffmpeg Helps iPhone Video to YouTube Tutorial<\/a>.<\/p-->\n<hr>\n<p id='fhpvytt'>Previous relevant <a target=\"_blank\" title='Ffmpeg Helps iPhone Video to YouTube Tutorial' href='\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-helps-iphone-video-to-youtube-tutorial\/' rel=\"noopener\">Ffmpeg Helps iPhone Video to YouTube Tutorial<\/a> is shown below.<\/p>\n<div style=\"width: 230px\" class=\"wp-caption alignnone\"><a target=\"_blank\" href=\"https:\/\/www.youtube.com\/watch?v=KB_2V-WW5ss\" rel=\"noopener\"><img decoding=\"async\" style=\"border: 15px solid pink;\" alt=\"Ffmpeg Helps iPhone Video to YouTube Tutorial\" src=\"http:\/\/www.rjmprogramming.com.au\/ffmpeg\/ffmpeg_to_youtube.gif\" title=\"Ffmpeg Helps iPhone Video to YouTube Tutorial\"  style=\"float:left;\"  \/><\/a><p class=\"wp-caption-text\">Ffmpeg Helps iPhone Video to YouTube Tutorial<\/p><\/div>\n<p>Today we recorded a video looking out from Govetts Leap, Blackheath, here in the Blue Mountains.  We captured it via the Camera app on an iPhone via its Video option.<\/p>\n<p>Nineteen seconds long, to share to this MacBook Air we needed AirDrop, the size of it precluding us from using the Photo app&#8217;s Mail sharing option.<\/p>\n<p>And that&#8217;s where we wanted to use the great <a target=\"_blank\" title='ffmpeg' href='https:\/\/www.ffmpeg.org\/' rel=\"noopener\">ffmpeg<\/a> in an optimal way to create a video that we could upload to YouTube.  In this, we arrived at <a target=\"_blank\" title='Excellent link, thanks' href='https:\/\/www.reddit.com\/r\/ffmpeg\/comments\/r1qwyy\/best_streaming_settings_for_youtube\/' rel=\"noopener\">this excellent link<\/a> getting us to try &#8230;<\/p>\n<p><code><br \/>\nffmpeg -i govetts_leap.MOV -c:v libx264 -preset slow -crf 18 -vf scale=out_color_matrix=bt709 -color_primaries bt709 -color_trc bt709 -colorspace bt709 -c:a aac -ar 48000 -ac 2 -b:a 320k -profile:v high -level 4.0 -bf 2 -coder 1 -pix_fmt yuv420p -b:v 10M -threads 4 -cpu-used 0 -r 30 -g 15 -movflags +faststart govetts_leap.mp4<br \/>\n<\/code><\/p>\n<p> &#8230; with success.  Checking with <a target=\"_blank\" title='Another great link, thanks' href='https:\/\/www.maestro.io\/blog\/video-formats\/' rel=\"noopener\">this other excellent link<\/a>, thanks, we were comforted that they would have recommended an output mp4 file format as well, it seems &#8230;<\/p>\n<p><iframe loading=\"lazy\" width=\"560\" height=\"315\" src=\"https:\/\/www.youtube.com\/embed\/KB_2V-WW5ss?si=IoTDBSVk7R6uyDfX\" title=\"YouTube video player\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe> <\/p>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d64630' onclick='var dv=document.getElementById(\"d64630\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/youtube\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d64630' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d64633' onclick='var dv=document.getElementById(\"d64633\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/ffmpeg\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d64633' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d64646' onclick='var dv=document.getElementById(\"d64646\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/browse\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d64646' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d64651' onclick='var dv=document.getElementById(\"d64651\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/email\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d64651' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n<hr>\n<p>If this was interesting you may be interested in <a title='Click here to see topics in which you might be interested' href='#d64519' onclick='var dv=document.getElementById(\"d64519\"); dv.innerHTML = \"&lt;iframe width=670 height=600 src=\" + \"https:\/\/www.rjmprogramming.com.au\/ITblog\/tag\/absolute-URL\" + \"&gt;&lt;\/iframe&gt;\"; dv.style.display = \"block\";'>this<\/a> too.<\/p>\n<div id='d64519' style='display: none; border-left: 2px solid green; border-top: 2px solid green;'><\/div>\n","protected":false},"excerpt":{"rendered":"<p>In yesterday&#8217;s Ffmpeg User Defined Video Editing Sharing Tutorial about sharing video data (that might have been edited by ffmpeg command line means) we warned &#8230; even though it is only likely to work for shorter videos &#8230; regarding the &hellip; <a href=\"https:\/\/www.rjmprogramming.com.au\/ITblog\/ffmpeg-user-defined-video-editing-crontab-assisted-sharing-tutorial\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,14,29,37],"tags":[52,152,1993,234,274,360,380,415,452,1839,4884,557,3961,587,932,997,1893,2293,1133,4885,1137,3942,1159,4886,3883,1231,1319,1345,1369,3230],"class_list":["post-64519","post","type-post","status-publish","format-standard","hentry","category-elearning","category-event-driven-programming","category-operating-system","category-tutorials","tag-absolute-url","tag-blur","tag-browse","tag-command-line","tag-crontab","tag-download","tag-email","tag-ffmpeg","tag-form","tag-genericization","tag-guassian-blue","tag-hashtag","tag-hashtagging","tag-iframe","tag-php","tag-programming","tag-schedule","tag-sepia","tag-share","tag-share-api","tag-sharing","tag-shell_exec","tag-sms","tag-softlink","tag-switch","tag-switches","tag-tutorial","tag-url","tag-video","tag-video-editor"],"_links":{"self":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/64519"}],"collection":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/comments?post=64519"}],"version-history":[{"count":4,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/64519\/revisions"}],"predecessor-version":[{"id":64523,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/posts\/64519\/revisions\/64523"}],"wp:attachment":[{"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/media?parent=64519"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/categories?post=64519"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.rjmprogramming.com.au\/ITblog\/wp-json\/wp\/v2\/tags?post=64519"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}