Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add DAW Integration #1266

Open
wants to merge 55 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
4511705
Add: Add Vst.Client
sevenc-nanashi Sep 1, 2024
03830c0
Add: Add Vst.ServerFinder
sevenc-nanashi Sep 3, 2024
2393013
Change: Vst -> DawIntegration
sevenc-nanashi Sep 3, 2024
b2e554b
Fix: I forgot to add files
sevenc-nanashi Sep 3, 2024
bc41223
change: VstServers -> PluginServers
sevenc-nanashi Sep 3, 2024
0dc6cc2
WIP: Adding Server list
sevenc-nanashi Sep 4, 2024
966fdd6
WIP: Reactive not working?
sevenc-nanashi Sep 8, 2024
37decb3
Add: Add dialog
sevenc-nanashi Sep 14, 2024
7c8f336
Add: Support sendinhg
sevenc-nanashi Sep 15, 2024
172d2c2
Add: Add missing file
sevenc-nanashi Sep 15, 2024
41ce80e
WIP: Creating VST
sevenc-nanashi Sep 15, 2024
82c5b94
Add: At least it works
sevenc-nanashi Sep 18, 2024
e00dbf5
Add: At least it works (But performance is poor)
sevenc-nanashi Sep 20, 2024
9875281
Improve: Resample on mixes update
sevenc-nanashi Sep 21, 2024
b535b96
Fix: Add lock
sevenc-nanashi Sep 21, 2024
63db1ae
Improve: Improve locks
sevenc-nanashi Sep 22, 2024
b2215d2
Improve: Send differences only
sevenc-nanashi Sep 23, 2024
15ddf18
Fix: Fix position
sevenc-nanashi Sep 23, 2024
4911be1
Fix: Fix deadlock
sevenc-nanashi Sep 23, 2024
be2b562
Fix: Fix around locking
sevenc-nanashi Sep 23, 2024
f7ca0f0
Fix: Fix crash on disconnect
sevenc-nanashi Sep 25, 2024
0b62231
Delete: Delete xxhash
sevenc-nanashi Sep 25, 2024
871ec73
Add: Add workflow to build vst3
sevenc-nanashi Sep 25, 2024
3aeaf8f
Fix: Fix reference
sevenc-nanashi Sep 25, 2024
0748d75
Fix: Fix condition
sevenc-nanashi Sep 25, 2024
0d0b309
Fix: Fix num of states
sevenc-nanashi Sep 25, 2024
d913f35
Fix: Add workaround for MacOS
sevenc-nanashi Sep 25, 2024
6f49709
Fix: Fix casing
sevenc-nanashi Sep 25, 2024
a1f1124
Fix: Fix rename
sevenc-nanashi Sep 25, 2024
dd6abbf
Fix: Fix name overlap
sevenc-nanashi Sep 25, 2024
ae5f073
Fix: Fix zlib building on macos or ubuntu
sevenc-nanashi Sep 25, 2024
9cad3d2
Fix: Fix build args
sevenc-nanashi Sep 25, 2024
3df9dc2
Fix: Fix compiler version
sevenc-nanashi Sep 25, 2024
5c3d9c0
Fix: Use gcc 13
sevenc-nanashi Sep 25, 2024
5457c30
Fix: Fix condition
sevenc-nanashi Sep 25, 2024
5dc5da1
Delete: Delete compile_flags.txt
sevenc-nanashi Sep 25, 2024
7e3ebca
Fix: Fix matrix reference
sevenc-nanashi Sep 25, 2024
8986d9f
Fix: Build gcc14
sevenc-nanashi Sep 25, 2024
6c519e4
Fix: Fix package list
sevenc-nanashi Sep 25, 2024
87aaa1d
Fix: Add dependency for building GCC
sevenc-nanashi Sep 25, 2024
87105f7
Improve: Cache gcc
sevenc-nanashi Sep 25, 2024
9694df6
Change: Get gcc from apt
sevenc-nanashi Sep 26, 2024
05004fb
Change: Use gcc
sevenc-nanashi Sep 26, 2024
315e237
Fix: Fix compiler specification
sevenc-nanashi Sep 26, 2024
4029922
Change: Build plugin on mac x64
sevenc-nanashi Sep 26, 2024
dee91ec
Fix: Include thread
sevenc-nanashi Sep 26, 2024
43fe2cd
Fix: Include cfloat
sevenc-nanashi Sep 26, 2024
2416a21
Fix: Fix building arguments
sevenc-nanashi Sep 26, 2024
1770cde
Fix: Fix some compiler differences
sevenc-nanashi Sep 26, 2024
86d1d59
Fix: Add LDFLAGS
sevenc-nanashi Sep 26, 2024
c897709
Add: Add expermintal-library to other options
sevenc-nanashi Sep 26, 2024
d0f0bd5
Add: Add initPortGroup
sevenc-nanashi Sep 26, 2024
33a8277
Change: Change font
sevenc-nanashi Sep 26, 2024
840a530
Merge: upstream/master -> add/vst-integration
sevenc-nanashi Sep 26, 2024
d41be37
Add: Add CLAP ID
sevenc-nanashi Sep 26, 2024
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
114 changes: 73 additions & 41 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
indent_style = space
# Code files
[*.{cs,csx,vb,vbx}]
indent_size = 4
indent_size = 4
insert_final_newline = true
charset = utf-8-bom
guidelines = 100
Expand All @@ -18,74 +18,83 @@ guidelines = 100
# Organize usings
dotnet_sort_system_directives_first = true
# this. preferences
dotnet_style_qualification_for_field = false:silent
dotnet_style_qualification_for_property = false:silent
dotnet_style_qualification_for_method = false:silent
dotnet_style_qualification_for_event = false:silent
dotnet_style_qualification_for_field = false:silent
dotnet_style_qualification_for_property = false:silent
dotnet_style_qualification_for_method = false:silent
dotnet_style_qualification_for_event = false:silent
# Language keywords vs BCL types preferences
dotnet_style_predefined_type_for_locals_parameters_members = true:silent
dotnet_style_predefined_type_for_member_access = true:silent
# Parentheses preferences
dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity:silent
dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity:silent
dotnet_style_parentheses_in_other_binary_operators = always_for_clarity:silent
dotnet_style_parentheses_in_other_operators = never_if_unnecessary:silent
dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity:silent
dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity:silent
dotnet_style_parentheses_in_other_binary_operators = always_for_clarity:silent
dotnet_style_parentheses_in_other_operators = never_if_unnecessary:silent
# Modifier preferences
dotnet_style_require_accessibility_modifiers = for_non_interface_members:silent
dotnet_style_readonly_field = true:suggestion
dotnet_style_require_accessibility_modifiers = for_non_interface_members:silent
dotnet_style_readonly_field = true:suggestion
# Expression-level preferences
dotnet_style_object_initializer = true:suggestion
dotnet_style_collection_initializer = true:suggestion
dotnet_style_explicit_tuple_names = true:suggestion
dotnet_style_null_propagation = true:suggestion
dotnet_style_coalesce_expression = true:suggestion
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:silent
dotnet_style_object_initializer = true:suggestion
dotnet_style_collection_initializer = true:suggestion
dotnet_style_explicit_tuple_names = true:suggestion
dotnet_style_null_propagation = true:suggestion
dotnet_style_coalesce_expression = true:suggestion
dotnet_style_prefer_is_null_check_over_reference_equality_method = true:silent
dotnet_prefer_inferred_tuple_names = true:suggestion
dotnet_prefer_inferred_anonymous_type_member_names = true:suggestion
dotnet_style_prefer_auto_properties = true:silent
dotnet_style_prefer_conditional_expression_over_assignment = true:silent
dotnet_style_prefer_conditional_expression_over_return = true:silent
dotnet_style_prefer_auto_properties = true:silent
dotnet_style_prefer_conditional_expression_over_assignment = true:silent
dotnet_style_prefer_conditional_expression_over_return = true:silent
###############################
# Naming Conventions #
###############################
# Style Definitions
dotnet_naming_style.pascal_case_style.capitalization = pascal_case
# Use PascalCase for constant fields
dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion
dotnet_naming_rule.constant_fields_should_be_pascal_case.symbols = constant_fields
dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style
dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style
dotnet_naming_symbols.constant_fields.applicable_kinds = field
dotnet_naming_symbols.constant_fields.applicable_accessibilities = *
dotnet_naming_symbols.constant_fields.required_modifiers = const
tab_width = 4
dotnet_code_quality_unused_parameters = all:suggestion
dotnet_style_prefer_simplified_boolean_expressions = true:suggestion
dotnet_style_prefer_inferred_tuple_names = true:suggestion
dotnet_style_prefer_inferred_anonymous_type_member_names = true:suggestion
dotnet_style_prefer_simplified_interpolation = true:suggestion
dotnet_style_prefer_compound_assignment = true:suggestion
dotnet_style_prefer_collection_expression = when_types_loosely_match:suggestion
dotnet_style_namespace_match_folder = true:suggestion
###############################
# C# Coding Conventions #
###############################
[*.cs]
# var preferences
csharp_style_var_for_built_in_types = true:silent
csharp_style_var_when_type_is_apparent = true:silent
csharp_style_var_elsewhere = true:silent
csharp_style_var_for_built_in_types = true:silent
csharp_style_var_when_type_is_apparent = true:silent
csharp_style_var_elsewhere = true:silent
# Expression-bodied members
csharp_style_expression_bodied_methods = false:silent
csharp_style_expression_bodied_constructors = false:silent
csharp_style_expression_bodied_operators = false:silent
csharp_style_expression_bodied_properties = true:silent
csharp_style_expression_bodied_indexers = true:silent
csharp_style_expression_bodied_accessors = true:silent
csharp_style_expression_bodied_methods = false:silent
csharp_style_expression_bodied_constructors = false:silent
csharp_style_expression_bodied_operators = false:silent
csharp_style_expression_bodied_properties = true:silent
csharp_style_expression_bodied_indexers = true:silent
csharp_style_expression_bodied_accessors = true:silent
# Pattern matching preferences
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
# Null-checking preferences
csharp_style_throw_expression = true:suggestion
csharp_style_conditional_delegate_call = true:suggestion
csharp_style_throw_expression = true:suggestion
csharp_style_conditional_delegate_call = true:suggestion
# Modifier preferences
csharp_preferred_modifier_order = public,private,protected,internal,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,volatile,async:suggestion
# Expression-level preferences
csharp_prefer_braces = true:silent
csharp_style_deconstructed_variable_declaration = true:suggestion
csharp_prefer_simple_default_expression = true:suggestion
csharp_prefer_braces = true:silent
csharp_style_deconstructed_variable_declaration = true:suggestion
csharp_prefer_simple_default_expression = true:suggestion
csharp_style_pattern_local_over_anonymous_function = true:suggestion
csharp_style_inlined_variable_declaration = true:suggestion
csharp_style_inlined_variable_declaration = true:suggestion
###############################
# C# Formatting Rules #
###############################
Expand All @@ -100,7 +109,7 @@ csharp_new_line_between_query_expression_clauses = false
# Indentation preferences
csharp_indent_case_contents = true
csharp_indent_switch_labels = true
csharp_indent_labels = flush_left
csharp_indent_labels = flush_left
# Space preferences
csharp_space_after_cast = false
csharp_space_after_keywords_in_control_flow_statements = true
Expand All @@ -109,13 +118,36 @@ csharp_space_between_method_declaration_parameter_list_parentheses = false
csharp_space_between_parentheses = false
csharp_space_before_colon_in_inheritance_clause = true
csharp_space_after_colon_in_inheritance_clause = true
csharp_space_around_binary_operators = before_and_after
csharp_space_around_binary_operators = before_and_after
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
csharp_space_between_method_call_name_and_opening_parenthesis = false
csharp_space_between_method_call_empty_parameter_list_parentheses = false
# Wrapping preferences
csharp_preserve_single_line_statements = true
csharp_preserve_single_line_blocks = true
csharp_using_directive_placement = outside_namespace:silent
csharp_prefer_simple_using_statement = true:suggestion
csharp_style_prefer_top_level_statements = true:silent
csharp_style_prefer_method_group_conversion = true:silent
csharp_style_namespace_declarations = block_scoped:silent
csharp_style_prefer_switch_expression = true:suggestion
csharp_style_prefer_primary_constructors = true:suggestion
csharp_style_prefer_pattern_matching = true:silent
csharp_style_prefer_extended_property_pattern = true:suggestion
csharp_style_prefer_not_pattern = true:suggestion
csharp_prefer_static_local_function = true:suggestion
csharp_prefer_static_anonymous_function = true:suggestion
csharp_style_prefer_readonly_struct = true:suggestion
csharp_style_prefer_readonly_struct_member = true:suggestion
csharp_style_expression_bodied_lambdas = true:silent
csharp_style_expression_bodied_local_functions = false:silent
csharp_style_prefer_null_check_over_type_check = true:suggestion
csharp_style_prefer_local_over_anonymous_function = true:suggestion
csharp_style_prefer_index_operator = true:suggestion
csharp_style_prefer_range_operator = true:suggestion
csharp_style_prefer_tuple_swap = true:suggestion
csharp_style_implicit_object_creation_when_type_is_apparent = true:suggestion
csharp_style_prefer_utf8_string_literals = true:suggestion
###############################
# VB Coding Conventions #
###############################
Expand Down
82 changes: 74 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,19 @@ jobs:
fail-fast: false
matrix:
arch:
- { name: win-x64, rid: win-x64, arch: x64, os: win, runs-on: windows-latest }
- { name: win-x86, rid: win-x86, arch: x86, os: win, runs-on: windows-latest }
- { name: win-arm64, rid: win-arm64, arch: arm64, os: win, runs-on: windows-latest }
- { name: osx-x64, rid: osx.10.14-x64, arch: x64, os: osx, runs-on: macos-13 }
- { name: osx-arm64, rid: osx-arm64, arch: arm64, os: osx, runs-on: macos-13 }
- { name: linux-x64, rid: linux-x64, arch: x64, os: linux, runs-on: ubuntu-latest }
- { name: linux-arm64, rid: linux-arm64, arch: arm64, os: linux, runs-on: ubuntu-latest }
- { name: win-x64, rid: win-x64, arch: x64, os: win, runs-on: windows-latest, daw-plugin: true }
- { name: win-x86, rid: win-x86, arch: x86, os: win, runs-on: windows-latest, daw-plugin: false }
- { name: win-arm64, rid: win-arm64, arch: arm64, os: win, runs-on: windows-latest, daw-plugin: true }
- { name: osx-x64, rid: osx.10.14-x64, arch: x64, os: osx, runs-on: macos-13, daw-plugin: true }
- { name: osx-arm64, rid: osx-arm64, arch: arm64, os: osx, runs-on: macos-13, daw-plugin: true }
- { name: linux-x64, rid: linux-x64, arch: x64, os: linux, runs-on: ubuntu-24.04, daw-plugin: true }
- { name: linux-arm64, rid: linux-arm64, arch: arm64, os: linux, runs-on: ubuntu-24.04, daw-plugin: true }

steps:
# Setup
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: actions/setup-dotnet@v4
with:
dotnet-version: "6.0.x"
Expand All @@ -56,14 +58,64 @@ jobs:
- name: Test
run: dotnet test OpenUtau.Test

# Build
# Build: Main
- name: Restore
run: dotnet restore OpenUtau -r ${{ matrix.arch.rid }}

- name: Publish
run: dotnet publish OpenUtau -c Release -r ${{ matrix.arch.rid }} --self-contained true -o bin/${{ matrix.arch.name }}/
if: ${{ matrix.arch.os != 'osx' }}

# Build: Daw Plugin

- name: Build Daw Plugin (Windows)
run: |
cd ./DawPlugin
cmake -B build -S . -DCMAKE_BUILD_TYPE=Release
cmake --build build --config Release
if: ${{ matrix.arch.daw-plugin && matrix.arch.os == 'win' }}

- name: Build Daw Plugin (Mac)
run: |
cd ./DawPlugin

brew install llvm
export PATH="/usr/local/opt/llvm/bin:$PATH"
export LDFLAGS="-L/usr/local/opt/llvm/lib/c++ -L/usr/local/opt/llvm/lib -lunwind -fexperimental-library"
export CPPFLAGS="-I/usr/local/opt/llvm/include -fexperimental-library"

