-
Notifications
You must be signed in to change notification settings - Fork 15
Usage of RealSense Extensions
Setup the Windows host as https://crosswalk-project.org/documentation/windows/windows_host_setup.html.
Install crosswalk-app-tools:
c:\> npm install -g crosswalk-app-tools
Please make sure the version of crosswalk-app-tools is above 0.10.3:
c:\> crosswalk-pkg -v
0.10.3
Create a Crosswalk app by referring to https://crosswalk-project.org/documentation/windows/build_an_application.html
The Crosswalk RealSense Sample App source code will be used as an example in following steps.
Enter the root of the app where it should have the manifest.json
file.
c:\> cd c:\path\to\rs_sample_v19.6.1_src\src
Create node_modules
folder inside the root of the app. Otherwise, npm might install extensions in wrong places.
c:\path\to\rs_sample_v19.6.1_src\src> mkdir node_modules
Install Depth Enabled Photography Extension.
c:\path\to\rs_sample_v19.6.1_src\src> npm install crosswalk-extension-dep
Install Face Tracking and Recognition Extension.
c:\path\to\rs_sample_v19.6.1_src\src> npm install crosswalk-extension-face
Install Hand Tracking Extension.
c:\path\to\rs_sample_v19.6.1_src\src> npm install crosswalk-extension-hand
Install Scene Perception Extension.
c:\path\to\rs_sample_v19.6.1_src\src> npm install crosswalk-extension-sp
(Optional) Verify the installation by
c:\path\to\rs_sample_v19.6.1_src\src> npm list
c:\path\to\rs_sample_v19.6.1_src\src
├── [email protected]
├── [email protected]
├── [email protected]
└── [email protected]
(Optional) Verify the manifest.json modification:
c:\path\to\rs_sample_v19.6.1_src\src> type manifest.json
{
"name": "Crosswalk RealSense Sample App",
"start_url": "index.html",
"xwalk_package_id": "org.crosswalk_project.rs_sample",
"xwalk_command_line": "--use-rs-video-capture",
"xwalk_windows_vendor": "Crosswalk Project",
"xwalk_extensions": [
"realsense_extensions/enhanced_photography",
"realsense_extensions/face",
"realsense_extensions/scene_perception",
"realsense_extensions/hand",
"node_modules/crosswalk-extension-dep",
"node_modules/crosswalk-extension-face",
"node_modules/crosswalk-extension-hand",
"node_modules/crosswalk-extension-sp"
]
}
Download Crosswalk Windows beta 19.49.514.1.
Package app with Crosswalk Runtime and RealSense Extensions to app installers.
c:\path\to\rs_sample_v19.6.1_src> crosswalk-pkg -p windows -c c:\path\to\crosswalk64-19.49.514.1.zip src
The generated org.crosswalk_project.rs_sample_with_rssdk_runtime_0.1.0.0.msi
is the app installer with the RSSDK runtime web installer. It launches the RSSDK runtime web installer to install dependencies during the application installation.
To learn more about RealSense JavaScript APIs. Please check out the API specifications:
- Depth Enabled Photography API
- Scene Perception API
- Face Tracking and Recognition API
- Hand Tracking API
The source code of Sample App demonstrates how to use them.