Skip to content

Add in the shader authoring guide chapter.#333

Open
gpx1000 wants to merge 12 commits into
KhronosGroup:mainfrom
gpx1000:shader-authoring
Open

Add in the shader authoring guide chapter.#333
gpx1000 wants to merge 12 commits into
KhronosGroup:mainfrom
gpx1000:shader-authoring

Conversation

@gpx1000

@gpx1000 gpx1000 commented Jul 21, 2025

Copy link
Copy Markdown
Contributor

No description provided.

Comment thread guide.adoc Outdated
@spencer-lunarg

Copy link
Copy Markdown
Contributor

I know @SaschaWillems already wrote a whole chapter around this "area" so want him approval

Also @swoods-nv would also be great to review

Comment thread chapters/shader_authoring_guide_slang_hlsl.adoc Outdated
Comment thread chapters/shader_authoring_guide_slang_hlsl.adoc Outdated
Comment thread chapters/shader_authoring_guide_slang_hlsl.adoc Outdated
Comment thread chapters/shader_authoring_guide_slang_hlsl.adoc Outdated

@swoods-nv swoods-nv left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

My main overarching comment is that I'd recommend caution when phrasing migration from HLSL->Slang as "upgrading" or similar. Vulkan consciously chooses not to have an official shading language, and both Slang and HLSL continue to evolve and gain new features.

@SaschaWillems

Copy link
Copy Markdown
Collaborator

There is def. some duplication here. The chapters I did are:

The latter was written with additional shading languages in mind.

So maybe it's better to

  • To a general slang chapter like the one I did for HLSL (first link)
  • And add slang to the already available high level shader language comparison (second link)

A separate chapter that kinda combines what we have + slang might be confusing.

@gpx1000

gpx1000 commented Jul 22, 2025

Copy link
Copy Markdown
Contributor Author

Okay, sounds good, I'll try to move things around.

@SaschaWillems

Copy link
Copy Markdown
Collaborator

Btw. the official slang docs do have migration guides, so maybe something we could link to:

@gpx1000

gpx1000 commented Jul 22, 2025

Copy link
Copy Markdown
Contributor Author

Good call on using those links, I'll add it in. The next version will have a lot of copy pasting to place the details in the right place. Should have a new version once I finish reviewing all changes.

@gpx1000

gpx1000 commented Jul 22, 2025

Copy link
Copy Markdown
Contributor Author

Alright, significant copy/pasting and reorganizing into the existing structure. I don't think I lost any of the details I wrote in the original version. However, hopefully that's closer to where things should go.

Comment thread chapters/slang.adoc Outdated
spencer-lunarg
spencer-lunarg previously approved these changes Jul 23, 2025

@spencer-lunarg spencer-lunarg left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

  • Adding Slang to the high_level_shader_language_comparison.adoc page is great (I often know a term in in GLSL and need to look up the Slang equivalent)
  • Will wait for @SaschaWillems approval on the HLSL additions added
  • Will wait for @swoods-nv for a re-read and approval on the new Slang chapter

Comment thread chapters/hlsl.adoc Outdated
Comment thread chapters/hlsl.adoc
Comment thread chapters/hlsl.adoc Outdated
Comment thread chapters/hlsl.adoc Outdated
Comment thread chapters/high_level_shader_language_comparison.adoc Outdated
Comment thread chapters/high_level_shader_language_comparison.adoc Outdated
@SaschaWillems

Copy link
Copy Markdown
Collaborator

That's a lot of text to review ^^

Added a few comments. One of the things that IMO needs more attention is Skang's ability to automatically generate binding slots. For me, that was one of the best things about Slang, and while you can somehow find that information in this PR I'd like to see that more explicitly stated.

Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated

@juliusikkala juliusikkala left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hmm... I think this requires quite a bit of work still. There are lots of references to deprecated and sometimes even non-existent features. The text is also very repetitive at places. Many sections are simply lists with little substance. Lots of repetition of modules-interfaces-generics.

I hope other reviewers can fill in more details, especially about the overall structure. I focused more on correctness in code examples, where I likely also didn't find every problem, so I hope others will check those carefully as well.

Comment thread chapters/high_level_shader_language_comparison.adoc Outdated
Comment thread chapters/high_level_shader_language_comparison.adoc Outdated
Comment thread chapters/high_level_shader_language_comparison.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
@SaschaWillems

Copy link
Copy Markdown
Collaborator

Tbh. I think we should remove the migrating from glsl/hlsl paragraphs. They're kind hard to read, some of the best practices feel out-of-place or don't apply and the official slang docs already have good migration guides:

Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
Comment thread chapters/slang.adoc Outdated
gpx1000 added 3 commits June 30, 2026 21:24
…efine Vulkan examples, and update migration guides.
# Conflicts:
#	chapters/high_level_shader_language_comparison.adoc
#	chapters/slang.adoc
…y content from this PR that was in the updated guide.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants