Skip to content

Commit 1369dfd

Browse files
authored
Merge branch 'develop/3.0' into feature/bool-field-property-transformation
2 parents 07a0532 + 0080d4f commit 1369dfd

103 files changed

Lines changed: 7633 additions & 2483 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.silktouch/sdl-clangsharp.stout

9.18 KB
Binary file not shown.

Directory.Packages.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<!-- Analyzers -->
2222
<PackageVersion Include="Microsoft.CodeAnalysis.Analyzers" Version="3.12.0-beta1.25218.8" />
2323
<!-- SilkTouch -->
24-
<PackageVersion Include="ClangSharp.PInvokeGenerator" Version="20.1.2.4" />
24+
<PackageVersion Include="ClangSharp.PInvokeGenerator" Version="21.1.8.3" />
2525
<PackageVersion Include="CSharpier.Core" Version="0.30.2" />
2626
<PackageVersion Include="Humanizer.Core" Version="2.14.1" />
2727
<PackageVersion Include="Microsoft.Build.Locator" Version="1.11.1" />

Silk.NET.sln

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,13 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "CSharp", "CSharp", "{12B4D1
116116
EndProject
117117
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "OpenAL", "OpenAL", "{662A1AEC-91F2-48FA-AA29-6F27038D30F2}"
118118
EndProject
119-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tutorial001.HelloSound", "examples\CSharp\OpenAL\Tutorial001.HelloSound\Tutorial001.HelloSound.csproj", "{946C912C-5BBB-446A-A566-0D1696D19F59}"
119+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OpenAL.Tutorial001.HelloSound", "examples\CSharp\OpenAL\Tutorial001.HelloSound\OpenAL.Tutorial001.HelloSound.csproj", "{946C912C-5BBB-446A-A566-0D1696D19F59}"
120+
EndProject
121+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SDL.Tutorial001.HelloWindow", "examples\CSharp\SDL\Tutorial001.HelloWindow\SDL.Tutorial001.HelloWindow.csproj", "{3444151F-2DE3-41BC-B5E0-EFBF0091C087}"
122+
EndProject
123+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "SDL", "SDL", "{96567E92-4A89-4AC8-9F20-C2A3FE644D10}"
124+
EndProject
125+
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Silk.NET.OpenAL.Soft.Native", "sources\OpenAL\Soft.Native\Silk.NET.OpenAL.Soft.Native.csproj", "{72256365-2C76-4E60-9CF0-A4FFF6F3843F}"
120126
EndProject
121127
Global
122128
GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -196,7 +202,15 @@ Global
196202
{946C912C-5BBB-446A-A566-0D1696D19F59}.Debug|Any CPU.Build.0 = Debug|Any CPU
197203
{946C912C-5BBB-446A-A566-0D1696D19F59}.Release|Any CPU.ActiveCfg = Release|Any CPU
198204
{946C912C-5BBB-446A-A566-0D1696D19F59}.Release|Any CPU.Build.0 = Release|Any CPU
199-
EndGlobalSection
205+
{3444151F-2DE3-41BC-B5E0-EFBF0091C087}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
206+
{3444151F-2DE3-41BC-B5E0-EFBF0091C087}.Debug|Any CPU.Build.0 = Debug|Any CPU
207+
{3444151F-2DE3-41BC-B5E0-EFBF0091C087}.Release|Any CPU.ActiveCfg = Release|Any CPU
208+
{3444151F-2DE3-41BC-B5E0-EFBF0091C087}.Release|Any CPU.Build.0 = Release|Any CPU
209+
{72256365-2C76-4E60-9CF0-A4FFF6F3843F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
210+
{72256365-2C76-4E60-9CF0-A4FFF6F3843F}.Debug|Any CPU.Build.0 = Debug|Any CPU
211+
{72256365-2C76-4E60-9CF0-A4FFF6F3843F}.Release|Any CPU.ActiveCfg = Release|Any CPU
212+
{72256365-2C76-4E60-9CF0-A4FFF6F3843F}.Release|Any CPU.Build.0 = Release|Any CPU
213+
EndGlobalSection
200214
GlobalSection(SolutionProperties) = preSolution
201215
HideSolutionNode = FALSE
202216
EndGlobalSection
@@ -235,6 +249,9 @@ Global
235249
{946C912C-5BBB-446A-A566-0D1696D19F59} = {662A1AEC-91F2-48FA-AA29-6F27038D30F2}
236250
{5E20252F-E2A0-46C9-BBEF-4CE5C96D0E07} = {DD29EA8F-B1A6-45AA-8D2E-B38DA56D9EF6}
237251
{E5E8FFBF-1319-4D33-B084-E732656E8A04} = {5E20252F-E2A0-46C9-BBEF-4CE5C96D0E07}
252+
{96567E92-4A89-4AC8-9F20-C2A3FE644D10} = {12B4D1CB-8938-4EC4-8895-79C4E6ABD1E8}
253+
{3444151F-2DE3-41BC-B5E0-EFBF0091C087} = {96567E92-4A89-4AC8-9F20-C2A3FE644D10}
254+
{72256365-2C76-4E60-9CF0-A4FFF6F3843F} = {AF13F7C9-4EE2-403E-B3D2-C4C2E45D9EF3}
238255
EndGlobalSection
239256
GlobalSection(ExtensibilityGlobals) = postSolution
240257
SolutionGuid = {78D2CF6A-60A1-43E3-837B-00B73C9DA384}

eng/native/cmake/zig-toolchain.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ if(ZIG_OS STREQUAL "linux")
4545
set(PKG_CONFIG_EXECUTABLE "/usr/bin/${ZIG_ARCH}-${ZIG_OS}-${LINUX_ABI}-pkg-config")
4646
set(ENV{PKG_CONFIG_LIBDIR} "/usr/lib/${ZIG_ARCH}-${ZIG_OS}-${LINUX_ABI}/pkgconfig")
4747
set(ENV{PKG_CONFIG_PATH} "/usr/lib/pkgconfig:/usr/share/pkgconfig")
48-
set(CMAKE_FIND_ROOT_PATH "/usr/${ZIG_ARCH}-${ZIG_OS}-${LINUX_ABI}")
48+
set(CMAKE_LIBRARY_ARCHITECTURE "${ZIG_ARCH}-${ZIG_OS}-${LINUX_ABI}")
4949
set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
5050
set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY BOTH)
5151
set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE BOTH)

