locked
DirectX and WinRT XAML in one app? RRS feed

  • Question

  • Is it possible to use both DirectX and WinRT XAML in one application? Suppose I want to use WinRT XAML for the bulk of my UI, but have one control rendered using DirectX. Can I do this? Are there any samples to demonstrate this?

    Thanks!

    Friday, September 16, 2011 2:17 PM

Answers

  • Hi Samuel,

    This is an area we have heard a lot of requests for, especially with the introduction of XAML and C++ support.  Right now we don't support this in the preview, however you should know we are aware of this constraint/desire and are working on ways to enable/improve the interop between XAML/DirectX for WinRT.


    Tim Heuer | Program Manager, XAML | http://timheuer.com/blog/ | @timheuer
    Friday, September 16, 2011 2:36 PM

All replies

  • Hi Samuel,

    This is an area we have heard a lot of requests for, especially with the introduction of XAML and C++ support.  Right now we don't support this in the preview, however you should know we are aware of this constraint/desire and are working on ways to enable/improve the interop between XAML/DirectX for WinRT.


    Tim Heuer | Program Manager, XAML | http://timheuer.com/blog/ | @timheuer
    Friday, September 16, 2011 2:36 PM
  • Thanks Tim.

    In my view, this should be given pretty high priority, considering that there doesn't appear to be any direct-mode drawing support ala DrawingContext in WPF.

    Friday, September 16, 2011 2:38 PM
  • lack of such support prevented my company from porting our product to Windows Phone - it was available for all WinCE based systems. This is a must feature for apps like navigation system. Suppose we want to publish our application in Win8 appstore, what technologies should we use? We need to be able to render very fast with the use of DirectX/OGL or at least have some kind of direct (very fast) access to frame buffer, and also we want to make use of Metro UI - by that I mean we do not want to write whole UI from scratch in DirectX.

     

    [edit]: I should have added that we are using C++

    thnx


    • Edited by luskan2 Thursday, October 6, 2011 7:33 AM important fact missing
    Thursday, October 6, 2011 6:43 AM
  • My company needs it as well. Ideally we need access to DX11 device object which is used internally for rendering by all other XAML UI elements including MediaObject. I don’t like the idea of D3DImage from .Net. It is too restrictive.

    Thanks


    Mikhail
    Friday, December 16, 2011 7:47 PM
  • Just adding to the use cases: I'd like to be able to build our rendering engine entirely in native DirectX code, and render to either a XAML or HTML surface element. So basically I provide the native implementation as a 3rd party library, and other developers will use that component within either their C#/XAML-based UI, or as an element in their JS/HTML-based UI.
    Friday, December 16, 2011 8:14 PM
    • Proposed as answer by Nitin Suri ' Friday, June 1, 2012 9:30 PM
    Friday, June 1, 2012 9:28 PM