cmake -B build -S . -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=/usr/local/opt/llvm/bin/clang -DCMAKE_CXX_COMPILER=/usr/local/opt/llvm/bin/clang++ \
-DCMAKE_CXX_FLAGS="-stdlib=libc++ -fexperimental-library"
cmake --build build --config Release
if: ${{ matrix.arch.daw-plugin && matrix.arch.os == 'osx' }}

- name: Build Daw Plugin (Linux)
run: |
cd ./DawPlugin

# Install OpenGL
sudo apt-get install libgl1-mesa-dev

cmake -B build -S . -DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=gcc-14 -DCMAKE_CXX_COMPILER=g++-14
cmake --build build --config Release
if: ${{ matrix.arch.daw-plugin && matrix.arch.os == 'linux' }}

- name: Package Daw Plugin
shell: bash
run: |
cd DawPlugin/build/bin
7z a openutau_daw_plugin-${{ matrix.arch.name }}.vst3.zip openutau_daw_plugin.vst3
if: ${{ matrix.arch.daw-plugin }}

- name: Package Daw Plugin (Mac)
shell: bash
run: |
cd DawPlugin/build/bin
7z a openutau_daw_plugin-${{ matrix.arch.name }}.au.zip openutau_daw_plugin.component
if: ${{ matrix.arch.daw-plugin && matrix.arch.os == 'osx' }}

