![]() |
VPP
0.8
A high-level modern C++ API for Vulkan
|
The VPP namespace. More...
Namespaces | |
ct | |
The VPP Computation Toolkit namespace. | |
Classes | |
class | arrayOf |
Template allowing to construct arrays of binding points. More... | |
class | Attachment |
Represents attachment graph node. More... | |
struct | Attribute |
Template for defining vertex or instance data fields. More... | |
class | Bar |
Utility base class for barrier classes. More... | |
class | BarrierList |
Multiple barriers with default parameters. More... | |
class | Barriers |
General class encapsulating description of a set of pipeline barriers. More... | |
class | Bool |
Shader (GPU-side) data type for boolean values. More... | |
class | Buf |
Generic class representing Vulkan buffers. More... | |
class | Buffer |
Typed Vulkan buffer of specified purpose. Most functions operating on buffers require typed buffer, therefore this is the class you want to use most of the time. More... | |
class | BufferMemoryBarrier |
Single buffer barrier. More... | |
class | BVec2 |
Shader (GPU-side) data type for 2-element boolean vectors. More... | |
class | BVec3 |
Shader (GPU-side) data type for 3-element boolean vectors. More... | |
class | BVec4 |
Shader (GPU-side) data type for 4-element boolean vectors. More... | |
class | CommandBuffer |
Represents a sequence of Vulkan commands. More... | |
class | CommandBufferRecorder |
Interface to the automatic command recording framework. More... | |
class | CommandPool |
Allocates and manages the lifetime of command buffers. More... | |
class | CompiledProcedures |
class | Computation |
Base class for single computation routine. More... | |
class | ComputationEngine |
Base class for computation engines. More... | |
class | ComputePass |
Represents compute pass. More... | |
class | ComputePipeline |
Compiled pipeline class for compute pipelines. More... | |
class | ComputePipelineConfig |
Base class for custom compute pipelines. More... | |
class | ComputePipelineLayout |
Pipeline layout template for a compute pipeline. Use to create actual pipeline layout (Vulkan objects) from abstract representation in the form of ComputePipelineConfig object. More... | |
class | ComputeShader |
Compute shader interface. More... | |
class | computeShader |
Binding point class for compute shaders. Place in your pipeline configuration class to declare a compute shader. More... | |
class | createInstance |
Instance factory class. More... | |
class | DebugReporter |
Base class for debug report generators. More... | |
class | Device |
Represents logical rendering device. More... | |
class | DeviceFeatures |
Utility class for dealing with device features and known extensions. More... | |
class | DeviceMemory |
class | dgvector |
Array allocated entirely on GPU side, without any mapping to the CPU side. More... | |
class | DispatchIndirectCommands |
Utility subclass representing a vector of indirect dispatch ranges. More... | |
class | Display |
Represents display attachment graph node. More... | |
class | Double |
Shader (GPU-side) data type for 64-bit floating point values. More... | |
class | DVec2 |
Shader (GPU-side) data type for 2-element 64-bit floating point vectors. More... | |
class | DVec3 |
Shader (GPU-side) data type for 3-element 64-bit floating point vectors. More... | |
class | DVec4 |
Shader (GPU-side) data type for 4-element 64-bit floating point vectors. More... | |
class | Event |
Allows the GPU to wait for certain condition on CPU or GPU side to occur. More... | |
class | ExtendedCommands |
class | Fence |
Allows the CPU to wait for GPU operation to finish. More... | |
class | Field |
Template for defining local structure data fields. More... | |
class | Float |
Shader (GPU-side) data type for 32-bit floating point values. More... | |
class | FragmentShader |
Fragment shader interface. More... | |
class | fragmentShader |
Binding point class for fragment shaders. Place in your pipeline configuration class to declare a fragment shader. More... | |
class | FrameBuffer |
Defines a vector of physical images to be used as targets for rendering attachments. More... | |
class | FrameImageView |
Untyped image view class. Useful for constructing FrameBuffer objects. More... | |
struct | Function |
Creates shader-level function. More... | |
class | geometryShader |
Binding point class for geometry shaders. Place in your pipeline configuration class to declare a geometry shader. More... | |
class | GeometryShader |
Geometry shader interface. More... | |
struct | gl_perVertex |
Auxiliary structure holding basic vertex attributes. More... | |
class | gvector |
Generic STL-style vector allocating memory on the GPU. More... | |
class | Image |
Class representing typed Vulkan image. More... | |
struct | ImageAttributes |
A template containing image attributes inside C++ type. More... | |
struct | ImageInfo |
A structure containing image parameters. More... | |
class | ImageMemoryBarrier |
Single image barrier. More... | |
class | ImageView |
Typed image view. More... | |
struct | ImageViewAttributes |
A template encoding image view attributes inside C++ type. More... | |
class | IMat2 |
Shader (GPU-side) data type for 2x2 32-bit integer matrices. More... | |
class | IMat2x3 |
Shader (GPU-side) data type for 2 columns, 3 rows 32-bit integer matrices. More... | |
class | IMat2x4 |
Shader (GPU-side) data type for 2 columns, 4 rows 32-bit integer matrices. More... | |
class | IMat3 |
Shader (GPU-side) data type for 3x3 32-bit integer matrices. More... | |
class | IMat3x2 |
Shader (GPU-side) data type for 3 columns, 2 rows 32-bit integer matrices. More... | |
class | IMat3x4 |
Shader (GPU-side) data type for 3 columns, 4 rows 32-bit integer matrices. More... | |
class | IMat4 |
Shader (GPU-side) data type for 4x4 32-bit integer matrices. More... | |
class | IMat4x2 |
Shader (GPU-side) data type for 4 columns, 2 rows 32-bit integer matrices. More... | |
class | IMat4x3 |
Shader (GPU-side) data type for 4 columns, 3 rows 32-bit integer matrices. More... | |
class | Img |
Class representing generic (untyped) Vulkan image. More... | |
class | inAttachment |
Input attachment binding point. More... | |
class | inConstSampledTexture |
A binding point for read-only texture with predefined (constant) sampler. More... | |
class | inConstSampler |
Static sampler binding point. More... | |
class | IndexedIndirectCommands |
Utility subclass representing a vector of indexed indirect draw ranges. More... | |
class | Indices |
Utility subclass representing a vector of indices for indexed draws. More... | |
class | IndirectBufferView |
class | IndirectCommands |
Utility subclass representing a vector of indirect draw ranges. More... | |
class | inPushConstant |
Binding point class for push constant data input to shaders. Place in your pipeline configuration class to declare a push constant. More... | |
class | Input |
Provides input access to communication variable binding point from shader code. More... | |
class | inSampledTexture |
A binding point for read-only texture with associated sampler. More... | |
class | inSampler |
Sampler binding point. More... | |
class | Instance |
Represents the instance of Vulkan system. More... | |
struct | InstanceStruct |
Base class for instance data structures. More... | |
class | Int |
Shader (GPU-side) data type for 32-bit signed integer values. More... | |
class | Int64 |
Shader (GPU-side) data type for 64-bit signed integer values. More... | |
class | inTexture |
Texture (read-only) image binding point. More... | |
class | inTextureBuffer |
Uniform (read-only) texel buffer binding point. More... | |
class | inUniformBuffer |
Binding point class for uniform (read-only) data input to shaders. Place in your pipeline configuration class to declare a uniform data source. More... | |
class | inUniformBufferDyn |
Currently not implemented. More... | |
struct | inVertexData |
Binding point class for vertex and instance input to shaders. Place in your pipeline configuration class to declare a vertex or instance data source. More... | |
class | ioBuffer |
Binding point class for storage (read-write) data buffer to shaders. Place in your pipeline configuration class to declare a storage data buffer. More... | |
class | ioBufferDyn |
Currently not implemented. More... | |
class | ioImage |
Storage (read-write) image binding point. More... | |
class | ioImageBuffer |
Storage (read-write) texel buffer binding point. More... | |
class | ioStructure |
Binding point class for inter-shader communication variable of structural type. Place in your pipeline configuration class to declare an inter-shader communication variable. More... | |
class | ioVariable |
Binding point class for inter-shader communication variable of simple type (scalar, vector or matrix). Place in your pipeline configuration class to declare an inter-shader communication variable. More... | |
class | IVec2 |
Shader (GPU-side) data type for 2-element 32-bit integer vectors. More... | |
class | IVec3 |
Shader (GPU-side) data type for 3-element 32-bit integer vectors. More... | |
class | IVec4 |
Shader (GPU-side) data type for 4-element 32-bit integer vectors. More... | |
class | LocalStruct |
Base class for local data structures. More... | |
class | MappableDeviceMemory |
class | Mat2 |
Shader (GPU-side) data type for 2x2 32-bit float matrices. More... | |
class | Mat2x3 |
Shader (GPU-side) data type for 2 columns, 3 rows 32-bit float matrices. More... | |
class | Mat2x4 |
Shader (GPU-side) data type for 2 columns, 4 rows 32-bit float matrices. More... | |
class | Mat3 |
Shader (GPU-side) data type for 3x3 32-bit float matrices. More... | |
class | Mat3x2 |
Shader (GPU-side) data type for 3 columns, 2 rows 32-bit float matrices. More... | |
class | Mat3x4 |
Shader (GPU-side) data type for 3 columns, 4 rows 32-bit float matrices. More... | |
class | Mat4 |
Shader (GPU-side) data type for 4x4 32-bit float matrices. More... | |
class | Mat4x2 |
Shader (GPU-side) data type for 4 columns, 2 rows 32-bit float matrices. More... | |
class | Mat4x3 |
Shader (GPU-side) data type for 4 columns, 3 rows 32-bit float matrices. More... | |
class | MemoryBarrier |
Single global memory barrier. More... | |
class | MemoryBinding |
A compound object containing references to a buffer and memory bound to it. More... | |
class | MemProfile |
Abstraction of GPU-interoperable memory types. More... | |
class | NonRenderingCommands |
Set of commands that may be used outside rendering context. More... | |
class | NormalizedSampler |
Texture sampler object (normalized). More... | |
struct | outAttachment |
Output attachment binding point. More... | |
class | Output |
Provides output access to communication variable binding point from shader code. More... | |
struct | Par |
Defines a function parameter. More... | |
class | PHVec4 |
class | PhysicalDevice |
Represents physical rendering device. More... | |
class | Pipeline |
Compiled pipeline class for graphics pipelines. More... | |
class | PipelineCache |
class | PipelineConfig |
Base class for custom rendering pipelines. More... | |
class | PipelineLayout |
Pipeline layout template for a graphics pipeline. Use to create actual pipeline layout (Vulkan objects) from abstract representation in the form of PipelineConfig object. More... | |
class | Pointer |
Shader (GPU-side) data type for pointers to workgroup and global scoped variables. More... | |
class | Postprocess |
Represents finalization process graph node. More... | |
class | Preprocess |
Represents preparation process graph node. More... | |
class | Procedure |
class | Process |
Represents process graph node. More... | |
class | Queue |
Command queue for execution of commands. More... | |
class | RenderGraph |
Base class for render graphs. More... | |
struct | RenderingCommandContext |
class | RenderingOptions |
A container for various rendering parameters. More... | |
class | RenderManager |
Simple rendering manager. More... | |
class | RenderPass |
Represents Vulkan render pass. More... | |
class | Semaphore |
Allows the GPU to wait for another GPU operation to finish. More... | |
struct | SGatherOffsets |
class | Shader |
Base class for shader interfaces. More... | |
class | ShaderDataBlock |
Represents a group of resources bound to rendering or compute pipeline. More... | |
struct | SNormalizedSampler |
Structure describing normalized sampler parameters. More... | |
class | StorageBufferView |
class | StreamDebugReporter |
A debug reporter class working with C++ output streams. More... | |
struct | SUnnormalizedSampler |
Structure describing unnormalized sampler parameters. More... | |
class | Surface |
Represents a surface visible on the screen. More... | |
struct | SurfaceInfo |
A platform-dependent structure containing information required to create a surface. More... | |
struct | SVulkanVersion |
Structure holding information about Vulkan version. More... | |
class | SwapChain |
Represents a set of swappable on-screen images. More... | |
class | TessControlShader |
Tessellation control shader interface. More... | |
class | tessControlShader |
Binding point class for tessellation control shaders. Place in your pipeline configuration class to declare a tessellation control shader. More... | |
class | tessEvalShader |
Binding point class for tessellation evaluation shaders. Place in your pipeline configuration class to declare a tessellation evaluation shader. More... | |
class | TessEvalShader |
Tessellation evaluation shader interface. More... | |
struct | TexelArray |
Provides shader code access to a binding point for a buffer holding array of formatted texels. These data objects are either simple scalars or vectors, defined by vpp::format object. More... | |
class | TexelBufferView |
Buffer view for texel buffers. More... | |
class | UInt |
Shader (GPU-side) data type for 32-bit unsigned integer values. More... | |
class | UInt64 |
Shader (GPU-side) data type for 64-bit unsigned integer values. More... | |
class | UniformArray |
Provides shader code access to a binding point for buffer holding array of structures. More... | |
class | UniformBufferView |
struct | UniformFld |
Template for defining uniform data fields. More... | |
class | UniformSimpleArray |
Provides shader code access to a binding point for buffer holding array of simple scalars, vectors or matrices. More... | |
class | UniformStruct |
Base class for uniform data structures. More... | |
class | UniformVar |
Provides access to scalar or arrayed buffer binding point from shader code. More... | |
class | UniversalCommands |
Set of commands that may be used anywhere (inside or outside rendering context). More... | |
class | UnnormalizedSampler |
Texture sampler object (normalized). More... | |
class | UVec2 |
Shader (GPU-side) data type for 2-element 32-bit unsigned integer vectors. More... | |
class | UVec3 |
Shader (GPU-side) data type for 3-element 32-bit unsigned integer vectors. More... | |
class | UVec4 |
Shader (GPU-side) data type for 4-element 32-bit unsigned integer vectors. More... | |
class | VArray |
Declares mutable shader local variable of array type. More... | |
class | VBool |
Shader (GPU-side) data type for mutable variables of boolean type. More... | |
class | VBVec2 |
Shader (GPU-side) data type for mutable variables of 2-element boolean vector type. More... | |
class | VBVec3 |
Shader (GPU-side) data type for mutable variables of 3-element boolean vector type. More... | |
class | VBVec4 |
Shader (GPU-side) data type for mutable variables of 4-element boolean vector type. More... | |
class | VDouble |
Shader (GPU-side) data type for mutable variables of 64-bit floating point type. More... | |
class | VDVec2 |
Shader (GPU-side) data type for mutable variables of 2-element 64-bit float vector type. More... | |
class | VDVec3 |
Shader (GPU-side) data type for mutable variables of 3-element 64-bit float vector type. More... | |
class | VDVec4 |
Shader (GPU-side) data type for mutable variables of 4-element 64-bit float vector type. More... | |
class | Vec2 |
Shader (GPU-side) data type for 2-element 32-bit float vectors. More... | |
class | Vec3 |
Shader (GPU-side) data type for 3-element 32-bit float vectors. More... | |
class | Vec4 |
Shader (GPU-side) data type for 4-element 32-bit float vectors. More... | |
class | VertexBufferView |
Buffer view for vertex buffers. More... | |
class | VertexIndexBufferView |
class | vertexShader |
Binding point class for vertex shaders. Place in your pipeline configuration class to declare a vertex shader. More... | |
class | VertexShader |
Vertex shader interface. More... | |
struct | VertexStruct |
Base class for vertex data structures. More... | |
class | VFloat |
Shader (GPU-side) data type for mutable variables of 32-bit floating point type. More... | |
struct | Viewport |
Helper class to define simple Vulkan viewport. More... | |
class | VInt |
Shader (GPU-side) data type for mutable variables of 32-bit signed integer type. More... | |
class | VInt64 |
Shader (GPU-side) data type for mutable variables of 64-bit signed integer type. More... | |
class | VIVec2 |
Shader (GPU-side) data type for mutable variables of 2-element 32-bit integer vector type. More... | |
class | VIVec3 |
Shader (GPU-side) data type for mutable variables of 3-element 32-bit integer vector type. More... | |
class | VIVec4 |
Shader (GPU-side) data type for mutable variables of 4-element 32-bit integer vector type. More... | |
class | VMat2 |
Shader (GPU-side) data type for mutable variables of 2x2 32-bit float matrix type. More... | |
class | VMat2x3 |
Shader (GPU-side) data type for mutable variables of 2 columns, 3 rows 32-bit float matrix type. More... | |
class | VMat2x4 |
Shader (GPU-side) data type for mutable variables of 2 columns, 4 rows 32-bit float matrix type. More... | |
class | VMat3 |
Shader (GPU-side) data type for mutable variables of 3x3 32-bit float matrix type. More... | |
class | VMat3x2 |
Shader (GPU-side) data type for mutable variables of 3 columns, 2 rows 32-bit float matrix type. More... | |
class | VMat3x4 |
Shader (GPU-side) data type for mutable variables of 3 columns, 4 rows 32-bit float matrix type. More... | |
class | VMat4 |
Shader (GPU-side) data type for mutable variables of 4x4 32-bit floating point matrix type. More... | |
class | VMat4x2 |
Shader (GPU-side) data type for mutable variables of 4 columns, 2 rows 32-bit float matrix type. More... | |
class | VMat4x3 |
Shader (GPU-side) data type for mutable variables of 4 columns, 3 rows 32-bit float matrix type. More... | |
class | Void |
Shader (GPU-side) void data type. More... | |
class | VUInt |
Shader (GPU-side) data type for mutable variables of 32-bit unsigned integer type. More... | |
class | VUInt64 |
Shader (GPU-side) data type for mutable variables of 64-bit unsigned integer type. More... | |
class | VUVec2 |
Shader (GPU-side) data type for mutable variables of 2-element 32-bit unsigned integer vector type. More... | |
class | VUVec3 |
Shader (GPU-side) data type for mutable variables of 3-element 32-bit unsigned integer vector type. More... | |
class | VUVec4 |
Shader (GPU-side) data type for mutable variables of 4-element 32-bit unsigned integer vector type. More... | |
class | VVec2 |
Shader (GPU-side) data type for mutable variables of 2-element 32-bit float vector type. More... | |
class | VVec3 |
Shader (GPU-side) data type for mutable variables of 3-element 32-bit float vector type. More... | |
class | VVec4 |
Shader (GPU-side) data type for mutable variables of 4-element 32-bit float vector type. More... | |
class | WArray |
Declares workgroup-scoped variable of array type. More... | |
class | WArray2 |
Declares workgroup-scoped variable of two-dimensional array type. More... | |
class | WArray3 |
class | WBool |
Shader (GPU-side) data type for workgroup variables of boolean type. More... | |
class | WDouble |
Shader (GPU-side) data type for workgroup variables of 64-bit floating point type. More... | |
class | WFloat |
Shader (GPU-side) data type for workgroup variables of 32-bit floating point type. More... | |
class | WInt |
Shader (GPU-side) data type for workgroup variables of 32-bit signed integer type. More... | |
class | WInt64 |
Shader (GPU-side) data type for workgroup variables of 64-bit unsigned integer type. More... | |
class | WUInt |
Shader (GPU-side) data type for workgroup variables of 32-bit unsigned integer type. More... | |
class | WUInt64 |
Shader (GPU-side) data type for workgroup variables of 64-bit unsigned integer type. More... | |
Typedefs | |
typedef Buffer< Buf::INDEX > | IndexBuffer |
Predefined class for index buffers, used in indexed draws. | |
typedef Buffer< Buf::VERTEX > | VertexBuffer |
Predefined class for vertex buffers. | |
typedef Buffer< Buf::INDIRECT > | IndirectBuffer |
Predefined class for indirect buffers, used in indirect draws. | |
template<class FormatT > | |
using | ImgTexture1D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_1D, VK_IMAGE_USAGE_SAMPLED_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgTexture2D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_2D, VK_IMAGE_USAGE_SAMPLED_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgTexture3D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_3D, VK_IMAGE_USAGE_SAMPLED_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgTextureCube = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_CUBE_2D, VK_IMAGE_USAGE_SAMPLED_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgStorage1D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_1D, VK_IMAGE_USAGE_STORAGE_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgStorage2D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_2D, VK_IMAGE_USAGE_STORAGE_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgStorage3D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_3D, VK_IMAGE_USAGE_STORAGE_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgStorageCube = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_CUBE_2D, VK_IMAGE_USAGE_STORAGE_BIT|VK_IMAGE_USAGE_TRANSFER_DST_BIT > > |
template<class FormatT > | |
using | ImgAttachment2D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_2D, VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT|VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT > > |
template<class FormatT > | |
using | ImgDepthAttachment2D = Image< ImageAttributes< FormatT, RENDER, IMG_TYPE_2D, VK_IMAGE_USAGE_DEPTH_STENCIL_ATTACHMENT_BIT|VK_IMAGE_USAGE_INPUT_ATTACHMENT_BIT > > |
typedef std::vector< PhysicalDevice > | PhysicalDevices |
Array of physical devices. | |
Enumerations | |
enum | EImagePurpose { RENDER, DISPLAY, SWAPCHAIN, RENDER_DEBUG } |
Enumeration specifying general purpose of an image. More... | |
enum | EImageType { IMG_TYPE_1D, IMG_TYPE_2D, IMG_TYPE_3D, IMG_TYPE_CUBE_2D, IMG_TYPE_RECT_2D } |
enum | ESamplingMode { SAMPLER_NORMALIZED, SAMPLER_UNNORMALIZED } |
enum | ETag { CPU, GPU, DEF } |
Enumeration type allowing to select the flavor of shader structural type: the CPU or GPU version. More... | |
enum | EMemorySemantics { MSM_NONE, MSM_ACQ, MSM_REL, MSM_ACQREL, MSM_UNIFORM, MSM_SUBGROUP, MSM_WORKGROUP, MSM_IMAGE } |
enum | EFeature { fRobustBufferAccess, fFullDrawIndexUint32, fImageCubeArray, fIndependentBlend, fGeometryShader, fTessellationShader, fSampleRateShading, fDualSrcBlend, fLogicOp, fMultiDrawIndirect, fDrawIndirectFirstInstance, fDepthClamp, fDepthBiasClamp, fFillModeNonSolid, fDepthBounds, fWideLines, fLargePoints, fAlphaToOne, fMultiViewport, fSamplerAnisotropy, fTextureCompressionETC2, fTextureCompressionASTC_LDR, fTextureCompressionBC, fOcclusionQueryPrecise, fPipelineStatisticsQuery, fVertexPipelineStoresAndAtomics, fFragmentStoresAndAtomics, fShaderTessellationAndGeometryPointSize, fShaderImageGatherExtended, fShaderStorageImageExtendedFormats, fShaderStorageImageMultisample, fShaderStorageImageReadWithoutFormat, fShaderStorageImageWriteWithoutFormat, fShaderUniformBufferArrayDynamicIndexing, fShaderSampledImageArrayDynamicIndexing, fShaderStorageBufferArrayDynamicIndexing, fShaderStorageImageArrayDynamicIndexing, fShaderClipDistance, fShaderCullDistance, fShaderFloat64, fShaderInt64, fShaderInt16, fShaderResourceResidency, fShaderResourceMinLod, fSparseBinding, fSparseResidencyBuffer, fSparseResidencyImage2D, fSparseResidencyImage3D, fSparseResidency2Samples, fSparseResidency4Samples, fSparseResidency8Samples, fSparseResidency16Samples, fSparseResidencyAliased, fVariableMultisampleRate, fInheritedQueries, fMultiview, fMultiviewGeometryShader, fMultiviewTessellationShader, fVariablePointersStorageBuffer, fVariablePointers, fStorageBuffer8BitAccess, fUniformAndStorageBuffer8BitAccess, fStoragePushConstant8, fShaderBufferInt64Atomics, fShaderSharedInt64Atomics, fStorageBuffer16BitAccess, fUniformAndStorageBuffer16BitAccess, fStoragePushConstant16, fStorageInputOutput16, fShaderFloat16, fShaderInt8, fSamplerYcbcrConversion, fProtectedMemory, fAdvancedBlendCoherentOperations, fConditionalRendering, fInheritedConditionalRendering, fShaderDrawParameters, fShaderInputAttachmentArrayDynamicIndexing, fShaderUniformTexelBufferArrayDynamicIndexing, fShaderStorageTexelBufferArrayDynamicIndexing, fShaderUniformBufferArrayNonUniformIndexing, fShaderSampledImageArrayNonUniformIndexing, fShaderStorageBufferArrayNonUniformIndexing, fShaderStorageImageArrayNonUniformIndexing, fShaderInputAttachmentArrayNonUniformIndexing, fShaderUniformTexelBufferArrayNonUniformIndexing, fShaderStorageTexelBufferArrayNonUniformIndexing, fDescriptorBindingUniformBufferUpdateAfterBind, fDescriptorBindingSampledImageUpdateAfterBind, fDescriptorBindingStorageImageUpdateAfterBind, fDescriptorBindingStorageBufferUpdateAfterBind, fDescriptorBindingUniformTexelBufferUpdateAfterBind, fDescriptorBindingStorageTexelBufferUpdateAfterBind, fDescriptorBindingUpdateUnusedWhilePending, fDescriptorBindingPartiallyBound, fDescriptorBindingVariableDescriptorCount, fRuntimeDescriptorArray, fDecodeModeSharedExponent, fVertexAttributeInstanceRateDivisor, fVertexAttributeInstanceRateZeroDivisor, fTransformFeedback, fGeometryStreams, fVulkanMemoryModel, fVulkanMemoryModelDeviceScope, fVulkanMemoryModelAvailabilityVisibilityChains, fInlineUniformBlock, fDescriptorBindingInlineUniformBlockUpdateAfterBind, fFragmentDensityMap, fFragmentDensityMapDynamic, fFragmentDensityMapNonSubsampledImages, fScalarBlockLayout, fDepthClipEnable, fMemoryPriority, fBufferDeviceAddress, fBufferDeviceAddressCaptureReplay, fBufferDeviceAddressMultiDevice, fExtBlendOperationAdvanced, fExtConditionalRendering, fExtConservativeRasterization, fExtDepthRangeUnrestricted, fExtDescriptorIndexing, fExtDiscardRectangles, fExtExternalMemoryHost, fExtHdrMetadata, fExtInlineUniformBlock, fExtPostDepthCoverage, fExtSampleLocations, fExtSamplerFilterMinmax, fExtScalarBlockLayout, fExtShaderSubgroupBallot, fExtShaderSubgroupVote, fExtShaderViewportIndexLayer, fExtTransformFeedback, fExtVertexAttributeDivisor, fExtStorage16bit, fExtStorage8bit, fExtBindMemory2, fExtCreateRenderpass2, fExtDedicatedAllocation, fExtDepthStencilResolve, fExtDescriptorUpdateTemplate, fExtDeviceGroup, fExtDrawIndirectCount, fExtDriverProperties, fExtExternalFence, fExtExternalFenceWin32, fExtExternalMemory, fExtExternalMemoryWin32, fExtExternalSemaphore, fExtExternalSemaphoreWin32, fExtGetMemoryRequirements2, fExtImageFormatList, fExtMultiview, fExtPushDescriptor, fExtRelaxedBlockLayout, fExtSamplerMirrorClampToEdge, fExtSamplerYcbcrConversion, fExtShaderAtomicInt64, fExtShaderDrawParameters, fExtShaderFloat16Int8, fExtShaderFloatControls, fExtStorageBufferStorageClass, fExtSwapchain, fExtSwapchainMutableFormat, fExtVariablePointers, fExtVulkanMemoryModel, fExtWin32KeyedMutex, fExtFragmentDensityMap, fExtAstcDecodeMode, fExtDepthClipEnable, fExtMemoryPriority, fExtBufferDeviceAddress } |
Optional device feature enumeration. More... | |
Functions | |
template<typename ... Args> | |
BarrierList | barriers (VkPipelineStageFlags sourceStage, VkPipelineStageFlags targetStage, Args &&... args) |
Creates a BarrierList object for specified resources. More... | |
BarrierList | barriers (const Img &hImage, const std::vector< VkImageSubresourceRange > ®ions, VkPipelineStageFlags sourceStage, VkPipelineStageFlags targetStage) |
Creates a BarrierList object for specified regions of an image. More... | |
template<class ResourceT > | |
MemoryBinding< ResourceT, DeviceMemory > | bindDeviceMemory (const ResourceT &res, const MemProfile &memProfile) |
Binds specified buffer to a DeviceMemory memory, and returns MemoryBinding object. More... | |
template<class ResourceT > | |
MemoryBinding< ResourceT, MappableDeviceMemory > | bindMappableMemory (const ResourceT &res, const MemProfile &memProfile) |
Binds specified buffer to a MappableDeviceMemory memory, and returns MemoryBinding object. More... | |
template<class AttributesT > | |
auto | bind (const ImageView< AttributesT > &view, VkImageLayout layout=VK_IMAGE_LAYOUT_UNDEFINED) |
Helper function to bind specified image view to a binding point in a pipeline. More... | |
template<class AttributesT , class SamplerT > | |
auto | bind (const SamplerT &sampler, const ImageView< AttributesT > &view, VkImageLayout layout=VK_IMAGE_LAYOUT_UNDEFINED) |
Helper function to bind specified image view and a sampler to a binding point in a pipeline. More... | |
void | If (Bool v) |
Creates the if clause of the conditional construct. More... | |
void | Else () |
Creates the else clause of the conditional construct. More... | |
void | Fi () |
Creates the ending clause of the conditional construct. More... | |
void | Do () |
Creates the do clause of the loop construct. More... | |
void | While (Bool v) |
Creates the while clause of the loop construct. More... | |
void | Od () |
Creates the closing clause of the loop construct. More... | |
void | For (VInt &variable, Int begin, Int end, Int step=1) |
Creates the for clause of the 'for' loop construct. More... | |
void | For (VUInt &variable, UInt begin, UInt end, UInt step=1) |
void | Rof () |
Creates the closing clause of the 'for' loop construct. More... | |
void | Switch (Int expr) |
Creates the switch construct. More... | |
void | Case (int value) |
Creates the case clause of the switch construct. | |
void | Default () |
Creates the default clause of the switch construct. | |
void | Break () |
Creates the break clause of the switch construct. | |
void | EndSwitch () |
Creates the closing clause of the switch construct. | |
void | Begin () |
Marks the start of function body. More... | |
void | End () |
Marks the end of function body. More... | |
void | Return () |
Immediately returns from the function. More... | |
template<typename ValueT > | |
void | Return (const ValueT &value) |
Returns the value from the function. | |
template<class CondT , class Arg1T , class Arg2T > | |
auto | Select (const CondT &cond, const Arg1T &argIfTrue, const Arg2T &argIfFalse) |
A conditional expression. More... | |
void | WorkgroupBarrier (EMemorySemantics msClass=MSM_WORKGROUP, EMemorySemantics msSem=MSM_ACQREL) |
Creates control and memory barrier affecting threads in a workgroup. | |
void | SubgroupBarrier (EMemorySemantics msClass=MSM_SUBGROUP, EMemorySemantics msSem=MSM_ACQREL) |
Creates control and memory barrier affecting threads in a subgroup. | |
template<typename TargetT , typename SourceT > | |
TargetT | StaticCast (const SourceT &source) |
General type conversion function. More... | |
template<typename TargetT , typename SourceT > | |
TargetT | ReinterpretCast (const SourceT &source) |
Bit pattern type conversion function. More... | |
Float | Round (const Float &x) |
Computes nearest whole number to x. More... | |
Vec2 | Round (const Vec2 &x) |
Vec3 | Round (const Vec3 &x) |
Vec4 | Round (const Vec4 &x) |
Double | Round (const Double &x) |
DVec2 | Round (const DVec2 &x) |
DVec3 | Round (const DVec3 &x) |
DVec4 | Round (const DVec4 &x) |
Float | RoundEven (const Float &x) |
Computes nearest whole number to x. More... | |
Vec2 | RoundEven (const Vec2 &x) |
Vec3 | RoundEven (const Vec3 &x) |
Vec4 | RoundEven (const Vec4 &x) |
Double | RoundEven (const Double &x) |
DVec2 | RoundEven (const DVec2 &x) |
DVec3 | RoundEven (const DVec3 &x) |
DVec4 | RoundEven (const DVec4 &x) |
Float | Trunc (const Float &x) |
Computes nearest whole number to x whose absolute value is not larger than the absolute value of x. | |
Vec2 | Trunc (const Vec2 &x) |
Vec3 | Trunc (const Vec3 &x) |
Vec4 | Trunc (const Vec4 &x) |
Double | Trunc (const Double &x) |
DVec2 | Trunc (const DVec2 &x) |
DVec3 | Trunc (const DVec3 &x) |
DVec4 | Trunc (const DVec4 &x) |
Int | Abs (const Int &x) |
Result is x if x >= 0. Otherwise result is -x. | |
IVec2 | Abs (const IVec2 &x) |
IVec3 | Abs (const IVec3 &x) |
IVec4 | Abs (const IVec4 &x) |
Float | Abs (const Float &x) |
Vec2 | Abs (const Vec2 &x) |
Vec3 | Abs (const Vec3 &x) |
Vec4 | Abs (const Vec4 &x) |
Double | Abs (const Double &x) |
DVec2 | Abs (const DVec2 &x) |
DVec3 | Abs (const DVec3 &x) |
DVec4 | Abs (const DVec4 &x) |
Int | Sign (const Int &x) |
Result is 1 if x > 0, 0 if x == 0, or -1 if x < 0. | |
IVec2 | Sign (const IVec2 &x) |
IVec3 | Sign (const IVec3 &x) |
IVec4 | Sign (const IVec4 &x) |
Float | Sign (const Float &x) |
Vec2 | Sign (const Vec2 &x) |
Vec3 | Sign (const Vec3 &x) |
Vec4 | Sign (const Vec4 &x) |
Double | Sign (const Double &x) |
DVec2 | Sign (const DVec2 &x) |
DVec3 | Sign (const DVec3 &x) |
DVec4 | Sign (const DVec4 &x) |
Float | Floor (const Float &x) |
Computes nearest whole number that is less than or equal to x. | |
Vec2 | Floor (const Vec2 &x) |
Vec3 | Floor (const Vec3 &x) |
Vec4 | Floor (const Vec4 &x) |
Double | Floor (const Double &x) |
DVec2 | Floor (const DVec2 &x) |
DVec3 | Floor (const DVec3 &x) |
DVec4 | Floor (const DVec4 &x) |
Float | Ceil (const Float &x) |
Computes nearest whole number that is greater than or equal to x. | |
Vec2 | Ceil (const Vec2 &x) |
Vec3 | Ceil (const Vec3 &x) |
Vec4 | Ceil (const Vec4 &x) |
Double | Ceil (const Double &x) |
DVec2 | Ceil (const DVec2 &x) |
DVec3 | Ceil (const DVec3 &x) |
DVec4 | Ceil (const DVec4 &x) |
Float | Fract (const Float &x) |
Computes x - Floor(x). | |
Vec2 | Fract (const Vec2 &x) |
Vec3 | Fract (const Vec3 &x) |
Vec4 | Fract (const Vec4 &x) |
Double | Fract (const Double &x) |
DVec2 | Fract (const DVec2 &x) |
DVec3 | Fract (const DVec3 &x) |
DVec4 | Fract (const DVec4 &x) |
Float | Radians (const Float &x) |
Converts degrees to radians. | |
Vec2 | Radians (const Vec2 &x) |
Vec3 | Radians (const Vec3 &x) |
Vec4 | Radians (const Vec4 &x) |
Float | Degrees (const Float &x) |
Converts radians to degrees. | |
Vec2 | Degrees (const Vec2 &x) |
Vec3 | Degrees (const Vec3 &x) |
Vec4 | Degrees (const Vec4 &x) |
Float | Sin (const Float &x) |
The standard trigonometric sine of x radians. | |
Vec2 | Sin (const Vec2 &x) |
Vec3 | Sin (const Vec3 &x) |
Vec4 | Sin (const Vec4 &x) |
Float | Cos (const Float &x) |
The standard trigonometric cosine of x radians. | |
Vec2 | Cos (const Vec2 &x) |
Vec3 | Cos (const Vec3 &x) |
Vec4 | Cos (const Vec4 &x) |
Float | Tan (const Float &x) |
The standard trigonometric tangent of x radians. | |
Vec2 | Tan (const Vec2 &x) |
Vec3 | Tan (const Vec3 &x) |
Vec4 | Tan (const Vec4 &x) |
Float | Asin (const Float &x) |
Arc sine. Result is an angle, in radians, whose sine is x. More... | |
Vec2 | Asin (const Vec2 &x) |
Vec3 | Asin (const Vec3 &x) |
Vec4 | Asin (const Vec4 &x) |
Float | Acos (const Float &x) |
Arc cosine. Result is an angle, in radians, whose cosine is x. More... | |
Vec2 | Acos (const Vec2 &x) |
Vec3 | Acos (const Vec3 &x) |
Vec4 | Acos (const Vec4 &x) |
Float | Atan (const Float &x) |
Arc tangent. Result is an angle, in radians, whose tangent is x. The range of result values is [-pi, pi]. | |
Vec2 | Atan (const Vec2 &x) |
Vec3 | Atan (const Vec3 &x) |
Vec4 | Atan (const Vec4 &x) |
Float | Sinh (const Float &x) |
Hyperbolic sine of x radians. | |
Vec2 | Sinh (const Vec2 &x) |
Vec3 | Sinh (const Vec3 &x) |
Vec4 | Sinh (const Vec4 &x) |
Float | Cosh (const Float &x) |
Hyperbolic cosine of x radians. | |
Vec2 | Cosh (const Vec2 &x) |
Vec3 | Cosh (const Vec3 &x) |
Vec4 | Cosh (const Vec4 &x) |
Float | Tanh (const Float &x) |
Hyperbolic tangent of x radians. | |
Vec2 | Tanh (const Vec2 &x) |
Vec3 | Tanh (const Vec3 &x) |
Vec4 | Tanh (const Vec4 &x) |
Float | Asinh (const Float &x) |
Arc hyperbolic sine. More... | |
Vec2 | Asinh (const Vec2 &x) |
Vec3 | Asinh (const Vec3 &x) |
Vec4 | Asinh (const Vec4 &x) |
Float | Acosh (const Float &x) |
Arc hyperbolic cosine. More... | |
Vec2 | Acosh (const Vec2 &x) |
Vec3 | Acosh (const Vec3 &x) |
Vec4 | Acosh (const Vec4 &x) |
Float | Atanh (const Float &x) |
Arc hyperbolic tangent. More... | |
Vec2 | Atanh (const Vec2 &x) |
Vec3 | Atanh (const Vec3 &x) |
Vec4 | Atanh (const Vec4 &x) |
Float | Atan2 (const Float &y, const Float &x) |
Arc tangent. More... | |
Vec2 | Atan2 (const Vec2 &y, const Vec2 &x) |
Vec3 | Atan2 (const Vec3 &y, const Vec3 &x) |
Vec4 | Atan2 (const Vec4 &y, const Vec4 &x) |
Float | Pow (const Float &x, const Float &y) |
Computes x raised to the y power. More... | |
Vec2 | Pow (const Vec2 &x, const Vec2 &y) |
Vec3 | Pow (const Vec3 &x, const Vec3 &y) |
Vec4 | Pow (const Vec4 &x, const Vec4 &y) |
Float | Exp (const Float &x) |
Computes the natural exponentiation of x (e^x). | |
Vec2 | Exp (const Vec2 &x) |
Vec3 | Exp (const Vec3 &x) |
Vec4 | Exp (const Vec4 &x) |
Float | Log (const Float &x) |
Computes the natural logarithm of x. More... | |
Vec2 | Log (const Vec2 &x) |
Vec3 | Log (const Vec3 &x) |
Vec4 | Log (const Vec4 &x) |
Float | Exp2 (const Float &x) |
Computes 2 raised to the x power (2^x). | |
Vec2 | Exp2 (const Vec2 &x) |
Vec3 | Exp2 (const Vec3 &x) |
Vec4 | Exp2 (const Vec4 &x) |
Float | Log2 (const Float &x) |
Computes the base-2 logarithm of x. More... | |
Vec2 | Log2 (const Vec2 &x) |
Vec3 | Log2 (const Vec3 &x) |
Vec4 | Log2 (const Vec4 &x) |
Float | Sqrt (const Float &x) |
Computes the square root of x. More... | |
Vec2 | Sqrt (const Vec2 &x) |
Vec3 | Sqrt (const Vec3 &x) |
Vec4 | Sqrt (const Vec4 &x) |
Double | Sqrt (const Double &x) |
DVec2 | Sqrt (const DVec2 &x) |
DVec3 | Sqrt (const DVec3 &x) |
DVec4 | Sqrt (const DVec4 &x) |
Float | InverseSqrt (const Float &x) |
Computes the reciprocal of Sqrt(x). More... | |
Vec2 | InverseSqrt (const Vec2 &x) |
Vec3 | InverseSqrt (const Vec3 &x) |
Vec4 | InverseSqrt (const Vec4 &x) |
Double | InverseSqrt (const Double &value) |
DVec2 | InverseSqrt (const DVec2 &value) |
DVec3 | InverseSqrt (const DVec3 &value) |
DVec4 | InverseSqrt (const DVec4 &value) |
Float | Determinant (const Mat2 &x) |
Computes the determinant of x. | |
Float | Determinant (const Mat3 &x) |
Float | Determinant (const Mat4 &x) |
Double | Determinant (const DMat2 &x) |
Double | Determinant (const DMat3 &x) |
Double | Determinant (const DMat4 &x) |
Mat2 | MatrixInverse (const Mat2 &x) |
Computes a matrix that is the inverse of x. More... | |
Mat3 | MatrixInverse (const Mat3 &x) |
Mat4 | MatrixInverse (const Mat4 &x) |
DMat2 | MatrixInverse (const DMat2 &x) |
DMat3 | MatrixInverse (const DMat3 &x) |
DMat4 | MatrixInverse (const DMat4 &x) |
template<typename ScalarT , size_t COLS, size_t ROWS> | |
Matrix< ScalarT, ROWS, COLS > | Transpose (const Matrix< ScalarT, COLS, ROWS > &value) |
Computes the transposition of a matrix. | |
Int | Min (const Int &x, const Int &y) |
Result is y if y < x, otherwise result is x. More... | |
IVec2 | Min (const IVec2 &x, const IVec2 &y) |
IVec3 | Min (const IVec3 &x, const IVec3 &y) |
IVec4 | Min (const IVec4 &x, const IVec4 &y) |
UInt | Min (const UInt &x, const UInt &y) |
UVec2 | Min (const UVec2 &x, const UVec2 &y) |
UVec3 | Min (const UVec3 &x, const UVec3 &y) |
UVec4 | Min (const UVec4 &x, const UVec4 &y) |
Float | Min (const Float &x, const Float &y) |
Vec2 | Min (const Vec2 &x, const Vec2 &y) |
Vec3 | Min (const Vec3 &x, const Vec3 &y) |
Vec4 | Min (const Vec4 &x, const Vec4 &y) |
Double | Min (const Double &x, const Double &y) |
DVec2 | Min (const DVec2 &x, const DVec2 &y) |
DVec3 | Min (const DVec3 &x, const DVec3 &y) |
DVec4 | Min (const DVec4 &x, const DVec4 &y) |
Int | Max (const Int &x, const Int &y) |
Result is y if x < y, otherwise result is x. More... | |
IVec2 | Max (const IVec2 &x, const IVec2 &y) |
IVec3 | Max (const IVec3 &x, const IVec3 &y) |
IVec4 | Max (const IVec4 &x, const IVec4 &y) |
UInt | Max (const UInt &x, const UInt &y) |
UVec2 | Max (const UVec2 &x, const UVec2 &y) |
UVec3 | Max (const UVec3 &x, const UVec3 &y) |
UVec4 | Max (const UVec4 &x, const UVec4 &y) |
Float | Max (const Float &x, const Float &y) |
Vec2 | Max (const Vec2 &x, const Vec2 &y) |
Vec3 | Max (const Vec3 &x, const Vec3 &y) |
Vec4 | Max (const Vec4 &x, const Vec4 &y) |
Double | Max (const Double &x, const Double &y) |
DVec2 | Max (const DVec2 &x, const DVec2 &y) |
DVec3 | Max (const DVec3 &x, const DVec3 &y) |
DVec4 | Max (const DVec4 &x, const DVec4 &y) |
Int | Clamp (const Int &x, const Int &minVal, const Int &maxVal) |
Computes the value of Min ( Max ( x, minVal ), maxVal ). More... | |
IVec2 | Clamp (const IVec2 &x, const IVec2 &minVal, const IVec2 &maxVal) |
IVec3 | Clamp (const IVec3 &x, const IVec3 &minVal, const IVec3 &maxVal) |
IVec4 | Clamp (const IVec4 &x, const IVec4 &minVal, const IVec4 &maxVal) |
UInt | Clamp (const UInt &x, const UInt &minVal, const UInt &maxVal) |
UVec2 | Clamp (const UVec2 &x, const UVec2 &minVal, const UVec2 &maxVal) |
UVec3 | Clamp (const UVec3 &x, const UVec3 &minVal, const UVec3 &maxVal) |
UVec4 | Clamp (const UVec4 &x, const UVec4 &minVal, const UVec4 &maxVal) |
Float | Clamp (const Float &x, const Float &minVal, const Float &maxVal) |
Vec2 | Clamp (const Vec2 &x, const Vec2 &minVal, const Vec2 &maxVal) |
Vec3 | Clamp (const Vec3 &x, const Vec3 &minVal, const Vec3 &maxVal) |
Vec4 | Clamp (const Vec4 &x, const Vec4 &minVal, const Vec4 &maxVal) |
Double | Clamp (const Double &x, const Double &minVal, const Double &maxVal) |
DVec2 | Clamp (const DVec2 &x, const DVec2 &minVal, const DVec2 &maxVal) |
DVec3 | Clamp (const DVec3 &x, const DVec3 &minVal, const DVec3 &maxVal) |
DVec4 | Clamp (const DVec4 &x, const DVec4 &minVal, const DVec4 &maxVal) |
Float | Mix (const Float &x, const Float &y, const Float &a) |
Computes the linear blend of x and y, i.e., x * (1 - a) + y * a. | |
Vec2 | Mix (const Vec2 &x, const Vec2 &y, const Vec2 &a) |
Vec3 | Mix (const Vec3 &x, const Vec3 &y, const Vec3 &a) |
Vec4 | Mix (const Vec4 &x, const Vec4 &y, const Vec4 &a) |
Double | Mix (const Double &x, const Double &y, const Double &a) |
DVec2 | Mix (const DVec2 &x, const DVec2 &y, const DVec2 &a) |
DVec3 | Mix (const DVec3 &x, const DVec3 &y, const DVec3 &a) |
DVec4 | Mix (const DVec4 &x, const DVec4 &y, const DVec4 &a) |
Float | Step (const Float &edge, const Float &x) |
Result is 0 if x < edge. Otherwise result is 1. | |
Vec2 | Step (const Vec2 &edge, const Vec2 &x) |
Vec3 | Step (const Vec3 &edge, const Vec3 &x) |
Vec4 | Step (const Vec4 &edge, const Vec4 &x) |
Double | Step (const Double &edge, const Double &x) |
DVec2 | Step (const DVec2 &edge, const DVec2 &x) |
DVec3 | Step (const DVec3 &edge, const DVec3 &x) |
DVec4 | Step (const DVec4 &edge, const DVec4 &x) |
Float | SmoothStep (const Float &edge0, const Float &edge1, const Float &x) |
Result is 0 if x <= edge0, 1 if x >= edge1, or smooth Hermite interpolation between 0 and 1 when edge0 < x < edge1. More... | |
Vec2 | SmoothStep (const Vec2 &edge0, const Vec2 &edge1, const Vec2 &x) |
Vec3 | SmoothStep (const Vec3 &edge0, const Vec3 &edge1, const Vec3 &x) |
Vec4 | SmoothStep (const Vec4 &edge0, const Vec4 &edge1, const Vec4 &x) |
Double | SmoothStep (const Double &edge0, const Double &edge1, const Double &x) |
DVec2 | SmoothStep (const DVec2 &edge0, const DVec2 &edge1, const DVec2 &x) |
DVec3 | SmoothStep (const DVec3 &edge0, const DVec3 &edge1, const DVec3 &x) |
DVec4 | SmoothStep (const DVec4 &edge0, const DVec4 &edge1, const DVec4 &x) |
Float | Fma (const Float &edge0, const Float &edge1, const Float &x) |
Computes a * b + c. | |
Vec2 | Fma (const Vec2 &edge0, const Vec2 &edge1, const Vec2 &x) |
Vec3 | Fma (const Vec3 &edge0, const Vec3 &edge1, const Vec3 &x) |
Vec4 | Fma (const Vec4 &edge0, const Vec4 &edge1, const Vec4 &x) |
Double | Fma (const Double &a, const Double &b, const Double &c) |
DVec2 | Fma (const DVec2 &a, const DVec2 &b, const DVec2 &c) |
DVec3 | Fma (const DVec3 &a, const DVec3 &b, const DVec3 &c) |
DVec4 | Fma (const DVec4 &a, const DVec4 &b, const DVec4 &c) |
UInt | PackSnorm4x8 (const Vec4 &v) |
Converts each component of the signed normalized floating-point value v into 8-bit integer values and packs them into the result. More... | |
UInt | PackUnorm4x8 (const Vec4 &v) |
Converts each component of the positive normalized floating-point value v into 8-bit integer values and packs them into the result. More... | |
UInt | PackSnorm2x16 (const Vec2 &v) |
Converts each component of the signed normalized floating-point value v into 16-bit integer values and packs them into the result. More... | |
UInt | PackUnorm2x16 (const Vec2 &v) |
Converts each component of the positive normalized floating-point value v into 16-bit integer values and packs them into the result. More... | |
UInt | PackHalf2x16 (const Vec2 &v) |
Converts the components of a two-component floating-point vector to the 16-bit float, then packs them into a 32-bit unsigned integer. More... | |
Double | PackDouble2x32 (const UVec2 &v) |
Packs the components of v into a 64-bit value. More... | |
Vec2 | UnpackSnorm2x16 (const UInt &p) |
Unpacks a single 32-bit unsigned integer p into a pair of 16-bit signed integers and converts them to normalized floating-point values. More... | |
Vec2 | UnpackUnorm2x16 (const UInt &p) |
Unpacks a single 32-bit unsigned integer p into a pair of 16-bit unsigned integers. and converts them to normalized floating-point values. More... | |
Vec2 | UnpackHalf2x16 (const UInt &v) |
Unpacks a 32-bit unsigned integer into a pair of 16-bit values, interpreted as 16-bit floating-point numbers, and converts them to 32-bit floating-point values. More... | |
Vec4 | UnpackSnorm4x8 (const UInt &p) |
Unpacks a single 32-bit unsigned integer p into four 8-bit signed integers and converts them to normalized floating-point values. More... | |
Vec4 | UnpackUnorm4x8 (const UInt &p) |
Unpacks a single 32-bit unsigned integer p into four 8-bit unsigned integers and converts them to normalized floating-point values. More... | |
UVec2 | UnpackDouble2x32 (const Double &value) |
Computes the two-component unsigned integer vector representation of v. The bit-level representation of v is preserved. More... | |
Float | Dot (const Vec2 &lhs, const Vec2 &rhs) |
Computes dot product of two vectors. | |
Float | Dot (const Vec3 &lhs, const Vec3 &rhs) |
Float | Dot (const Vec4 &lhs, const Vec4 &rhs) |
Double | Dot (const DVec2 &lhs, const DVec2 &rhs) |
Double | Dot (const DVec3 &lhs, const DVec3 &rhs) |
Double | Dot (const DVec4 &lhs, const DVec4 &rhs) |
template<size_t COLS, size_t ROWS> | |
TRMatrix< Float, COLS, ROWS > | OuterProduct (const TRVector< Float, ROWS > &lhs, const TRVector< Float, COLS > &rhs) |
Computes linear-algebraic outer product of two vectors. | |
template<size_t COLS, size_t ROWS> | |
TRMatrix< Double, COLS, ROWS > | OuterProduct (const TRVector< Double, ROWS > &lhs, const TRVector< Double, COLS > &rhs) |
Float | Length (const Float &value) |
Computes the length of a vector. | |
Float | Length (const Vec2 &value) |
Float | Length (const Vec3 &value) |
Float | Length (const Vec4 &value) |
Double | Length (const Double &value) |
Double | Length (const DVec2 &value) |
Double | Length (const DVec3 &value) |
Double | Length (const DVec4 &value) |
Float | Distance (const Float &v1, const Float &v2) |
Computes the distance between v1 and v2. | |
Float | Distance (const Vec2 &v1, const Vec2 &v2) |
Float | Distance (const Vec3 &v1, const Vec3 &v2) |
Float | Distance (const Vec4 &v1, const Vec4 &v2) |
Double | Distance (const Double &v1, const Double &v2) |
Double | Distance (const DVec2 &v1, const DVec2 &v2) |
Double | Distance (const DVec3 &v1, const DVec3 &v2) |
Double | Distance (const DVec4 &v1, const DVec4 &v2) |
Vec3 | Cross (const Vec3 &x, const Vec3 &y) |
Computes the cross product of x and y. | |
DVec3 | Cross (const DVec3 &x, const DVec3 &y) |
Float | Normalize (const Float &x) |
Computes the vector in the same direction as x but with a length of 1. | |
Vec2 | Normalize (const Vec2 &x) |
Vec3 | Normalize (const Vec3 &x) |
Vec4 | Normalize (const Vec4 &x) |
Double | Normalize (const Double &x) |
DVec2 | Normalize (const DVec2 &x) |
DVec3 | Normalize (const DVec3 &x) |
DVec4 | Normalize (const DVec4 &x) |
Float | FaceForward (const Float &n, const Float &i, const Float &nref) |
If the dot product of nref and i is negative, the result is n, otherwise it is -n. | |
Vec2 | FaceForward (const Vec2 &n, const Vec2 &i, const Vec2 &nref) |
Vec3 | FaceForward (const Vec3 &n, const Vec3 &i, const Vec3 &nref) |
Vec4 | FaceForward (const Vec4 &n, const Vec4 &i, const Vec4 &nref) |
Double | FaceForward (const Double &n, const Double &i, const Double &nref) |
DVec2 | FaceForward (const DVec2 &n, const DVec2 &i, const DVec2 &nref) |
DVec3 | FaceForward (const DVec3 &n, const DVec3 &i, const DVec3 &nref) |
DVec4 | FaceForward (const DVec4 &n, const DVec4 &i, const DVec4 &nref) |
Float | Reflect (const Float &i, const Float &n) |
Computes reflected vector to the vector i . More... | |
Vec2 | Reflect (const Vec2 &i, const Vec2 &n) |
Vec3 | Reflect (const Vec3 &i, const Vec3 &n) |
Vec4 | Reflect (const Vec4 &i, const Vec4 &n) |
Double | Reflect (const Double &i, const Double &n) |
DVec2 | Reflect (const DVec2 &i, const DVec2 &n) |
DVec3 | Reflect (const DVec3 &i, const DVec3 &n) |
DVec4 | Reflect (const DVec4 &i, const DVec4 &n) |
Float | Refract (const Float &i, const Float &n, const Float &eta) |
Computes refracted vector to the vector i . More... | |
Vec2 | Refract (const Vec2 &i, const Vec2 &n, const Float &eta) |
Vec3 | Refract (const Vec3 &i, const Vec3 &n, const Float &eta) |
Vec4 | Refract (const Vec4 &i, const Vec4 &n, const Float &eta) |
Double | Refract (const Double &i, const Double &n, const Float &eta) |
DVec2 | Refract (const DVec2 &i, const DVec2 &n, const Float &eta) |
DVec3 | Refract (const DVec3 &i, const DVec3 &n, const Float &eta) |
DVec4 | Refract (const DVec4 &i, const DVec4 &n, const Float &eta) |
Int | FindLsb (const Int &v) |
Computes the bit number of the least-significant 1-bit in the binary representation of v . More... | |
IVec2 | FindLsb (const IVec2 &v) |
IVec3 | FindLsb (const IVec3 &v) |
IVec4 | FindLsb (const IVec4 &v) |
UInt | FindLsb (const UInt &v) |
UVec2 | FindLsb (const UVec2 &v) |
UVec3 | FindLsb (const UVec3 &v) |
UVec4 | FindLsb (const UVec4 &v) |
Int | FindMsb (const Int &value) |
Computes the bit number of the most-significant 1-bit in the binary representation of v . More... | |
IVec2 | FindMsb (const IVec2 &value) |
IVec3 | FindMsb (const IVec3 &value) |
IVec4 | FindMsb (const IVec4 &value) |
UInt | FindMsb (const UInt &value) |
UVec2 | FindMsb (const UVec2 &value) |
UVec3 | FindMsb (const UVec3 &value) |
UVec4 | FindMsb (const UVec4 &value) |
Float | NMin (const Float &x, const Float &y) |
Result is y if y < x, otherwise result is x. More... | |
Vec2 | NMin (const Vec2 &x, const Vec2 &y) |
Vec3 | NMin (const Vec3 &x, const Vec3 &y) |
Vec4 | NMin (const Vec4 &x, const Vec4 &y) |
Double | NMin (const Double &x, const Double &y) |
DVec2 | NMin (const DVec2 &x, const DVec2 &y) |
DVec3 | NMin (const DVec3 &x, const DVec3 &y) |
DVec4 | NMin (const DVec4 &x, const DVec4 &y) |
Float | NMax (const Float &x, const Float &y) |
Result is y if x < y, otherwise result is x. More... | |
Vec2 | NMax (const Vec2 &x, const Vec2 &y) |
Vec3 | NMax (const Vec3 &x, const Vec3 &y) |
Vec4 | NMax (const Vec4 &x, const Vec4 &y) |
Double | NMax (const Double &x, const Double &y) |
DVec2 | NMax (const DVec2 &x, const DVec2 &y) |
DVec3 | NMax (const DVec3 &x, const DVec3 &y) |
DVec4 | NMax (const DVec4 &x, const DVec4 &y) |
Float | NClamp (const Float &x, const Float &minVal, const Float &maxVal) |
Result is min ( max ( x, minVal), maxVal ). More... | |
Vec2 | NClamp (const Vec2 &x, const Vec2 &minVal, const Vec2 &maxVal) |
Vec3 | NClamp (const Vec3 &x, const Vec3 &minVal, const Vec3 &maxVal) |
Vec4 | NClamp (const Vec4 &x, const Vec4 &minVal, const Vec4 &maxVal) |
Double | NClamp (const Double &x, const Double &minVal, const Double &maxVal) |
DVec2 | NClamp (const DVec2 &x, const DVec2 &minVal, const DVec2 &maxVal) |
DVec3 | NClamp (const DVec3 &x, const DVec3 &minVal, const DVec3 &maxVal) |
DVec4 | NClamp (const DVec4 &x, const DVec4 &minVal, const DVec4 &maxVal) |
Int | Mod (const Int &lhs, const Int &rhs) |
Modulo operation of lhs modulo rhs . More... | |
IVec2 | Mod (const IVec2 &lhs, const IVec2 &rhs) |
IVec3 | Mod (const IVec3 &lhs, const IVec3 &rhs) |
IVec4 | Mod (const IVec4 &lhs, const IVec4 &rhs) |
IMat2 | Mod (const IMat2 &lhs, const IMat2 &rhs) |
IMat3 | Mod (const IMat3 &lhs, const IMat3 &rhs) |
IMat4 | Mod (const IMat4 &lhs, const IMat4 &rhs) |
UInt | Mod (const UInt &lhs, const UInt &rhs) |
UVec2 | Mod (const UVec2 &lhs, const UVec2 &rhs) |
UVec3 | Mod (const UVec3 &lhs, const UVec3 &rhs) |
UVec4 | Mod (const UVec4 &lhs, const UVec4 &rhs) |
UMat2 | Mod (const UMat2 &lhs, const UMat2 &rhs) |
UMat3 | Mod (const UMat3 &lhs, const UMat3 &rhs) |
UMat4 | Mod (const UMat4 &lhs, const UMat4 &rhs) |
Float | Mod (const Float &lhs, const Float &rhs) |
Vec2 | Mod (const Vec2 &lhs, const Vec2 &rhs) |
Vec3 | Mod (const Vec3 &lhs, const Vec3 &rhs) |
Vec4 | Mod (const Vec4 &lhs, const Vec4 &rhs) |
Mat2 | Mod (const Mat2 &lhs, const Mat2 &rhs) |
Mat3 | Mod (const Mat3 &lhs, const Mat3 &rhs) |
Mat4 | Mod (const Mat4 &lhs, const Mat4 &rhs) |
Double | Mod (const Double &lhs, const Double &rhs) |
DVec2 | Mod (const DVec2 &lhs, const DVec2 &rhs) |
DVec3 | Mod (const DVec3 &lhs, const DVec3 &rhs) |
DVec4 | Mod (const DVec4 &lhs, const DVec4 &rhs) |
DMat2 | Mod (const DMat2 &lhs, const DMat2 &rhs) |
DMat3 | Mod (const DMat3 &lhs, const DMat3 &rhs) |
DMat4 | Mod (const DMat4 &lhs, const DMat4 &rhs) |
std::pair< Float, Float > | Modf (const Float &x) |
Computes the fractional part of x (as the first result) and the whole number part (second result). More... | |
std::pair< Vec2, Vec2 > | Modf (const Vec2 &x) |
std::pair< Vec3, Vec3 > | Modf (const Vec3 &x) |
std::pair< Vec4, Vec4 > | Modf (const Vec4 &x) |
std::pair< Double, Double > | Modf (const Double &x) |
std::pair< DVec2, DVec2 > | Modf (const DVec2 &x) |
std::pair< DVec3, DVec3 > | Modf (const DVec3 &x) |
std::pair< DVec4, DVec4 > | Modf (const DVec4 &x) |
Float | Ldexp (const Float &x, const Int &exp) |
Builds a floating-point number from x and the corresponding integral exponent of two in exp . More... | |
Vec2 | Ldexp (const Vec2 &x, const IVec2 &exp) |
Vec3 | Ldexp (const Vec3 &x, const IVec3 &exp) |
Vec4 | Ldexp (const Vec4 &x, const IVec4 &exp) |
Double | Ldexp (const Double &x, const Int &exp) |
DVec2 | Ldexp (const DVec2 &x, const IVec2 &exp) |
DVec3 | Ldexp (const DVec3 &x, const IVec3 &exp) |
DVec4 | Ldexp (const DVec4 &x, const IVec4 &exp) |
std::pair< Float, Int > | Frexp (const Float &x) |
Splits x into a floating-point significand in the range [0.5, 1.0) and an integral exponent of two,. More... | |
std::pair< Vec2, IVec2 > | Frexp (const Vec2 &x) |
std::pair< Vec3, IVec3 > | Frexp (const Vec3 &x) |
std::pair< Vec4, IVec4 > | Frexp (const Vec4 &x) |
std::pair< Double, Int > | Frexp (const Double &x) |
std::pair< DVec2, IVec2 > | Frexp (const DVec2 &x) |
std::pair< DVec3, IVec3 > | Frexp (const DVec3 &x) |
std::pair< DVec4, IVec4 > | Frexp (const DVec4 &x) |
Bool | IsNaN (const Float &x) |
Result is true if x is an IEEE NaN, otherwise result is false. | |
BVec2 | IsNaN (const Vec2 &x) |
BVec3 | IsNaN (const Vec3 &x) |
BVec4 | IsNaN (const Vec4 &x) |
Bool | IsNaN (const Double &x) |
BVec2 | IsNaN (const DVec2 &x) |
BVec3 | IsNaN (const DVec3 &x) |
BVec4 | IsNaN (const DVec4 &x) |
Bool | IsInf (const Float &value) |
Result is true if x is an IEEE Inf, otherwise result is false. | |
BVec2 | IsInf (const Vec2 &value) |
BVec3 | IsInf (const Vec3 &value) |
BVec4 | IsInf (const Vec4 &value) |
Bool | IsInf (const Double &value) |
BVec2 | IsInf (const DVec2 &value) |
BVec3 | IsInf (const DVec3 &value) |
BVec4 | IsInf (const DVec4 &value) |
Bool | IsAnyComponentTrue (const BVec2 &v) |
Result is true if any component of the vector is true, otherwise false. | |
Bool | IsAnyComponentTrue (const BVec3 &v) |
Bool | IsAnyComponentTrue (const BVec4 &v) |
Bool | IsAllComponentsTrue (const BVec2 &v) |
Result is true if all components of the vector are true, otherwise false. | |
Bool | IsAllComponentsTrue (const BVec3 &v) |
Bool | IsAllComponentsTrue (const BVec4 &v) |
Int | BitCount (const Int &value) |
Reverses the bits in specified value. More... | |
IVec2 | BitCount (const IVec2 &value) |
IVec3 | BitCount (const IVec3 &value) |
IVec4 | BitCount (const IVec4 &value) |
Int | BitCount (const UInt &value) |
IVec2 | BitCount (const UVec2 &value) |
IVec3 | BitCount (const UVec3 &value) |
IVec4 | BitCount (const UVec4 &value) |
Int | BitReverse (const Int &value) |
Counts the number of set bits in specified value. More... | |
IVec2 | BitReverse (const IVec2 &value) |
IVec3 | BitReverse (const IVec3 &value) |
IVec4 | BitReverse (const IVec4 &value) |
UInt | BitReverse (const UInt &value) |
UVec2 | BitReverse (const UVec2 &value) |
UVec3 | BitReverse (const UVec3 &value) |
UVec4 | BitReverse (const UVec4 &value) |
template<class ImageT > | |
void | UseImage (const ImageT &img) |
Declares image binding point as used in the shader. More... | |
template<class ValueT > | |
void | Ignore (const ValueT &value) |
Computes the expression given as argument and ignores the result. More... | |
template<class TextureT , class SamplerT > | |
auto | MakeSampledTexture (const TextureT &texture, const SamplerT &sampler) |
Converts texture and sampler pair to combined sampled texture. More... | |
template<class TextureT > | |
auto | ExtractSampledTexture (const TextureT &texture) |
Extracts the texture part from combined sampled texture. More... | |
template<class ImageT > | |
auto | ImageSize (const ImageT &image) |
Retrieves the extent of specified image. More... | |
template<class ImageT , class LodT > | |
auto | TextureSize (const ImageT &image, const Int &lod) |
Retrieves the extent of specified MIP image level. More... | |
template<class ImageT > | |
Int | ImageQuerySamples (const ImageT &image) |
Retrieves the number of samples per pixel in the image. More... | |
template<class ImageT > | |
Int | ImageQueryLevels (const ImageT &image) |
Retrieves the number of MIP levels in the image. More... | |
template<class ImageT , class CoordsT > | |
Vec2 | TextureQueryLod (const ImageT &image, const CoordsT &coords) |
Retrieves the mipmap level and the level of detail for a hypothetical sampling of image at coordinate using an implicit level of detail. More... | |
template<class ImageT > | |
auto | SubpassLoad (const ImageT &image) |
Reads a pixel from input attachment. More... | |
template<class ImageT > | |
auto | SubpassLoad (const ImageT &image, const IVec2 &coords) |
Reads a pixel from input attachment, with offset. More... | |
template<class ImageT > | |
auto | SubpassLoad (const ImageT &image, const Int &nSample) |
Reads a sample from multisampled input attachment. More... | |
template<class ImageT > | |
auto | SubpassLoad (const ImageT &image, const IVec2 &coords, const Int &nSample) |
Reads a sample from multisampled input attachment, with offset. More... | |
template<class ImageT , class CoordsT > | |
auto | ImageLoad (const ImageT &image, const CoordsT &coords) |
Reads a pixel from a storage image. More... | |
template<class ImageT , class CoordsT > | |
auto | ImageLoad (const ImageT &image, const CoordsT &coords, const Int &nSample) |
Reads a sample from multisampled storage image. More... | |
template<class ImageT , class CoordsT , class ValueT > | |
void | ImageStore (const ImageT &image, const CoordsT &coords, const ValueT &value) |
Writes a pixel to a storage image. More... | |
template<class ImageT , class CoordsT , class ValueT > | |
void | ImageStore (const ImageT &image, const CoordsT &coords, const ValueT &value, const Int &nSample) |
Writes a sample to multisampled storage image. More... | |
template<class TextureT , class CoordsT > | |
auto | TexelFetch (const TextureT &texture, const CoordsT &coords) |
Reads a texel from a texture without sampling. More... | |
template<class TextureT , class CoordsT > | |
auto | TexelFetch (const TextureT &texture, const CoordsT &coords, const Int &nSample) |
Reads a texel from multisampled texture without sampling. More... | |
template<class TextureT , class CoordsT > | |
auto | TexelFetchLod (const TextureT &texture, const CoordsT &coords, const Int &nLevel) |
Reads a texel from a specified MIP level of texture without sampling. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | TexelFetchOffset (const TextureT &texture, const CoordsT &coords, const OffsetT &offset) |
Reads a texel (with coordinate offset) from a texture without sampling. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | TexelFetchLodOffset (const TextureT &texture, const CoordsT &coords, const Int &nLevel, const OffsetT &offset) |
Reads a texel from a specified MIP level (with coordinate offset) of texture without sampling. More... | |
template<class TextureT , class CoordsT > | |
auto | Texture (const TextureT &texture, const CoordsT &coords) |
Samples a texel from a texture. More... | |
template<class TextureT , class CoordsT > | |
auto | Texture (const TextureT &texture, const CoordsT &coords, const Float &bias) |
Samples a texel from a texture with LOD bias. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | Texture (const TextureT &texture, const CoordsT &coords, const OffsetT &offset) |
Samples a texel from a texture with coordinate offset. More... | |
template<class TextureT , class CoordsT , class GradT > | |
auto | Texture (const TextureT &texture, const CoordsT &coords, const GradT &gradX, const GradT &gradY) |
Samples a texel from a texture with LOD gradient. More... | |
template<class TextureT , class CoordsT , class OffsetT , class GradT > | |
auto | Texture (const TextureT &texture, const CoordsT &coords, const OffsetT &offset, const GradT &gradX, const GradT &gradY) |
Samples a texel from a texture with coordinate offset and LOD gradient. More... | |
template<class TextureT , class CoordsT > | |
auto | TextureLod (const TextureT &texture, const CoordsT &coords, const Float &lod) |
Samples a texel from a texture with explicit MIP levels selection. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | TextureLod (const TextureT &texture, const CoordsT &coords, const OffsetT &offset, const Float &lod) |
Samples a texel from a texture with coordinate offset and explicit MIP levels selection. More... | |
template<class TextureT , class CoordsT > | |
auto | TextureProj (const TextureT &texture, const CoordsT &coords) |
Samples a texel from a texture with perspective division. More... | |
template<class TextureT , class CoordsT > | |
auto | TextureProj (const TextureT &texture, const CoordsT &coords, const Float &bias) |
Samples a texel from a texture with perspective division and LOD bias. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | TextureProj (const TextureT &texture, const CoordsT &coords, const OffsetT &offset) |
Samples a texel from a texture with perspective division and coordinate offset. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | TextureProj (const TextureT &texture, const CoordsT &coords, const OffsetT &offset, const Float &bias) |
Samples a texel from a texture with perspective division, coordinate offset and LOD bias. More... | |
template<class TextureT , class CoordsT , class GradT > | |
auto | TextureProj (const TextureT &texture, const CoordsT &coords, const GradT &gradX, const GradT &gradY) |
Samples a texel from a texture with perspective division, and LOD gradient. More... | |
template<class TextureT , class CoordsT , class OffsetT , class GradT > | |
auto | TextureProj (const TextureT &texture, const CoordsT &coords, const OffsetT &offset, const GradT &gradX, const GradT &gradY) |
Samples a texel from a texture with perspective division, coordinate offset and LOD gradient. More... | |
template<class TextureT , class CoordsT > | |
auto | TextureLodProj (const TextureT &texture, const CoordsT &coords, const Float &lod) |
Samples a texel from a texture with perspective division and explicit MIP levels selection. More... | |
template<class TextureT , class CoordsT , class OffsetT > | |
auto | TextureLodProj (const TextureT &texture, const CoordsT &coords, const OffsetT &offset, const Float &lod) |
Samples a texel from a texture with perspective division, coordinate offset and explicit MIP levels selection. More... | |
template<class TextureT , class Arg1T , class Arg2T > | |
auto | TextureDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T > | |
auto | TextureDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T , class Arg4T > | |
auto | TextureDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3, const Arg4T &arg4) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T , class Arg4T , class Arg5T > | |
auto | TextureDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3, const Arg4T &arg4, const Arg5T &arg5) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T > | |
auto | TextureLodDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T , class Arg4T > | |
auto | TextureLodDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3, const Arg4T &arg4) |
template<class TextureT , class Arg1T , class Arg2T > | |
auto | TextureProjDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T > | |
auto | TextureProjDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T , class Arg4T > | |
auto | TextureProjDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3, const Arg4T &arg4) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T , class Arg4T , class Arg5T > | |
auto | TextureProjDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3, const Arg4T &arg4, const Arg5T &arg5) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T > | |
auto | TextureLodProjDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T , class Arg4T > | |
auto | TextureLodProjDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3, const Arg4T &arg4) |
template<class TextureT , class Arg1T , class Arg2T > | |
auto | TextureGather (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T > | |
auto | TextureGather (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3) |
template<class TextureT , class Arg1T , class Arg2T , class Arg3T > | |
auto | TextureGatherDref (const TextureT &texture, const Arg1T &arg1, const Arg2T &arg2, const Arg3T &arg3) |
template<class ValueT > | |
TUpdateMultipleDescriptors< ValueT > | multi (const ValueT &value, std::uint32_t startIdx=0) |
Resource binding helper for binding items or ranges of resource arrays. | |
void | operator<< (const Process &target, const std::function< void() > &cmds) |
Defines a command sequence for rendering process. | |
void | operator<< (const Preprocess &target, const std::function< void() > &cmds) |
Defines a command sequence for preparation process. | |
void | operator<< (const Postprocess &target, const std::function< void() > &cmds) |
Defines a command sequence for finalization process. | |
The VPP namespace.
enum vpp::EFeature |
Optional device feature enumeration.
VPP offers unified interface to deal with both device features and known device extensions. Thus, extensions are listed as features in this enumeration and are being enabled in the same fashion. VPP automatically handles dependencies between features and extensions. For example, if you enable the fShaderSharedInt64Atomics
feature (e.g. to use Int64 in a shader), VPP will automatically enable fExtShaderAtomicInt64
extension.
Extensions correspond to values with fExt
prefix. Other values are for features.
See section 30.1 in the official Vulkan docs for complete description of base features. For extension-specific features, you can find separate edition of Vulkan spec document augmented with a description of each extension.
Caution: values of this type listed below are intended to be used only as arguments to methods accepting EFeature type. Do not declare your own EFeature variables nor use the values in other contexts, as you will likely encounter C++ errors if you do so.
Extensions which are listed in the enumeration below are being referred to as known extensions. Those are mostly Khronos and multivendor extensions. Some of these extensions are also integrated into VPP API, but not all. Integration of extensions is a work in progress. Currently the following ones have explicit support in the VPP API:
Vendor-specific extensions are currently unsupported. Subsequent versions of VPP will make possible to enable them and use though mixing of VPP and core Vulkan API.
enum vpp::EImagePurpose |
Enumeration specifying general purpose of an image.
This is more general distinction than Img::EUsageFlags.
enum vpp::ETag |
Enumeration type allowing to select the flavor of shader structural type: the CPU or GPU version.
Use as a template argument to instantiate wanted version. This applies to subclass templates of the following: VertexStruct, InstanceStruct, UniformStruct, LocalStruct. Also the value of ETag type is passed to members of these structures: Attribute, UniformFld, Field.
Enumerator | |
---|---|
CPU | Selects CPU version of the structure. |
GPU | Selects GPU version of the structure. |
DEF | Internal use only. |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Arc cosine. Result is an angle, in radians, whose cosine is x.
The range of result values is [0, pi]. Result is undefined if Abs(x) > 1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Arc hyperbolic cosine.
Result is the non-negative inverse of Cosh. Result is undefined if x < 1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Arc sine. Result is an angle, in radians, whose sine is x.
The range of result values is [-pi/2, pi/2]. Result is undefined if Abs(x) > 1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Arc tangent.
Result is an angle, in radians, whose tangent is y/x. The signs of x and y are used to determine what quadrant the angle is in. The range of result values is [-pi, pi]. Result is undefined if x and y are both 0.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Arc hyperbolic tangent.
Result is the inverse of Tanh. Result is undefined if Abs(x) >= 1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
BarrierList vpp::barriers | ( | VkPipelineStageFlags | sourceStage, |
VkPipelineStageFlags | targetStage, | ||
Args &&... | args | ||
) |
Creates a BarrierList object for specified resources.
This function requires only source and destination stages, and also a list of resource references (vpp::Buf or vpp::Img). You can provide vpp::Bar::EStage values as the stages (they are equivalent to Vulkan enumeration).
Caution: this function throws vpp::XInvalidBarrier exception when it detects an error like invalid stage for particular type of resource, or lack of required usage flags on the resource. This situation indicates a bug in your program.
An example:
BarrierList vpp::barriers | ( | const Img & | hImage, |
const std::vector< VkImageSubresourceRange > & | regions, | ||
VkPipelineStageFlags | sourceStage, | ||
VkPipelineStageFlags | targetStage | ||
) |
Creates a BarrierList object for specified regions of an image.
This function requires source and destination stages, the image and a list of its regions. You can provide vpp::Bar::EStage values as the stages (they are equivalent to Vulkan enumeration).
For each provided region, separate barrier will be created.
Caution: this function throws vpp::XInvalidBarrier exception when it detects an error like invalid stage for particular type of resource, or lack of required usage flags on the resource. This situation indicates a bug in your program.
void vpp::Begin | ( | ) |
auto vpp::bind | ( | const ImageView< AttributesT > & | view, |
VkImageLayout | layout = VK_IMAGE_LAYOUT_UNDEFINED |
||
) |
Helper function to bind specified image view to a binding point in a pipeline.
When you call ShaderDataBlock::update method in order to bind actual resources (buffers, images) to shader data blocks, you provide a list of assignments. In each assignment, the binding point name comes on the left hand side, and on the right hand side usually there is the name of the image or buffer object. You can use the bind() function call in this place, to provide additional parameters.
Currently you can specify the layout in which the resource will be when being accessed by the shader. This is applicable only for binding points of the following types: inTexture, inSampledTexture, inConstSampledTexture, inAttachment. Allowed values are:
In any case, if you do not use the bind function at all, one of the values listed above, appropriate for the binding point, will be assumed.
auto vpp::bind | ( | const SamplerT & | sampler, |
const ImageView< AttributesT > & | view, | ||
VkImageLayout | layout = VK_IMAGE_LAYOUT_UNDEFINED |
||
) |
Helper function to bind specified image view and a sampler to a binding point in a pipeline.
When you call ShaderDataBlock::update method in order to bind actual resources (buffers, images) to shader data blocks, you provide a list of assignments. In each assignment, the binding point name comes on the left hand side, and on the right hand side usually there is the name of the image or buffer object. You can use the bind() function call in this place, to provide additional parameters.
This variant of the bind() function allows to bind a sampler along with an image. You must use it for inSampledTexture binding points (and for anything else). This is because inSampledTexture represents a texture image with predefined sampler, although not statically associated (as with inConstSampledTexture).
You can also specify the layout in which the resource will be when being accessed by the shader. This is applicable only for binding points of the following types: inTexture, inSampledTexture, inConstSampledTexture, inAttachment. Allowed values are:
If you do not provide this parameter, one of the values listed above, appropriate for the binding point, will be assumed.
MemoryBinding< ResourceT, DeviceMemory > vpp::bindDeviceMemory | ( | const ResourceT & | res, |
const MemProfile & | memProfile | ||
) |
Binds specified buffer to a DeviceMemory memory, and returns MemoryBinding object.
The buffer (vpp::Buf or vpp::Buffer subclass) is specified a the res
parameter.
It is a convenient practice to use C++ auto
type inference to declare the result for this function.
MemoryBinding< ResourceT, MappableDeviceMemory > vpp::bindMappableMemory | ( | const ResourceT & | res, |
const MemProfile & | memProfile | ||
) |
Binds specified buffer to a MappableDeviceMemory memory, and returns MemoryBinding object.
The buffer (vpp::Buf or vpp::Buffer subclass) is specified a the res
parameter.
It is a convenient practice to use C++ auto
type inference to declare the result for this function.
Reverses the bits in specified value.
Results are computed per component.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Counts the number of set bits in specified value.
Results are computed per component.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes the value of Min ( Max ( x, minVal ), maxVal ).
Result is undefined if minVal > maxVal.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Double vpp::Determinant | ( | const DMat2 & | x | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Double vpp::Determinant | ( | const DMat3 & | x | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Double vpp::Determinant | ( | const DMat4 & | x | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void vpp::Do | ( | ) |
Creates the do clause of the loop construct.
Place in the shader code to create a loop construct. Always use with While() clause. At the end of the looped block, place the closing clause Od(). All instructions between While() and Od() will be executed as long as the expression in While() evaluates to true.
Usually a loop control variable is used to limit iterations. You must declare the variable explicitly, somewhere before the Do() clause. Also do not forget to increment the variable, or make the loop finish by other means. Infinite loop will cause unpredictable behavior, most likely the GPU driver will restart. In case you program hangs due to infinite loop on GPU, kill it explicitly (e.g. with Task Manager).
Note that Do(), While() and Od() are actually function calls (as C++ instructions cannot be overloaded). You must put semicolon after them. Also pay attention to the fact that the code block between While() and Od() does not create C++ scope. If you want to have C++ scope there, you must put the braces explicitly around the code. It is recommended if you create new identifiers inside the block, although not required.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void vpp::Else | ( | ) |
Creates the else clause of the conditional construct.
Place in the shader code between If() and Fi() clauses to create a conditional construct with else branch. All instructions between If() and Else() will be executed only if the expression evaluates to true. Instructions between Else() and Fi() will be executed only if the expression evaluates to false.
void vpp::End | ( | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
auto vpp::ExtractSampledTexture | ( | const TextureT & | texture | ) |
Extracts the texture part from combined sampled texture.
As the argument, provide inSampledTexture, inConstSampledTexture or inTextureBuffer object.
Returns an equivalent of inTexture object.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void vpp::Fi | ( | ) |
Computes the bit number of the least-significant 1-bit in the binary representation of v
.
If v
is 0, the result is -1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes the bit number of the most-significant 1-bit in the binary representation of v
.
For unsigned or or positive numbers, the result will be the bit number of the most significant 1-bit. For signed negative numbers, the result will be the bit number of the most significant 0-bit. For a value of 0 or -1, the result is -1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Creates the for clause of the 'for' loop construct.
Place in the shader code to create a 'for' loop construct. At the end of the looped block, always place the closing clause Rof().
The For() loop is simplified, specialized version of While(). It takes a single integer variable reference to the loop control variable. The variable must be declared earlier. The loop will initialize the variable to begin
value and before executing each iteration it will check whether the variable is less than end
. At the end of each iteration, the step
value will be added to the control variable.
This kind of 'for' loop is more similar to languages like Fortran, but is still useful in many scenarios. For C++ like 'for' (with arbitrary condition), use the While() loop.
Note that For(), and Rof() are actually function calls (as C++ instructions cannot be overloaded). You must put semicolon after them. Also pay attention to the fact that the code block between For() and Rof() does not create C++ scope. If you want to have C++ scope there, you must put the braces explicitly around the code. It is recommended if you create new identifiers inside the block, although not required.
Caution: pay attention to the fact that For() automatically increments the control variable, unlike While(). This is important thing to be aware of when converting between For() and While() constructs.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Splits x into a floating-point significand in the range [0.5, 1.0) and an integral exponent of two,.
The computation is being performed according to the formula:
The significand is the first result and the exponent is the second result.
For a floating-point value of zero, the significand and exponent are both zero.
For a floating-point value that is an infinity or is not a number, the result is undefined.
If an implementation supports negative 0, Frexp (-0) should result in -0. Otherwise it will result in 0.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void vpp::If | ( | Bool | v | ) |
Creates the if clause of the conditional construct.
Place in the shader code to create a conditional construct. Use a conditional expression as the argument of If(). At the end of conditional block, place the closing clause Fi(). All instructions between If() and Fi() will be executed only if the expression evaluates to true.
Note that If() and Fi() are actually function calls (as C++ instructions cannot be overloaded). You must put semicolon after them. Also pay attention to the fact that the code block between If() and Fi() does not create C++ scope. If you want to have C++ scope there, you must put the braces explicitly around the code. It is recommended if you create new identifiers inside the block, although not required.
void vpp::Ignore | ( | const ValueT & | value | ) |
Computes the expression given as argument and ignores the result.
This is useful to suppress validation warnings about unused objects (e.g. buffer accessors). Can be handy if you temporarily comment out some code to pinpoint a bug.
auto vpp::ImageLoad | ( | const ImageT & | image, |
const CoordsT & | coords | ||
) |
Reads a pixel from a storage image.
As the first argument, provide an object of ioImage or ioImageBuffer type.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
auto vpp::ImageLoad | ( | const ImageT & | image, |
const CoordsT & | coords, | ||
const Int & | nSample | ||
) |
Reads a sample from multisampled storage image.
As the first argument, provide an object of ioImage or ioImageBuffer type.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, specify the sample index.
Int vpp::ImageQueryLevels | ( | const ImageT & | image | ) |
Retrieves the number of MIP levels in the image.
As the argument, you may provide an object of the following types: ioImage, inTexture, inSampledTexture, inConstSampledTexture.
Int vpp::ImageQuerySamples | ( | const ImageT & | image | ) |
Retrieves the number of samples per pixel in the image.
As the argument, you may provide an object of the following types: ioImage, inTexture, inSampledTexture, inConstSampledTexture. It must be a 2D image.
auto vpp::ImageSize | ( | const ImageT & | image | ) |
Retrieves the extent of specified image.
As the argument, you may provide an object of the following types: ioImage, inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer, ioImageBuffer.
This function returns either Int or integer vector of size appropriate for the number of dimensions in the image (e.g. IVec2 for 2D image).
void vpp::ImageStore | ( | const ImageT & | image, |
const CoordsT & | coords, | ||
const ValueT & | value | ||
) |
Writes a pixel to a storage image.
As the first argument, provide an object of ioImage or ioImageBuffer type.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, provide a scalar or vector compatible with image format (e.g. Int for I32 format, Vec4 for normalized RGBA formats, etc.).
void vpp::ImageStore | ( | const ImageT & | image, |
const CoordsT & | coords, | ||
const ValueT & | value, | ||
const Int & | nSample | ||
) |
Writes a sample to multisampled storage image.
As the first argument, provide an object of ioImage or ioImageBuffer type.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, provide a scalar or vector compatible with image format (e.g. Int for I32 format, Vec4 for normalized RGBA formats, etc.).
As the fourth argument, specify the destination sample index.
Computes the reciprocal of Sqrt(x).
Result is undefined if x <= 0.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Builds a floating-point number from x
and the corresponding integral exponent of two in exp
.
Computes the result as:
If this product is too large to be represented in the floating-point type, the result is undefined. If exp
is greater than +128 (single precision) or +1024 (double precision), the result undefined. If exp
is less than -126 (single precision) or -1022 (double precision), the result may be flushed to zero. Additionally, splitting the value into a significand and exponent using Frexp and then reconstructing a floating-point value using Ldexp should yield the original input for zero and all finite non-denormalized values.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes the natural logarithm of x.
Result is undefined if x <= 0.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes the base-2 logarithm of x.
Result is undefined if x <= 0.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
auto vpp::MakeSampledTexture | ( | const TextureT & | texture, |
const SamplerT & | sampler | ||
) |
Converts texture and sampler pair to combined sampled texture.
As the first argument, provide inTexture object.
As the second argument you may use inSampler or inConstSampler object.
This function creates and returns combined texture-sampler object, which is equivalent to inSampledTexture.
Computes a matrix that is the inverse of x.
The values in the result are undefined if x is singular or poorly conditioned (nearly singular).
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
DMat2 vpp::MatrixInverse | ( | const DMat2 & | x | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
DMat3 vpp::MatrixInverse | ( | const DMat3 & | x | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
DMat4 vpp::MatrixInverse | ( | const DMat4 & | x | ) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Result is y if x < y, otherwise result is x.
Result is undefined if one of the operands is a NaN.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Result is y if y < x, otherwise result is x.
Result is undefined if one of the operands is a NaN.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Modulo operation of lhs
modulo rhs
.
The sign of a non-zero result comes from the right operand.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
UMat2 vpp::Mod | ( | const UMat2 & | lhs, |
const UMat2 & | rhs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
UMat3 vpp::Mod | ( | const UMat3 & | lhs, |
const UMat3 & | rhs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
UMat4 vpp::Mod | ( | const UMat4 & | lhs, |
const UMat4 & | rhs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
DMat2 vpp::Mod | ( | const DMat2 & | lhs, |
const DMat2 & | rhs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
DMat3 vpp::Mod | ( | const DMat3 & | lhs, |
const DMat3 & | rhs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
DMat4 vpp::Mod | ( | const DMat4 & | lhs, |
const DMat4 & | rhs | ||
) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes the fractional part of x (as the first result) and the whole number part (second result).
Both results will have the same sign as x.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Result is min ( max ( x, minVal), maxVal ).
Result is undefined if minVal > maxVal.The semantics used by min() and max() are those of NMin and NMax.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Result is y if x < y, otherwise result is x.
If one operand is a NaN, the other operand is the result. If both operands are NaN, the result is a NaN.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Result is y if y < x, otherwise result is x.
If one operand is a NaN, the other operand is the result. If both operands are NaN, the result is a NaN.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
void vpp::Od | ( | ) |
Creates the closing clause of the loop construct.
Place in the shader code to create a loop construct. Always use with Do() .. While() clauses. Place Od() at the end of the looped block. All instructions between While() and Od() will be executed as long as the expression in While() evaluates to true.
See Do() documentation for more details.
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Packs the components of v into a 64-bit value.
If an IEEE 754 Inf or NaN is created, it will not signal, and the resulting floating-point value is unspecified. Otherwise, the bit-level representation of v is preserved.
The first vector component specifies the 32 least significant bits. The second component specifies the 32 most significant bits.
Converts the components of a two-component floating-point vector to the 16-bit float, then packs them into a 32-bit unsigned integer.
The first vector component specifies the 16 least-significant bits of the result. The second component specifies the 16 most-significant bits.
Converts each component of the signed normalized floating-point value v into 16-bit integer values and packs them into the result.
The conversion for component c of v to fixed point is done as follows:
The first component of the vector will be written to the least significant bits of the output. The last component will be written to the most significant bits.
Converts each component of the signed normalized floating-point value v into 8-bit integer values and packs them into the result.
The conversion for component c of v to fixed point is done as follows:
The first component of the vector will be written to the least significant bits of the output. The last component will be written to the most significant bits.
Converts each component of the positive normalized floating-point value v into 16-bit integer values and packs them into the result.
The conversion for component c of v to fixed point is done as follows:
The first component of the vector will be written to the least significant bits of the output. The last component will be written to the most significant bits.
Converts each component of the positive normalized floating-point value v into 8-bit integer values and packs them into the result.
The conversion for component c of v to fixed point is done as follows:
The first component of the vector will be written to the least significant bits of the output. The last component will be written to the most significant bits.
Computes x raised to the y power.
Result is undefined if x < 0. Result is undefined if x = 0 and y <= 0.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes reflected vector to the vector i
.
For the incident vector i
and surface orientation n
, the result is the reflection direction:
Vector n must already be normalized in order to achieve the desired result.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes refracted vector to the vector i
.
For the incident vector i
and surface normal n
, and the ratio of indices of refraction eta, the result is the refraction vector. The result is computed by:
If k
< 0 the result is 0, otherwise, the result is:
The input parameters for the incident vector i
and the surface normal n
must already be normalized to get the desired results.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
TargetT vpp::ReinterpretCast | ( | const SourceT & | source | ) |
Bit pattern type conversion function.
ReinterpretCast() works much like C++ reinterpret_cast
operator. It can convert between scalars or vectors made from scalars of same size. This operator preserves bit pattern but not value. One of possible uses is to convert between floating-point and integer types, in order to utilise various bit tricks to speed up floating point approximations.
void vpp::Return | ( | ) |
Immediately returns from the function.
Use when the erturn type is Void.
void vpp::Rof | ( | ) |
Creates the closing clause of the 'for' loop construct.
See For() documentation for more details.
Computes nearest whole number to x.
The fraction 0.5 will round in a direction chosen by the implementation, presumably the direction that is fastest. This includes the possibility that Round x is the same value as RoundEven x for all values of x.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes nearest whole number to x.
A fractional part of 0.5 will round toward the nearest even whole number.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
auto vpp::Select | ( | const CondT & | cond, |
const Arg1T & | argIfTrue, | ||
const Arg2T & | argIfFalse | ||
) |
A conditional expression.
Since the operator ?:
in C++ can not be overloaded, VPP offers a counterpart as a function.
Select() takes three arguments.
The first argument should be the condition to check. It must be one of two following cases:
The second and third argument can be any two expressions, but evaluating to common type. If the condition is true
, the expression given as second argument will be the result. Otherwise, the third expression will be the result. It matches semantics of the ?:
C++ operator.
In case if you specify a vector as the condition, you can select vector components individually. This feature does not exist in C++.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Result is 0 if x <= edge0, 1 if x >= edge1, or smooth Hermite interpolation between 0 and 1 when edge0 < x < edge1.
This is equivalent to: t*t*(3 - 2*t), where t = Clamp ( (x-edge0) / (edge1-edge0), 0, 1 )
Result is undefined if edge0 >= edge1.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
TargetT vpp::StaticCast | ( | const SourceT & | source | ) |
General type conversion function.
StaticCast() is the analog of C++ static_cast
operator. In VPP it can (and must) be used to convert between simple types. It can handle scalar types as well as vector and matrix types of same sizes. Some examples:
It generally works in similar fashion as in C++. However, in VPP usage of this operator is much more frequent because VPP deliberately does not implement automatic type conversions of C++. This is to minimize code complexity, avoid possible compiler problems and cryptic error messages as well as reduce confusion and "surprise" to the user. Generally VPP will not convert different types (even if they only differ in signedness) unless you ask it to do so.
For scalar types (but not vectors) VPP offers a shorthand on the form of additional constructor for a scalar type. For example:
These constructors are equivalent to calling StaticCast() on their argument. They are declared as explicit
.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
auto vpp::SubpassLoad | ( | const ImageT & | image | ) |
Reads a pixel from input attachment.
Call only inside fragment shaders.
As the argument, provide an object of inAttachment type.
This function returns 4-element vector of type compatible with image format. For example, Vec4 or IVec4. For images where the format uses less than 4 components, unused components will be equal to 0.
The function reads a pixel from currently processed location. It is implicitly maintained by the fragment shader.
auto vpp::SubpassLoad | ( | const ImageT & | image, |
const IVec2 & | coords | ||
) |
Reads a pixel from input attachment, with offset.
Call only inside fragment shaders.
As the first argument, provide an object of inAttachment type.
As the second argument, provide a vector of coordinates which will be added to the currently processed location, in order to compute source pixel location.
This function returns 4-element vector of type compatible with image format. For example, Vec4 or IVec4. For images where the format uses less than 4 components, unused components will be equal to 0.
auto vpp::SubpassLoad | ( | const ImageT & | image, |
const Int & | nSample | ||
) |
Reads a sample from multisampled input attachment.
Call only inside fragment shaders.
As the first argument, provide an object of inAttachment type.
As the second argument, provide an index of the sample.
This function returns 4-element vector of type compatible with image format. For example, Vec4 or IVec4. For images where the format uses less than 4 components, unused components will be equal to 0.
auto vpp::SubpassLoad | ( | const ImageT & | image, |
const IVec2 & | coords, | ||
const Int & | nSample | ||
) |
Reads a sample from multisampled input attachment, with offset.
Call only inside fragment shaders.
As the first argument, provide an object of inAttachment type.
As the second argument, provide a vector of coordinates which will be added to the currently processed location, in order to compute source pixel location.
As the third argument, provide an index of the sample.
This function returns 4-element vector of type compatible with image format. For example, Vec4 or IVec4. For images where the format uses less than 4 components, unused components will be equal to 0.
void vpp::Switch | ( | Int | expr | ) |
Creates the switch construct.
Place in the shader code to create a switch ... case construct. Provide switch expression as the argument. Always use with Case() and EndSwitch(). Optionally use also Default() and Break().
The semantics of the Switch() instruction is identical to the C++ counterpart. Particluarly, the fall-through behavior is the same, so you need Break() clause to break control flow just as in C++. Also Default() works the same as in C++.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
auto vpp::TexelFetch | ( | const TextureT & | texture, |
const CoordsT & | coords | ||
) |
Reads a texel from a texture without sampling.
This function allows to read raw texel, without any sampling or filtering. It is a counterpart of ImageLoad(), but working on textures instead of storage images.
As the first argument, you may provide an object of the following types: inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
The function returns 4-element vector of type determined by the image format. It can be either floating point type (Vec4) or integer type (IVec4, UVec4).
The source image must not be a cube map.
auto vpp::TexelFetch | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Int & | nSample | ||
) |
Reads a texel from multisampled texture without sampling.
This function allows to read raw texel, without any sampling or filtering. It is a counterpart of ImageLoad(), but working on textures instead of storage images.
As the first argument, you may provide an object of the following types: inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, specify the sample index.
The function returns 4-element vector of type determined by the image format. It can be either floating point type (Vec4) or integer type (IVec4, UVec4).
The source image must not be a cube map.
auto vpp::TexelFetchLod | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Int & | nLevel | ||
) |
Reads a texel from a specified MIP level of texture without sampling.
As the first argument, you may provide an object of the following types: inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, specify the MIP level.
The function returns 4-element vector of type determined by the image format. It can be either floating point type (Vec4) or integer type (IVec4, UVec4).
The source image must not be a cube map nor a multisampled image.
auto vpp::TexelFetchLodOffset | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Int & | nLevel, | ||
const OffsetT & | offset | ||
) |
Reads a texel from a specified MIP level (with coordinate offset) of texture without sampling.
This function allows to read raw texel, without any sampling or filtering. It is a counterpart of ImageLoad(), but working on textures instead of storage images.
As the first argument, you may provide an object of the following types: inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, specify the MIP level.
As the fourth argument, provide additional offset which will be added to coords
coordinate vector. Note that the offset vector does not have additional coordinate for the array level.
The function returns 4-element vector of type determined by the image format. It can be either floating point type (Vec4) or integer type (IVec4, UVec4).
The source image must not be a cube map.
auto vpp::TexelFetchOffset | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset | ||
) |
Reads a texel (with coordinate offset) from a texture without sampling.
This function allows to read raw texel, without any sampling or filtering. It is a counterpart of ImageLoad(), but working on textures instead of storage images.
As the first argument, you may provide an object of the following types: inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer.
As the second argument, provide a vector of integer type and the number of components appropriate for the image dimensionality (e.g. IVec2 for 2D image, Int for a buffer, IVec3 for arrayed 2D image, etc.). Note that arrayed images require extra coordinate to specify the array level.
As the third argument, provide additional offset which will be added to coords
coordinate vector. Note that the offset vector does not have additional coordinate for the array level.
The function returns 4-element vector of type determined by the image format. It can be either floating point type (Vec4) or integer type (IVec4, UVec4).
The source image must not be a cube map.
auto vpp::Texture | ( | const TextureT & | texture, |
const CoordsT & | coords | ||
) |
Samples a texel from a texture.
This function allows to read a texel with sampling and filtering. It is a primary method to read from textures.
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
As the second argument, provide a vector of floating point type and the number of components appropriate for the image dimensionality, taking into account whether the image is arrayed and/or cube map.
Arrayed image always adds single coordinate at the end. Since entire vector is floating point, you must convert an integer array index to floating point.
Cube maps are very specific case. They are essentially layered 2D textures treated like they were 3D textures. A cube map has 6 layers corresponding to different faces of a cube. Imagine that we are positioned in the middle of the cube (this is an origin of our coordinate system) and we have a 3D vector of (s, r, t) coordinates which starts at origin and points away from it in some direction. A line along this direction will intersect one of cube faces at some point and we take our texel color from this point (with sampling and filtering). Therefore for cube maps, you need to specify 3D vector to Texture
function, and for arrayed cube maps - 4D vector.
The function returns 4-element vector of type determined by the image format. It can be either floating point type (Vec4) or integer type (IVec4, UVec4).
The function may be only used within fragment shaders.
auto vpp::Texture | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Float & | bias | ||
) |
Samples a texel from a texture with LOD bias.
This function allows to read a texel with sampling and filtering. It differs from the base version in that you specify a bias to be added to the parameter affecting selection of MIP levels from which the texel will be taken.
The image must not be multisampled.
Remaining details are identical as in the base Texture
function.
auto vpp::Texture | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset | ||
) |
Samples a texel from a texture with coordinate offset.
This function allows to read a texel with sampling and filtering. It differs from the base version in that you specify an offset to be added to the coordinates from where the texel will be sampled.
The image must not be a cube map.
Remaining details are identical as in the base Texture
function.
auto vpp::Texture | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const GradT & | gradX, | ||
const GradT & | gradY | ||
) |
Samples a texel from a texture with LOD gradient.
This function allows to read a texel with sampling and filtering. It differs from the base version in that you specify a gradient which affects selection of MIP levels from which the texel will be taken.
This is more advanced function. See section 15.6.2 of the Vulkan docs for more information.
The image must not be multisampled.
The function may be used also in other shaders than fragment.
Remaining details are identical as in the base Texture
function.
auto vpp::Texture | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset, | ||
const GradT & | gradX, | ||
const GradT & | gradY | ||
) |
Samples a texel from a texture with coordinate offset and LOD gradient.
This function allows to read a texel with sampling and filtering. It differs from the base version in that you specify both a coordinate offset and a gradient which affects selection of MIP levels from which the texel will be taken.
This is more advanced function. See section 15.6.2 of the Vulkan docs for more information.
The image must not be multisampled.
The function may be used also in other shaders than fragment.
Remaining details are identical as in the base Texture
function.
auto vpp::TextureDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3, | ||
const Arg4T & | arg4 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3, | ||
const Arg4T & | arg4, | ||
const Arg5T & | arg5 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureGather | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureGather | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureGatherDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureLod | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Float & | lod | ||
) |
Samples a texel from a texture with explicit MIP levels selection.
This function allows to read a texel with sampling and filtering. It differs from the base version in that you specify a parameter which selects the MIP levels in more direct way, as described in section 15.6.7 of the official Vulkan spec.
The image must not be multisampled.
The function may be used also in other shaders than fragment.
Remaining details are identical as in the base Texture
function.
auto vpp::TextureLod | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset, | ||
const Float & | lod | ||
) |
Samples a texel from a texture with coordinate offset and explicit MIP levels selection.
This function allows to read a texel with sampling and filtering. It differs from the base version in that you specify a coordinate offset as well as a parameter which selects the MIP levels in more direct way, as described in section 15.6.7 of the official Vulkan spec.
The image must not be multisampled.
The function may be used also in other shaders than fragment.
Remaining details are identical as in the base Texture
function.
auto vpp::TextureLodDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureLodDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3, | ||
const Arg4T & | arg4 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureLodProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Float & | lod | ||
) |
Samples a texel from a texture with perspective division and explicit MIP levels selection.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies perspective division and MIP levels selection.
The function may be used also in other shaders than fragment.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureLodProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset, | ||
const Float & | lod | ||
) |
Samples a texel from a texture with perspective division, coordinate offset and explicit MIP levels selection.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies all of these operations: perspective division, coordinate offset and LOD level selection. The offset is being applied after the division. See the descriptions of respective Texture
variants for more detail.
The function may be used also in other shaders than fragment.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureLodProjDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureLodProjDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3, | ||
const Arg4T & | arg4 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureProj | ( | const TextureT & | texture, |
const CoordsT & | coords | ||
) |
Samples a texel from a texture with perspective division.
This function allows to read a texel with sampling and filtering. It differs from the base version in that the coordinate vector has one more component at the end. Remaining components will be divided by this extra component, just as in the prespective division.
The image must not be multisampled, arrayed nor cube map.
The image sampler must be a normalized sampler.
Remaining details are identical as in the base Texture
function.
auto vpp::TextureProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const Float & | bias | ||
) |
Samples a texel from a texture with perspective division and LOD bias.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies both perspective division and LOD bias. See the descriptions of respective Texture
variants for more detail.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset | ||
) |
Samples a texel from a texture with perspective division and coordinate offset.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies both perspective division and coordinate offset. The offset is being applied after the division. See the descriptions of respective Texture
variants for more detail.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset, | ||
const Float & | bias | ||
) |
Samples a texel from a texture with perspective division, coordinate offset and LOD bias.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies all of these operations: perspective division, coordinate offset and LOD bias. The offset is being applied after the division. See the descriptions of respective Texture
variants for more detail.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const GradT & | gradX, | ||
const GradT & | gradY | ||
) |
Samples a texel from a texture with perspective division, and LOD gradient.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies both perspective and LOD gradient. See the descriptions of respective Texture
variants for more detail.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureProj | ( | const TextureT & | texture, |
const CoordsT & | coords, | ||
const OffsetT & | offset, | ||
const GradT & | gradX, | ||
const GradT & | gradY | ||
) |
Samples a texel from a texture with perspective division, coordinate offset and LOD gradient.
This function allows to read a texel with sampling and filtering. It differs from the base version in that it applies all of these operations: perspective division, coordinate offset and LOD gradient. The offset is being applied after the division. See the descriptions of respective Texture
variants for more detail.
Remaining details are identical as in the base TextureProj
function.
auto vpp::TextureProjDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureProjDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureProjDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3, | ||
const Arg4T & | arg4 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
auto vpp::TextureProjDref | ( | const TextureT & | texture, |
const Arg1T & | arg1, | ||
const Arg2T & | arg2, | ||
const Arg3T & | arg3, | ||
const Arg4T & | arg4, | ||
const Arg5T & | arg5 | ||
) |
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
Vec2 vpp::TextureQueryLod | ( | const ImageT & | image, |
const CoordsT & | coords | ||
) |
Retrieves the mipmap level and the level of detail for a hypothetical sampling of image at coordinate using an implicit level of detail.
As the first argument, you may provide an object of the following types: inSampledTexture, inConstSampledTexture.
As the second argument, specify a vector of floating point values of the size appropriate for image dimensionality (e.g. Vec2 for 2D image).
This function may be called only in fragment shaders.
auto vpp::TextureSize | ( | const ImageT & | image, |
const Int & | lod | ||
) |
Retrieves the extent of specified MIP image level.
As the first argument, you may provide an object of the following types: inTexture, inSampledTexture, inConstSampledTexture, inTextureBuffer.
As the second argument, specify the MIP level index.
This function returns either Int or integer vector of size appropriate for the number of dimensions in the image (e.g. IVec2 for 2D image).
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Computes the two-component unsigned integer vector representation of v. The bit-level representation of v is preserved.
The first component of the vector contains the 32 least significant bits of the double
. The second component consists of the 32 most significant bits.
Unpacks a 32-bit unsigned integer into a pair of 16-bit values, interpreted as 16-bit floating-point numbers, and converts them to 32-bit floating-point values.
Subnormal numbers are either preserved or flushed to zero, consistently within an implemenation.
The first component of the vector is obtained from the 16 least-significant bits of v. The second component is obtained from the 16 most-significant bits of v.
Unpacks a single 32-bit unsigned integer p into a pair of 16-bit signed integers and converts them to normalized floating-point values.
The conversion for unpacked fixed-point value f to floating point is done as follows:
The first component of the result will be extracted from the least significant bits of the input. The last component will be extracted from the most significant bits.
Unpacks a single 32-bit unsigned integer p into four 8-bit signed integers and converts them to normalized floating-point values.
The conversion for unpacked fixed-point value f to floating point is done as follows:
The first component of the result will be extracted from the least significant bits of the input. The last component will be extracted from the most significant bits.
Unpacks a single 32-bit unsigned integer p into a pair of 16-bit unsigned integers. and converts them to normalized floating-point values.
The conversion for unpacked fixed-point value f to floating point is done as follows:
The first component of the result will be extracted from the least significant bits of the input. The last component will be extracted from the most significant bits.
Unpacks a single 32-bit unsigned integer p into four 8-bit unsigned integers and converts them to normalized floating-point values.
The conversion for unpacked fixed-point value f to floating point is done as follows:
The first component of the result will be extracted from the least significant bits of the input. The last component will be extracted from the most significant bits.
void vpp::UseImage | ( | const ImageT & | img | ) |
Declares image binding point as used in the shader.
In general, image binding points do not require to be declared before accessing them. There is one exception, though: if the first access to the image binding point is inside conditional block, then it must be declared earlier in the code to prevent SPIR-V error. The error is caused by the fact that image can't be introduced conditionally.
An example:
void vpp::While | ( | Bool | v | ) |
Creates the while clause of the loop construct.
Place in the shader code to create a loop construct. Always use with Do() clause. At the end of the looped block, place the closing clause Od(). All instructions between While() and Od() will be executed as long as the expression in While() evaluates to true.
See Do() documentation for more details.