Skip to content

Commit

Permalink
fix(server) add intelnuc option
Browse files Browse the repository at this point in the history
  • Loading branch information
smarthomeagentur committed Sep 24, 2023
1 parent 0c4dd43 commit b761a1c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion server.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ var State = {
rotation: 0,
volume: Volume,
audio: false,
intelnuc: false,
};
var BalenaRelease;
var BlockButton = false;
Expand Down Expand Up @@ -149,6 +150,9 @@ async function vlcPlayer(file, loop = false, fullscreen = false) {
playerParams.push("--video-filter", "transform{true}");
}
}
if (State.intelnuc) {
playerParams.push("--aout", "alsa", "--alsa-audio-device=plughw:CARD=0,DEV=3");
}
//TODO check if we need to start fullsccreen or if performance is better without
if (fullscreen) {
playerParams.push("-f");
Expand Down Expand Up @@ -209,10 +213,11 @@ async function vlcBlockPlaying() {
});
}

async function vlcSettings(rotation = 0, volume = Volume, audio = false) {
async function vlcSettings(rotation = 0, volume = Volume, audio = false, intelnuc = false) {
State.rotation = rotation;
State.volume = volume;
State.audio = audio;
State.intelnuc = intelnuc;
}

async function vlcPlayFile(file) {
Expand Down

0 comments on commit b761a1c

Please sign in to comment.