Skip to content

More modularity in the Uber shader #203

@jayliu50

Description

@jayliu50

Describe the problem

I'm trying to implement a custom shader (adds elevation contour lines) that also leverages the clipping primitive, and it seems harder than it should be. The Uber shader is a monolith of code.

Describe the solution you'd like

Consider breaking up the hlsl into modules. Perhaps even modules could be leveraged by custom functions in shader graph. (That use out parameters.)

I should be able to include a module or subgraph that will make my shader clip the same way as the Uber shader (for example).

Describe alternatives you've considered

Better support for shader graph in general. Either subgraphs and custom functions or both. #34

Additional context

Caveat is I am rather new to hlsl and unfamiliar with best practices. If performance suffers from breaking out the code, I'd be curious to know exactly how much.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions