Files
rkt-web-player/scribblings/rkt-web-player.scrbl
T
2026-08-26 22:12:52 +02:00

35 lines
1.3 KiB
Racket

#lang scribble/manual
@(require (for-label racket/base
racket/contract
rkt-web-player))
@title{RKT Web Player}
@author{Hans van Dijkema}
@defmodule[rkt-web-player]
RKT Web Player combines local playback through @tt{racket-audio}
with UPnP and Sonos discovery and playback through
@tt{racket-audio-dlna}. The user interface is served to a web
browser by Racket's web server.
@defproc[(run-web-player
[music-paths (listof path-string?)]
[#:listen-ip listen-ip string? "127.0.0.1"]
[#:port port exact-positive-integer? 8080]
[#:dlna-port dlna-port exact-positive-integer? 8734]
[#:launch-browser? launch-browser? boolean? #t]) any/c] {
Treats every entry in @racket[music-paths] as a separate music library and
starts the web interface on @racket[listen-ip] and @racket[port]. Directory
contents are browsed one level at a time. Metadata and recursive contents are
only read when the user adds or plays a selected item.
The @racket[dlna-port] is used to publish local audio files to a selected
network renderer. Player resources are closed when the web server exits.
The default listen address only exposes the interface to the local computer.
Use a LAN address deliberately if other devices should control the player.
}