Multimedia: Difference between revisions

From Chaosdorf Wiki
No edit summary
(→‎Sound: Add chromecast in sound section)
(28 intermediate revisions by 11 users not shown)
Line 2: Line 2:
[[File:Pulseaudio.png|thumb|right|PulseAudio Volume Control]]
[[File:Pulseaudio.png|thumb|right|PulseAudio Volume Control]]


The front area of our space is equipped with a powerful sound system. Seven wall-mounted speakers (JBL control), accompanied by a subwoofer beneath the stairs are wired to four amplifiers located in the server room. {{H|hyperion}} is connected to them.
The Hackcenter area of our space is equipped with a powerful sound system. four ceiling- and wall-mounted speakers (JBL control), accompanied by a subwoofer in the right front corner are wired to four amplifiers located in the server room.


=== PulseAudio ===
=== PulseAudio ===
Use [[Wikipedia:PulseAudio|PulseAudio]] for playback from your machine or MPD/VLC/Kodi.


Use [[Wikipedia:PulseAudio|PulseAudio]] for playback from your machine or MPD/MPlayer/XBMC on {{H|hyperion}}.
PULSE_SERVER=pulse.chaosdorf.space vlc


There are three output devices available:
For example, use the following command to create a remote sink on your machine:
pacmd load-module module-tunnel-sink server=pulse.chaosdorf.space


# ''Laptop Lounge'' for listening, presentations and theatre sound
Then, switch the desired stream to the new sink. Use can use <tt>pavucontrol</tt> for that.
# ''Hackcenter'' for showing stuff in the back of the room
 
# ''Combined Output'' \o ALL the outputs, for general background music
'''Warning:''' Remember to lower your playback volume before switching outputs to prevent damaging everyones ears.


Use on the following commands to create a remote sink on your machine:
Um vom lokalen Capture-Device an den Mischer zu streamen, nutze folgendes Kommando:
parec --latency-msec=50 | pacat --latency-msec=50 --server=pulse.chaosdorf.space


pacmd load-module module-tunnel-sink server=hyperion sink=hackcenter
=== MPRIS auf MQTT publishen ===


or
Um Artist/Title auf dem Dashboard anzuzeigen.


