summaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
authorcheneym2 <acheney@nvidia.com>2024-04-16 22:02:45 -0400
committerGitHub <noreply@github.com>2024-04-16 19:02:45 -0700
commit67313584d6879d68db53ced3108c2370bed5e8c1 (patch)
tree202f64210053d12a8ca2c6a2a22b000c020443eb /docs
parent282da4ac94d60d3244f4d72085e66fb82cf5abd8 (diff)
Fix Slang documentation typos (#3961)
Diffstat (limited to 'docs')
-rw-r--r--docs/gpu-feature/texture/footprint-queries.md2
-rw-r--r--docs/repro.md2
-rw-r--r--docs/user-guide/02-conventional-features.md4
-rw-r--r--docs/user-guide/05-capabilities.md6
-rw-r--r--docs/user-guide/06-interfaces-generics.md10
-rw-r--r--docs/user-guide/08-compiling.md10
-rw-r--r--docs/user-guide/09-reflection.md2
-rw-r--r--docs/user-guide/09-targets.md6
8 files changed, 21 insertions, 21 deletions
diff --git a/docs/gpu-feature/texture/footprint-queries.md b/docs/gpu-feature/texture/footprint-queries.md
index 3d0fef2d3..b47a95262 100644
--- a/docs/gpu-feature/texture/footprint-queries.md
+++ b/docs/gpu-feature/texture/footprint-queries.md
@@ -48,7 +48,7 @@ To query the footprint that would be accessed by this operation, we can use an o
```hlsl
uint granularity = ...;
-TextureFootprint2D footprint = texure.queryFootprintCoarse(granularity,
+TextureFootprint2D footprint = texture.queryFootprintCoarse(granularity,
sampler, coords);
```
diff --git a/docs/repro.md b/docs/repro.md
index 7a032df07..54ad8b978 100644
--- a/docs/repro.md
+++ b/docs/repro.md
@@ -38,7 +38,7 @@ When a repro is loaded, before files are loaded from the repro itself, they will
Now you might want to change the compilation options. Using -load-repro it will compile with the options as given. It is not possible to change those options as part of -load-repro. If you want to change the compilation options (and files), you can use -extract-repro, and look at the manifest which will list a command line that will typically repeat the compilation. Now you can just attach the repro as a file system, and set the command line options as appropriate, based on the command line listed in the manifest. Note! If there is a fairly complex directory hierarchy, it may be necessary to specify the input sources paths *as if* they are held on the original files system. You can see how these map in the manifest.
-Note that currently is is disabled to access any new source files - they will be determined as `not found`. This behaviour could be changed such that the regular file system was used, or the ISlangFilesystem set on the API is used as a fallback.
+Note that currently it is disabled to access any new source files - they will be determined as `not found`. This behaviour could be changed such that the regular file system was used, or the ISlangFilesystem set on the API is used as a fallback.
There currently isn't a mechanism to alter the options of a repro from the command line (other than altering the contents of the source). The reason for this is because of how command lines are processed currently in Slang. A future update could enable specifying a repro and then altering the command line options used. It can be achieved through the API though. Once the repro is loaded via the `spLoadRepro` function, options can be changed as normal. The two major places where option alteration may have surprising behavior are...
diff --git a/docs/user-guide/02-conventional-features.md b/docs/user-guide/02-conventional-features.md
index 933b19357..e50debd10 100644
--- a/docs/user-guide/02-conventional-features.md
+++ b/docs/user-guide/02-conventional-features.md
@@ -244,7 +244,7 @@ Opaque types (and structure or array types that contain them) may be limited in
#### Texture Types
-Texture types -- including `Texure2D`, `TextureCubeArray`, `RWTexture2D`, and more -- are used to access formatted data for read, write, and sampling operations.
+Texture types -- including `Texture2D`, `TextureCubeArray`, `RWTexture2D`, and more -- are used to access formatted data for read, write, and sampling operations.
Textures can be used to represent simple images, but also support _mipmapping_ as a way to reduce noise when sampling at lower than full resolution.
The full space of texture types follows the formula:
@@ -254,7 +254,7 @@ where:
* The _access_ can be read-only (no prefix), read-write (`RW`), or read-write with a guarantee of rasterization order for operations on the given resource (`RasterizerOrdered`).
* The _base shape_ can be `1D`, `2D`, `3D`, or `Cube`.
-* The _multisample-ness_ can non-multiple-sample, or multi-sampled (`MS`).
+* The _multisample-ness_ can be non-multiple-sample, or multi-sampled (`MS`).
* The _array-ness_ can either be non-arrayed, or arrayed (`Array`).
* The _element type_ can either be explicitly specified (`<T>`) or left as the default of `float4`
diff --git a/docs/user-guide/05-capabilities.md b/docs/user-guide/05-capabilities.md
index 5f69a3026..8f377f5a4 100644
--- a/docs/user-guide/05-capabilities.md
+++ b/docs/user-guide/05-capabilities.md
@@ -27,7 +27,7 @@ a `discard` statement, it shall be a type-check error.
Slang models code generation targets, shader stages, API extensions and hardware features as distinct capability atoms. For example, `GLSL_460` is a capability atom that stands for the GLSL 460 code generation target,
`compute` is an atom that represents the compute shader stage, `_sm_6_7` is an atom representing the shader model 6.7 feature set in D3D, `SPV_KHR_ray_tracing` is an atom representing the `SPV_KHR_ray_tracing` SPIR-V extension, and `spvShaderClockKHR` is an atom for the `ShaderClockKHR` SPIRV capability. For a complete list of capabilities supported by the Slang compiler, check the [capability definition file](https://github.com/shader-slang/slang/blob/master/source/slang/slang-capabilities.capdef).
-A capabiltiy **requirement** can be a single capability atom, a conjunction of capability atoms, or a disjunction of conjunction of capability atoms. A function can declare its
+A capability **requirement** can be a single capability atom, a conjunction of capability atoms, or a disjunction of conjunction of capability atoms. A function can declare its
capability requirement with the following syntax:
```csharp
@@ -94,7 +94,7 @@ public void myFunc()
## Inferrence of Capability Requirements
-By default, Slang will infer the capability requirements of a function given its definition, as long as the function has `internal` or `private` visibilty. For example, given:
+By default, Slang will infer the capability requirements of a function given its definition, as long as the function has `internal` or `private` visibility. For example, given:
```csharp
void myFunc()
{
@@ -112,7 +112,7 @@ Since `discard` statement requires capability `fragment`.
## Inferrence on target_switch
-A `__target_switch` statement will introduce disjunctions in its inferred capabiltiy requirement. For example:
+A `__target_switch` statement will introduce disjunctions in its inferred capability requirement. For example:
```csharp
void myFunc()
{
diff --git a/docs/user-guide/06-interfaces-generics.md b/docs/user-guide/06-interfaces-generics.md
index 9de38e6e3..ba543df56 100644
--- a/docs/user-guide/06-interfaces-generics.md
+++ b/docs/user-guide/06-interfaces-generics.md
@@ -680,7 +680,7 @@ T compute<T>(T a1, T a2)
Extensions to Interfaces
-----------------------------
-In addtion to extending ordinary types, you can define extensions on interfaces as well:
+In addition to extending ordinary types, you can define extensions on interfaces as well:
```csharp
// An example interface.
interface IFoo
@@ -748,9 +748,9 @@ Builtin Interfaces
Slang supports the following builtin interfaces:
- `IComparable`, provides methods for comparing two values of the conforming type. Supported by all basic data types, vector types and matrix types.
-- `IRangedValue`, proivides methods for retrieving the minimum and maxinum value expressed by the range of the type. Supported by all integer and floating-point scalar types.
-- `IArithmetic`, provides methods for the `+`, '-`, '*`, `/`, `%` and negating operations. Also provide a method for explicit conversion from `int`. Implemented by all builtin integer and floating-point scalar, vector and matrix types.
-- `ILogical`, provides methods for all bit operations and logical `and`, `or`, `not` oeprations. Also provide a method for explicit conversion from `int`. Implemented by all builtin integer scalar, vector and matrix types.
+- `IRangedValue`, provides methods for retrieving the minimum and maximum value expressed by the range of the type. Supported by all integer and floating-point scalar types.
+- `IArithmetic`, provides methods for the `+`, `-`, `*`, `/`, `%` and negating operations. Also provide a method for explicit conversion from `int`. Implemented by all builtin integer and floating-point scalar, vector and matrix types.
+- `ILogical`, provides methods for all bit operations and logical `and`, `or`, `not` operations. Also provide a method for explicit conversion from `int`. Implemented by all builtin integer scalar, vector and matrix types.
- `IInteger`, represents a logical integer that supports both `IArithmetic` and `ILogical` operations. Implemented by all builtin integer scalar types.
- `IDifferentiable`, represents a value that is differentiable.
- `IFloat`, represents a logical float that supports both `IArithmetic`, `ILogical` and `IDifferentiable` operations. Also provides methods to convert to and from `float`. Implemented by all builtin floating-point scalar, vector and matrix types.
@@ -759,7 +759,7 @@ Slang supports the following builtin interfaces:
- `__BuiltinIntegerType`, implemented by all integer scalar types.
- `__BuiltinFloatingPointType`, implemented by all floating-point scalar types.
- `__BuiltinArithmeticType`, implemented by all integer and floating-point scalar types.
-- `__BuiltinLogicalType`, implemmented by all integer types and the `bool` type.
+- `__BuiltinLogicalType`, implemented by all integer types and the `bool` type.
Operator overloads are defined for `IArithmetic`, `ILogical`, `IInteger`, `IFloat`, `__BuiltinIntegerType`, `__BuiltinFloatingPointType`, `__BuiltinArithmeticType` and `__BuiltinLogicalType` types, so the following code is valid:
diff --git a/docs/user-guide/08-compiling.md b/docs/user-guide/08-compiling.md
index 14f12ed4a..90dd4c4dc 100644
--- a/docs/user-guide/08-compiling.md
+++ b/docs/user-guide/08-compiling.md
@@ -68,8 +68,8 @@ Developers are encouraged to use this model because it directly documents intent
### Explicit Entry Point Options
-For compatibility with existing code, the Slang compiler also supports explicit specification of entry point functions using configuration optiosn external to shader source code.
-When these options are used the compiler will *ignore* all `[shader(...)]` attributes and only use the explicitly-specified entry points intead.
+For compatibility with existing code, the Slang compiler also supports explicit specification of entry point functions using configuration options external to shader source code.
+When these options are used the compiler will *ignore* all `[shader(...)]` attributes and only use the explicitly-specified entry points instead.
### Shader Parameters
@@ -139,7 +139,7 @@ at the linking step.
Once a program is linked, the user can request generation of the _kernel_ code for an entry point.
The same entry point can be used to generate many different kernels.
-First, and entry point can be compiled for different targets, resulting in different kernels in the appropriate format for each target.
+First, an entry point can be compiled for different targets, resulting in different kernels in the appropriate format for each target.
Second, different compositions of shader code can result in different layouts, which leads to different kernels being required.
## Command-Line Compilation with `slangc`
@@ -294,7 +294,7 @@ Notable features that Slang supports which cannot be accessed from `slangc` incl
* Slang allows applications to control the way that shader modules and entry points are composed (which in turn influences their layout); `slangc` currently implements a single default policy for how to generate a composition of shader code.
-Applications that more control over compilation are encouraged to use the C++ compilation API described in the next section.
+Applications that need more control over compilation are encouraged to use the C++ compilation API described in the next section.
## Using the Compilation API
@@ -488,7 +488,7 @@ Slang::ComPtr<IModule> module = session->loadModule("MyShaders", diagnostics.wri
In this example, if any diagnostic messages were produced when loading `MyShaders`, then the `diagnostics` pointer will be set to a blob that contains the textual content of those diagnostics.
The content of a blob can be accessed with `getBufferPointer()`, and the size of the content can be accessed with `getBufferSize()`.
-Diagnostic blobs produces by the Slang compiler are always null-terminated, so that they can be used with C-style sting APIs:
+Diagnostic blobs produces by the Slang compiler are always null-terminated, so that they can be used with C-style string APIs:
```c++
if(diagnostics)
diff --git a/docs/user-guide/09-reflection.md b/docs/user-guide/09-reflection.md
index cef2f0b10..8572dbe08 100644
--- a/docs/user-guide/09-reflection.md
+++ b/docs/user-guide/09-reflection.md
@@ -42,7 +42,7 @@ for(unsigned pp = 0; pp < parameterCount; pp++)
We can also enumerate the compile entry points, in order to inspect their parameters:
```c++
-SlangUInt entryPointCount = shaderRefelction->getEntryPointCount();
+SlangUInt entryPointCount = shaderReflection->getEntryPointCount();
for(SlangUInt ee = 0; ee < entryPointCount; ee++)
{
slang::EntryPointReflection* entryPoint =
diff --git a/docs/user-guide/09-targets.md b/docs/user-guide/09-targets.md
index 0b7845108..61735d4bb 100644
--- a/docs/user-guide/09-targets.md
+++ b/docs/user-guide/09-targets.md
@@ -152,7 +152,7 @@ For example, a fragment kernel cannot use both `u0` and `SV_Target0` at once.
Direct3D 12
-----------
-Direct3D 12 (D3D12) is the current major version of the Direct2D API.
+Direct3D 12 (D3D12) is the current major version of the Direct3D API.
D3D12 kernels must be compiled to the DirectX Intermediate Language (DXIL).
DXIL is a layered encoding based off of LLVM bitcode; it introduces additional formatting rules and constraints which are loosely documented.
@@ -294,7 +294,7 @@ High-level-language shader parameters are bounding to a "binding" index for Open
The binding index of a parameter is the zero-based index of the slot (of the appropriate kind) that must be used to pass an argument value.
Note that while OpenGL and Vulkan both use binding indices for shader parameters like textures, the semantics of those are different because OpenGL uses distinct slots for passing buffers and textures.
-For OpenGL is is legal to have a texture that uses `binding=2` and a buffer that uses `binding=2` in the same kernel, because those are indices of distinct kinds of slots, while this scenario would typically be invalid for Vulkan.
+For OpenGL it is legal to have a texture that uses `binding=2` and a buffer that uses `binding=2` in the same kernel, because those are indices of distinct kinds of slots, while this scenario would typically be invalid for Vulkan.
CUDA and OptiX
--------------
@@ -347,7 +347,7 @@ For the purposes of Slang, different CPU-based host platforms are largely the sa
All support binary code in a native machine-code format.
All CPU platforms Slang supports use a flat memory model with a single virtual address space, where any data type can be stored at any virtual address.
-Note that this section consider CPU-based platforms only as targets for kernel compilation; using a CPU as a target for scalar "host" code is an advanced target beyond the scope of this document.
+Note that this section considers CPU-based platforms only as targets for kernel compilation; using a CPU as a target for scalar "host" code is an advanced target beyond the scope of this document.
### Pipelines