Skip to content

Commit ba79200

Browse files
committed
More pictures
1 parent 86985c2 commit ba79200

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

assets/generics.jpg

52.7 KB
Loading

assets/hlsl-compatibility.jpg

296 KB
Loading

index.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,21 +38,24 @@ To help applications managing feature set differences across platforms, Slang's
3838

3939
In addition, Slang provides [flexible interop](/slang/user-guide/a1-04-interop.html) features to allow you to directly embed target code or SPIRV in your shaders.
4040

41-
## Automatic Differentiation
41+
## Embrace Neural Graphics with Automatic Differentiation
4242
<img class="fullwidthImage" style="max-width:800px" src="/assets/autodiff.jpg"/>
4343

4444
Slang can [automatically generate both forward and backward derivative propagation code](/slang/user-guide/autodiff.html) for complex functions that involve arbitrary control flow and dynamic dispatch. This allows users to easily make existing rendering codebases differentiable, or to use Slang as the kernel language in a PyTorch driven machine learning framework via [`slangtorch`](/slang/user-guide/a1-02-slangpy.html).
4545

46-
## Module System
46+
## Scalable Software Development with Modules
4747
<img class="fullwidthImage" style="max-width:900px" src="/assets/modules-1.jpg"/>
4848

4949
Slang provides a [module system](/slang/user-guide/modules.html) that can be used to logically organize code and benefit from separate compilation. Slang modules can be compiled offline to a custom IR (with optional obfuscation) and then linked at runtime to generate DXIL, SPIR-V etc.
5050

5151
## Code Specialization that Works with Modules
5252

53+
<img class="fullwidthImage" style="max-width:500px" src="/assets/generics.jpg"/>
54+
5355
Slang supports [generics and interfaces](/slang/user-guide/interfaces-generics.html) (a.k.a. type traits/protocols) to allow clear expression of shader specialization without resorting to preprocessor techniques or string-pasting. Unlike C++ templates, Slang's generics are checked ahead of time and don't produce cascading error messages that are difficult to diagnose. The same generic shader can be specialized for a variety of different types to produce specialized code ahead of time, or on the fly, completely under application control.
5456

5557
## Easy On-ramp from HLSL and GLSL
58+
<img class="fullwidthImage" style="max-width:700px" src="/assets/hlsl-compatibility.jpg"/>
5659

5760
Slang's syntax is similar to HLSL and most existing HLSL code can be compiled with the Slang compiler out-of-the-box, or with minor modifications. It is possible to start taking advantage of Slang's benefits without rewriting or porting your shader codebase.
5861

0 commit comments

Comments
 (0)