aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLoek Le Blansch <loek@pipeframe.xyz>2024-09-26 16:16:31 +0200
committerLoek Le Blansch <loek@pipeframe.xyz>2024-09-26 16:16:31 +0200
commit59b2541ea882e360b6ba9c724f238e545a9aa4fe (patch)
treee7f924b986bcde3f32d4b192925cd1935b17ce56
parent6329755a372d90985bda1cd164fae8d91d4a60c6 (diff)
add WIP audio facade
-rw-r--r--design.tex10
-rw-r--r--img/facade-audio.puml39
2 files changed, 49 insertions, 0 deletions
diff --git a/design.tex b/design.tex
new file mode 100644
index 0000000..bfc49ad
--- /dev/null
+++ b/design.tex
@@ -0,0 +1,10 @@
+\documentclass{projdoc}
+
+\title{Software Design}
+
+\begin{document}
+
+\includepumldiag{img/facade-audio.puml}
+
+\end{document}
+
diff --git a/img/facade-audio.puml b/img/facade-audio.puml
new file mode 100644
index 0000000..0b0e6ea
--- /dev/null
+++ b/img/facade-audio.puml
@@ -0,0 +1,39 @@
+@startuml
+!include theme.ipuml
+skinparam Linetype ortho
+
+
+package crepe {
+ class Sound {
+ +Sound(crepe::api::Resource)
+
+ +pause()
+ +play()
+ +rewind()
+ +set_volume(float)
+ +set_looping(bool)
+
+ -_handle : SoLoud::handle
+ -_paused : bool
+ }
+
+ class SoundSystem {
+
+ }
+}
+
+package SoLoud {
+ class Soloud
+ class WavStream
+ class Wav
+}
+
+' layout
+crepe -[hidden]down- SoLoud
+SoLoud.Wav -[hidden]right- SoLoud.WavStream
+SoLoud.WavStream -[hidden]right- SoLoud.Soloud
+
+crepe.Sound ..> (SoLoud.WavStream, SoLoud.Wav) : either
+crepe.SoundSystem ..> SoLoud.Soloud
+
+@enduml