Skip to content
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

Examples of matrix input usage in Spatial Shaders #5895

Merged
merged 1 commit into from
Jul 19, 2022
Merged

Examples of matrix input usage in Spatial Shaders #5895

merged 1 commit into from
Jul 19, 2022

Conversation

paddy-exe
Copy link
Contributor

@paddy-exe paddy-exe commented Jun 29, 2022

Introduces examples for matrix input usage to users in Spatial Shaders such as:

  • object's world space position
  • camera's world space position
  • camera eye vector in world space direction of the camera
  • camera's view direction to the object in view space

@paddy-exe
Copy link
Contributor Author

@clayjohn I incorporated your feedback in and moved the code together directly above the Fragment built-ins. I did leave the note about the MODEL_VIEW_MATRIX there though since it seems quite useful to know. Let me know what you think about this.

@paddy-exe paddy-exe marked this pull request as ready for review June 30, 2022 08:17
Copy link
Member

@clayjohn clayjohn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks!

Copy link
Member

@mhilbrunner mhilbrunner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very small nitpick, otherwise looks perfect!

tutorials/shaders/shader_reference/spatial_shader.rst Outdated Show resolved Hide resolved
Copy link
Member

@mhilbrunner mhilbrunner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the quick update, and good work on this PR :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants