-
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
769 additions
and
36 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,6 @@ | ||
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="https://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="https://schemas.microsoft.com/winfx/2006/xaml/presentation"> | ||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=MIDICC/@EntryIndexedValue">MIDICC</s:String> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=MIDICC/@EntryIndexedValue">True</s:Boolean> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=sidechain/@EntryIndexedValue">True</s:Boolean> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=Unkwown/@EntryIndexedValue">True</s:Boolean> | ||
<s:Boolean x:Key="/Default/UserDictionary/Words/=Vtbl/@EntryIndexedValue">True</s:Boolean></wpf:ResourceDictionary> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,101 @@ | ||
// Copyright (c) Alexandre Mutel. All rights reserved. | ||
// Licensed under the BSD-Clause 2 license. | ||
// See license.txt file in the project root for full license information. | ||
|
||
using System.Runtime.InteropServices; | ||
|
||
namespace NPlug; | ||
|
||
public struct AudioEvent | ||
{ | ||
/// <summary> | ||
/// event bus index | ||
/// </summary> | ||
public int BusIndex; | ||
|
||
/// <summary> | ||
/// sample frames related to the current block start sample position | ||
/// </summary> | ||
public int SampleOffset; | ||
|
||
/// <summary> | ||
/// position in project | ||
/// </summary> | ||
public double Position; | ||
|
||
/// <summary> | ||
/// combination of @ref EventFlags | ||
/// </summary> | ||
public AudioEventFlags Flags; | ||
|
||
/// <summary> | ||
/// a value from @ref EventTypes | ||
/// </summary> | ||
public AudioEventKind Kind; | ||
|
||
/// <summary> | ||
/// The value of this event. | ||
/// </summary> | ||
public AudioEventValue Value; | ||
|
||
/// <summary> | ||
/// The value of an <see cref="AudioEvent"/> that depends on the <see cref="AudioEvent.Kind"/> | ||
/// </summary> | ||
[StructLayout(LayoutKind.Explicit)] | ||
public struct AudioEventValue | ||
{ | ||
/// <summary> | ||
/// type == kNoteOnEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.NoteOnEvent NoteOn; | ||
|
||
/// <summary> | ||
/// type == kNoteOffEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.NoteOffEvent NoteOff; | ||
|
||
/// <summary> | ||
/// type == kDataEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.DataEvent Data; | ||
|
||
/// <summary> | ||
/// type == kPolyPressureEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.PolyPressureEvent PolyPressure; | ||
|
||
/// <summary> | ||
/// type == kNoteExpressionValueEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.NoteExpressionValueEvent NoteExpressionValue; | ||
|
||
/// <summary> | ||
/// type == kNoteExpressionTextEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.NoteExpressionTextEvent NoteExpressionText; | ||
|
||
/// <summary> | ||
/// type == kChordEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.ChordEvent Chord; | ||
|
||
/// <summary> | ||
/// type == kScaleEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.ScaleEvent Scale; | ||
|
||
/// <summary> | ||
/// type == kLegacyMIDICCOutEvent | ||
/// </summary> | ||
[FieldOffset(0)] | ||
public AudioEvents.LegacyMIDICCOutEvent MidiCCOut; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// Copyright (c) Alexandre Mutel. All rights reserved. | ||
// Licensed under the BSD-Clause 2 license. | ||
// See license.txt file in the project root for full license information. | ||
|
||
namespace NPlug; | ||
|
||
public enum AudioEventFlags : ushort | ||
{ | ||
None = 0, | ||
|
||
/// <summary> | ||
/// Indicates that the event is played live (directly from keyboard) | ||
/// </summary> | ||
IsLive = 1 << 0, | ||
|
||
/// <summary> | ||
/// reserved for user (for internal use) | ||
/// </summary> | ||
UserReserved1 = 1 << 14, | ||
|
||
/// <summary> | ||
/// reserved for user (for internal use) | ||
/// </summary> | ||
UserReserved2 = 1 << 15, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
// Copyright (c) Alexandre Mutel. All rights reserved. | ||
// Licensed under the BSD-Clause 2 license. | ||
// See license.txt file in the project root for full license information. | ||
|
||
namespace NPlug; | ||
|
||
public enum AudioEventKind : ushort | ||
{ | ||
/// <summary> | ||
/// is @ref NoteOnEvent | ||
/// </summary> | ||
NoteOn = 0, | ||
|
||
/// <summary> | ||
/// is @ref NoteOffEvent | ||
/// </summary> | ||
NoteOff = 1, | ||
|
||
/// <summary> | ||
/// is @ref DataEvent | ||
/// </summary> | ||
Data = 2, | ||
|
||
/// <summary> | ||
/// is @ref PolyPressureEvent | ||
/// </summary> | ||
PolyPressure = 3, | ||
|
||
/// <summary> | ||
/// is @ref NoteExpressionValueEvent | ||
/// </summary> | ||
NoteExpressionValue = 4, | ||
|
||
/// <summary> | ||
/// is @ref NoteExpressionTextEvent | ||
/// </summary> | ||
NoteExpressionText = 5, | ||
|
||
/// <summary> | ||
/// is @ref ChordEvent | ||
/// </summary> | ||
Chord = 6, | ||
|
||
/// <summary> | ||
/// is @ref ScaleEvent | ||
/// </summary> | ||
Scale = 7, | ||
|
||
/// <summary> | ||
/// is @ref LegacyMIDICCOutEvent | ||
/// </summary> | ||
LegacyMIDICCOut = 65535, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.