与Fusion有关的两个问题可能是相关的 [英] Two issues with Fusion that might be related

查看:79
本文介绍了与Fusion有关的两个问题可能是相关的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试调试Fusion导致我的应用程序崩溃的问题。我正在重建我的网格。这似乎工作正常,但是当我在网格上调用GetVertices()方法时,我的应用程序在本机代码中崩溃:

I'm trying to debug an issue with Fusion that causes my application to crash. I'm generating a mesh from my reconstruction. That seems to work fine but when I call the GetVertices() method on the mesh my application crashes in the native code:

"此API已从HRESULT返回异常:0x80004005"

"This API has returned an exception from an HRESULT: 0x80004005"

我试图删除所有异步代码,甚至在UI线程上调度操作但仍然是同样的错误。

I've tried to remove all async code and even dispatch the operation on the UI thread but still the same error.

当我尝试它可以在示例代码KinectFusionExplorer中使用相同的操作。

When I try the same operation in the sample code KinectFusionExplorer it works.

我注意到编译器抱怨处理器架构时出现以下警告:

I notice that the compiler complains about the processor architecture with the following warning:

警告  1  ;正在构建的项目的处理器体系结构与"MSIL"之间存在不匹配。以及参考"Microsoft.Kinect.Fusion,Version = 2.0.0.0,Culture = neutral,PublicKeyToken = 31bf3856ad364e35,
processorArchitecture = AMD64","AMD64"的处理器体系结构。这种不匹配可能会导致运行时故障。请考虑通过Configuration Manager更改项目的目标处理器体系结构,以便在项目和引用的
之间调整处理器体系结构,或者依赖于具有与项目的目标处理器体系结构相匹配的处理器体系结构的引用。

Warning 1 There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "Microsoft.Kinect.Fusion, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=AMD64", "AMD64". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project.

在一个并行项目中我得到几乎相同,但知道它抱怨'x86':

In a parallel project I get almost the same but know it complains about 'x86':

警告  2 之间存在不匹配正在构建的项目的处理器体系结构"MSIL"以及参考"Microsoft.Kinect.Fusion,Version = 2.0.0.0,Culture = neutral,PublicKeyToken = 31bf3856ad364e35,
processorArchitecture = AMD64","x86"的处理器体系结构。这种不匹配可能会导致运行时故障。请考虑通过Configuration Manager更改项目的目标处理器体系结构,以便在项目和引用的
之间调整处理器体系结构,或者依赖于具有与项目的目标处理器体系结构相匹配的处理器体系结构的引用。 

Warning 2 There was a mismatch between the processor architecture of the project being built "MSIL" and the processor architecture of the reference "Microsoft.Kinect.Fusion, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=AMD64", "x86". This mismatch may cause runtime failures. Please consider changing the targeted processor architecture of your project through the Configuration Manager so as to align the processor architectures between your project and references, or take a dependency on references with a processor architecture that matches the targeted processor architecture of your project. 

两个项目都设置为'任何CPU'

Both project are set to build for 'Any CPU'

如果我的目标是x64,我可以获得警告消失但似乎与SDK样本在没有警告的情况下为AnyCPU编译的事实奇怪地相关,我可以在该代码中毫无困难地调用GetVertices()。此外,当我定位
x64时,我的代码仍会崩溃。

I can get the warnings to disappear if I target x64 but it seems oddly correlated to the fact that the SDK sample compiles for AnyCPU without warning and I can call GetVertices() without any trouble in that code. Also, my code still crashes when I target x64.

任何想法?

问候,

/ Peter

推荐答案

从它的声音来看,它很可能是一个32位对比64位版本的KinectFusion / Kinect.Face dlls。

From the sound of it, it's most likely a 32bit vs 64bit version of the KinectFusion/ Kinect.Face dlls.

你能否确认你正在使用 这些dll的正确版本是否适用于正确的目标架构?

Can you verify that you're using the  correct version of these dlls' for the correct targeted architecture?

使用与Sample相同的dll并测试项目中不同的架构目标平台,看看是否有帮助。

Use the same dll that the Sample uses and test your different architecture targed platforms in your project and see if that helps.

我似乎记得SDK没有明确指定DLL是32位还是64位,除了输出文件夹。因此,您只需要确保在正确的平台上使用正确的平台。

I seem to remember that the SDK doesn't explicitly specify if the DLL's are 32 bit or 64bit, except by way of the output folders. So you just need to make sure you're using the correct one for the correct platform.


这篇关于与Fusion有关的两个问题可能是相关的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