How 14ag/dlna-server works
DLNA Server turns configured folders, playlists, and remote URLs into a persistent media catalog that DLNA players can browse and stream. The user configures sources and starts the server; it scans them, advertises itself on the network, and serves discovery, catalog, and media requests. Catalog updates can trigger notifications to subscribed players. The graph preserves documented playlist/HLS, remote-streaming, access-control, and companion-art/subtitle capabilities. Some subsystem links use README-level evidence because their implementation was not sampled.
Main entry points: media_sources_common.cpp Source scanning · server.cpp Server lifecycle · httpserver.cpp HTTP and streaming · config.h Configuration
Components 22
Setup and control
- Configuration
src/config.h - Desktop controls
src/mainwindow.cpp - Settings dialog
src/settingsdlg.cpp - Application startup
src/main.cpp
Media catalog
- Source scanning
src/media_sources_common.cpp - Remote and playlist handling
src/network_sources.cpp - Media catalog
src/media_sources.h - Persistent media IDs
src/media_database.cpp
DLNA serving
- Content Directory
src/contentdirectory.cpp - HTTP and streaming
src/httpserver.cpp - Client access rules
src/ipwhitelist.cpp - UPnP eventing
src/upnp_eventing.cpp
Network presence
- Server lifecycle
src/server.cpp - SSDP discovery
src/ssdp.cpp - Network endpoints
src/netutils.cpp
Operations
- Change watchers
src/source_watcher.cpp - Logging
src/log.cpp
Other components
- User
- DLNA players
- Media sources
- FTP and web sources
- Local files
Connections 27
- User → Desktop controls: configures sources
README.md - Desktop controls → Settings dialog: opens settings
src/mainwindow.cpp - Settings dialog → Configuration: updates settings
src/settingsdlg.cpp - Application startup → Configuration: loads configuration
src/main.cpp - Application startup → Server lifecycle: starts server
src/main.cpp - Configuration → Source scanning: supplies sources
src/media_sources_common.cpp - Media sources → Local files: selects local media
README.md - Media sources → FTP and web sources: selects remote media
README.md - Server lifecycle → Source scanning: starts scans
src/server.cpp - Source scanning → Remote and playlist handling: parses remote playlists
src/media_sources_common.cpp - Remote and playlist handling → FTP and web sources: fetches and streams
README.md - Source scanning → Media catalog: publishes media
src/media_sources_common.cpp - Source scanning → Persistent media IDs: tracks stable IDs
src/media_sources_common.cpp - Server lifecycle → SSDP discovery: starts discovery
src/server.cpp - SSDP discovery → Network endpoints: uses network endpoints
src/ssdp.cpp - DLNA players → SSDP discovery: discovers server
README.md - Server lifecycle → HTTP and streaming: starts HTTP service
src/server.cpp - DLNA players → HTTP and streaming: requests media
README.md - HTTP and streaming → Content Directory: routes catalog requests
src/httpserver.cpp - Content Directory → Media catalog: reads catalog
src/contentdirectory.cpp - HTTP and streaming → Remote and playlist handling: fetches HLS manifests
src/httpserver.cpp - HTTP and streaming → Client access rules: checks client access
src/httpserver.cpp - HTTP and streaming → UPnP eventing: handles subscriptions
src/httpserver.cpp - Source scanning → UPnP eventing: notifies catalog updates
src/media_sources_common.cpp - Server lifecycle → Change watchers: starts change watches
src/server.cpp - Change watchers → Source scanning: triggers rescans
- Server lifecycle → Logging: records lifecycle
src/server.cpp