是的DirectX和OpenGL 3D WPF良好替代复杂的应用程序吗? [英] Is WPF 3D good alternate of DirectX and OpenGL for complex applications?

查看:1630
本文介绍了是的DirectX和OpenGL 3D WPF良好替代复杂的应用程序吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经用了学习WPF的3D功能,以及几个实现,并且我发现它是非常有能力,而且我也学习的DirectX 11,并且相比,使用3D类WPF是非常棘手的。我只用WPF 3D非常基本的东西,我的问题是:

I have used WPF's 3D capabilities for learning, and for a few implementations, and I have found it to be very capable, and I am also learning DirectX 11, and it is very tricky compared to using 3D classes in WPF. I have only used WPF 3D for very basic stuff, my question is:

时的WPF 3D的高级应用,如3D建模工具,游戏引擎和三维模拟等同样美好,它替代DirectX和OpenGL?

Is WPF 3D equally good for advanced applications such as 3D modelling tools, game engines and 3D simulations etc to be an alternative to DirectX and OpenGL?

如果有什么东西在同一联赛,请注明这一点。

If there is anything else in the same league, please mention it too.

推荐答案

好问题。答案是这取决于

在一个更有用的音符,我可以这样说:几年前我开发在OpenGL一个CAD风格的3D渲染的应用程序。这不得不显示石油钻井平台的CAD模型具有高达百万对象,并允许用户进行放大右细节,或缩小,移动对象等...我可以与一些肯定地说,WPF将不适合本应用的类型,这纯粹是太慢了。这个应用程序是使用C ++ / CLI开发和桥接从.NET图形用户界面(工具栏,窗口)到C ++ OpenGL的(渲染表面),甚至是推出了性能本地C ++ / OpenGL应用程序撞了过来,由于的的thunk 。所以,如果你想要的是最高性能,的你不能击败原生C ++与DirectX或OpenGL。

On a more useful note I can say this: A few years ago I developed a CAD-style 3D rendering application in OpenGL. This had to display CAD models of oil rigs with up to 1,000,000 objects and allow the user to zoom right in to detail, or zoom out, move objects etc... I can say with some certainty that WPF wouldn't be suitable for this type of application as it would just be too slow. This application was developed using C++/CLI and bridged from a .NET GUI (Toolbar, window) to C++ to OpenGL (render surface) and even that introduced a performance hit over a native C++/OpenGL application due to thunking. So, if you want the highest performance, you cannot beat native C++ with DirectX or OpenGL.

WPF能够提供高性能的3D图形和流畅的交互更简单的3D应用程序。例如,一个三维图面或3D旋转木马,甚至是三维CAD模型查看器,只要该模型是相当简单的。一旦对象开始计数来壮大你会发现渲染引擎无法处理它 - 当你需要切换到一个渲染引擎,支持直接访问GPU那。

WPF can provide high performance 3D graphics and smooth interactivity for simpler 3D applications. For instance, a 3D chart surface or a 3D carousel, even a 3D CAD model viewer so long as the model was fairly simple. Once the object count starts to ramp up you will notice the rendering engine can't handle it - that's when you need to switch to a rendering engine that allows direct access to the GPU.

有关中途之家的解决方案(管理+的DirectX),尝试 SlimDx 。这基本上是托管DirectX一个开源实现,是非常强大和灵活的。托管与本地C ++的性能损失较小(约5%),右完成后,托管DirectX可以是非常高性能的​​。

For a halfway house solution (managed + DirectX), try SlimDx. This is basically an open source implementation of Managed DirectX and is extremely powerful and versatile. The performance hit of managed vs. native C++ is minor (~5%) and when done right, managed DirectX can be extremely performant.

有关WPF3D的展示,我建议你试试此链接。正如你看到WPF3D可以非常直观感染力和有时复杂的例子,但你不会找到任何百万对象石油钻井平台在那里;)

For a showcase of WPF3D I suggest you try this link. As you notice WPF3D can make extremely visually appealling and sometimes complex examples but you won't find any 1,000,000 object oil rigs in there ;)

最后,它是什么,你想要做的WPF 3D?刚兴趣点或者你有一个具体的项目实施,并想知道这将是合适的?

Finally, what is it that you wanted to do in WPF 3D? Just a point of interest or do you have a specific project to implement and want to know if it would be suitable?

最好的问候,

这篇关于是的DirectX和OpenGL 3D WPF良好替代复杂的应用程序吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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