]> git.mxchange.org Git - core.git/commitdiff
Improved some debug lines
authorRoland Häder <roland@mxchange.org>
Sat, 28 Aug 2021 08:36:15 +0000 (10:36 +0200)
committerRoland Häder <roland@mxchange.org>
Sat, 28 Aug 2021 08:36:15 +0000 (10:36 +0200)
Signed-off-by: Roland Häder <roland@mxchange.org>
contrib/audio.php

index 40508f1451aa5da319705d67006ab7277374f097..7118af6a4b4e5c27dec32582dc081f57b4abd4b4 100644 (file)
@@ -35,17 +35,17 @@ function analyzeForNoiseOnly ($data) {
 
        if (!$GLOBALS['options']['keep_noise'] && !$GLOBALS['options']['ignore_noise'] && count($GLOBALS['analysis']['breakdown']) == 2 && isset($GLOBALS['analysis']['breakdown'][127]) && isset($GLOBALS['analysis']['breakdown'][128])) {
                if ($GLOBALS['options']['analyze_input']) {
-                       //echo 'NOISE1!' . PHP_EOL;
+                       //* NOISY: */ echo 'NOISE1!' . PHP_EOL;
                }
                return NULL;
        } elseif (!$GLOBALS['options']['keep_noise'] && !$GLOBALS['options']['ignore_noise'] && count($GLOBALS['analysis']['breakdown']) == 1 && isset($GLOBALS['analysis']['breakdown'][127])) {
                if ($GLOBALS['options']['analyze_input']) {
-                       //echo 'NOISE2!' . PHP_EOL;
+                       //* NOISY: */ echo 'NOISE2!' . PHP_EOL;
                }
                return NULL;
        } elseif (!$GLOBALS['options']['keep_noise'] && $GLOBALS['options']['ignore_noise'] && count($GLOBALS['analysis']['breakdown']) < 2) {
                if ($GLOBALS['options']['analyze_input']) {
-                       //echo 'NOISE3!' . PHP_EOL;
+                       //* NOISY: */ echo 'NOISE3!' . PHP_EOL;
                }
                return NULL;
        }
@@ -64,7 +64,7 @@ while (TRUE) {
        $data = trim(fread($pcm, $GLOBALS['options']['buffer_size']));
        if ((empty($data)) || ($data == $empty)) {
                if ($GLOBALS['options']['analyze_input']) {
-                       //echo 'EMPTY!' . PHP_EOL;
+                       //* NOISY: */ echo 'EMPTY!' . PHP_EOL;
                }
                continue;
        }
@@ -76,7 +76,7 @@ while (TRUE) {
        if (empty($data)) {
                // Skip this
                continue;
-       } // END - if
+       }
 
        $GLOBALS['analysis']['average'] = floor($GLOBALS['analysis']['average'] / strlen($data));
 
@@ -103,7 +103,7 @@ while (TRUE) {
                if (empty($out)) {
                        // Skip this
                        continue;
-               } // END - if
+               }
 
                echo $out;
        } else {