新しいコンソールアプリケーションまたはWinFormsアプリケーションを作成し、AssimpNet(バージョン3.3.2)用のNuGetパッケージを追加することができますが、何らかの理由で新鮮なものから3Dファイルをロードしようとすると私は次の例外を取得するASP.NETのWeb APIプロジェクト:ASP.NETでAssimpNetを使用できない
例外:
Error loading unmanaged library from path: Assimp32.dll, see inner exception for details.The specified module could not be found. (Exception from HRESULT: 0x8007007E)`
内部例外:
The specified module could not be found. (Exception from HRESULT: 0x8007007E)`
私はAnyCPU、x86用の私のプロジェクトをコンパイルしようとしています、x64と同じ結果が得られます。この例外は、ライブラリを使用しようとするとスローされます。他のエンドポイントも正常に動作し、すべての警告なしですべてがコンパイルされます。新しいASP.NET Web APIプロジェクトを使用してこの問題を一貫して再現できます。
ご協力いただければ幸いです。
完全なエラーメッセージとスタックトレースは次のとおりです。
An error has occurred.Error loading unmanaged library from path: Assimp32.dll, see inner exception for details.
The specified module could not be found. (Exception from HRESULT: 0x8007007E)Assimp.AssimpException at Assimp.Unmanaged.AssimpLibraryWindowsImplementation.NativeLoadLibrary(String path)
at Assimp.Unmanaged.AssimpLibraryImplementation.LoadAssimpLibrary(String path)
at Assimp.Unmanaged.AssimpLibrary.LoadLibrary()
at Assimp.Unmanaged.AssimpLibrary.CreatePropertyStore()
at Assimp.AssimpContext.CreateConfigs()
at Assimp.AssimpContext.ImportFile(String file, PostProcessSteps postProcessFlags)
at Assimp.AssimpContext.ImportFile(String file)
at AssimpTest.Controllers.ValuesController.Get(Int32 id) in c:\users\eric\documents\visual studio 2015\Projects\AssimpTest\AssimpTest\Controllers\ValuesController.cs:line 21
at lambda_method(Closure , Object , Object[])
at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass10.<GetExecutor>b__9(Object instance, Object[] methodParameters)
at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.Execute(Object instance, Object[] arguments)
at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary`2 arguments, CancellationToken cancellationToken)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Web.Http.Controllers.ApiControllerActionInvoker.<InvokeActionAsyncCore>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Web.Http.Controllers.ActionFilterResult.<ExecuteAsync>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Web.Http.Controllers.AuthenticationFilterResult.<ExecuteAsync>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Web.Http.Dispatcher.HttpControllerDispatcher.<SendAsync>d__1.MoveNext()An error has occurred.The specified module could not be found. (Exception from HRESULT: 0x8007007E)System.IO.FileNotFoundException