# Create Zip
- name: DirectML
shell: cmd
Expand Down Expand Up @@ -127,6 +179,18 @@ jobs:
path: OpenUtau-osx-${{ matrix.arch.name }}.dmg
if: ${{ !inputs.release && matrix.arch.os == 'osx' }}

- uses: actions/upload-artifact@v4
with:
name: openutau_daw_plugin-${{ matrix.arch.name }}.vst3.zip
path: DawPlugin/build/bin/openutau_daw_plugin-${{ matrix.arch.name }}.vst3.zip
if: ${{ !inputs.release && matrix.arch.daw-plugin }}

- uses: actions/upload-artifact@v4
with:
name: openutau_daw_plugin-${{ matrix.arch.name }}.au.zip
path: DawPlugin/build/bin/openutau_daw_plugin-${{ matrix.arch.name }}.au.zip
if: ${{ !inputs.release && matrix.arch.daw-plugin && matrix.arch.os == 'osx' }}

# Appcast
- name: Appcast Windows
shell: cmd
Expand Down Expand Up @@ -156,4 +220,6 @@ jobs:
files: |
appcast.${{ matrix.arch.name }}*.xml
OpenUtau-${{ matrix.arch.name }}.*
DawPlugin/build/bin/openutau_daw_plugin-${{ matrix.arch.name }}.vst3.zip
DawPlugin/build/bin/openutau_daw_plugin-${{ matrix.arch.name }}.au.zip
if: ${{ inputs.release }}
24 changes: 24 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
[submodule "DawPlugin/deps/dpf"]
path = DawPlugin/deps/dpf
url = https://github.com/distrho/DPF.git
[submodule "DawPlugin/deps/asio"]
path = DawPlugin/deps/asio
url = https://github.com/chriskohlhoff/asio
[submodule "DawPlugin/deps/dpf_widgets"]
path = DawPlugin/deps/dpf_widgets
url = https://github.com/sevenc-nanashi/DPF-Widgets.git
[submodule "DawPlugin/deps/choc"]
path = DawPlugin/deps/choc
url = https://github.com/Tracktion/choc
[submodule "DawPlugin/deps/uuid-v4"]
path = DawPlugin/deps/uuid-v4
url = https://github.com/rkg82/uuid-v4.git
[submodule "DawPlugin/deps/yamc"]
path = DawPlugin/deps/yamc
url = https://github.com/yohhoy/yamc.git
[submodule "DawPlugin/deps/zlib"]
path = DawPlugin/deps/zlib
url = https://github.com/madler/zlib.git
[submodule "DawPlugin/deps/gzip-hpp"]
path = DawPlugin/deps/gzip-hpp
url = https://github.com/mapbox/gzip-hpp.git
25 changes: 25 additions & 0 deletions DawPlugin/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Created by https://www.toptal.com/developers/gitignore/api/cmake
# Edit at https://www.toptal.com/developers/gitignore?templates=cmake

### CMake ###
CMakeLists.txt.user
CMakeCache.txt
CMakeFiles
CMakeScripts
Testing
Makefile
cmake_install.cmake
install_manifest.txt
compile_commands.json
CTestTestfile.cmake
_deps

### CMake Patch ###
# External projects
*-prefix/

# End of https://www.toptal.com/developers/gitignore/api/cmake

build/
!deps/noto_sans/.gitkeep
deps/noto_sans/*
Loading