-
Notifications
You must be signed in to change notification settings - Fork 317
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DOCF-6396 - Processor content model re-org #2123
base: docs-content-model-reorg
Are you sure you want to change the base?
DOCF-6396 - Processor content model re-org #2123
Conversation
When you create bindings for your [actions](actions.md), you can choose to add processors to the Bindings. These process the values from the controls they bind to, before the system applies them to the Action value. For example, you could invert the `Vector2` values from the controls along the Y axis before passing the values to the associated Action. | ||
|
||
Processors on Actions work the same way, but affect all bindings on an Action. | ||
|
||
If there are processors on both the Binding and the Action, the Input System processes the processors from the binding first. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mixture of B(b) and A(a) for bindings and actions
@@ -1,25 +1,30 @@ | |||
# Predefined Processors | |||
# Built-in Processors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we even need this page? it's repeating information that's already in the API docs.
I'd be tempted to bin it and add something to the intro doc that's like:
## Built in processors
The Input System package comes with a set of built-in processors, defined in the `Processors` class, which you can use with [bindings](ActionBindings.md), [actions](actions.md) and [controls](controls.md). For a list of processors, refer to the [`Processors` API documentation](../api/UnityEngine.InputSystem.Processors.html)
@duckets what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be useful to have a much smaller simpler page with a list or table of the built-in processors, each with a single line describing what they are and a link to the API.
Also need to check that the API description is at last as good as the description from the manual, and replace if not - for example i looked at "Invert Vector 3" and the manual says:
Inverts the values from a Control (that is, multiplies the values by -1). Inverts the x axis of the vector if invertX is true, the y axis if invertY is true, and the z axis if invertZ is true.
Whereas the API says:
Inverts the x and/or y and/or z channel of a Vector3.
The manual content is better, so we should replace the API text with that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ben's suggestions works for me.
There is some information in this page that isn't in the API docs, and I"m not sure if it's more appropriate for the user manual or the API docs - specifically I'm talking about the paragraphs in lines 112 and 113. What would you suggest for those?
@@ -1,8 +1,10 @@ | |||
# Writing custom Processors | |||
# Writing custom processors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the toc this is "Write" rather than "Writing"
Packages/com.unity.inputsystem/Documentation~/write-custom-processors.md
Show resolved
Hide resolved
|
||
If you [create a layout from JSON](layouts.md#layout-from-json), you can specify processors on your Controls like this: | ||
|
||
```CSharp |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
```CSharp | |
```json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One change, which is to simplify the built-in processors page
@@ -1,25 +1,30 @@ | |||
# Predefined Processors | |||
# Built-in Processors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be useful to have a much smaller simpler page with a list or table of the built-in processors, each with a single line describing what they are and a link to the API.
Also need to check that the API description is at last as good as the description from the manual, and replace if not - for example i looked at "Invert Vector 3" and the manual says:
Inverts the values from a Control (that is, multiplies the values by -1). Inverts the x axis of the vector if invertX is true, the y axis if invertY is true, and the z axis if invertZ is true.
Whereas the API says:
Inverts the x and/or y and/or z channel of a Vector3.
The manual content is better, so we should replace the API text with that.
Re-org for Processor documentation.