1<!DOCTYPE html> 2<html lang="en" dir="ltr"> 3 <head><meta charset='utf-8'> 4<meta name='viewport' content='width=device-width, initial-scale=1'><meta name='description' content='Making a console app to automate online radio with AltaCast, VLC, and VB Virtual Audio Cable'> 5<title>Console App to Automate Stream with AltaCast, VLC, VB Virtual Cable - David Ballesteros</title> 6 7 8<link rel='canonical' href='https://reddavid.me/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/'> 9 10<link rel="stylesheet" href="/scss/style.min.727c909a7b62f2a469fa51d4fdcf8b35db0d4138b68188e56bab6684f1733df4.css"><meta property='og:title' content='Console App to Automate Stream with AltaCast, VLC, VB Virtual Cable'> 11<meta property='og:description' content='Making a console app to automate online radio with AltaCast, VLC, and VB Virtual Audio Cable'> 12<meta property='og:url' content='https://reddavid.me/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/'> 13<meta property='og:site_name' content='David Ballesteros'> 14<meta property='og:type' content='article'><meta property='article:section' content='Post' /><meta property='article:tag' content='C#' /><meta property='article:tag' content='CSharp' /><meta property='article:tag' content='Software Development' /><meta property='article:tag' content='. NET' /><meta property='article:tag' content='dotNet' /><meta property='article:tag' content='Console app' /><meta property='article:tag' content='AltaCast' /><meta property='article:tag' content='online radio' /><meta property='article:tag' content='VLC' /><meta property='article:tag' content='Programming' /><meta property='article:tag' content='VB Virtual Audio Cable' /><meta property='article:published_time' content='2023-02-20T17:03:47+08:00' /><meta property='article:modified_time' content='2023-02-20T17:03:47+08:00' /><meta property='og:image' content='https://reddavid.me/images/og/stream.png' /> 15<meta name="twitter:site" content="@reddvid"> 16<meta name="twitter:creator" content="@reddvid"><meta name="twitter:title" content="Console App to Automate Stream with AltaCast, VLC, VB Virtual Cable"> 17<meta name="twitter:description" content="Making a console app to automate online radio with AltaCast, VLC, and VB Virtual Audio Cable"><meta name="twitter:card" content="summary_large_image"> 18<meta name="twitter:image" content='https://reddavid.me/images/og/stream.png' /> 19
19<script async src="https://www.googletagmanager.com/gtag/js?id=315152754"></script>
19 20
20<script> 21 var doNotTrack = false; 22 if ( false ) { 23 var dnt = (navigator.doNotTrack || window.doNotTrack || navigator.msDoNotTrack); 24 var doNotTrack = (dnt == "1" || dnt == "yes"); 25 } 26 if (!doNotTrack) { 27 window.dataLayer = window.dataLayer || []; 28 function gtag(){dataLayer.push(arguments);} 29 gtag('js', new Date()); 30 gtag('config', '315152754'); 31 } 32 </script>
32<meta name="application-name" content="Red David Blog"> 33<meta name="apple-mobile-web-app-title" content="Red David Blog"> 34<meta name="theme-color" content="#212121"> 35<meta name="msapplication-TileColor" content="#FF0000"> 36<link rel="preload" href="/Mona-Sans.woff2" as="font" type="font/woff2" crossorigin> 37<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico" /> 38<link rel="icon" type="image/png" sizes="32x32" href="/favicon-32x32.png"> 39<link rel="icon" type="image/png" sizes="16x16" href="/favicon-16x16.png"> 40<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png"> 41<link rel="mask-icon" href="/safari-pinned-tab.svg" color="#FF0000"> 42<link rel="manifest" href="/site.webmanifest"> 43<link rel="canonical" href="https://reddavid.me/" /> 44<link rel="alternate" href="/index.xml" type="application/rss+xml" title="Red David | Tech, Gaming, and Coding Blog"> 45<link rel="feed" href="/index.xml" type="application/rss+xml" title="Red David | Tech, Gaming, and Coding Blog"> 46<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/normalize.min.css"> 47<link rel="stylesheet" href="/css/style.min.css"> 48<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/[email protected]/css/all.min.css"> 49<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/animate.min.css">
50<script type="application/ld+json"> 51 { 52 "@context": "http://schema.org", 53 "@type": "WebSite", 54 "url": "https:\/\/reddavid.me\/","inLanguage": "en","author": { 55 "@type": "Person", 56 "name": "Red David" 57 },"description": "Electronics Engineer, Gamer and Streamer. Blogging about technology, coding and software development, and music.","image": "https:\/\/reddavid.me\/images\/Apple-Devices-Preview.png","thumbnailUrl": "https:\/\/reddavid.me\/images\/screenshot.png","license": "This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.","name": "Red David | Tech, Gaming, and Coding Blog" 58 } 59</script>
vendor: 67 bytes, lines 59-61
59 60 61<script async src="https://www.googletagmanager.com/gtag/js?id=
61UA-129071597-1
vendor: 13 bytes, line 61
61"></script>
62<script> 63
vendor: 145 bytes, lines 63-66
63window.dataLayer = window.dataLayer || []; 64 function gtag() { dataLayer.push(arguments); } 65 gtag('js', new Date()); 66 gtag('config', '
66UA-129071597-1
vendor: 5 bytes, line 66
66');
67</script>
67 68
69<script type="text/javascript"> 70 (function (c, l, a, r, i, t, y) { 71 c[a] = c[a] || function () { (c[a].q = c[a].q || []).push(arguments) }; 72 t = l.createElement(r); t.async = 1; t.src = "https://www.clarity.ms/tag/" + i; 73 y = l.getElementsByTagName(r)[0]; y.parentNode.insertBefore(t, y); 74 })(window, document, "clarity", "script", "fw2ox762en"); 75</script>
75 76
77<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-2042503086093877" 78 crossorigin="anonymous"></script>
78 79 </head> 80 <body class=" 81article-page 82"> 83
83<script> 84 (function() { 85 const colorSchemeKey = 'StackColorScheme'; 86 if(!localStorage.getItem(colorSchemeKey)){ 87 localStorage.setItem(colorSchemeKey, "dark"); 88 } 89 })(); 90 </script>
90<script> 91 (function() { 92 const colorSchemeKey = 'StackColorScheme'; 93 const colorSchemeItem = localStorage.getItem(colorSchemeKey); 94 const supportDarkMode = window.matchMedia('(prefers-color-scheme: dark)').matches === true; 95 96 if (colorSchemeItem == 'dark' || colorSchemeItem === 'auto' && supportDarkMode) { 97 98 99 document.documentElement.dataset.scheme = 'dark'; 100 } else { 101 document.documentElement.dataset.scheme = 'light'; 102 } 103 })(); 104</script>
104 105<div class="container main-container flex on-phone--column extended"><aside class="sidebar left-sidebar sticky "> 106 <button class="hamburger hamburger--spin" type="button" id="toggle-menu" aria-label="Toggle Menu"> 107 <span class="hamburger-box"> 108 <span class="hamburger-inner"></span> 109 </span> 110 </button> 111 112 <header> 113 114 115 <figure class="site-avatar"> 116 <a href="/"> 117 118 <img src="/images/avatar.jpg" width="300" height="300" class="site-logo" loading="lazy" alt="Avatar"> 119 120 </a> 121 122 <span class="emoji">ð</span> 123 124 </figure> 125 126 127 128 <div class="site-meta"> 129 <h1 class="site-name"><a href="/">David Ballesteros</a></h1> 130 <h2 class="site-description">Personal blog about life, tech, gaming, coding, and music</h2> 131 </div> 132 </header><ol class="social-menu"> 133 134 <li> 135 <a 136 href='https://github.com/reddvid' 137 target="_blank" 138 title="GitHub" 139 > 140 141 142 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-github" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 143 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 144 <path d="M9 19c-4.3 1.4 -4.3 -2.5 -6 -3m12 5v-3.5c0 -1 .1 -1.4 -.5 -2c2.8 -.3 5.5 -1.4 5.5 -6a4.6 4.6 0 0 0 -1.3 -3.2a4.2 4.2 0 0 0 -.1 -3.2s-1.1 -.3 -3.5 1.3a12.3 12.3 0 0 0 -6.2 0c-2.4 -1.6 -3.5 -1.3 -3.5 -1.3a4.2 4.2 0 0 0 -.1 3.2a4.6 4.6 0 0 0 -1.3 3.2c0 4.6 2.7 5.7 5.5 6c-.6 .6 -.6 1.2 -.5 2v3.5" /> 145</svg> 146 147 148 </a> 149 </li> 150 151 <li> 152 <a 153 href='https://instagram.com/reddvid' 154 target="_blank" 155 title="Instagram" 156 > 157 158 159 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-instagram" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 160 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 161 <rect x="4" y="4" width="16" height="16" rx="4" /> 162 <circle cx="12" cy="12" r="3" /> 163 <line x1="16.5" y1="7.5" x2="16.5" y2="7.501" /> 164</svg> 165 166 167 168 169 </a> 170 </li> 171 172 <li> 173 <a 174 href='https://linkedin.com/in/reddvid' 175 target="_blank" 176 title="LinkedIn" 177 > 178 179 180 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-linkedin" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 181 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 182 <rect x="4" y="4" width="16" height="16" rx="2" /> 183 <line x1="8" y1="11" x2="8" y2="16" /> 184 <line x1="8" y1="8" x2="8" y2="8.01" /> 185 <line x1="12" y1="16" x2="12" y2="11" /> 186 <path d="M16 16v-3a2 2 0 0 0 -4 0" /> 187</svg> 188 189 190 191 192 </a> 193 </li> 194 195 <li> 196 <a 197 href='https://twitter.com/reddvid' 198 target="_blank" 199 title="Twitter" 200 > 201 202 203 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-twitter" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 204 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 205 <path d="M22 4.01c-1 .49 -1.98 .689 -3 .99c-1.121 -1.265 -2.783 -1.335 -4.38 -.737s-2.643 2.06 -2.62 3.737v1c-3.245 .083 -6.135 -1.395 -8 -4c0 0 -4.182 7.433 4 11c-1.872 1.247 -3.739 2.088 -6 2c3.308 1.803 6.913 2.423 10.034 1.517c3.58 -1.04 6.522 -3.723 7.651 -7.742a13.84 13.84 0 0 0 .497 -3.753c-.002 -.249 1.51 -2.772 1.818 -4.013z" /> 206</svg> 207 208 209 210 211 </a> 212 </li> 213 214 <li> 215 <a 216 href='https://youtube.com/@reddavid' 217 target="_blank" 218 title="YouTube" 219 > 220 221 222 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-youtube" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 223 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 224 <rect x="3" y="5" width="18" height="14" rx="4" /> 225 <path d="M10 9l5 3l-5 3z" /> 226</svg> 227 228 229 230 231 </a> 232 </li> 233 234 </ol><ol class="menu" id="main-menu"> 235 236 237 238 239 <li > 240 <a href='/' > 241 242 243 244 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-home" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 245 <path stroke="none" d="M0 0h24v24H0z"/> 246 <polyline points="5 12 3 12 12 3 21 12 19 12" /> 247 <path d="M5 12v7a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-7" /> 248 <path d="M9 21v-6a2 2 0 0 1 2 -2h2a2 2 0 0 1 2 2v6" /> 249</svg> 250 251 252 253
254 <span>Home</span> 255 </a> 256 </li> 257 258 259 260 <li > 261 <a href='/posts/' > 262 263 264 265 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-archive" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 266 <path stroke="none" d="M0 0h24v24H0z"/> 267 <rect x="3" y="4" width="18" height="4" rx="2" /> 268 <path d="M5 8v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-10" /> 269 <line x1="10" y1="12" x2="14" y2="12" /> 270</svg> 271 272 273 274 275 <span>Posts</span> 276 </a> 277 </li> 278 279 280 281 <li > 282 <a href='/links/' > 283 284 285 286 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-link" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 287 <path stroke="none" d="M0 0h24v24H0z"/> 288 <path d="M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5" /> 289 <path d="M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5" /> 290</svg> 291 292 293 294 295 <span>Links</span> 296 </a> 297 </li> 298 299 300 301 <li > 302 <a href='/portfolio/' > 303 304 305 306 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-pencil" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 307 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 308 <path d="M4 20h4l10.5 -10.5a1.5 1.5 0 0 0 -4 -4l-10.5 10.5v4" /> 309 <line x1="13.5" y1="6.5" x2="17.5" y2="10.5" /> 310</svg> 311 312 313 314 315 <span>Portfolio</span> 316 </a> 317 </li> 318 319 320 321 <li > 322 <a href='/about/' > 323 324 325 326 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-user" 327width="24" 328height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 329 <path stroke="none" d="M0 0h24v24H0z"/> 330 <circle cx="12" cy="7" r="4" /> 331 <path d="M6 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2" /> 332</svg> 333 334 335 336 337 <span>About</span> 338 </a> 339 </li> 340 341 342 343 <li > 344 <a href='/gaming/' > 345 346 347 348 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-mouse" 349 width="24" height="24" viewBox="0 0 24 24" 350 stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 351 <path stroke="none" d="M0 0h24v24H0z" /> 352 <rect x="6" y="3" width="12" height="18" rx="4" /> 353 <line x1="12" y1="7" x2="12" y2="11" /> 354</svg> 355 356 357 358 359 <span>Gaming</span> 360 </a> 361 </li> 362 363 364 <div class="menu-bottom-section"> 365 <li id="i18n-switch"> 366 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-language" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 367 <path stroke="none" d="M0 0h24v24H0z" fill="none"/> 368 <path d="M4 5h7" /> 369 <path d="M9 3v2c0 4.418 -2.239 8 -5 8" /> 370 <path d="M5 9c-.003 2.144 2.952 3.908 6.7 4" /> 371 <path d="M12 20l4 -9l4 9" /> 372 <path d="M19.1 18h-6.2" /> 373</svg> 374 375 376 377 <select name="language" onchange="window.location.href = this.selectedOptions[0].value"> 378 379 <option value="https://reddavid.me/" selected>English</option> 380 381 </select> 382 </li> 383 384 385 386 <li id="dark-mode-toggle"> 387 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-toggle-left" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 388 <path stroke="none" d="M0 0h24v24H0z"/> 389 <circle cx="8" cy="12" r="2" /> 390 <rect x="2" y="6" width="20" height="12" rx="6" /> 391</svg> 392 393 394 395 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-toggle-right" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 396 <path stroke="none" d="M0 0h24v24H0z"/> 397 <circle cx="16" cy="12" r="2" /> 398 <rect x="2" y="6" width="20" height="12" rx="6" /> 399</svg> 400 401 402
403 <span>Dark Mode</span> 404 </li> 405 406 </div> 407 </ol> 408</aside> 409<main class="main full-width"> 410<article class="main-article"> 411 412 413 414 <header class="article-header"> 415 <div class="article-image"> 416 <a href="/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/"> 417 418 <img src="/images/og/stream.png" loading="lazy" alt="Featured image of post Console App to Automate Stream with AltaCast, VLC, VB Virtual Cable" /> 419 420 </a> 421 </div> 422 423 424 <div class="article-details"> 425 426 <header class="article-category"> 427 428 <a href="/categories/coding/" style="background-color: #2a9d8f; color: #fff;" > 429 Coding 430 </a> 431 432 </header> 433 434 435 <div class="article-title-wrapper"> 436 <h1 class="article-title"> 437 <a href="/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/">Console App to Automate Stream with AltaCast, VLC, VB Virtual Cable</a> 438 </h1> 439 440 441 <h3 class="article-subtitle"> 442 Making a console app to automate online radio with AltaCast, VLC, and VB Virtual Audio Cable 443 </h3> 444 445 </div> 446 447 448 <footer class="article-time"> 449 450 <div> 451 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-calendar-time" width="56" height="56" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 452 <path stroke="none" d="M0 0h24v24H0z"/> 453 <path d="M11.795 21h-6.795a2 2 0 0 1 -2 -2v-12a2 2 0 0 1 2 -2h12a2 2 0 0 1 2 2v4" /> 454 <circle cx="18" cy="18" r="4" /> 455 <path d="M15 3v4" /> 456 <path d="M7 3v4" /> 457 <path d="M3 11h16" /> 458 <path d="M18 16.496v1.504l1 1" /> 459</svg> 460 <time class="article-time--published">Feb 20, 2023 17:03</time> 461 </div> 462 463 464 465 <div> 466 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-clock" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 467 <path stroke="none" d="M0 0h24v24H0z"/> 468 <circle cx="12" cy="12" r="9" /> 469 <polyline points="12 7 12 12 15 15" /> 470</svg> 471 472 473 474 <time class="article-time--reading"> 475 5 minute read 476 </time> 477 </div> 478 479 </footer> 480 481 482 483</div> 484</header> 485 <br> 486 <hr style="width: 90%; opacity: .55; background-color:rgba(255, 255, 255, 0.5);"> 487 <br> 488 489 490 <section class="article-content"> 491 492 493 <p><a class="link" href="#programming-a-console-app" >02/22 Updated Code to Fix Timer</a></p> 494<p>What happens when radio stationâs go offline - or after their broadcast hours end? Dead air. Well, I am not sure if it is also the term being used in 24/7 audio servers.</p> 495<p>This âdead airâ not only affects the usability of streaming apps but also prevents users who differ in time zones. These users will be deprived of any content thus affecting possible audiences for the station.</p> 496<p>I recently brought up to the team by letting our stations utilize the audio servers 24/7 by adding program replays during off-air hours. The servers, which use CentovaOS, allow uploading audio files to be played during âoff-streamâ called AutoDJ. The stations can also let their PCs run 24/7 but the cost, manpower, and effort to implement such system seem to be a struggle as operations differ from each station.</p> 497<p>Since I have been letting my work PC âonâ all of the time, I proceeded to make it as a client to stream filler programs at times all stations are off-the-air.</p> 498<h2 id="multi-port-stream-with-altacast">Multi-port Stream with AltaCast 499</h2><p>Weâve been using <a class="link" href="https://sourceforge.net/projects/butt/" target="_blank" rel="noopener" 500 >butt (broadcast using this tool)</a> and/or <a class="link" href="https://directory.shoutcast.com/Winamp" target="_blank" rel="noopener" 501 >WinAmp Shoutcast DSP</a> to upload a single stream to the servers (each station) - and running 12 instances of it is highly unrecommended.</p> 502<p>My internet search led me to a program called <a class="link" href="http://www.altacast.com/" target="_blank" rel="noopener" 503 >AltaCast</a> - which supports multiple streams. The standalone app initially supports OGG encoded streams but downloading <a class="link" href="https://lame.sourceforge.io/" target="_blank" rel="noopener" 504 >MP3Lame</a> encoders now supports MP3 (duh).</p> 505<p>I started off streaming one port, and it works well. Then 3, then all 12. But the app crashes. Further troubleshooting let me conclude that it might be limited to 6 simultaneous streams.</p> 506<p>Now with that limitation, this thing would be impossible. Then I tried to âcopyâ the standalone app on another location and reconfigured the remaining 6 streams, and it worked!</p> 507<p>The only problem is that there is no way to rename the configurations as to which is which.</p> 508<p><img src="/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/img/altacast.png" width="427" height="513" srcset="/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/img/altacast_hu_eead32b77be072d1.png 480w, /p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/img/altacast_hu_48b7cfc12a2ab550.png 1024w" loading="lazy" alt="AltaCast" class="gallery-image" data-flex-grow="83"
509 data-flex-basis="199px" ></p> 510<h2 id="virtual-cable">Virtual Cable 511</h2><p>There should be nothing wrong to use the desktop audio to stream, but to avoid any unwanted noise/audio, I installed <a class="link" href="https://vb-audio.com/Cable/" target="_blank" rel="noopener" 512 >VB Virtual Audio Cable</a> which installed a virtual audio I/O on Windows to re-route certain appsâ audio.</p> 513<p>I used the VB Cable Output as the input for two instances of AltaCast.</p> 514<h2 id="media-playback">Media Playback 515</h2><p>I will be using <a class="link" href="https://www.videolan.org/vlc/" target="_blank" rel="noopener" 516 >VLC</a> as the media player since it supports network streams. Right now, I will be âhooking-upâ to <a class="link" href="https://www.dwiz882am.com/" target="_blank" rel="noopener" 517 >DWIZ 882</a> (one of our affiliate station) programs upto 12 midnight. Then use <a class="link" href="https://cnnphilippines.com/" target="_blank" rel="noopener" 518 >CNN Philippines</a> programs 12-3am.</p> 519<h2 id="programming-a-console-app">Programming a Console App 520</h2><p>This app will be a timer to check set times:</p> 521<ul> 522<li>10PM - Start Client Stream</li> 523<li>12MN - Change Media Source</li> 524<li>3AM - Stop/Quit Stream</li> 525</ul> 526<p><strong>UPDATE</strong></p> 527<ul> 528<li>Fixed various bugs (time check)</li> 529<li>Changed every second tick to every minute</li> 530<li>Adjusted Trim Extension to remove seconds</li> 531</ul> 532<p>Below is the full code:</p> 533<div class="highlight"><div class="chroma"> 534<table class="lntable"><tr><td class="lntd"> 535<pre tabindex="0" class="chroma"><code><span class="lnt"> 1 536</span><span class="lnt"> 2 537</span><span class="lnt"> 3 538</span><span class="lnt"> 4 539</span><span class="lnt"> 5 540</span><span class="lnt"> 6 541</span><span class="lnt"> 7 542</span><span class="lnt"> 8 543</span><span class="lnt"> 9 544</span><span class="lnt">10 545</span><span class="lnt">11 546</span><span class="lnt">12 547</span><span class="lnt">13 548</span><span class="lnt">14 549</span><span class="lnt">15 550</span><span class="lnt">16 551</span><span class="lnt">17 552</span><span class="lnt">18 553</span><span class="lnt">19 554</span><span class="lnt">20 555</span><span class="lnt">21 556</span><span class="lnt">22 557</span><span class="lnt">23 558</span><span class="lnt">24 559</span><span class="lnt">25 560</span><span class="lnt">26 561</span><span class="lnt">27 562</span><span class="lnt">28 563</span><span class="lnt">29 564</span><span class="lnt">30 565</span><span class="lnt">31 566</span><span class="lnt">32 567</span><span class="lnt">33 568</span><span class="lnt">34 569</span><span class="lnt">35 570</span><span class="lnt">36 571</span><span class="lnt">37 572</span><span class="lnt">38 573</span><span class="lnt">39 574</span><span class="lnt">40 575</span><span class="lnt">41 576</span><span class="lnt">42 577</span><span class="lnt">43 578</span><span class="lnt">44 579</span><span class="lnt">45 580</span><span class="lnt">46 581</span><span class="lnt">47 582</span><span class="lnt">48 583</span><span class="lnt">49 584</span><span class="lnt">50 585</span><span class="lnt">51 586</span><span class="lnt">52 587</span><span class="lnt">53 588</span><span class="lnt">54 589</span><span class="lnt">55 590</span><span class="lnt">56 591</span><span class="lnt">57 592</span><span class="lnt">58 593</span><span class="lnt">59 594</span><span class="lnt">60 595</span><span class="lnt">61 596</span><span class="lnt">62 597</span><span class="lnt">63 598</span><span class="lnt">64 599</span><span class="lnt">65 600</span><span class="lnt">66 601</span><span class="lnt">67 602</span><span class="lnt">68 603</span><span class="lnt">69 604</span><span class="lnt">70 605</span><span class="lnt">71 606</span><span class="lnt">72 607</span><span class="lnt">73 608</span><span class="lnt">74 609</span><span class="lnt">75 610</span><span class="lnt">76 611</span><span class="lnt">77 612</span><span class="lnt">78 613</span><span class="lnt">79 614</span><span class="lnt">80 615</span><span class="lnt">81 616</span><span class="lnt">82 617</span><span class="lnt">83 618</span><span class="lnt">84 619</span><span class="lnt">85 620</span><span class="lnt">86 621</span><span class="lnt">87 622</span><span class="lnt">88 623</span><span class="lnt">89 624</span><span class="lnt">90 625</span><span class="lnt">91 626</span><span class="lnt">92 627</span><span class="lnt">93 628</span><span class="lnt">94 629</span><span class="lnt">95 630</span><span class="lnt">96 631</span></code></pre></td> 632<td class="lntd"> 633<pre tabindex="0" class="chroma"><code class="language-csharp" data-lang="csharp"><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">System</span><span class="p">;</span> 634</span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">System.Diagnostics</span><span class="p">;</span> 635</span></span><span class="line"><span class="cl"><span class="k">using</span> <span class="nn">System.Threading</span><span class="p">;</span> 636</span></span><span class="line"><span class="cl"> 637</span></span><span class="line"><span class="cl"><span class="kd">public</span> <span class="k">class</span> <span class="nc">Program</span> 638</span></span><span class="line"><span class="cl"><span class="p">{</span> 639</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="n">Timer</span><span class="p">?</span> <span class="n">_timer</span><span class="p">;</span> 640</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="kt">bool</span> <span class="n">isActive</span> <span class="p">=</span> <span class="kc">
640false</span><span class="p">;</span> 641</span></span><span class="line"><span class="cl"> 642</span></span><span class="line"><span class="cl"> <span class="kd">public</span> <span class="kd">static</span> <span class="k">void</span> <span class="n">Main</span><span class="p">()</span> 643</span></span><span class="line"><span class="cl"> <span class="p">{</span> 644</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">();</span> 645</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="s">"Welcome to Stream Control!"</span><span class="p">);</span> 646</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="s">"--------------------------"</span><span class="p">);</span> 647</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="s">"App Version: 0.1-beta"</span><span class="p">);</span> 648</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">();</span> 649</span></span><span class="line"><span class="cl"> 650</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="s">"Starting timer..."</span><span class="p">);</span> 651</span></span><span class="line"><span class="cl"> <span class="c1">// Changed timer tick to 60_000 ms | 60 secs</span> 652</span></span><span class="line"><span class="cl"> <span class="n">_timer</span> <span class="p">=</span> <span class="k">new</span> <span class="n">Timer</span><span class="p">(</span><span class="n">TimerCallback</span><span class="p">,</span> <span class="kc">null</span><span class="p">,</span> <span class="m">0</span><span class="p">,</span> <span class="m">60_000</span><span class="p">);</span> 653</span></span><span class="line"><span class="cl"> 654</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">ReadLine</span><span class="p">();</span> 655</span></span><span class="line"><span class="cl"> <span class="p">}</span> 656</span></span><span class="line"><span class="cl"> 657</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="k">void</span> <span class="n">TimerCallback</span><span class="p">(</span><span class="n">Object</span> <span class="n">o</span><span class="p">)</span> 658</span></span><span class="line"><span class="cl"> <span class="p">{</span> 659</span></span><span class="line"><span class="cl"> <span class="n">TimeSpan</span> <span class="n">start</span> <span class="p">=</span> <span class="n">TimeSpan</span><span class="p">.</span><span class="n">Parse</span><span class="p">(</span><span class="s">"22:10"</span><span class="p">);</span> 660</span></span><span class="line"><span class="cl"> <span class="n">TimeSpan</span> <span class="n">shift</span> <span class="p">=</span> <span class="n">TimeSpan</span><span class="p">.</span><span class="n">Parse</span><span class="p">(</span><span class="s">"23:59"</span><span class="p">);</span> 661</span></span><span class="line"><span class="cl"> <span class="n">TimeSpan</span> <span class="n">stop</span> <span class="p">=</span> <span class="n">TimeSpan</span><span class="p">.</span><span class="n">Parse</span><span class="p">(</span><span class="s">"02:55"</span><span class="p">);</span> 662</span></span><span class="line"><span class="cl"> <span class="n">TimeSpan</span> <span class="n">now</span> <span class="p">=</span> <span class="n">DateTime</span><span class="p">.</span><span class="n">Now</span><span class="p">.</span><span class="n">TimeOfDay</span><span class="p">;</span> 663</span></span><span class="line"><span class="cl">
663 <span class="n">now</span> <span class="p">=</span> <span class="n">now</span><span class="p">.</span><span class="n">StripSeconds</span><span class="p">();</span> 664</span></span><span class="line"><span class="cl"> 665</span></span><span class="line"><span class="cl"> <span class="n">Console</span><span class="p">.</span><span class="n">WriteLine</span><span class="p">(</span><span class="s">$"Now: {now} | Start: {start} | Shift: {shift} | Stop: {stop}"</span><span class="p">);</span> 666</span></span><span class="line"><span class="cl"> 667</span></span><span class="line"><span class="cl"> <span class="k">if</span> <span class="p">(</span><span class="n">now</span> <span class="p">==</span> <span class="n">start</span> <span class="p">&&</span> <span class="p">!</span><span class="n">isActive</span><span class="p">)</span> 668</span></span><span class="line"><span class="cl"> <span class="p">{</span> 669</span></span><span class="line"><span class="cl"> <span class="n">StartLocalStream</span><span class="p">();</span> 670</span></span><span class="line"><span class="cl"> <span class="n">isActive</span> <span class="p">=</span> <span class="kc">true</span><span class="p">;</span> 671</span></span><span class="line"><span class="cl"> <span class="p">}</span> 672</span></span><span class="line"><span class="cl"> <span class="k">else</span> <span class="k">if</span> <span class="p">(</span><span class="n">now</span> <span class="p">==</span> <span class="n">shift</span> <span class="p">&&</span> <span class="n">isActive</span><span class="p">)</span> 673</span></span><span class="line"><span class="cl"> <span class="p">{</span> 674</span></span><span class="line"><span class="cl"> <span class="c1">// Change Media Playback</span> 675</span></span><span class="line"><span class="cl"> <span class="n">ChangeMediaPlayback</span><span class="p">();</span> 676</span></span><span class="line"><span class="cl"> <span class="p">}</span> 677</span></span><span class="line"><span class="cl"> <span class="k">else</span> <span class="k">if</span> <span class="p">(</span><span class="n">now</span> <span class="p">==</span> <span class="n">stop</span> <span class="p">&&</span> <span class="n">isActive</span><span class="p">)</span> 678</span></span><span class="line"><span class="cl"> <span class="p">{</span> 679</span></span><span class="line"><span class="cl"> <span class="c1">// Stop apps</span> 680</span></span><span class="line"><span class="cl"> <span class="n">KillProcesses</span><span class="p">(</span><span class="s">"vlc"</span><span class="p">);</span> 681</span></span><span class="line"><span class="cl"> <span class="n">KillProcesses</span><span class="p">(</span><span class="s">"altacastStandalone"</span><span class="p">);</span> 682</span></span><span class="line"><span class="cl"> <span class="n">isActive</span> <span class="p">=</span> <span class="kc">false</span><span class="p">;</span> 683</span></span><span class="line"><span class="cl"> <span class="p">}</span> 684</span></span><span class="line"><span class="cl"> <span class="p">}</span> 685</span></span><span class="line"><span class="cl"> 686</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="k">void</span> <span class="n">ChangeMediaPlayback</span><span class="p">()</span> 687</span></span><span class="line"><span class="cl"> <span class="p">{</span> 688</span></span><span class="line"><span class="cl"> <span class="c1">// Get media playing for max 3 hours</span> 689</span></span><span class="line"><span class="cl"> <span class="c1">// Kill any initial VLC</span> 690</span></span><span class="line"><span class="cl"> <span class="kt">var</span> <span class="n">vlc</span> <span class="p">=</span> <span class="s">@"C:\Program Files\VideoLAN\VLC\vlc.exe"</span><span class="p">;</span> 691</span></span><span class="line"><span class="cl"> 692</span></span><span class="line"><span class="cl">
692 <span class="n">KillProcesses</span><span class="p">(</span><span class="s">"vlc"</span><span class="p">);</span> 693</span></span><span class="line"><span class="cl"> 694</span></span><span class="line"><span class="cl"> <span class="n">CreateAndRunProcess</span><span class="p">(</span><span class="n">directory</span><span class="p">:</span> <span class="s">@"C:\Program Files\VideoLan\VLC"</span><span class="p">,</span> <span class="n">fileName</span><span class="p">:</span> <span class="n">vlc</span><span class="p">,</span> <span class="n">args</span><span class="p">:</span> <span class="s">"https://streaming.cnnphilippines.com/live/myStream/playlist.m3u8"</span><span class="p">);</span> 695</span></span><span class="line"><span class="cl"> <span class="p">}</span> 696</span></span><span class="line"><span class="cl"> 697</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="k">void</span> <span class="n">StartLocalStream</span><span class="p">()</span> 698</span></span><span class="line"><span class="cl"> <span class="p">{</span> 699</span></span><span class="line"><span class="cl"> <span class="kt">var</span> <span class="n">vlc</span> <span class="p">=</span> <span class="s">@"C:\Program Files\VideoLAN\VLC\vlc.exe"</span><span class="p">;</span> 700</span></span><span class="line"><span class="cl"> <span class="kt">var</span> <span class="n">altaCast1</span> <span class="p">=</span> <span class="s">@"D:\altacast\altacastStandalone.exe"</span><span class="p">;</span> 701</span></span><span class="line"><span class="cl"> <span class="kt">var</span> <span class="n">altaCast2</span> <span class="p">=</span> <span class="s">@"D:\altacast2\altacastStandalone.exe"</span><span class="p">;</span> 702</span></span><span class="line"><span class="cl"> 703</span></span><span class="line"><span class="cl"> <span class="n">CreateAndRunProcess</span><span class="p">(</span><span class="n">directory</span><span class="p">:</span> <span class="s">@"C:\Program Files\VideoLan\VLC"</span><span class="p">,</span> <span class="n">fileName</span><span class="p">:</span> <span class="n">vlc</span><span class="p">,</span> <span class="n">args</span><span class="p">:</span> <span class="s">"http://149.56.147.197:9079/stream"</span><span class="p">);</span> 704</span></span><span class="line"><span class="cl"> <span class="n">CreateAndRunProcess</span><span class="p">(</span><span class="n">directory</span><span class="p">:</span> <span class="s">@"D:\altacast\"</span><span class="p">,</span> <span class="n">fileName</span><span class="p">:</span> <span class="n">altaCast1</span><span class="p">,</span> <span class="n">isShell</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> <span class="n">verb</span><span class="p">:</span> <span class="s">"runas"</span><span class="p">);</span> 705</span></span><span class="line"><span class="cl"> <span class="n">CreateAndRunProcess</span><span class="p">(</span><span class="n">directory</span><span class="p">:</span> <span class="s">@"D:\altacast2\"</span><span class="p">,</span> <span class="n">fileName</span><span class="p">:</span> <span class="n">altaCast2</span><span class="p">,</span> <span class="n">isShell</span><span class="p">:</span> <span class="kc">true</span><span class="p">,</span> <span class="n">verb</span><span class="p">:</span> <span class="s">"runas"</span><span class="p">);</span> 706</span></span><span class="line"><span class="cl"> <span class="p">}</span> 707</span></span><span class="line"><span class="cl"> 708</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="k">void</span> <span class="n">CreateAndRunProcess</span><span class="p">(</span><span class="kt">string</span> <span class="n">directory</span><span class="p">,</span> <span class="kt">string</span> <span class="n">fileName</span><span class="p">,</span> <span class="kt">string</span> <span class="n">args</span> <span class="p">=</span> <span class="kc">null</span><span class="p">,</span> <span class="kt">bool</span> <span class="n">isShell</span> <span class="p">=</span> <span class="kc">
708false</span><span class="p">,</span> <span class="kt">string</span> <span class="n">verb</span> <span class="p">=</span> <span class="kc">null</span><span class="p">)</span> 709</span></span><span class="line"><span class="cl"> <span class="p">{</span> 710</span></span><span class="line"><span class="cl"> <span class="n">ProcessStartInfo</span> <span class="n">procInfo</span> <span class="p">=</span> <span class="k">new</span> <span class="n">ProcessStartInfo</span> 711</span></span><span class="line"><span class="cl"> <span class="p">{</span> 712</span></span><span class="line"><span class="cl"> <span class="n">WorkingDirectory</span> <span class="p">=</span> <span class="n">directory</span><span class="p">,</span> 713</span></span><span class="line"><span class="cl"> <span class="n">FileName</span> <span class="p">=</span> <span class="n">fileName</span><span class="p">,</span> 714</span></span><span class="line"><span class="cl"> <span class="n">UseShellExecute</span> <span class="p">=</span> <span class="n">isShell</span><span class="p">,</span> 715</span></span><span class="line"><span class="cl"> <span class="n">Verb</span> <span class="p">=</span> <span class="n">verb</span><span class="p">,</span> 716</span></span><span class="line"><span class="cl"> <span class="n">Arguments</span> <span class="p">=</span> <span class="n">args</span> 717</span></span><span class="line"><span class="cl"> <span class="p">};</span> 718</span></span><span class="line"><span class="cl"> <span class="n">Process</span><span class="p">.</span><span class="n">Start</span><span class="p">(</span><span class="n">procInfo</span><span class="p">);</span> 719</span></span><span class="line"><span class="cl"> <span class="p">}</span> 720</span></span><span class="line"><span class="cl"> 721</span></span><span class="line"><span class="cl"> <span class="kd">private</span> <span class="kd">static</span> <span class="k">void</span> <span class="n">KillProcesses</span><span class="p">(</span><span class="kt">string</span> <span class="n">processName</span><span class="p">)</span> 722</span></span><span class="line"><span class="cl"> <span class="p">{</span> 723</span></span><span class="line"><span class="cl"> <span class="k">foreach</span> <span class="p">(</span><span class="kt">var</span> <span class="n">process</span> <span class="k">in</span> <span class="n">Process</span><span class="p">.</span><span class="n">GetProcessesByName</span><span class="p">(</span><span class="n">processName</span><span class="p">))</span> 724</span></span><span class="line"><span class="cl"> <span class="p">{</span> 725</span></span><span class="line"><span class="cl"> <span class="n">process</span><span class="p">.</span><span class="n">Kill</span><span class="p">();</span> 726</span></span><span class="line"><span class="cl"> <span class="p">}</span> 727</span></span><span class="line"><span class="cl"> <span class="p">}</span> 728</span></span><span class="line"><span class="cl"><span class="p">}</span> 729</span></span></code></pre></td></tr></table> 730</div> 731</div><p>Â </p> 732<div class="highlight"><div class="chroma"> 733<table class="lntable"><tr><td class="lntd"> 734<pre tabindex="0" class="chroma"><code><span class="lnt">1 735</span><span class="lnt">2 736</span><span class="lnt">3 737</span><span class="lnt">4 738</span><span class="lnt">5 739</span><span class="lnt">6 740</span><span class="lnt">7 741</span><span class="lnt">8 742</span></code></pre></td> 743<td class="lntd"> 744<pre tabindex="0" class="chroma"><code class="language-csharp" data-lang="csharp"><span class="line"><span class="cl"><span class="c1">// https://stackoverflow.com/a/35750677</span> 745</span></span><span class="line"><span class="cl"><span class="kd">public</span> <span class="kd">static</span> <span class="k">class</span> <span class="nc">TimeExtensions</span> 746</span></span><span class="line"><span class="cl"><span class="p">{</span> 747</span></span><span class="line"><span class="cl"> <span class="kd">public</span> <span class="kd">static</span> <span class="n">TimeSpan</span> <span class="n">StripMilliseconds</span><span class="p">(</span><span class="k">this</span> <span class="n">TimeSpan</span> <span class="n">time</span><span class="p">)</span> 748</span></span><span class="line"><span class="cl"> <span class="p">{</span> 749</span></span><span class="line"><span class="cl">
749 <span class="k">return</span> <span class="k">new</span> <span class="n">TimeSpan</span><span class="p">(</span><span class="n">time</span><span class="p">.</span><span class="n">Days</span><span class="p">,</span> <span class="n">time</span><span class="p">.</span><span class="n">Hours</span><span class="p">,</span> <span class="n">time</span><span class="p">.</span><span class="n">Minutes</span><span class="p">,</span> <span class="n">time</span><span class="p">.</span><span class="n">Seconds</span><span class="p">);</span> 750</span></span><span class="line"><span class="cl"> <span class="p">}</span> 751</span></span><span class="line"><span class="cl"><span class="p">}</span> 752</span></span></code></pre></td></tr></table> 753</div> 754</div><p><img src="/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/img/console-app-running.png" width="1115" height="628" srcset="/p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/img/console-app-running_hu_62dab6a344e3e8e4.png 480w, /p/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable/img/console-app-running_hu_e5af151a94f6f3f.png 1024w" loading="lazy" alt="Console App" class="gallery-image" data-flex-grow="177" 755 data-flex-basis="426px" ></p> 756<p>Iâve only tested it for a day and made some fixes to continue the app running.</p> 757<p>You can tune in at <a class="link" href="https://tunein.rpnradio.com/" target="_blank" rel="noopener" 758 >https://tunein.rpnradio.com/</a> and weâll debug any errors. ð</p> 759<h2 id="future-plans">Future Plans 760</h2><p>As of now, stationsâ broadcast hours differ (sign on and sign off) and I want the app to be dynamic. Some plans for the app:</p> 761<ul> 762<li>Detect actual âdead airâ time</li> 763<li>Detect actual âon airâ time</li> 764<li>Custom playlist in VLC (not relying on âhook upsâ)</li> 765</ul> 766<p>Thanks for reading the blog post.</p> 767 768</section> 769 770 771 772 773<style> 774 #share-buttons { 775 display: inline-block; 776 vertical-align: middle; 777 } 778 779 #share-buttons:after { 780 content: ""; 781 display: block; 782 clear: both; 783 } 784 785 #share-buttons>div { 786 position: relative; 787 text-align: left; 788 height: 36px; 789 width: 32px; 790 float: left; 791 text-align: center; 792 } 793 794 #share-buttons>div>svg { 795 height: 16px; 796 fill: #d5d5d5; 797 margin-top: 10px; 798 } 799 800 #share-buttons>div:hover { 801 cursor: pointer; 802 } 803 804 #share-buttons>div.facebook:hover>svg { 805 fill: #3B5998; 806 } 807 808 #share-buttons>div.twitter:hover>svg { 809 fill: #55ACEE; 810 } 811 812 #share-buttons>div.linkedin:hover>svg { 813 fill: #0077b5; 814 } 815 816 #share-buttons>div.pinterest:hover>svg { 817 fill: #CB2027; 818 } 819 820 #share-buttons>div.mail:hover>svg { 821 fill: #7D7D7D; 822 } 823 824 #share-buttons>div.facebook>svg { 825 height: 18px; 826 margin-top: 9px; 827 } 828 829 #share-buttons>div.twitter>svg { 830 height: 20px; 831 margin-top: 8px; 832 } 833 834 #share-buttons>div.linkedin>svg { 835 height: 19px; 836 margin-top: 7px; 837 } 838 839 #share-buttons>div.pinterest>svg { 840 height: 20px; 841 margin-top: 9px; 842 } 843 844 #share-buttons>div.mail>svg { 845 height: 14px; 846 margin-top: 11px; 847 } 848</style> 849 850 851<div style="text-align: right; margin-right: 30px;"> 852 <p style="color: silver; font-size: 1.3rem; margin-bottom: 0px; margin-right: 5px;">Share this:</p> 853 <div id="share-buttons"> 854 <div class="facebook" title="Share this on Facebook" 855 onclick="window.open('http://www.facebook.com/share.php?u=https:\/\/reddavid.me\/p\/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable\/');"><svg viewBox="0 0 1792 1792" 856 xmlns="http://www.w3.org/2000/svg"> 857 <path 858 d="M1343 12v264h-157q-86 0-116 36t-30 108v189h293l-39 296h-254v759h-306v-759h-255v-296h255v-218q0-186 104-288.5t277-102.5q147 0 228 12z" /> 859 </svg></div> 860 <div class="twitter" title="Share this on Twitter" 861 onclick="window.open('http://twitter.com/intent/tweet?text=Console App to Automate Stream with AltaCast, VLC, VB Virtual Cable&url=https:\/\/reddavid.me\/p\/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable\/');"><svg
862 viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> 863 <path 864 d="M1684 408q-67 98-162 167 1 14 1 42 0 130-38 259.5t-115.5 248.5-184.5 210.5-258 146-323 54.5q-271 0-496-145 35 4 78 4 225 0 401-138-105-2-188-64.5t-114-159.5q33 5 61 5 43 0 85-11-112-23-185.5-111.5t-73.5-205.5v-4q68 38 146 41-66-44-105-115t-39-154q0-88 44-163 121 149 294.5 238.5t371.5 99.5q-8-38-8-74 0-134 94.5-228.5t228.5-94.5q140 0 236 102 109-21 205-78-37 115-142 178 93-10 186-50z" /> 865 </svg></div> 866 <div class="linkedin" title="Share this on Linkedin" 867 onclick="window.open('https://www.linkedin.com/shareArticle?mini=true&url=https:\/\/reddavid.me\/p\/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable\/&title=&summary=&source=');"> 868 <svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> 869 <path 870 d="M477 625v991h-330v-991h330zm21-306q1 73-50.5 122t-135.5 49h-2q-82 0-132-49t-50-122q0-74 51.5-122.5t134.5-48.5 133 48.5 51 122.5zm1166 729v568h-329v-530q0-105-40.5-164.5t-126.5-59.5q-63 0-105.5 34.5t-63.5 85.5q-11 30-11 81v553h-329q2-399 2-647t-1-296l-1-48h329v144h-2q20-32 41-56t56.5-52 87-43.5 114.5-15.5q171 0 275 113.5t104 332.5z" /> 871 </svg> 872 </div> 873 874 <div class="mail" title="Share this through Email" onclick="window.open('mailto:?&body=https:\/\/reddavid.me\/p\/console-app-to-automate-stream-with-altacast-vlc-vb-virtual-cable\/');"><svg
875 viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> 876 <path 877 d="M1792 710v794q0 66-47 113t-113 47h-1472q-66 0-113-47t-47-113v-794q44 49 101 87 362 246 497 345 57 42 92.5 65.5t94.5 48 110 24.5h2q51 0 110-24.5t94.5-48 92.5-65.5q170-123 498-345 57-39 100-87zm0-294q0 79-49 151t-122 123q-376 261-468 325-10 7-42.5 30.5t-54 38-52 32.5-57.5 27-50 9h-2q-23 0-50-9t-57.5-27-52-32.5-54-38-42.5-30.5q-91-64-262-182.5t-205-142.5q-62-42-117-115.5t-55-136.5q0-78 41.5-130t118.5-52h1472q65 0 112.5 47t47.5 113z" /> 878 </svg></div> 879 </div> 880</div> 881 882 883 <footer class="article-footer"> 884 885<br> 886<hr> 887<section class="article-tags"> 888 889 <a href="/tags/c%23/">C#</a> 890 891 <a href="/tags/csharp/">CSharp</a> 892 893 <a href="/tags/software-development/">Software Development</a> 894 895 <a href="/tags/.-net/">. NET</a> 896 897 <a href="/tags/dotnet/">DotNet</a> 898 899 <a href="/tags/console-app/">Console App</a> 900 901 <a href="/tags/altacast/">AltaCast</a> 902 903 <a href="/tags/online-radio/">Online Radio</a> 904 905 <a href="/tags/vlc/">VLC</a> 906 907 <a href="/tags/programming/">Programming</a> 908 909 <a href="/tags/vb-virtual-audio-cable/">VB Virtual Audio Cable</a> 910 911</section> 912 913 914 </footer> 915 916 917 918 919 920</article> 921 922 923 924 925 926 927 928 929 930 931 932<aside class="related-contents--wrapper"> 933 <h2 class="section-title"></h2> 934 <div class="related-contents"> 935 <div class="flex article-list--tile"> 936 937 938<article class="has-image"> 939 <a href="/p/more-work-automation-by-building-a-wpf-app/"> 940 941 942 <div class="article-image"> 943 944 <img src="/images/og/work-automation.png" loading="lazy" data-key="" 945 data-hash="/images/og/work-automation.png" /> 946 947 </div> 948 949 950 <div class="article-details"> 951 <h2 class="article-title">More Work Automation by Building a WPF App</h2> 952 </div> 953 </a> 954</article> 955 956 957<article class="has-image"> 958 <a href="/p/automating-obs-recording-with-winforms-app/"> 959 960 961 <div class="article-image"> 962 963 <img src="/images/og/automate-obs.png" loading="lazy" data-key="" 964 data-hash="/images/og/automate-obs.png" /> 965 966 </div> 967 968 969 <div class="article-details"> 970 <h2 class="article-title">Automating OBS Recording With WinForms App</h2> 971 </div> 972 </a> 973</article> 974 975 976<article class="has-image"> 977 <a href="/p/scraping-facebook-pages-to-get-number-of-likes-and-followers/"> 978 979 980 <div class="article-image"> 981 982 <img src="/images/og/scraping.png" loading="lazy" data-key="" 983 data-hash="/images/og/scraping.png" /> 984 985 </div> 986 987 988 <div class="article-details"> 989 <h2 class="article-title">Scraping Facebook Pages to Get Number of Likes and Followers</h2> 990 </div> 991 </a> 992</article> 993 994 995<article class="has-image"> 996 <a href="/p/get-rpn-radio-for-ios/"> 997 998 999 <div class="article-image"> 1000 1001 <img src="/images/og/rpnradio-appstore.png" loading="lazy" data-key="" 1002 data-hash="/images/og/rpnradio-appstore.png" /> 1003 1004 </div> 1005 1006 1007 <div class="article-details"> 1008 <h2 class="article-title">Get RPN Radio for iOS</h2> 1009 </div> 1010 </a> 1011</article> 1012 1013 1014<article class="has-image"> 1015 <a href="/p/rpnradio-ui-overhaul/"> 1016 1017 1018 <div class="article-image"> 1019 1020 <img src="/images/feat/rpnradio-ui.jpeg" loading="lazy" data-key="rpnradio-ui-overhaul" 1021 data-hash="/images/feat/rpnradio-ui.jpeg" /> 1022 1023 </div> 1024 1025 1026 <div class="article-details"> 1027 <h2 class="article-title">RPN Radio UI Overhaul</h2> 1028 </div> 1029 </a> 1030</article> 1031 1032 </div> 1033 </div> 1034</aside> 1035 1036 1037 1038 1039
1039<script 1040 src="https://giscus.app/client.js" 1041 data-repo="reddvid/reddvid.github.io" 1042 data-repo-id="MDEwOlJlcG9zaXRvcnkxNzc0NDEzMDE=" 1043 data-category="General" 1044 data-category-id="DIC_kwDOCpOKFc4CT3lg" 1045 data-mapping="pathname" 1046 data-reactions-enabled="1" 1047 data-emit-metadata="0" 1048 data-theme="light" 1049 data-lang="en" 1050 crossorigin="anonymous" 1051 async 1052></script>
vendor: 2 bytes, line 1052
1052
1053<script> 1054 function setGiscusTheme(theme) { 1055 let giscus = document.querySelector("iframe.giscus-frame"); 1056 if (giscus) { 1057 giscus.contentWindow.postMessage( 1058 { 1059 giscus: { 1060 setConfig: { 1061 theme: theme, 1062 }, 1063 }, 1064 }, 1065 "https://giscus.app" 1066 ); 1067 } 1068 } 1069 1070 (function () { 1071 addEventListener("message", (e) => { 1072 if (event.origin !== "https://giscus.app") return; 1073 handler(); 1074 }); 1075 window.addEventListener("onColorSchemeChange", handler); 1076 1077 function handler() { 1078 if (document.documentElement.dataset.scheme === "light") { 1079 setGiscusTheme('light'); 1080 } else { 1081 setGiscusTheme('dark'); 1082 } 1083 } 1084 })(); 1085</script>
1085 1086 1087 1088 1089<footer class="site-footer"> 1090 <section class="copyright"> 1091 © 1092 1093 2018 - 1094 1095 2025 David Ballesteros 1096 </section> 1097 <section class="powerby"> 1098 1099 Some Rights Reserved. <br /> 1100 Built with <a class="link" href="https://gohugo.io/" target="_blank" rel="noopener">Hugo</a> <br> <a 1101 class="link" href="https://reddavid.me/privacy" target="_blank" rel="noopener">Privacy Policy</a> <br /> 1102 Theme <b><a class="link" href="https://github.com/CaiJimmy/hugo-theme-stack" target="_blank" 1103 rel="noopener" data-version="3.10.0">Stack</a></b> designed by <a class="link" href="https://jimmycai.com" target="_blank" rel="noopener">Jimmy</a> 1104 </section> 1105</footer> 1106 1107 1108<div class="pswp" tabindex="-1" role="dialog" aria-hidden="true"> 1109 1110 1111 <div class="pswp__bg"></div> 1112 1113 1114 <div class="pswp__scroll-wrap"> 1115 1116 1117 <div class="pswp__container"> 1118 <div class="pswp__item"></div> 1119 <div class="pswp__item"></div> 1120 <div class="pswp__item"></div> 1121 </div> 1122 1123 1124 <div class="pswp__ui pswp__ui--hidden"> 1125 1126 <div class="pswp__top-bar"> 1127 1128 1129 1130 <div class="pswp__counter"></div> 1131 1132 <button class="pswp__button pswp__button--close" title="Close (Esc)"></button> 1133 1134 <button class="pswp__button pswp__button--share" title="Share"></button> 1135 1136 <button class="pswp__button pswp__button--fs" title="Toggle fullscreen"></button> 1137 1138 <button class="pswp__button pswp__button--zoom" title="Zoom in/out"></button> 1139 1140 1141 1142 <div class="pswp__preloader"> 1143 <div class="pswp__preloader__icn"> 1144 <div class="pswp__preloader__cut"> 1145 <div class="pswp__preloader__donut"></div> 1146 </div> 1147 </div> 1148 </div> 1149 </div> 1150 1151 <div class="pswp__share-modal pswp__share-modal--hidden pswp__single-tap"> 1152 <div class="pswp__share-tooltip"></div> 1153 </div> 1154 1155 <button class="pswp__button pswp__button--arrow--left" title="Previous (arrow left)"> 1156 </button> 1157 1158 <button class="pswp__button pswp__button--arrow--right" title="Next (arrow right)"> 1159 </button> 1160 1161 <div class="pswp__caption"> 1162 <div class="pswp__caption__center" style="text-align: center;"></div> 1163 </div> 1164 1165 </div> 1166 1167 </div> 1168 1169</div>
1169<script 1170 src="https://cdn.jsdelivr.net/npm/[email protected]/dist/photoswipe.min.js"integrity="sha256-ePwmChbbvXbsO02lbM3HoHbSHTHFAeChekF1xKJdleo="crossorigin="anonymous" 1171 defer 1172 > 1173 </script>
1173<script 1174 src="https://cdn.jsdelivr.net/npm/[email protected]/dist/photoswipe-ui-default.min.js"integrity="sha256-UKkzOn/w1mBxRmLLGrSeyB4e1xbrp4xylgAWb3M42pU="crossorigin="anonymous" 1175 defer 1176 > 1177 </script>
1177<link 1178 rel="stylesheet" 1179 href="https://cdn.jsdelivr.net/npm/[email protected]/dist/default-skin/default-skin.min.css"crossorigin="anonymous" 1180 ><link 1181 rel="stylesheet" 1182 href="https://cdn.jsdelivr.net/npm/[email protected]/dist/photoswipe.min.css"crossorigin="anonymous" 1183 > 1184 1185 </main> 1186<aside class="sidebar right-sidebar sticky"> 1187 1188 1189 1190 <section class="widget archives"> 1191 <div class="widget-icon"> 1192 <svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-hash" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"> 1193 <path stroke="none" d="M0 0h24v24H0z"/> 1194 <line x1="5" y1="9" x2="19" y2="9" /> 1195 <line x1="5" y1="15" x2="19" y2="15" /> 1196 <line x1="11" y1="4" x2="7" y2="20" /> 1197 <line x1="17" y1="4" x2="13" y2="20" /> 1198</svg> 1199 1200 1201 1202 </div> 1203 <h2 class="widget-title section-title">Table of contents</h2> 1204 1205 <div class="widget--toc"> 1206 <nav id="TableOfContents"> 1207 <ul> 1208 <li><a href="#multi-port-stream-with-altacast">Multi-port Stream with AltaCast</a></li> 1209 <li><a href="#virtual-cable">Virtual Cable</a></li> 1210 <li><a href="#media-playback">Media Playback</a></li> 1211 <li><a href="#programming-a-console-app">Programming a Console App</a></li> 1212 <li><a href="#future-plans">Future Plans</a></li> 1213 </ul> 1214</nav> 1215 </div> 1216 </section> 1217 1218 1219 1220 </aside> 1221 1222 1223 </div> 1224
1224<script 1225 src="https://cdn.jsdelivr.net/npm/[email protected]/dist/vibrant.min.js"integrity="sha256-awcR2jno4kI5X0zL8ex0vi2z+KMkF24hUW8WePSA9HM="crossorigin="anonymous" 1226 1227 > 1228 </script>
1228<script type="text/javascript" src="/ts/main.js" defer></script>
vendor: 2 bytes, line 1228
1228
1229<script> 1230 (function () { 1231 const customFont = document.createElement('link'); 1232 customFont.href = "https://fonts.googleapis.com/css2?family=Lato:wght@300;400;700&display=swap"; 1233 1234 customFont.type = "text/css"; 1235 customFont.rel = "stylesheet"; 1236 1237 document.head.appendChild(customFont); 1238 }()); 1239</script>
1239 1240 1241
1241<script src='https://storage.ko-fi.com/cdn/scripts/overlay-widget.js'></script>
1241 1242
1242<script> 1243 kofiWidgetOverlay.draw('reddavid', { 1244 'type': 'floating-chat', 1245 'floating-chat.donateButton.text': 'Support me', 1246 'floating-chat.donateButton.background-color': '#d9534f', 1247 'floating-chat.donateButton.text-color': '#fff' 1248 }); 1249 </script>
1249 1250 </body> 1251</html>
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.