Donner SVG main
0.8.0 ยท 382bd0190.8.0 main
SVG editor and embeddable C⁠+⁠+⁠20 engine.
Loading...
Searching...
No Matches
ConvolveMatrix.h File Reference

SVG convolution parameters and precompiled shader projections. More...

#include <cstddef>
#include <cstdint>
#include "donner/gpu/shader/CompiledShader.h"
Include dependency graph for ConvolveMatrix.h:
This graph shows which files directly or indirectly include this file:

Classes

struct  donner::gpu::shader::programs::ConvolveMatrixParams
 Host storage layout consumed by the matrix-convolution program. More...

Namespaces

namespace  donner
 Top-level Donner namespace, which is split into different sub-namespaces such as donner::svg and donner::css.

Functions

const CompiledShaderView & donner::gpu::shader::programs::ConvolveMatrixShader ()
 Returns the WGSL projection and reflected interface for matrix convolution.
const CompiledShaderView & donner::gpu::shader::programs::ConvolveMatrixNativeShader ()
 Returns only the platform's native MSL or SPIR-V projection and the reflected interface.

Variables

constexpr uint32_t donner::gpu::shader::programs::kConvolveMatrixKernelCapacity = 25
 Maximum number of tightly packed kernel coefficients in the parameter storage block.

Detailed Description

SVG convolution parameters and precompiled shader projections.

Function Documentation

◆ ConvolveMatrixNativeShader()

const CompiledShaderView & donner::gpu::shader::programs::ConvolveMatrixNativeShader ( )

Returns only the platform's native MSL or SPIR-V projection and the reflected interface.

Returns
Stable view into a process-lifetime artifact.

◆ ConvolveMatrixShader()

const CompiledShaderView & donner::gpu::shader::programs::ConvolveMatrixShader ( )

Returns the WGSL projection and reflected interface for matrix convolution.

The host admits positive kernel orders whose product fits the coefficient array, targets inside the kernel, and finite coefficients, bias and nonzero divisor. The shader rotates the row-major kernel by 180 degrees, supports duplicate/wrap/transparent edges and optionally preserves alpha.

Returns
Stable view into a process-lifetime artifact.