Render spectrogram
render.spectrogramLook at sound: a spectrogram of media or of a score as an image, time left to right, pitch bottom to top on a musical scale with note names up the side, brighter is louder. With a score_id, or a tempo you give, bar and beat lines are drawn. Up to 60 s an image. Low notes sit at the bottom, a voice in the middle, hiss and cymbals at the top; a held note is a level line, a hit is a vertical one. Comes inline and with a signed download url. One row per semitone from C1 (32.7 Hz) to B9 (15.8 kHz), A4 = 440 Hz; brightness is the level in dBFS from -90 dB (black) to 0 (a full-scale sine), the same scale on every picture. Low rows trade time detail for pitch (a window of 0.92 s at C2, 0.23 s at C4, 28.667 ms at C7); the result gives each octave's window, the plot's pixel box, and where each bar line is. Drawn on the same axes as render.notes.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "render.spectrogram"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tempo | No | Beats per minute, to draw bar and beat lines on media | |
| media_id | No | Media to draw. One of media_id or score_id | |
| score_id | No | A score to render and draw | |
| long_edge | No | Longest side (the width) in pixels; rows get taller with it | |
| from_seconds | No | Start of the range. Default 0 | |
| beats_per_bar | No | Beats in a bar, with tempo: bar lines are drawn and numbered. Without it, beat lines only | |
| until_seconds | No | End of the range. Up to 60 s after the start. Default the end, or 60 s after the start if that comes first | |
| first_bar_seconds | No | Where bar 1 starts in the media, with tempo. Default 0 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| bars | Yes | ||
| plot | Yes | The plot in image pixels: a time t is at x = left + (t - from_seconds) / seconds_per_pixel; a row is row_pixels high, the highest at top | |
| image | Yes | ||
| level | Yes | ||
| pitch | Yes | ||
| analysis | Yes | How levels were measured | |
| media_id | No | ||
| score_id | No | ||
| beat_lines | Yes | Beat lines drawn (none when closer than 4 pixels) | |
| from_seconds | Yes | ||
| until_seconds | Yes | ||
| window_seconds | Yes | Window length at each C: the time detail of that octave | |
| seconds_per_pixel | Yes |