Demonstrates some flexibility available with SwapChainPanel in Windows 8.1 #223
Conversation
…teForSizeChange is called on panel.SizeChanged instead of Window.Current.CoreWindow.SizeChanged.
… is done by SwapChainPanelTarget itself.
…age a normal Page and no more SwapChainPanel
…enderer because Exception was thrown in desinger)
Please wait with a pull. i just checked the other examples, and with changes in SwapChainPanelTarget they obviously don't work any more. I will remove them completely, as they are pointless now anyway and this also further reduces duplicate code in Windows 8.1 Samples. |
Done. You may pull now. This removes all Projects from Win81 Samples and lets just one Sample remain. This sample (another MiniCubeXaml) shows how SwapChainPanel can be used now appearing anywhere as XAML-panel. |
Merged. I had to do some fixes (8bf3955) in order to make the sample compilable, also I have removed the MiniCube project as it wasn't included in any solution. |
Thanks. Please consider duplicating my changes in CubeRenderer.cs in other Projects using CubeRenderer. When used in Designer (VS or Blend) the corresponding Shaders can't be found. This makes the UI-Elements to be hard to edit there. Or wait and I will improve my CubeRenderer.cs with an clean fix like this, instead of just catching the FileNotFoundException: |
Thanks for contribution. If you could provide a fix - that would be great. Feel free to open a new pull request when it's ready. |
I will open a new pull request once I have a clean fix for this as described in the link above. |
It does so by changing MiniCubeXaml-Sample. For rendering the Window-Background is not used any-more, a custom UserControl is used. MainPage equps it with TextBlock in front, back and even as content. Panel is rotated and scaled. Scaling makes the rendering blurry, in further Samples/Versions it might be interesting to compensate it.