SharpMetal 1.0.0-preview21
See the version list below for details.
dotnet add package SharpMetal --version 1.0.0-preview21
NuGet\Install-Package SharpMetal -Version 1.0.0-preview21
<PackageReference Include="SharpMetal" Version="1.0.0-preview21" />
<PackageVersion Include="SharpMetal" Version="1.0.0-preview21" />
<PackageReference Include="SharpMetal" />
paket add SharpMetal --version 1.0.0-preview21
#r "nuget: SharpMetal, 1.0.0-preview21"
#:package SharpMetal@1.0.0-preview21
#addin nuget:?package=SharpMetal&version=1.0.0-preview21&prerelease
#tool nuget:?package=SharpMetal&version=1.0.0-preview21&prerelease
Why?
The .NET ecosystem is very much lacking a good Metal binding package. Existing options are outdated or don't integrate well into cross-platform projects. This project aims to be a complete, up-to-date package that stays true to the original API while making the API easy to use and integrate into C#.
What can you make with it?
Progress is underway to build a full set of working reimplementations of the metal-cpp samples. Thanks to the generator, the entire Metal API, from compute shaders to raytracing, should be available, although specific things may take further tweaking.
I want to contribute!
Wonderful! SharpMetal is built with .NET 8.0, and follows a couple of specific guidelines:
- Block Namespaces
- Source Generated P/Invokes
LibraryImportnotDllImport
- Use C# types where possible
NSInteger→longNSUInteger→ulong
- Mark structs and classes with
SupportedOSPlatformattribute - SharpMetal is built for macOS primarily, so when there are platform-specific differences, use the macOS option
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- No dependencies.
NuGet packages (2)
Showing the top 2 NuGet packages that depend on SharpMetal:
| Package | Downloads |
|---|---|
|
OpenUsd.Rendering.Silk.Metal
Metal backend for the OpenUsd Silk.NET renderer. |
|
|
OpenUsd.Viewer
Avalonia viewport and inspector shell for OpenUSD stages, embeddable on a caller-owned stage scheduler. |
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on SharpMetal:
| Repository | Stars |
|---|---|
|
AvaloniaUI/NImpeller
|
| Version | Downloads | Last Updated | |
|---|---|---|---|
| 1.1.0 | 12,641 | 11/2/2025 | |
| 1.0.0-preview21 | 17,905 | 12/28/2024 |