|
1 | 1 | <template>
|
2 | 2 | <div class="settings-vmix-view">
|
3 |
| - <p><a href="https://vmix.com" target="_blank">vMix</a> is a popular software video mixer and switcher. You can send text directly to vMix and display it in a title input. You can then use vMix's font and color controls to style captioned text. <a href="/help/integrations/vmix/">Visit the Help Center</a> for more information.</p> |
4 |
| - <!-- |
5 |
| - <button id="sendToVmixSettingToggle" type="button" class="btn btn-secondary btn-block" disabled autocomplete="off"> |
6 |
| - <i class="fa fa-times mr-2" aira-hidden="true"></i>Send to vMix is <span id="send-to-vmix-status-text">off</span> |
7 |
| - </button> |
8 |
| - --> |
9 |
| - <hr/> |
10 |
| - <div class="vmixStep" data-vmix-step="1" data-error-state="false"> |
11 |
| - <h3> |
12 |
| - <span class="badge badge-danger pt-2 mr-2" data-toggle="tooltip" data-placement="top" title="Not complete"><i class="fa fa-exclamation-triangle"></i></span> |
13 |
| - <span class="badge badge-success pt-2 mr-2" hidden><i class="fa fa-check"></i> Done</span> |
14 |
| - <a href="#vmixStep1" data-toggle="collapse" aria-expanded="false" aria-controls="vmixStep1">Step 1: Install the Chrome Extension</a> |
15 |
| - </h3> |
16 |
| - <div id="vmixStep1" class="collapse show ml-4"> |
17 |
| - <p class="mb-2"> |
18 |
| - The Web Captioner Connector extension enables your browser to send commands to vMix running on your computer or somewhere else on the network. |
19 |
| - </p> |
20 |
| - <button id="addExtensionToChromeButton" type="button" class="btn btn-info"><i class="fa fa-chrome mr-2"></i>Add to Chrome</button> |
21 |
| - <button id="extensionIsAddedToChromeButton" type="button" class="btn btn-success" hidden disabled><i class="fa fa-check mr-2"></i>Added to Chrome</button> |
22 |
| - </div> |
23 |
| - </div> |
24 |
| - <hr/> |
25 |
| - <div class="vmixStep" data-vmix-step="2" data-error-state="false"> |
26 |
| - <h3> |
27 |
| - <span class="badge badge-danger pt-2 mr-2" data-toggle="tooltip" data-placement="top" title="Not complete"><i class="fa fa-exclamation-triangle"></i></span> |
28 |
| - <span class="badge badge-success pt-2 mr-2" hidden><i class="fa fa-check"></i> Done</span> |
29 |
| - <a href="#vmixStep2" data-toggle="collapse" aria-expanded="false" aria-controls="vmixStep2">Step 2: Enable vMix web controller</a> |
30 |
| - </h3> |
31 |
| - <div id="vmixStep2" class="collapse show"> |
32 |
| - <ol class="ml-0 mb-2"> |
33 |
| - <li>In vMix, go to <strong>Settings > Web Controller</strong>.</li> |
34 |
| - <li>Check the box to enable the <a href="http://www.vmix.com/knowledgebase/article.aspx/69/how-to-control-vmix-from-a-web-browser-using-vmix-web-controller" target="_blank">web controller</a>. Specify a port number or accept the default.</li> |
35 |
| - <li>Copy and paste the website address that appears in vMix here:</li> |
36 |
| - </ol> |
37 |
| - <div class="form-group ml-4 mb-2"> |
38 |
| - <input type="url" id="vmixWebControllerAddress" class="form-control" placeholder="vMix Web Controller Address" required="true" /> |
39 |
| - <p class="mb-2"><small class="form-text text-muted">Example: http://192.168.1.1:8080</small></p> |
40 |
| - </div> |
41 |
| - <p class="ml-4"> |
42 |
| - <button class="btn btn-info" id="testConnectionButton"><i class="fa fa-check mr-2" hidden aria-hidden="true"></i>Test Connection</button> |
43 |
| - <i id="testConnectionSpinner" hidden class="fa fa-circle-o-notch fa-spin fa-fw"></i> |
44 |
| - <strong id="connectionSuccessMessage" hidden class="text-success ml-2">Success!</strong> |
45 |
| - <p id="couldNotConnectMessage" hidden class="text-danger ml-4"><strong>Could not connect. Check to make sure that vMix is running, web controller in vMix is enabled, and that the web controller address above is correct.</strong></p> |
46 |
| - </p> |
47 |
| - </div> |
48 |
| - </div> |
49 |
| - <hr/> |
50 |
| - <div class="vmixStep" data-vmix-step="3" data-error-state="false"> |
51 |
| - <h3> |
52 |
| - <span class="badge badge-danger pt-2 mr-2" data-toggle="tooltip" data-placement="top" title="Not complete"><i class="fa fa-exclamation-triangle"></i></span> |
53 |
| - <span class="badge badge-success pt-2 mr-2" hidden><i class="fa fa-check"></i> Done</span> |
54 |
| - <a href="#vmixStep3" data-toggle="collapse" aria-expanded="false" aria-controls="vmixStep3">Step 3: Import the Web Captioner title template into vMix</a> |
55 |
| - </h3> |
56 |
| - <div id="vmixStep3" class="collapse show"> |
57 |
| - <ol class="ml-0 mb-2"> |
58 |
| - <li>Download the Web Captioner vMix title template:<br/> <a href="/web-captioner-title.xaml" class="btn btn-secondary mt-1 mb-2">Web Captioner vMix Title Template <i class="fa fa-external-link ml-1" aria-hidden="true"></i></a></li> |
59 |
| - <li>In vMix, go to <strong>Add Input > Title/XAML</strong>. In the upper right of the Input Select window, click <strong>Browse...</strong> and open the Web Captioner title template.</li> |
60 |
| - <li>The title will appear in the <strong>Recent</strong> tab. Double-click it.</li> |
61 |
| - <li>In the Title Editor that appears, optionally customize font and text size. Close it when you are finished.</li> |
62 |
| - <li>Test your imported title:</li> |
63 |
| - </ol> |
64 |
| - <div class="ml-4"> |
65 |
| - <button class="btn btn-info" id="testVmixTitleButton"><i class="fa fa-check mr-2" hidden aria-hidden="true"></i>Send Test Message to vMix</button> |
66 |
| - <i id="testVmixTitleSpinner" hidden class="fa fa-circle-o-notch fa-spin fa-fw"></i> |
67 |
| - <p id="testVmixTitleSuccessMessage" style="font-weight:bold" hidden class="text-success ml-4">Success!</p> |
68 |
| - <p id="testVmixTitleErrorMessage" style="font-weight:bold" hidden class="text-danger ml-4">Error</p> |
69 |
| - </div> |
70 |
| - </div> |
71 |
| - </div> |
| 3 | + <p><a href="https://vmix.com" target="_blank">vMix</a> is a popular software video mixer and switcher. You can send text directly to vMix and display it in a title input. You can then use vMix's font and color controls to style captioned text. <a href="/help/integrations/vmix/">Visit the Help Center</a> to learn more.</p> |
| 4 | + <b-card no-body> |
| 5 | + <b-tabs small pills card class="nav-fill" v-model="vmixStepsTabIndex"> |
| 6 | + <b-tab active> |
| 7 | + <template slot="title"> |
| 8 | + <div class="text-md-left"> |
| 9 | + <i class="fa fa-check" v-if="chromeExtensionInstalled" aria-hidden="true"></i> Step 1 |
| 10 | + <div class="small d-none d-md-block"><span class="d-none d-xl-inline">Install </span>Chrome Extension</div> |
| 11 | + </div> |
| 12 | + </template> |
| 13 | + <h4 class="mt-0">Install the Chrome Extension</h4> |
| 14 | + <p class="mb-2">The Web Captioner Connector extension for Google Chrome lets Web Captioner connect to vMix.</p> |
| 15 | + <div class="mt-3 mb-4"> |
| 16 | + <b-button v-if="!chromeExtensionInstalled" @click="initChromeExtensionInstall" variant="outline-info"><i class="fa fa-chrome mr-2"></i>Add to Chrome</b-button> |
| 17 | + <b-button v-else variant="outline-info" disabled><i class="fa fa-check mr-2"></i>Extension Installed</b-button> |
| 18 | + </div> |
| 19 | + <hr class="my-3" /> |
| 20 | + <div class="text-right"> |
| 21 | + <b-button @click="vmixStepsTabIndex = 1" size="sm" :variant="chromeExtensionInstalled ? 'secondary' : 'default'" :disabled="!chromeExtensionInstalled">Next <i class="fa fa-chevron-right" aria-hidden="true"></i></b-button> |
| 22 | + </div> |
| 23 | + </b-tab> |
| 24 | + <b-tab :disabled="!chromeExtensionInstalled"> |
| 25 | + <template slot="title"> |
| 26 | + <div class="text-md-left" id="vmixStep2Tab"> |
| 27 | + Step 2 |
| 28 | + <div class="small d-none d-md-block">vMix Web Controller</div> |
| 29 | + </div> |
| 30 | + <b-tooltip v-if="!chromeExtensionInstalled" target="vmixStep2Tab"> |
| 31 | + Complete step 1 first |
| 32 | + </b-tooltip> |
| 33 | + </template> |
| 34 | + <h4 class="mt-0">Enable the vMix Web Controller</h4> |
| 35 | + <p>In vMix, go to <strong>Settings > Web Controller</strong>. Check the box to enable the <a href="http://www.vmix.com/knowledgebase/article.aspx/69/how-to-control-vmix-from-a-web-browser-using-vmix-web-controller" target="_blank">web controller</a>. Specify a port number or accept the default.</p> |
| 36 | + <p>Provide the address that appears in vMix:</p> |
| 37 | + <b-input-group :class="{'append-embedded-in-input': webControllerConnected}"> |
| 38 | + <input @keydown="resetWebControllerConnectedStatus()" v-model="webControllerAddress" type="url" class="form-control" placeholder="vMix Web Controller Address" required="true" /> |
| 39 | + <template slot="append" v-if="webControllerConnected"> |
| 40 | + <div class="input-group-text text-success"> |
| 41 | + <i class="fa fa-check fa-fw pr-3" style="position:relative;top:-1px" aria-hidden="true"></i> Connected |
| 42 | + </div> |
| 43 | + </template> |
| 44 | + </b-input-group> |
| 45 | + <p class="mt-2"><small class="form-text text-muted">Example: http://192.168.1.1:8080</small></p> |
| 46 | + <b-alert :show="showConnectionFailureMessage" dismissible variant="danger">Cannot connect to vMix. Make sure Web Controller is enabled in vMix and that you've copied over the website address correctly. It should look something like this: http://192.168.1.1:8080</b-alert> |
| 47 | + <hr class="my-3" /> |
| 48 | + <div class="text-right"> |
| 49 | + <b-button @click="refreshVmixSetupStatus()" size="sm" :variant="webControllerAddress == '' ? 'default' : 'secondary'" :disabled="webControllerAddress == ''">Next <i class="fa fa-chevron-right" aria-hidden="true"></i></b-button> |
| 50 | + </div> |
| 51 | + </b-tab> |
| 52 | + <b-tab> |
| 53 | + <template slot="title"> |
| 54 | + <div class="text-md-left"> |
| 55 | + Step 3 |
| 56 | + <div class="small d-none d-md-block"><span class="d-none d-xl-inline">Import </span>Title Template</div> |
| 57 | + </div> |
| 58 | + </template> |
| 59 | + <h4 class="mt-0">Import the Web Captioner Title Template into vMix</h4> |
| 60 | + <ol class="ml-0 mb-2"> |
| 61 | + <li>Download the Web Captioner vMix title template:<br/> <a href="/web-captioner-title.xaml" class="btn btn-outline-info mt-1 mb-2">Web Captioner vMix Title Template <i class="fa fa-external-link ml-1" aria-hidden="true"></i></a></li> |
| 62 | + <li>In vMix, go to <strong>Add Input > Title/XAML</strong>. In the upper right of the Input Select window, click <strong>Browse...</strong> and open the Web Captioner title template.</li> |
| 63 | + <li>The title will appear in the <strong>Recent</strong> tab. Double-click it.</li> |
| 64 | + <li>In the Title Editor that appears, optionally customize font and text size. Close it when you are finished.</li> |
| 65 | + </ol> |
| 66 | + <hr class="my-3" /> |
| 67 | + <div class="text-right"> |
| 68 | + <b-button size="sm" :variant="webControllerAddress == '' ? 'default' : 'secondary'" :disabled="webControllerAddress == ''">Test and Finish Setup</b-button> |
| 69 | + </div> |
| 70 | + </b-tab> |
| 71 | + </b-tabs> |
| 72 | + </b-card> |
72 | 73 | </div>
|
73 | 74 | </template>
|
74 | 75 |
|
| 76 | +<style> |
| 77 | + .nav-link.disabled { |
| 78 | + color:#aaa!important; |
| 79 | + cursor:default; |
| 80 | + } |
| 81 | + .nav-link.disabled:hover { |
| 82 | + background:#eee; |
| 83 | + } |
| 84 | +
|
| 85 | + .input-group.append-embedded-in-input input { |
| 86 | + border-right: 0px solid transparent; |
| 87 | + } |
| 88 | +
|
| 89 | + .input-group.append-embedded-in-input .input-group-append .input-group-text { |
| 90 | + background-color: transparent; |
| 91 | + border-left: 0px solid transparent; |
| 92 | + } |
| 93 | +
|
| 94 | +</style> |
| 95 | + |
| 96 | + |
75 | 97 | <script>
|
76 | 98 |
|
77 | 99 | export default {
|
78 | 100 | name: 'settings-vmix-view',
|
| 101 | + data: function() { |
| 102 | + return { |
| 103 | + vmixStepsTabIndex: 0, |
| 104 | + }; |
| 105 | + }, |
| 106 | + mounted: function() { |
| 107 | + this.refreshVmixSetupStatus(); |
| 108 | + }, |
| 109 | + methods: { |
| 110 | + initChromeExtensionInstall: function () { |
| 111 | + let self = this; |
| 112 | + chrome.webstore.install(null, function() { |
| 113 | + // Successful |
| 114 | + self.refreshVmixSetupStatus(); |
| 115 | + }, function() { |
| 116 | + // Unsuccessful |
| 117 | + }); |
| 118 | + }, |
| 119 | + refreshVmixSetupStatus: function () { |
| 120 | + this.$store.dispatch('REFRESH_VMIX_SETUP_STATUS'); |
| 121 | + }, |
| 122 | + resetWebControllerConnectedStatus: function () { |
| 123 | + this.$store.commit('RESET_WEB_CONTROLLER_CONNECTED_STATUS'); |
| 124 | + }, |
| 125 | + }, |
| 126 | + computed: { |
| 127 | + chromeExtensionInstalled: function() { |
| 128 | + return this.$store.state.integrations.vmix.chromeExtensionInstalled; |
| 129 | + }, |
| 130 | + webControllerConnected: function() { |
| 131 | + return this.$store.state.integrations.vmix.webControllerConnected; |
| 132 | + }, |
| 133 | + webControllerAddress: { |
| 134 | + get () { |
| 135 | + return this.$store.state.integrations.vmix.webControllerAddress; |
| 136 | + }, |
| 137 | + set (webControllerAddress) { |
| 138 | + this.$store.commit('SET_VMIX_WEB_CONTROLLER_ADDRESS', {webControllerAddress}); |
| 139 | + } |
| 140 | + }, |
| 141 | + showConnectionFailureMessage: function () { |
| 142 | + return this.webControllerAddress != '' && this.webControllerConnected === false; |
| 143 | + }, |
| 144 | + }, |
79 | 145 | }
|
80 | 146 | </script>
|
0 commit comments