eng/submodules/sdl

Submodule sdl updated 1645 files

examples/CSharp/OpenAL/Tutorial001.HelloSound/Tutorial001.HelloSound.csproj renamed to examples/CSharp/OpenAL/Tutorial001.HelloSound/OpenAL.Tutorial001.HelloSound.csproj

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,15 @@
55
<TargetFramework>net10.0</TargetFramework>
66
<ImplicitUsings>enable</ImplicitUsings>
77
<Nullable>enable</Nullable>
8+
9+
<!-- Ensure native binaries are copied when referencing Silk by ProjectReference -->
10+
<!-- See: https://dotnet.github.io/Silk.NET/docs/v3/for-contributors/build-system#native-packaging -->
11+
<RuntimeIdentifier Condition="'$(RuntimeIdentifier)' == ''">$(NETCoreSdkRuntimeIdentifier)</RuntimeIdentifier>
812
</PropertyGroup>
913

1014
<ItemGroup>
1115
<ProjectReference Include="..\..\..\..\sources\OpenAL\OpenAL\Silk.NET.OpenAL.csproj" />
16+
<ProjectReference Include="..\..\..\..\sources\OpenAL\Soft.Native\Silk.NET.OpenAL.Soft.Native.csproj" />
1217
</ItemGroup>
1318

1419
<ItemGroup>

examples/CSharp/OpenAL/Tutorial001.HelloSound/Program.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1-
using NAudio.Wave;
1+
// Licensed to the .NET Foundation under one or more agreements.
2+
// The .NET Foundation licenses this file to you under the MIT license.
3+
4+
using NAudio.Wave;
25
using Silk.NET.OpenAL;
36

47
// NOTE: If you prefer, you can use the static ALContext and AL functions instead of creating an API object!
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
// Licensed to the .NET Foundation under one or more agreements.
2+
// The .NET Foundation licenses this file to you under the MIT license.
3+
4+
using Silk.NET.SDL;
5+
6+
if (!Sdl.Init(Sdl.InitVideo))
7+
{
8+
throw new Exception($"SDL failed to initialize: {Sdl.GetError().ReadToString()}");
9+
}
10+
11+
var window = Sdl.CreateWindow("Silk.NET.SDL - Hello Window", 800, 600, Sdl.WindowResizable);
12+
if (window == nullptr)
13+
{
14+
throw new Exception("Failed to create window");
15+
}
16+
17+
try
18+
{
19+
var renderer = Sdl.CreateRenderer(window, nullptr);
20+
{
21+
var shouldRun = true;
22+
while (shouldRun)
23+
{
24+
var e = default(Event);
25+
Sdl.PollEvent(e.AsRef());
26+
27+
if (e.Type == (uint)EventType.Quit)
28+
{
29+
shouldRun = false;
30+
}
31+
32+
Sdl.SetRenderDrawColor(renderer, 0, 255, 0, 255);
33+
Sdl.RenderClear(renderer);
34+
Sdl.RenderPresent(renderer);
35+
}
36+
}
37+
Sdl.DestroyWindow(window);
38+
}
39+
finally
40+
{
41+
Sdl.Quit();
42+
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<OutputType>Exe</OutputType>
5+
<TargetFramework>net10.0</TargetFramework>
6+
<ImplicitUsings>enable</ImplicitUsings>
7+
<Nullable>enable</Nullable>
8+
9+
<!-- Ensure native binaries are copied when referencing Silk by ProjectReference -->
10+
<!-- See: https://dotnet.github.io/Silk.NET/docs/v3/for-contributors/build-system#native-packaging -->
11+
<RuntimeIdentifier Condition="'$(RuntimeIdentifier)' == ''">$(NETCoreSdkRuntimeIdentifier)</RuntimeIdentifier>
12+
</PropertyGroup>
13+
14+
<ItemGroup>
15+
<ProjectReference Include="..\..\..\..\sources\SDL\SDL\Silk.NET.SDL.csproj" />
16+
</ItemGroup>
17+
18+
</Project>

sources/OpenAL/OpenAL/AL.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,17 @@ namespace Silk.NET.OpenAL;
77

88
public partial class AL
99
{
10-
static AL() =>
10+
static AL()
11+
{
1112
LoaderInterface.RegisterAlternativeName(
1213
"openal",
1314
"/System/Library/Frameworks/OpenAL.framework/OpenAL"
1415
);
1516

17+
LoaderInterface.RegisterAlternativeName("openal", "OpenAL32");
18+
LoaderInterface.RegisterAlternativeName("openal", "soft_oal");
19+
}
20+
1621
public partial class ThisThread
1722
{
1823
private static partial IAL ContextFactory() =>

0 commit comments

Comments
 (0)