Skip to content

Commit

Permalink
Launch both cameras and main
Browse files Browse the repository at this point in the history
  • Loading branch information
qhdwight committed Apr 27, 2024
1 parent 2dbf979 commit cac3618
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 10 deletions.
3 changes: 2 additions & 1 deletion launch/basestation.launch
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@

<node if="$(arg run_frontend)" name="gui_frontend" pkg="mrover" type="gui_frontend.sh" cwd="node" required="true" />
<node if="$(arg run_backend)" name="gui_backend" pkg="mrover" type="gui_backend.sh" cwd="node" required="true" />
<node if="$(arg run_browser)" name="gui_chromium" pkg="mrover" type="gui_chromium.sh" />
<node if="$(arg run_browser)" name="gui_chromium_menu" pkg="mrover" type="gui_chromium_menu.sh" />
<node if="$(arg run_browser)" name="gui_chromium_cameras" pkg="mrover" type="gui_chromium_cameras.sh" />

<group if="$(arg run_rviz)">
<arg name="rvizconfig" default="$(find mrover)/config/rviz/basestation.rviz" />
Expand Down
9 changes: 1 addition & 8 deletions src/teleoperation/frontend/src/components/MenuButton.vue
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<template>
<a class="btn btn-primary" :href="link" :target="calcTarget">{{ name }}</a>
<a class="btn btn-primary" :href="link">{{ name }}</a>
</template>
<script lang="ts">
import { defineComponent } from 'vue'
Expand All @@ -17,13 +17,6 @@ export default defineComponent({
required: true
}
},
computed: {
calcTarget() {
if (this.name == "Cameras") return ")blank";
else return "_self"
}
}
})
</script>

Expand Down
4 changes: 3 additions & 1 deletion src/teleoperation/gui_chromium.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,6 @@
# Chromium currently only supports this when using VA-API hardware acceleration
# It uses the WebCodecs API to decode
# You can easily test if your setup works with this URL: https://w3c.github.io/webcodecs/samples/video-decode-display/
chromium --enable-features=VaapiVideoDecodeLinuxGL --app=http://localhost:8080
readonly FLAGS="--enable-features=VaapiVideoDecodeLinuxGL"
readonly ADDRESS="http://localhost:8080"
chromium ${FLAGS} --app=${ADDRESS}/$1
3 changes: 3 additions & 0 deletions src/teleoperation/gui_chromium_cameras.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

$(dirname $0)/gui_chromium.sh Cameras
3 changes: 3 additions & 0 deletions src/teleoperation/gui_chromium_menu.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/bash

$(dirname $0)/gui_chromium.sh

0 comments on commit cac3618

Please sign in to comment.