我正在尝试使用SharpGL库运行 WPF 应用程序。根据 GitHub 页面上描述的文档,它应该很简单PM> Install-Package SharpGL.WPF
,但是当尝试OpenGLControl
像这样在 xaml中创建一个
<Window x:Class="MapRendering.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:sharpGl="clr-namespace:SharpGL.WPF;assembly=SharpGL.WPF"
mc:Ignorable="d"
Title="MainWindow" Height="450" Width="800">
<Grid>
<DockPanel>
<sharpGl:OpenGLControl/>
</DockPanel>
</Grid>
</Window>
我收到以下程序集参考错误
Could not load file or assembly 'SharpGL.SceneGraph, Version=2.4.1.1, Culture=neutral, PublicKeyToken=27fc851303210b27' or one of its dependencies.
现在我可以从 GitHub 拉取SharpGL.SceneGraph
源代码,通过手动浏览构建和添加 dll。但为什么SharpGL.SceneGraph
dll 不与SharpGL.WPF
? 我错过了什么吗?