1
\$\begingroup\$

I am creating my first Windows Store application in XAML, and I cannot seem to find a proper example for the requirements I have.

The basic idea of the app is to have a large scrollable canvas which would lazily start animating visible parts of the view as soon as user stops panning over a certain content (with some audio played also):

As the user pans to the right, new content is revealed and animations start when panning stops for a moment

My original idea was to use a StackPanel to add a bunch of custom controls, each of which would then animate itself once visible (with a short delay), but I have a couple of concerns:

  1. If the entire canvas is ~50 screen widths wide, is it feasible to load all content at the beginning, or do I need to plan doing some lazy loading during scrolling? For example, when I select a certain region in the Bing Travel app, it seems to lazily load tiles as I scroll it towards the end.

  2. Since content is stretched 100% vertically, and these animations are vectorized to be resolution independent, I am not sure if XAML (CompositionTarget) will be able to handle this, or I have to go for DirectX (MonoGame or C++) to get rid of flicker.

  3. Even better, is there an example for Windows 8 which uses a 100% vertically sized GridView with custom animated controls inside?

\$\endgroup\$
1
\$\begingroup\$

If you want to render game content in Windows Store App the best way to do this is SwapChainBackgroundPanel (Windows 8), SwapChainPanel (Windows 8.1)

I think this is what you are looking for.

\$\endgroup\$
  • \$\begingroup\$ Thanks. Although, it seems like in Windows 8.1 the SwapChainBackgroundPanel has become pretty much obsolete with the introduction of the SwapChainPanel class. \$\endgroup\$ – Groo Nov 12 '13 at 13:24
  • \$\begingroup\$ Agreed. Updated answer so it's less confusing. \$\endgroup\$ – Lufi Nov 12 '13 at 13:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.