Skip to content

Advice for setting up slang shaders in a C# program #5466

Answered by csyonghe
Ollhax asked this question in Q&A
Discussion options

You must be logged in to vote

@Ollhax Thank you for giving slang a try for your use case. Unfortunately, Slang's GLSL backend isn't intended to generate glsl code for OpenGL, instead it emits Vulkan-flavored GLSL which does allow separated texture-samplers.

It seems that we will need to get explicit binding to work on Sampler2D objects to get you unblocked, which we should be able to do.

There should be existing ways to export COM interfaces to .Net as C# interfaces. I haven't digged into it, but https://learn.microsoft.com/en-us/previous-versions/dotnet/netframework-4.0/ms404285(v=vs.100) seems relevant.

Replies: 4 comments 6 replies

Comment options

You must be logged in to vote
1 reply
@Ollhax
Comment options

Answer selected by Ollhax
Comment options

You must be logged in to vote
3 replies
@Ollhax
Comment options

@Ollhax
Comment options

@Ollhax
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@Ollhax
Comment options

@csyonghe
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants