Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
167 changes: 167 additions & 0 deletions docs/alphatex/_bar-metadata.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -720,3 +720,170 @@ This tag allows specifying the sustain pedal relative to the bar. The sustain pe

`}</AlphaTexSample>

## `\voiceMode`

```plain title="Syntax"
\voiceMode mode
```

**Description:** Changes the mode how alphaTab should treat voices when adding `\voice`.

You can either choose to write voice-by-voice where each voice has all bars defined.
You write bar-by-bar where a new voice is only added to the current bar.


**Parameters:**

| Name | Description | Type | Required |
|------|-------------|------|----------|
| `mode` | The mode which should be active | `staffWise\|barWise` | yes |

**Parameter Values:**

Following parameters have value limitations

| Name | Values |
|------|--------|
| `mode` | <ParameterValuesTable values={[["staffWise","Staff-Wise voices"],["barWise","Bar-Wise voices"]]} /> |

**Example:**

<AlphaTexSample tracks="all" player={true} >{`
\\title "Staff Wise Voices"
\\voiceMode staffWise
// Voice 1
\\voice
// Bar 1 Voice 1
C4*4 |
// Bar 2 Voice 1
C5*4 |
// Bar 3 Voice 1
C6*4
// Voice 2
\\voice
// Bar 1 Voice 2
C3*4 |
// Bar 2 Voice 2
C4*4 |
// Bar 3 Voice 2
C5 * 4

`}</AlphaTexSample>
<AlphaTexSample tracks="all" player={true} >{`
\\title "Bar Wise Voices"
\\voiceMode barWise
// Bar 1
// Bar 1 Voice 1
\\voice
C4*4
// Bar 1 Voice 2
\\voice
C3*4
|
// Bar 2
// Bar 2 Voice 1
\\voice
C5*4
// Bar 2 Voice 2
\\voice
C4*4
|
// Bar 3
// Bar 3 Voice 1
\\voice
C6*4
// Bar 3 Voice 2
\\voice
C5 * 4

`}</AlphaTexSample>

## `\barNumberDisplay`

```plain title="Syntax"
\barNumberDisplay mode
```

**Description:** Sets the display mode for bar numbers.

**Parameters:**

| Name | Description | Type | Required |
|------|-------------|------|----------|
| `mode` | The mode to use | `allBars\|firstOfSystem\|hide` | yes |

**Parameter Values:**

Following parameters have value limitations

| Name | Values |
|------|--------|
| `mode` | <ParameterValuesTable values={[["allBars","All bars"],["firstOfSystem","First bar of every system"],["hide","Hide"]]} /> |

**Example:**

<AlphaTexSample tracks="all" player={true} settings={{"display":{"layoutMode":"Parchment"}}}>{`
\\defaultBarNumberDisplay hide
\\track { defaultsystemslayout 3 }
C4.1 | \\barNumberDisplay allBars C4.1 | C4.1 |
\\barNumberDisplay firstOfSystem C4.1 | \\barNumberDisplay firstOfSystem C4.1 | C4.1

`}</AlphaTexSample>
<AlphaTexSample tracks="all" player={true} settings={{"display":{"layoutMode":"Parchment"}}}>{`
\\defaultBarNumberDisplay firstOfSystem
\\track { defaultsystemslayout 3 }
C4.1 | \\barNumberDisplay allBars C4.1 | C4.1 |
\\barNumberDisplay hide C4.1 | C4.1 | C4.1

`}</AlphaTexSample>

## `\beaming`

```plain title="Syntax"
\beaming (duration groups)
```

**Description:** Defines a custom beaming rule defining how beams of certain durations should be beamed.

To define how beats should be beamed we need 2 parts:

1. A duration with which we splitup the bars
2. A list of group sizes defining how many split-parts should be beamed together.

The beaming rules go hand-in-hand with the time signature as the rules need to properly
define the groups for the whole beat.

Let's take a simple example of a 4/4 time signature. If we want to ensure that the beats within the quarter notes are
beamed together we can write variants like this:

a. `\beaming (4 1 1 1 1)`
b. `\beaming (8 2 2 2 2)`
c. `\beaming (16 4 4 4 4)`

We slice the bar into 4, 8 or 16 parts. Then we add "groups" to those parts. If two beats start in the same group, they can be beamed together.
Simple as that.

There are some common guidelines on how beaming "should be done" and alphaTab ships a wide range of defaults. But in case of more specialized time signatures,
you can also customize the beaming as you need by slicing the bar and grouping the beats as needed.


**Parameters:**

| Name | Description | Type | Required |
|------|-------------|------|----------|
| `duration` | The note duration defining the smallest group size | `Number` | yes |
| `groups` | For every group the number of notes contained in the group. | `Number[]` | no |

**Example:**

<AlphaTexSample tracks="all" player={true} >{`
\\ts (4 4)
\\beaming (8 4 2 2)
C4.8 * 8 |

\\ts (4 4)
\\beaming (8 4 4)
C4.8 * 8

`}</AlphaTexSample>

Expand Down
16 changes: 12 additions & 4 deletions docs/alphatex/_beat-properties.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ C4 {balance 0} D4 E4 {balance 16} F4
## `tp`

```plain title="Syntax"
tp speed
tp (marks style)
```

**Description:** Add a tremolo picking to the beat.
Expand All @@ -898,20 +898,28 @@ tp speed

| Name | Description | Type | Required |
|------|-------------|------|----------|
| `speed` | The tremolo picking speed | `8\|16\|32` | yes |
| `marks` | The number of tremolo marks | `Number` | yes |
| `style` | The tremolo style | `default\|buzzRoll` | no |

**Parameter Values:**

Following parameters have value limitations

| Name | Values |
|------|--------|
| `speed` | <ParameterValuesTable values={[["8","8th Notes"],["16","16th Notes"],["32","32nd Notes"]]} /> |
| `marks` | <ParameterValuesTable values={[["1","1 tremolo mark (8th notes)"],["2","2 tremolo mark (16th notes)"],["3","3 tremolo mark (32nd notes)"],["4","4 tremolo mark (64th notes)"],["5","5 tremolo mark (128th notes)"]]} /> |
| `style` | <ParameterValuesTable values={[["default","Default tremolo"],["buzzRoll","Buzz roll tremolo"]]} /> |

**Example:**

<AlphaTexSample tracks="all" player={true} >{`
3.3{tp 8} 3.3{tp 16} 3.3{tp 32}
3.3{tp 1} 3.3{tp 2} 3.3{tp 3}

`}</AlphaTexSample>
<AlphaTexSample tracks="all" player={true} >{`
\\title "Buzz Rolls"
3.3{tp (0 buzzRoll)} // no audio
3.3{tp (1 buzzRoll)} // 8th notes tremolo shown as buzzroll

`}</AlphaTexSample>

Expand Down
Loading