pacmd load-module module-tunnel-sink server=hyperion sink=laptop_lounge
[https://gist.github.com/YtvwlD/06cc690a360a8d7d29b067b800ac8998]


or
=== Airplay ===


pacmd load-module module-tunnel-sink server=hyperion sink=combined
We have [https://github.com/chaosdorf/shairplay Shairplay] running as a bridge to stream audio using the Airplay protocol. Just choose "shairplay" from the list of available outputs.


Then, switch the desired stream to the new sink. Use can use <tt>pavucontrol</tt> for that.
=== ALSA ===
PulseAudio outputs over the usual ALSA devices. The default mixer settings are balanced for nice background sound in the [[Hackcenter]]. To override these, use the PulseAudio mixer interface.
There's a web interface at https://pulseweb.chaosdorf.space.


'''Warning''' Remember to lower your playback volume before switching outputs to prevent damaging everyones ears.
=== MPD ===
[[File:ympd.png|thumb|right|300px|Unser Web Interface]]
Zum Musikhören: Die Verstärker über die Schalterleiste in der Ecke einschalten, sicherstellen, dass Input 1 ausgewählt ist und [[sobek]] an ist. Die Anlage ist an den Multimedia-Server angeschlossen, auf dem ein [https://www.musicpd.org/ MPD] als Jukebox läuft.


=== ALSA ===
Anschließend kann die Musik zum Beispiel über unser Web Interface unter https://ympd.chaosdorf.space/ gesteuert werden.


PulseAudio outputs over the usual ALSA devices. The default mixer settings are balanced for nice background sound both in the [[Laptop Lounge|Lounge]] and in the [[Hackcenter]]. To override these, use the PulseAudio mixer interface.
Da das Web Interface auf Einfachheit ausgelegt ist, möchtet ihr evtl. einen MPD Client auf eurem Gerät nutzen. Eine umfassende Liste gibt es unter http://mpd.wikia.com/wiki/Clients


=== Musik ===
Als Hostnamen in den Clients "mpd" eingeben.
Zum Musikhören: Die Verstärker im Serverraum einschalten. Die Anlage ist an den Multimedia-Server (hyperion) angeschlossen. Auf hyperion läuft ein MPD, welcher mit jedem üblichen MPD-Client bedient werden kann. Zusätzliche Musik kann per NFS hochgeladen werden, anschließend muss die Datenbank des MPD z.B. mit "mpc update" aktualisiert werden.
* Für Android ist [https://github.com/gateship-one/malp MALP] ([https://play.google.com/store/apps/details?id=org.gateshipone.malp Play Store] [https://f-droid.org/app/org.gateshipone.malp F-Droid]) der heißeste Scheiß.
* Für PCs (Linux, macOS und Windows) taugt [https://github.com/CDrummond/cantata/releases Cantata].
* Das iOS-Universum hat leider wenig Liebe für MPD übrig.


=== Audio-Bork ===
Neue Musik hinzufügen:
Our current audio-device is being detected as a 'C-Media CMI8788' and it's semi-borked. It sometimes works perfectly, sometimes its only serving one amplifier, sometimes it doesn't work at all.


Kernel-Modul:
* Neuen Ordner auf ftp unter music anlegen.
<blockquote>modinfo snd-oxygen                                                          : ( filename:      /lib/modules/3.10.40-1-lts/kernel/sound/pci/oxygen/snd- oxygen.ko.gz license:        GPL v2 description:    C-Media CMI8788 driver author:        Clemens Ladisch <clemens@ladisch.de> alias:          pci:v000013F6d00008788sv00007284sd00009781bc*sc*i* alias:          pci:v000013F6d00008788sv00007284sd00009761bc*sc*i* alias:          pci:v000013F6d00008788sv00005431sd0000017Abc*sc*i* alias:          pci:v000013F6d00008788sv0000415Asd00005431bc*sc*i* alias:          pci:v000013F6d00008788sv000014C3sd00001711bc*sc*i* alias:          pci:v000013F6d00008788sv000014C3sd00001710bc*sc*i* alias:          pci:v000013F6d00008788sv000013F6sd0000FFFFbc*sc*i* alias:          pci:v000013F6d00008788sv000013F6sd00008782bc*sc*i* alias:          pci:v000013F6d00008788sv00001043sd00008521bc*sc*i* alias:          pci:v000013F6d00008788sv00001043sd00008467bc*sc*i* alias:          pci:v000013F6d00008788sv00001A58sd00000910bc*sc*i* alias:          pci:v000013F6d00008788sv0000147Asd0000A017bc*sc*i* alias:          pci:v000013F6d00008788sv000013F6sd00008788bc*sc*i* alias:          pci:v000013F6d00008788sv000013F6sd00000010bc*sc*i* alias:          pci:v000013F6d00008788sv000013F6sd00000001bc*sc*i* alias:          pci:v000013F6d00008788sv000010B0sd00000219bc*sc*i* alias:          pci:v000013F6d00008788sv000010B0sd00000218bc*sc*i* alias:          pci:v000013F6d00008788sv000010B0sd00000217bc*sc*i* alias:          pci:v000013F6d00008788sv000010B0sd00000216bc*sc*i* depends:        snd-oxygen-lib,snd intree:        Y vermagic:      3.10.40-1-lts SMP mod_unload modversions parm:          index:card index (array of int) parm:          id:ID string (array of charp) parm:          enable:enable card (array of bool)</blockquote>
* Musikdateien in den Ordner kopieren.
* mpc --host=mpd update --wait [Ordnername]


aplay findet kein Device:
Man kann den Ordnernamen auch weglassen, aber dann dauert es ggf. länger.
<blockquote> aplay -l                                                                    aplay: device_list:268: no soundcards found...
</blockquote>


mpd-Log:
=== Chromecast ===
<blockquote>30 20:57:28 hyperion mpd[2758]: pulse_output: Failed to open "Pulseaudio Output" [pulse]: failed to connect: Connection refused May 30 20:57:28 hyperion mpd[2758]: output: Failed to open audio output May 30 20:57:28 hyperion mpd[2758]: player: problems opening audio device while playing "Creative Commons Collection/Totally Legitimate/01. Copyright needs to die.mp3"
Am Medienumschalter ist ein Chromecast an Kanal 4<ref>[[Mediarack#Anschl.C3.BCsse_Medienumschalter_IN1606]]</ref> auswählbar, dann kann man Sound über Verstärker hören ✨
</blockquote>


== Filme ==
== Filme ==
→[[Projector]]
=== Chromecast ===
Im Hackcenter hängt am TV ein Chromecast.
Android (mit installierten Google-Apps) (und dementsprechend fast jede Audio-/Video-App dafür), die offizielle YouTube-App für iOS und Google Chrome können out of the Box die Chromecasts ansprechen.


[[Beamer]]
Um lokal gespeicherte Videos abzuspielen, ist [https://github.com/xat/castnow CastNow] ein gutes Tool, obwohl es NodeJS nutzt. Ohne Optionen erwartet ein Chrome einen '''MP4-Container''' mit '''AVC-Videotrack''' und '''AAC-Audiotrack'''. CastNow kann ffmpeg nutzen, um Dateien entsprechend zu konvertieren (mittels <tt>--tomp4</tt>) und reicht dafür einfach nur ffmpeg-Kommandos durch. Wenn man also ein Video hat, das nur einen AVC-Videotrack hat, aber einen anderes Audioformat, wäre das entsprechende Kommando:
<pre>castnow ./myvideo.mkv --tomp4 --ffmpeg-vcodec copy</pre>


[[Category:Services]]
[[Category:Services]]

Revision as of 21:55, 4 May 2023

Sound

PulseAudio Volume Control

The Hackcenter area of our space is equipped with a powerful sound system. four ceiling- and wall-mounted speakers (JBL control), accompanied by a subwoofer in the right front corner are wired to four amplifiers located in the server room.

PulseAudio

Use PulseAudio for playback from your machine or MPD/VLC/Kodi.

PULSE_SERVER=pulse.chaosdorf.space vlc

For example, use the following command to create a remote sink on your machine:

pacmd load-module module-tunnel-sink server=pulse.chaosdorf.space

Then, switch the desired stream to the new sink. Use can use pavucontrol for that.

Warning: Remember to lower your playback volume before switching outputs to prevent damaging everyones ears.

Um vom lokalen Capture-Device an den Mischer zu streamen, nutze folgendes Kommando:

parec --latency-msec=50 | pacat --latency-msec=50 --server=pulse.chaosdorf.space

MPRIS auf MQTT publishen

Um Artist/Title auf dem Dashboard anzuzeigen.

[1]

Airplay

We have Shairplay running as a bridge to stream audio using the Airplay protocol. Just choose "shairplay" from the list of available outputs.

ALSA

PulseAudio outputs over the usual ALSA devices. The default mixer settings are balanced for nice background sound in the Hackcenter. To override these, use the PulseAudio mixer interface. There's a web interface at https://pulseweb.chaosdorf.space.

MPD

Unser Web Interface

Zum Musikhören: Die Verstärker über die Schalterleiste in der Ecke einschalten, sicherstellen, dass Input 1 ausgewählt ist und sobek an ist. Die Anlage ist an den Multimedia-Server angeschlossen, auf dem ein MPD als Jukebox läuft.

Anschließend kann die Musik zum Beispiel über unser Web Interface unter https://ympd.chaosdorf.space/ gesteuert werden.

Da das Web Interface auf Einfachheit ausgelegt ist, möchtet ihr evtl. einen MPD Client auf eurem Gerät nutzen. Eine umfassende Liste gibt es unter http://mpd.wikia.com/wiki/Clients

Als Hostnamen in den Clients "mpd" eingeben.

  • Für Android ist MALP (Play Store F-Droid) der heißeste Scheiß.
  • Für PCs (Linux, macOS und Windows) taugt Cantata.
  • Das iOS-Universum hat leider wenig Liebe für MPD übrig.

Neue Musik hinzufügen:

  • Neuen Ordner auf ftp unter music anlegen.
  • Musikdateien in den Ordner kopieren.
  • mpc --host=mpd update --wait [Ordnername]

Man kann den Ordnernamen auch weglassen, aber dann dauert es ggf. länger.

Chromecast

Am Medienumschalter ist ein Chromecast an Kanal 4[1] auswählbar, dann kann man Sound über Verstärker hören ✨

Filme

Projector

Chromecast

Im Hackcenter hängt am TV ein Chromecast.

Android (mit installierten Google-Apps) (und dementsprechend fast jede Audio-/Video-App dafür), die offizielle YouTube-App für iOS und Google Chrome können out of the Box die Chromecasts ansprechen.

Um lokal gespeicherte Videos abzuspielen, ist CastNow ein gutes Tool, obwohl es NodeJS nutzt. Ohne Optionen erwartet ein Chrome einen MP4-Container mit AVC-Videotrack und AAC-Audiotrack. CastNow kann ffmpeg nutzen, um Dateien entsprechend zu konvertieren (mittels --tomp4) und reicht dafür einfach nur ffmpeg-Kommandos durch. Wenn man also ein Video hat, das nur einen AVC-Videotrack hat, aber einen anderes Audioformat, wäre das entsprechende Kommando:

castnow ./myvideo.mkv --tomp4 --ffmpeg-vcodec copy