diff --git a/index.html b/index.html
index bf64537..3a96625 100644
--- a/index.html
+++ b/index.html
@@ -128,7 +128,7 @@
-
diff --git a/src/API.ts b/src/API.ts
index 186e997..55384f7 100644
--- a/src/API.ts
+++ b/src/API.ts
@@ -86,6 +86,7 @@ export class UserAPI {
private printTimeoutID: number = 0;
public MidiConnection: MidiConnection;
public scale_aid: string | number | undefined = undefined;
+ public hydra: any;
load: samples;
constructor(public app: Editor) {
diff --git a/src/WindowBehavior.ts b/src/WindowBehavior.ts
index 1282738..b5e5a1d 100644
--- a/src/WindowBehavior.ts
+++ b/src/WindowBehavior.ts
@@ -32,13 +32,13 @@ export const saveBeforeExit = (app: Editor): null => {
export const installWindowBehaviors = (
app: Editor,
window: Window,
- preventMultipleTabs: boolean = false,
+ preventMultipleTabs: boolean = false
) => {
window.addEventListener("resize", () =>
- handleResize(app.interface.scope as HTMLCanvasElement),
+ handleResize(app.interface.scope as HTMLCanvasElement)
);
window.addEventListener("resize", () =>
- handleResize(app.interface.feedback as HTMLCanvasElement),
+ handleResize(app.interface.feedback as HTMLCanvasElement)
);
window.addEventListener("beforeunload", (event) => {
event.preventDefault();
@@ -61,11 +61,11 @@ export const installWindowBehaviors = (
if (e.key == "page_available") {
document.getElementById("all")!.classList.add("invisible");
alert(
- "Topos is already opened in another tab. Close this tab now to prevent data loss.",
+ "Topos is already opened in another tab. Close this tab now to prevent data loss."
);
}
},
- false,
+ false
);
}
};
diff --git a/src/documentation/more/bonus.ts b/src/documentation/more/bonus.ts
index 5a5e5ff..1138c04 100644
--- a/src/documentation/more/bonus.ts
+++ b/src/documentation/more/bonus.ts
@@ -7,7 +7,7 @@ export const bonus = (application: Editor): string => {
return `
# Bonus features
-Some features are here "just for fun" or "just because I can". They are not very interesting per se but are still available nonetheless. They mostly gravitate towards manipulating visuals or patterning other multimedia formats.
+Some features have been included as a bonus. These features are often about patterning over things that are not directly related to sound: pictures, video, etc.
## Hydra Visual Live Coding
@@ -15,19 +15,19 @@ Some features are here "just for fun" or "just because I can". They are not very
⚠️ This feature can generate flashing images that could trigger photosensitivity or epileptic seizures. ⚠️
-[Hydra](https://hydra.ojack.xyz/?sketch_id=mahalia_1) is a popular live-codable video synthesizer developed by [Olivia Jack](https://ojack.xyz/) and other contributors. It follows the metaphor of analog synthesizer patching to allow its user to create complex live visuals from a web browser window. Being very easy to use, extremely powerful and also very rewarding to use, Hydra has become a popular choice for adding visuals into a live code performance. Topos provides a simple way to integrate Hydra into a live coding session and to blend it with regular Topos code.
+[Hydra](https://hydra.ojack.xyz/?sketch_id=mahalia_1) is a popular live-codable video synthesizer developed by [Olivia Jack](https://ojack.xyz/) and other contributors. It follows an analog synthesizer patching metaphor to encourage live coding complex shaders. Being very easy to use, extremely powerful and also very rewarding to use, Hydra has become a popular choice for adding visuals into a live code performance.
${makeExample(
"Hydra integration",
- `beat(4) :: app.hydra.osc(3, 0.5, 2).out()`,
- true,
+ `beat(4) :: hydra.osc(3, 0.5, 2).out()`,
+ true
)}
-You may feel like it's doing nothing! Press ${key_shortcut(
- "Ctrl+D",
- )} to close the documentation. **Boom, all shiny!**
+Close the documentation to see the effect: ${key_shortcut(
+ "Ctrl+D"
+ )}! **Boom, all shiny!**
-Be careful not to call