The codes above work when run in AH4's script window, or when saved as UTF-8 files with the extension .ahcommand and opened by AH. I'd like to be able to run them as Javascript directly from KM if possible.
Audio Hijack is a powerful audio recorder, enabling you to record any audio heard on your Mac. Save web streams, create podcasts, preserve important voice chat conversations, and so much more. If you can hear it, Audio Hijack can record it.But Audio Hijack's abilities extend beyond recording, to other audio tasks as well. It makes it easy for content creators to broadcast RTMP live streams or online radio stations. If you want to improve microphone inputs, or apply an equalizer to a movie, the powerful audio effects can help. You can even timeshift audio on your Mac, rewinding live audio.
The Web Audio template will create a session like the one seen above, with three blocks in the audio grid. On the left, the Safari web browser has been selected as the source. Audio will flow from Safari into a Recorder block, where it will be saved to an MP3 file. The audio will then flow on to the computer's speakers, so it can be heard while it's playing.This default setup will already enable us to record from Safari. Adjusting and extending things further is as simple as adding new blocks from the Blocks tab, in the sidebar.Activating the Session
Once the session is configured as desired, we hit the Run button in the lower left. This starts audio flowing through Audio Hijack, and thanks to the blocks we've configured, it's both recorded to an MP3 file and heard via the system's default output. When we're done, we click the Stop button to end audio flow. Now we can check our recording.
Click the Recordings tab in the sidebar on the right side of the session window to see a list of recordings made with this session. We can give the recording a listen, pass it to an audio editor, reveal the actual file in the Finder, and more.
Everything in Audio Hijack begins with a session, a reusable collection of settings used to capture and manipulate audio however you like. Sessions are the fundamental document of Audio Hijack, and they're continuously saved as you adjust them. Once a session is configured to your needs, you'll run it to record, broadcast, or adjust audio.The Session List window provides a list of all your saved sessions for re-use.
The audio grid is the heart of each session. Within a session, you'll chain together blocks in the audio grid, creating a pipeline for audio to flow through. To set up a session, add two or more blocks from the block library in the sidebar to the audio grid. By default, connections will be made automatically between nearby blocks. You can always experiment to get the exact audio pipeline you're after, and if you need to, just select Undo to revert undesired changes.
When a session is activated by clicking the Run button, audio from the sources selected will flow through the blocks in the audio grid (from left to right by default). The audio is shown in orange as it flows through the audio pipeline. Each block in the chain will adjust, output, or record the audio according to its settings.
The available blocks for use in the audio grid can be found in the block library, located in the sidebar of each session. Every session will need at least one Source block, which will bring audio in, as well as one Output block, to record audio, broadcast it, or pass it along to your speakers.
Sessions can also use audio effect blocks to change and improve audio. Audio Hijack includes a powerful collection of Built-In Effects, along with support for both the Audio Unit Effects provided by MacOS and those available from third parties. Meter blocks provide visual meters so you can see how audio is flowing. Finally, Advanced blocks provide additional ways to manipulate audio, discussed in depth on the Advanced Blocks page.
The sequence of blocks you lay out will determine what audio is affected by Audio Hijack, and how it's affected. Block layouts can be very simple, like this layout where audio from the computer's built-in microphone is being recorded.
Layouts can also be more complex, and more powerful. Below, audio from two different inputs is being adjusted with different audio effects. Each input is then recorded separately, before a third recording combining the two is made. This layout will result in three different audio files.
Each popover contains custom settings and controls for that particular block. These are largely straight-forward, though some audio effects have more complex settings. Remember that you can always experiment to get the sound you're after.
By default, Audio Hijack handles the logic of connecting blocks to create the session's audio pipeline. This is recommended for most users, but if you wish to tweak things yourself, you can. To begin, turn off the Automatic Connections switch in the session's Info tab.
When Automatic Connections are turned off, you must manually connect one block to another to create the audio pipeline. This is done in the session's edit mode, which can be entered by clicking the Edit Connections button in the lower right of the audio grid.
The Blocks tab contains Audio Hijack's block library, which provides all available blocks for use in the audio grid. Blocks are dragged and dropped from here into your session to configure your audio pipeline. The block library is discussed in more depth on the Mastering Sessions page.
To preview a recording, click its Play button. You can also click one or more recordings to highlight, then use the Actions menu to reveal the selected file(s) in the Finder, open them in your chosen audio editor, add them to Apple's Music app, or share them via the MacOS Share controls.
With timers, you can trigger a session to run at a specified time. Timers allow you to to record audio on a schedule or create a musical alarm. Once a timer is configured, just make sure your computer is on and you're logged in. After that, Audio Hijack will run the session at the time you specify, launching itself and your sources if necessary.
In their default state, sessions automatically handle connecting blocks to create your audio pipeline. This is recommended for most users, but if you wish, you can toggle off the Automatic Connections switch to configure things manually. Learn more about manual connections on the Mastering Sessions page.
Audio Hijack's Recorder block makes it possible to save any audio flowing through the app. Recording audio is one of the most common use cases for Audio Hijack, so most sessions include at least one Recorder block. This page provides helpful hints on using the block.
The Recorder block defaults to saving an MP3 file into an Audio Hijack sub-folder your Mac's Music folder. The file is named with the session name, date, and time. These defaults make it easy to begin recording. Just drop a Recorder block into your chain, and you'll be able to record audio without needing to adjust any settings at all.
Audio Hijack can analyze your audio stream, and take action when it detects silence in the audio. The silence can be removed from the recording (eliminating gaps in the audio), used to trigger the creation of a new file, or used to stop recording entirely.
While recording, clicking the Pause button on the Recorder block's face or the Pause Recording button in its popover will prevent audio from being added to the currently recording file. The button will then illuminate and switch to saying Resume or Resume Recording. To resume adding audio to the currently recording file, just click again.
When the Recorder block is paused, audio continues to pass through your session, but it is not added to the file you're saving. Pausing can be useful when your stream contains audio you do not wish to be saved, eliminating the need to edit the file later.
Using multiple Recorder blocks in a single session is a great way to get synchronized recordings, all with a single click.Recording to Multiple FormatsIf you wish to record the same audio to multiple formats, you can add multiple Recorder blocks to your session.
The example session above shows two Recorder blocks with different format settings. The first is recording to lossy MP3, while the second is recording to lossless ALAC. Because Recorder blocks don't adjust audio in the pipeline, the order of your blocks doesn't matter. Having an MP3 Recorder before an Apple Lossless Recorder, for example, will not negatively impact the recording quality of the Apple Lossless file.
In the above example, the same audio will be recorded to two different file formats. You may also wish to record different portions of your audio pipeline to different files. This can also be accomplished using multiple Recorder blocks.
The above images shows a simple in-person podcast setup. Microphone A will be recorded to one file, while Microphone B will be recorded to a second file. Finally, the combined audio from Microphones A and B will be recorded in a third file.
First up is the On/Off switch, found in the upper right of each block's popover. Using this switch (or right-clicking a block and selecting Turn Off This Block) enables you to turn off an individual block in your audio chain.
You can see which blocks are currently off by looking at your chain. Those blocks which are grayed out are inactive, and won't affect audio in any way. The audio will simply flow past any inactive blocks, as if they weren't there. Just be sure all desired blocks are on when needed!
Presets aren't limited solely to audio effects like the 10 Band Equalizer. In fact, you can save a preset in almost any block, including the Application input, the Recorder block, and much more. Once you configure presets, they'll save you a tremendous amount of time.
Audio Editor: Select your favorite audio editor for use alongside Audio Hijack. Once you set this, click the Actions button in the Recordings tab to send recordings made with Audio Hijack to it with a click.
e2b47a7662