2dog.avalonia
4.7.1.71
dotnet add package 2dog.avalonia --version 4.7.1.71
NuGet\Install-Package 2dog.avalonia -Version 4.7.1.71
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="2dog.avalonia" Version="4.7.1.71" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="2dog.avalonia" Version="4.7.1.71" />
<PackageReference Include="2dog.avalonia" />
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add 2dog.avalonia --version 4.7.1.71
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: 2dog.avalonia, 4.7.1.71"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package 2dog.avalonia@4.7.1.71
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=2dog.avalonia&version=4.7.1.71
#tool nuget:?package=2dog.avalonia&version=4.7.1.71
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
2dog.avalonia
Embed a Godot viewport inside an Avalonia application.
GodotControl brings the engine's rendered output into Avalonia's compositor, so ordinary
Avalonia controls – panels, buttons, popups – render on top of the running game.
var session = new GodotSession(new GodotSessionOptions
{
Project = "mygame",
Path = Engine.ResolveContent(),
});
godotControl.Session = session;
session.Start();
- The session owns the engine (one per process) and pumps frames on the Avalonia UI thread.
- The control is a view: it can be attached, detached, and re-parented freely.
- On natives with texture-sharing support the viewport is composited zero-copy on the GPU
(D3D11 shared textures on Windows, Vulkan external memory on Linux, IOSurface on macOS);
otherwise a CPU readback fallback is used automatically (
GodotSessionOptions.PresentationMode). - Dispose the session before the application exits (e.g. in
Window.OnClosing).
Requires the 2dog.engine package (pulled in automatically) and Avalonia 12.1.1+.
On Windows, declare DPI awareness in your app manifest (the scaffolded host does) so the
engine's own DPI call cannot desync Avalonia's scaling mid-run.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net10.0
- 2dog.engine (>= 4.7.1.71)
- Avalonia (>= 12.1.1)
- Silk.NET.Direct3D11 (>= 2.22.0)
- Silk.NET.DXGI (>= 2.22.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.