Restructur and start dedicated pages for user tutorials #7

Merged
6543 merged 8 commits from proper-getting-started into main 2024-08-21 19:13:55 -04:00
24 changed files with 83 additions and 58 deletions
Showing only changes of commit 81de4ef148 - Show all commits

18
.editorconfig Normal file
View File

@@ -0,0 +1,18 @@
root = true
[*]
indent_style = space
indent_size = 2
tab_width = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
[*.md]
trim_trailing_whitespace = false
indent_size = 1
[*.{css,js,json}]
indent_style = tab

View File

@@ -32,4 +32,4 @@ jobs:
# The GH actions bot is used by default if you didn't specify the two fields.
# You can swap them out with your own user credentials.
user_name: github-actions[bot]
user_email: 41898282+github-actions[bot]@users.noreply.github.com
user_email: 41898282+github-actions[bot]@users.noreply.github.com

View File

@@ -1,3 +1,3 @@
#!/bin/sh
GIT_USER=$1 USE_SSH=true yarn deploy
GIT_USER=$1 USE_SSH=true yarn deploy

View File

@@ -11,12 +11,12 @@ Every message uses [flatbuffers](https://google.github.io/flatbuffers/) and [fle
namespace StardustXR;
table Message {
type: ubyte;
id: uint;
object: string;
method: string;
error: string;
data:[ubyte] (flexbuffer);
type: ubyte;
id: uint;
object: string;
method: string;
error: string;
data:[ubyte] (flexbuffer);
}
root_type Message;
@@ -75,4 +75,4 @@ A `Vector` of 2 `double` is treated as a `Vector2`.
### Vector3
A `Vector` of 3 `double` is treated as a `Vector3`.
### Quaternion
A `Vector` of 4 `double` is treated as a `Quaternion`.
A `Vector` of 4 `double` is treated as a `Quaternion`.

View File

@@ -10,4 +10,4 @@ Creates a new [Model](../types/Model.md) at `/model/[name]` with parent at `spac
Sets the sky texture to be the image (HDR) at the absolute `path`.
### `setSkylight(string path)`
Sets the ambient lighting (using spherical harmonics) to the HDR at the absolute `path`.
Sets the ambient lighting (using spherical harmonics) to the HDR at the absolute `path`.

View File

@@ -10,4 +10,4 @@ Creates a new [BoxField](../types/field/BoxField.md) at `/field/[name]` with par
Creates a new [CylinderField](../types/field/CylinderField.md) at `/field/[name]` with parent at `spacePath`.
### `createSphereField(string name, string spacePath, Vector3 origin, float radius)`
Creates a new [SphereField](../types/field/SphereField.md) at `/field/[name]` with parent at `spacePath`.
Creates a new [SphereField](../types/field/SphereField.md) at `/field/[name]` with parent at `spacePath`.

View File

@@ -13,4 +13,4 @@ Creates a new [InputHandler](../types/input/InputHandler.md) with the specified
## Methods
### `Vector<Vector<string inputHandlerUUID, Vector3 position>> getInputHandlers(string spacePath, bool excludeSelf)`
Returns a list of all [InputHandler](../types/input/InputHandler.md) UUIDs and their positions (relative to the space at `spacePath`), as well as puts aliases to those handlers in `/input/global_handler/[UUID]`. Excludes handlers from this client if `excludeSelf` is true.
Returns a list of all [InputHandler](../types/input/InputHandler.md) UUIDs and their positions (relative to the space at `spacePath`), as well as puts aliases to those handlers in `/input/global_handler/[UUID]`. Excludes handlers from this client if `excludeSelf` is true.

View File

@@ -7,4 +7,4 @@ Object managing spatial objects and spatial manipulation.
Creates a new [Spatial](../types/Spatial.md) at `/spatial/spatial/[name]` with parent at `spacePath`.
### `createZone(string name, string fieldPath, string spacePath, Vector3 origin, Quat orientation, string callbackPath, string callbackMethod)`
Creates a new [Zone](../types/Zone.md) at `/spatial/zone/[name]` with parent at `spacePath` and field at `fieldPath`. The arguments `callbackPath` and `callbackMethod` refer to a callback method accepting a `Vector` of 2 `TypedVector`s, the first being a list of names of nodes that have just entered the field and the second being names of nodes that left (as `string`).
Creates a new [Zone](../types/Zone.md) at `/spatial/zone/[name]` with parent at `spacePath` and field at `fieldPath`. The arguments `callbackPath` and `callbackMethod` refer to a callback method accepting a `Vector` of 2 `TypedVector`s, the first being a list of names of nodes that have just entered the field and the second being names of nodes that left (as `string`).

View File

@@ -38,4 +38,4 @@ Sets the material property `propertyName` on this model's submesh at `submeshInd
|`emission` | `string` | Path to the emission texture of the material (if it has one). |
|`metal` | `string` | Path to the metalness texture of the material (if it has one). |
|`normal` | `string` | Path to the normal map texture of the material (if it has one). |
|`occlusion` | `string` | Path to the occlusion map texture of the material (if it has one). |
|`occlusion` | `string` | Path to the occlusion map texture of the material (if it has one). |

View File

@@ -10,4 +10,4 @@ A base type for all other types that exist in 3D space.
Destroy this node immediately, as well as all its children if it has any.
### `setEnabled(bool enabled)`
Set if this node is enabled or not, for example a disabled model will not render and a disabled input handler will not recieve input.
Set if this node is enabled or not, for example a disabled model will not render and a disabled input handler will not recieve input.

View File

@@ -53,4 +53,4 @@ Enable/disable this spatial's zoneable property.
## Methods
### `Vector<Vector3 origin, Quat orientation, Vector3 scale> getTransform(null)`
Returns the `origin`, `orientation`, and `scale` of this spatial relative to its parent.
Returns the `origin`, `orientation`, and `scale` of this spatial relative to its parent.

View File

@@ -15,4 +15,4 @@ Returns `true`/`false` if the [Spatial](Spatial) is captured by this zone or ano
Captures the [Spatial](Spatial) at `spatialUUID` if that [Spatial](Spatial) exists and is accessible by this zone. This means that the [Spatial](Spatial) cannot be seen or affected by other zones unless a zone is closer to the [Spatial](Spatial) than this zone.
### `release(string spatialUUID)`
Uncaptures the [Spatial](Spatial) at `spatialUUID` so any zone the [Spatial](Spatial) is inside can access it.
Uncaptures the [Spatial](Spatial) at `spatialUUID` so any zone the [Spatial](Spatial) is inside can access it.

View File

@@ -4,4 +4,4 @@ This field is in a rectangular prism shape.
## Properties
### `setSize(Vector3 size)`
Sets the size of the box.
Sets the size of the box.

View File

@@ -4,4 +4,4 @@ A cylinder shaped field defined by radius and length, along the forward vector.
## Properties
### `setSize(Vector3 size)`
Sets the size of the box.
Sets the size of the box.

View File

@@ -10,4 +10,4 @@ Returns the distance from `point` to the surface of the object, positive if the
Returns the normal of `point` compared to the surface of the object. Normal always points toward object.
### `Vector3 closestPoint(string spacePath, Vector3 point)`
Returns the closest point from `point` to the surface of the object. Use this instead of `distance` and `normal` when best to limit IPC calls.
Returns the closest point from `point` to the surface of the object. Use this instead of `distance` and `normal` when best to limit IPC calls.

View File

@@ -4,4 +4,4 @@ This Field is in a sphere shape.
## Properties
### `setRadius(double size)`
Sets the radius of the sphere.
Sets the radius of the sphere.

View File

@@ -23,4 +23,4 @@ Get a list of all action names (human-readable).
Set all the objects on this input handler to `actions`.
### `runAction(String actionName)`
Runs the action specififed by `actionName`.
Runs the action specififed by `actionName`.

View File

@@ -48,4 +48,4 @@ Standard supported datamap keys will be put in the individual type's documentati
<!-- Sets the position of this [InputMethod](../input/InputMethod). This pose also defines the main interaction point. -->
### `modifyDatamap(Dictionary data)`
Merges the datamap of this [InputMethod](InputMethod) with `data`. Each key here will add to the datamap if not present and set the existing value if present. Any key not present in `data` will be unaffected.
Merges the datamap of this [InputMethod](InputMethod) with `data`. Each key here will add to the datamap if not present and set the existing value if present. Any key not present in `data` will be unaffected.

View File

@@ -1,4 +1,5 @@
# HandInput
### Derived from [InputMethod](../InputMethod)
A full 27-bone hand+forearm input with useful abstractions provided through the datamap.
@@ -6,6 +7,7 @@ A full 27-bone hand+forearm input with useful abstractions provided through the
The local space of a hand is where +Z is away from the palm, +Y is from the palm to the fingers, and +X is orthogonal and to the right.
## Serialization
| Key | Value Type |
|-----------|--------------|
| origin | `Vector3` |
@@ -15,36 +17,39 @@ The local space of a hand is where +Z is away from the palm, +Y is from the palm
```js
[
thumb metacarpal,
thumb proximal,
thumb distal,
thumb tip,
index metacarpal,
index proximal,
index intermediate,
index distal,
index tip,
middle metacarpal,
middle proximal,
middle intermediate,
middle distal,
middle tip,
ring metacarpal,
ring proximal,
ring intermediate,
ring distal,
ring tip,
little metacarpal,
little proximal,
little intermediate,
little distal,
little tip
thumb metacarpal,
thumb proximal,
thumb distal,
thumb tip,
index metacarpal,
index proximal,
index intermediate,
index distal,
index tip,
middle metacarpal,
middle proximal,
middle intermediate,
middle distal,
middle tip,
ring metacarpal,
ring proximal,
ring intermediate,
ring distal,
ring tip,
little metacarpal,
little proximal,
little intermediate,
little distal,
little tip
]
```
(This section is WIP)
## Datamap
### Required
| Key | Value Type | Description |
|-----------------|-----------------------------|--------------------------------------------------------------------|
| confidence | `float` (range `0.0`-`1.0`) | How confident the hand tracker is of the pose of the hand |
@@ -54,4 +59,5 @@ The local space of a hand is where +Z is away from the palm, +Y is from the palm
| grabStrength | `float` (range `0.0`-`1.0`) | How much the hand is making a fist |
## Methods
**TODO**: Properly secured field distance calculation accessible to clients
**TODO**: Properly secured field distance calculation accessible to clients

View File

@@ -33,7 +33,7 @@ module.exports = {
},
{
type: 'doc',
docId: 'getting-started/overview',
docId: 'overview',
position: 'left',
label: 'Docs',
},

View File

@@ -1,12 +1,13 @@
/**
* Creating a sidebar enables you to:
- create an ordered group of docs
- render a sidebar for each doc of that group
- provide next/previous navigation
Creating a sidebar enables you to:
- create an ordered group of docs
- render a sidebar for each doc of that group
- provide next/previous navigation
The sidebars can be generated from the filesystem, or explicitly defined here.
Create as many sidebars as you want.
The sidebars can be generated from the filesystem, or explicitly defined here.
Create as many sidebars as you want.
*/
module.exports = {

View File

@@ -43,4 +43,4 @@ li.task-list-item > input[type="checkbox"] {
.gallery {
margin: 0 auto;
max-width: 1250px;
}
}

View File

@@ -70,4 +70,4 @@ title: Roadmap
- [ ] Panel Item UI
- [ ] Flatland
More to come!
More to come!

View File

@@ -1 +1 @@
stardustxr.org
stardustxr.org