HoloLens Development Notes-app model app models

Source: Internet
Author: User
Tags app service unsupported

HoloLens uses the app model provided by Universal Windows Platform (UWP). The UWP app model defines how apps are securely and completely installed, updated, versioned, and removed. It manages the application lifecycle-how applications are executed, hibernate, and interrupted-and how the application state is preserved. It also covers integration and interaction with the operating system, files, and other applications.

App Life cycle App lifecycle

The life cycle of holographic applications involves the concept of standard applications, such as placement. Start, break, and remove.

Placement is the start Placement is launch

Each app is launched in the HoloLens shell by placing an app tile. These application magnets, when placed, will start to run the application. These app tiles persist where they are placed, and you can return to the app from them at any time.

Once the placement is complete (unless the placement is aroused by the app-initiated), the app starts. HoloLens apps can run an app at the same time. Once you have placed and launched an app, any other activated app will be suspended, where you place it, and the app tile will leave its last state. Read the article on the Standard Life cycle to learn more about handling recovery and other life-cycle events.

Remove is to close/terminate processing of remove is close/terminate process

When you remove a placed app tile from the world, this closes the underlying process. This can be useful to ensure that your app is terminated or that a problematic app is restarted.

App suspend/Terminate app Suspension/termination

With HoloLens, users can create multiple boot portals for an app. They do this by launching your app from the Start menu and placing the app's tile in the world. Each app tile behaves as a different boot entry, with a separate tile instance in the system. The Secondarytile.findallasync () query queue will be able to list all applied two-level tiles.

When a UWP app pauses, the screen that applies the current state is fetched.

The key difference with other Windows 10 platforms is that by coreapplication.resuming and coreapplication.activated events, an instance of how the app is notified of it is activated.

Case Recovery Activated
Launch an app new instance from the Start menu Activating the app with a new Tileid
Launch a second app instance from the Start menu Activating the app with a new Tileid
Select an app instance that is not currently active Activating an app using the Tileid of an instance association
Select a different app, and then select the previously activated instance Recovery is triggered
Select a different app, and then select an instance that was not previously activated Recovery is triggered Then activate the app using the Tileid associated with the instance

Extended execution Extended Execution

Sometimes your app needs to continue doing some work or playing sounds in the background. Background tasks are available in Windows holographic, but there are some limitations.

App View app views

When your app is active, you can choose which type of view to display. For an app coreapplication, there's always an initial app view (app view) and any number of other secondary views you want to create. For a desktop environment, you can think of an app view as a window. Our Holographic Application project template will create a unity project in which the initial view is a holographic view. Your app can use techniques like XAML to create additional 2D views to use shell controls such as in-app purchases. If your app starts in a generic application, the initial view will be 2D, but you can add an additional holographic view to enhance the HoloLens experience. Imagine that we built a picture viewer in XAML with a view toggle button that can switch to the holographic view in a single click, and in the holographic view, photos from the app fly to the world and to the surface of the object.

Creating a Hologram View Create a holographic view

A holographic view is an application that creates a holographic view through the Holographicspace type.

2D view in hybrid World 2D views in the Mixed worlds

Any non-holographic view will be rendered as a 2D view in your world.

Secondary view tile placement Placement of further App Tiles

With the two-level tile (secondary tile) API You can place any number of 2D views you want. These placed tiles will appear as splash screens, starting with your app since then. Windows holographic currently does not support rendering any 2D tile as a live tile. You can find more information on the level two tile API (econdary tile APIs) page.

Toggle View Switching views

Switch from a 2D view to a holographic view switching from the 2D XAML view to the holographic view

If the user uses XAML, then XAML Iframeworkviewsource will control the first view of the app. Applications need to switch to a holographic view before activating the Corewindow to ensure that the application goes directly to the holographic experience.

Use Coreapplication::createnewview and applicationviewswitcher::switchasync to switch views.

Attention:

    • Do not specify the consolidate tag for the Switchasync method when you switch from XAML view to a holographic view or an app panel that will be removed from the world
    • The Switchasync method should be called by the dispatcher associated with the view you want to switch to
    • If you need to start a virtual keyboard or want to activate another app, you need to use the Switchasync method to return to the XAML view

Switch from the holographic view to the keyboard XAML view switching from the holographic view back to a keyboard XAML views

Switching between views is often done to display a keyboard in a holographic application. If your app displays a 2D view, the shell can only display the system keyboard. If your app needs to get a text input source, then they'll write a custom XAML view with a text input box that can switch back after it's switched to it.

In the above scenario, you can use Applicationviewswitcher::switchasync to switch back to the XAML view from your holographic view.

App Sizes App Size

The 2D app view always appears in a fixed visual panel. This allows all 2D views to display an equal amount of content. Here are further details about the size of the 2D app view:

    • The aspect ratio of the app is always the same when resizing
    • When resizing, the applied resolution and stretch rate do not change
    • Apps cannot query their actual size in the world

App Tile App Tiles

The Start menu uses the standard small and medium tiles for pin view and all app views.

Interactive app to app interactions

When you build your app, you get a rich inter-application communication mechanism on Windows 10. Even though HoloLens currently does not support the latest Application protocol launch (App service protocol launches), many new protocol APIs and file registration mechanisms ensure that applications are started and communicated across the HoloLens.

Protocol protocols

HoloLens supports inter-application launch via Windows.System.Launcher APIs.

When you start another app, the following is considered:

    • When the non-modal is started, such as Launchuriasync, the user must place it before interacting with the application.
    • Modal applications are placed at the top of the window when the modal is started, such as Launchuriforresultsasync
    • HoloLens cannot be in exclusive view (this should refer to a holographic view?). Top overlay on other apps. In order to display the launched app, HoloLens will use it to go back to the world to show this app.

Document Picker file Pickers

HoloLens supports Fileopenpicker and filesavepicker contracts. Although apps that don't support file selection contracts are preinstalled, you can download them from the Windows store-for example, OneDrive.

If you have multiple file selection apps installed, you won't see any ambiguous UI, which is often used to pick which app to start. Instead, the first installed file picker will be selected. When you save a file, the file name that includes the timestamp is automatically generated. The user cannot change the file love you.

By default, the following are the locally supported file extension formats:

App contract and Windows holographic Extension app contracts and Windows Hologrphic extensions

Application contracts and extension portals allow you to register your app to use the more underlying operating system features, such as processing file extensions or using background tasks. Below is a list of Windows holographic supported contracts and extension portals. This differs from the set of APIs it supports.

Contract or Extension

Contract or expansion

Supported?

is supported

Account picture Provider (extension) Unsupported
Alarm Unsupported
APP Service

Supported but isn't fully functional in the current version of Windows holographic

Supported, but not all features are available for the current version

Appointments Provider Unsupported
AutoPlay (extension) Unsupported
Background Tasks (extension)

Partially supported (not all triggers work on Windows holographic)

Partially supported, current version not all triggers are available

Update Task (extension) Supported
Cached File Updater Contract Supported
Camera Settings (extension) Unsupported
Dial protocol Unsupported
File Activation (extension) Supported
File Open Picker Contract Supported
File Save Picker Contract Supported
Lock Screen Call Unsupported
Media Playback Unsupported
Play to Contract Unsupported
Preinstalled Config Task Unsupported
Print 3D Workflow Supported
Print task Settings (extension) Unsupported
URI Activation (extension) Supported
Restricted Launch Unsupported
Search contract Unsupported
Settings contract Unsupported
Share contract Unsupported
Ssl/certificates (extension) Supported
Web account Provider Supported

App files store app file Storage

All of the storage is implemented through the Windows.storage namespace. Read the following to learn more details. HoloLens does not support app storage synchronization/roaming.

    • Documents, folders and libraries files, folders, and libraries
    • Store and search settings and other application data store and retrieve settings and other app

Known directories known folders

Check out KnownFolders for more details on how UWP apps use KnownFolders.

Property

Property

Supported on HoloLens development Edition

HoloLens Development Board Support

Description

Describe

Appcaptures Yes

Gets the App Captures folder.

Get App Capture folder

Cameraroll Yes

Gets The Camera Roll folder.

Camera folder

Documentslibrary Yes

Gets the Documents library. The Documents library is not a intended for general use.

Document Library

Musiclibrary Yes

Gets the Music library.

Music Library

Objects3d Yes

Gets the Objects 3D folder.

3D Object Folder

Pictureslibrary Yes

Gets the Pictures library.

Photo Gallery

Playlists Yes

Gets the play lists folder.

Play List Folder

Savedpictures Yes

Gets the Saved Pictures folder.

Saved Pictures folder

Videoslibrary Yes

Gets the Videos library.

Video Library

HomeGroup No

Gets the HomeGroup folder.

HomeGroup folder

Mediaserverdevices No

Gets the folder of Media server (Digital Living Network Alliance (DLNA)) devices.

Media Devices Folder

Recordedcalls No

Gets the recorded calls folder.

Phone Recording folder

Removabledevices No

Gets the removable Devices folder.

Removable devices folder

App Packaged App Package

With WINDOWS10, you no longer need to target the operating system but instead, you need to target one or more device families (target your app to a or more device families). A device family defines the APIs, system character sets, and behavior collections that all devices in this family can apply. It also determines which series of devices your app can install from the App Store.

Original address:https://developer.microsoft.com/en-us/windows/holographic/app_model#App_views

HoloLens Development Notes-app model app models

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.