locked
Windows 8 WinRT C++ Mixing code.

    Question

  • As I digest all this stuff questions came quickly to mind.

    Does anyone know of a channel9 video that mentions interaction between char arrays HWindows etc and the new WinRT types?

    I know they have a string object but what if I have a char array? Or need to put the string into a char array?

    What if I have code to dump uncompressed video data to the screen?

    How do I place that onto a WinRT window?

    Is there a talk on OLD versus new and what the speed impact is of using the new versus using the new?

    In other words with all the HDC's HWindows and other C++ code that has been created over time how do you integrate with this new WinRT beast and whats the performance impact?

    All these things seem so vague dont they?


    bfxtech.com
    Wednesday, September 21, 2011 3:06 PM

Answers

  • The HWND type is not valid in metro style apps - they render using XAML or DirectX, and HWNDs aren't valid for either of those presentation frameworks.  You can have an array of unsigned chars - IVector<unsigned char> if you want to represent an array of bytes (I'm assuming you really meant unsigned chars, not signed characters).

    You can use the media rendering engine (in Windows.Media) to render that video stream on the screen.  In general, rendering video using the media engine will be faster than rendering video using GDI.

     

    Saturday, September 24, 2011 4:29 PM

All replies

  • Hello Btasa,

     

    This thread was created in the Windows Developer Preview: General OS questions  forum; the Microsoft Moderation team has moved this thread to the Building Metro style apps with C++  forum.


    Steven
    Friday, September 23, 2011 8:47 PM
  • C++/CLI is not supported yet.

    To pass a string array: IVector<String^>^

    dump uncompressed video data: I think you need to use Windows Media Foundation



    The following is signature, not part of post
    Please mark the post answered your question as the answer, and mark other helpful posts as helpful, so they will appear differently to other users who are visiting your thread for the same problem.
    Visual C++ MVP
    Saturday, September 24, 2011 12:39 AM
  • The HWND type is not valid in metro style apps - they render using XAML or DirectX, and HWNDs aren't valid for either of those presentation frameworks.  You can have an array of unsigned chars - IVector<unsigned char> if you want to represent an array of bytes (I'm assuming you really meant unsigned chars, not signed characters).

    You can use the media rendering engine (in Windows.Media) to render that video stream on the screen.  In general, rendering video using the media engine will be faster than rendering video using GDI.

     

    Saturday, September 24, 2011 4:29 PM