forked from StereoKit/StereoKit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathGuideSamples.cs
More file actions
268 lines (267 loc) · 13.8 KB
/
Copy pathGuideSamples.cs
File metadata and controls
268 lines (267 loc) · 13.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
// This is generated by /tools/Build-SampleGuide.ps1
/// :CodeDoc: Guides 15 Sample Code
/// # StereoKit Sample Code
///
/// Here are a list of small demos that illustrate how
/// certain parts of StereoKit works!
///
/// ## [Anchors](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoAnchors.cs)
///
/// This demo uses StereoKit's Anchor API to add, remove, and load spatial anchors that are locked to local physical locations. These can be used for persisting locations across sessions, or increasing the stability of your experiences!
///
/// 
///
/// ## [Asset Enumeration](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoAssets.cs)
///
/// If you need to take a peek at what's currently loaded, StereoKit has a couple tools in the Assets class!
///
/// This demo is just a quick illustration of how to enumerate through your Assets.
///
/// 
///
/// ## [Controllers](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoControllers.cs)
///
/// While StereoKit prioritizes hand input, sometimes a controller has more precision! StereoKit provides access to any controllers via the Input.Controller function. This is a debug visualization of the controller data provided there.
///
/// StereoKit will simulate hands if only controllers are present, but it will not simulate controllers if only hands are present.
///
/// 
///
/// ## [Device](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoDevice.cs)
///
/// The Device class contains a number of interesting bits of data about the device it's running on! Most of this is just information, but there's a few properties that can also be modified.
///
/// 
///
/// ## [Eye Tracking](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoEyes.cs)
///
/// If the hardware supports it, and permissions are granted, eye tracking is as simple as grabbing Input.Eyes!
///
/// This scene is raycasting your eye ray at the indicated plane, and the dot's red/green color indicates eye tracking availability! On flatscreen you can simulate eye tracking with Alt+Mouse.
///
/// 
///
/// ## [Mesh Generation](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoGeo.cs)
///
/// Generating a Mesh or Model via code can be an important task, and StereoKit provides a number of tools to make this pretty easy! In addition to the Default meshes, you can also generate a number of shapes, seen here. (See the Mesh.Gen functions)
///
/// If the provided shapes aren't enough, it's also pretty easy to procedurally assemble a mesh of your own from vertices and indices! That's the wavy surface all the way to the right.
///
/// 
///
/// ## [Hand Sim Poses](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoHandPoses.cs)
///
/// StereoKit simulates hand joints for controllers and mice, but sometimes you really just need to test a funky gesture!
///
/// The Input.HandSimPose functions allow you to customize how StereoKit simulates these hand poses, and this scene is a small tool to help you with capturing poses for these functions!
///
/// 
///
/// ## [Hand Input](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoHands.cs)
///
/// StereoKit uses a hands first approach to user input! Even when hand-sensors aren't available, hand data is simulated instead using existing devices. Check out Input.Hand for all the cool data you get!
///
/// This demo is the source for the 'Using Hands' guide, and is a collection of different options and examples of how to get, use, and visualize Hand data.
///
/// 
///
/// ## [Composition Layers](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoLayers.cs)
///
/// OpenXR allows for a variety of surfaces to be composed onto the screen. StereoKit by default manages just a single 'Projection Layer', but you can also submit additional layers with special shapes (quad layers), or special color buffers (like video)!
///
/// 
///
/// ## [Lighting Editor](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoLighting.cs)
///
///
///
/// 
///
/// ## [Line Render](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoLineRender.cs)
///
///
///
/// 
///
/// ## [Lines](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoLines.cs)
///
///
///
/// 
///
/// ## [Many Objects](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoManyObjects.cs)
///
/// ......
///
/// 
///
/// ## [Materials](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoMaterial.cs)
///
///
///
/// 
///
/// ## [Material Chain](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoMaterialChain.cs)
///
/// Materials can be chained together to create a multi-pass material! What you're seeing in this sample is an 'Inverted Shell' outline, a two-pass effect where a second render pass is scaled along the normals and flipped inside-out.
///
/// 
///
/// ## [Math](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoMath.cs)
///
/// StereoKit has a SIMD optimized math library that provides a wide array of high-level math functions, shapes, and intersection formulas!
///
/// In C#, math types are backed by System.Numerics for easy interop with code from the rest of the C# ecosystem.
///
/// 
///
/// ## [Microphone](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoMicrophone.cs)
///
/// Sometimes you need direct access to the microphone data! Maybe for a special effect, or maybe you just need to stream it to someone else. Well, there's an easy API for that!
///
/// This demo shows how to grab input from the microphone, and use it to drive an indicator that tells users that you're listening!
///
/// 
///
/// ## [Model Nodes](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoNodes.cs)
///
/// ModelNode API lets...
///
/// 
///
/// ## [Mixed Reality](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoMixedReality.cs)
///
/// You can set up AR with OpenXR by changing the environment blend mode! In StereoKit, this is modifiable via Device.DisplayBlend at runtime, and SKSettings.blendPreference during initialization.
///
/// Note that some devices may not support each blend mode! Like a HoloLens can't be Opaque, and some VR headsets can't be transparent!
///
/// 
///
/// ## [PBR Shaders](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoPBR.cs)
///
/// Shaders!
///
/// 
///
/// ## [Permissions](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoPermissions.cs)
///
/// StereoKit comes with APIs for managing cross-platform permissions. While on Desktop, permissions are almost not an issue, platforms like Android can get kinda complicated! Here, StereoKit provides an API that handles the more complicated permission issues of platforms like Android, and also can be a regular part of your desktop code!
///
/// 
///
/// ## [File Picker](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoPicker.cs)
///
/// Applications need to save and load files at runtime! StereoKit has a cross-platform, MR compatible file picker built in, Platform.FilePicker.
///
/// On systems/conditions where a native file picker is available, that's what you'll get! Otherwise, StereoKit will fall back to a custom picker built with StereoKit's UI.
///
/// 
///
/// ## [Point Clouds](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoPointCloud.cs)
///
/// Point clouds are not a built-in feature of StereoKit, but it's not hard to do this yourself! Check out the code for this demo for a class that'll help you do this directly from data, or from a Model.
///
/// 
///
/// ## [Ray to Mesh](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoRayMesh.cs)
///
///
///
/// 
///
/// ## [Record Mic](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoRecordMic.cs)
///
/// A common use case for the microphone would be to record a snippet of audio! This demo shows reading data from the Microphone, and using that to create a sound for playback.
///
/// 
///
/// ## [Render Lists](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoRenderList.cs)
///
/// All draw calls are stored in RenderList.Primary, but you can also store your draw calls to custom RenderLists! This allows you to draw more specific scenes to render textures with greater control, for use as icons, thumbnails, and all sorts of interesting things!
///
/// 
///
/// ## [Render Scaling](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoRenderScaling.cs)
///
/// Sometimes you need to boost the number of pixels your app renders, to reduce jaggies! Renderer.Scaling and Renderer.Multisample let you increase the size of the draw surface, and multisample each pixel.
///
/// This is powerful stuff, so use it sparingly!
///
/// 
///
/// ## [Rounded UI](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoRoundedUI.cs)
///
///
///
/// 
///
/// ## [Dynamic ShadowMaps](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoShadows.cs)
///
/// Using StereoKit's Renderer.RenderTo, SetGlobalTexture, MaterialBuffers, and a bit of ingenuity, you can also add shadow mapping to your app!
///
/// This is a very basic single cascade implementation of shadow mapping to illustrate the idea.
///
/// 
///
/// ## [Skeleton Estimation](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoSkeleton.cs)
///
/// With knowledge about where the head and hands are, you can make a decent guess about where some other parts of the body are! The StereoKit repository contains an AvatarSkeleton IStepper to show a basic example of how something like this can be done.
///
/// 
///
/// ## [Sound](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoSound.cs)
///
///
///
/// 
///
/// ## [Text](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoText.cs)
///
///
///
/// 
///
/// ## [Text Input](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoTextInput.cs)
///
///
///
/// 
///
/// ## [Procedural Textures](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoTextures.cs)
///
/// Here's a quick sample of procedurally assembling a texture!
///
/// 
///
/// ## [UI](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoUI.cs)
///
/// ...
///
/// 
///
/// ## [UI Grab Bar](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoUIGrabBar.cs)
///
/// This is an example of using external handles to manipulate a Window's pose! Since _you_ own the Pose data, you can do whatever you want with it!
/// The grab bar below the window is a common sight to see in recent XR UI, so here's one way to replicate that with SK's API.
///
/// 
///
/// ## [UI Settings](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoUISettings.cs)
///
///
///
/// 
///
/// ## [UI Tearsheet](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoUITearsheet.cs)
///
/// An enumeration of all the different types of UI elements!
///
/// 
///
/// ## [Unicode Text](https://github.com/StereoKit/StereoKit/blob/master/Examples/StereoKitTest/Demos/DemoUnicode.cs)
///
///
///
/// 
///
/// :End: