 |
Flutter Impeller
|
|
Go to the documentation of this file.
5 #ifndef FLUTTER_IMPELLER_CORE_FORMATS_H_
6 #define FLUTTER_IMPELLER_CORE_FORMATS_H_
13 #include "flutter/fml/hash_combine.h"
14 #include "flutter/fml/logging.h"
65 return "DevicePrivate";
67 return "DeviceTransient";
149 return "R8G8UNormInt";
151 return "R8G8B8A8UNormInt";
153 return "R8G8B8A8UNormIntSRGB";
155 return "B8G8R8A8UNormInt";
157 return "B8G8R8A8UNormIntSRGB";
159 return "R32G32B32A32Float";
161 return "R16G16B16A16Float";
163 return "B10G10R10XR";
165 return "B10G10R10XRSRGB";
167 return "B10G10R10A10XR";
171 return "D24UnormS8Uint";
173 return "D32FloatS8UInt";
233 return "MultisampleResolve";
235 return "StoreAndMultisampleResolve";
274 return "Texture2DMultisample";
276 return "TextureCube";
278 return "TextureExternalOES";
317 return "ShaderWrite";
319 return "RenderTarget";
544 constexpr
size_t Hash()
const {
545 return fml::HashCombine(
698 struct hash<
impeller::StencilAttachmentDescriptor> {
707 #endif // FLUTTER_IMPELLER_CORE_FORMATS_H_
BlendFactor src_color_blend_factor
@ kGreater
Comparison test passes if new_value > current_value.
@ kDecrementClamp
Decrement the current stencil value by 1. Clamp it to zero.
@ kStoreAndMultisampleResolve
constexpr const char * PixelFormatToString(PixelFormat format)
constexpr bool CanClearAttachment(LoadAction action)
StencilOperation depth_failure
CompareFunction stencil_compare
constexpr bool IsDepthWritable(PixelFormat format)
@ kEqual
Comparison test passes if new_value == current_value.
@ kGreaterEqual
Comparison test passes if new_value >= current_value.
@ kKeep
Don't modify the current stencil value.
constexpr const char * LoadActionToString(LoadAction action)
constexpr size_t GetHash() const
@ kIncrementClamp
Increment the current stencil value by 1. Clamp it to the maximum.
BlendOperation alpha_blend_op
@ kInvert
Perform a logical bitwise invert on the current stencil value.
@ kSetToReferenceValue
Reset the stencil value to the reference value.
PixelFormat
The Pixel formats supported by Impeller. The naming convention denotes the usage of the component,...
@ kNearest
Select nearest to the sample point. Most widely supported.
constexpr size_t Hash() const
@ kNearest
The nearst mipmap level is selected.
@ kDecrementWrap
Decrement the current stencil value by 1. If at zero, set to maximum.
@ kOneMinusDestinationColor
PrimitiveType
Decides how backend draws pixels based on input vertices.
StorageMode
Specified where the allocation resides and how it is used.
constexpr bool operator==(const DepthAttachmentDescriptor &o) const
MipFilter
Options for selecting and filtering between mipmap levels.
constexpr size_t BytesPerPixelForPixelFormat(PixelFormat format)
std::shared_ptr< Texture > texture
constexpr bool operator==(const DepthRange &other) const
@ kPoint
Draws a point at each input vertex.
constexpr const char * StorageModeToString(StorageMode mode)
constexpr std::size_t operator()(const impeller::DepthAttachmentDescriptor &des) const
std::string AttachmentToString(const Attachment &attachment)
std::string ColorAttachmentToString(const ColorAttachment &color)
StencilOperation stencil_failure
constexpr bool IsStencilWritable(PixelFormat format)
@ kNone
Does not use the index buffer.
@ kIncrementWrap
Increment the current stencil value by 1. If at maximum, set to zero.
MinMagFilter
Describes how the texture should be sampled when the texture is being shrunk (minified) or expanded (...
StencilOperation depth_stencil_pass
@ kLessEqual
Comparison test passes if new_value <= current_value.
constexpr bool operator==(const StencilAttachmentDescriptor &o) const
constexpr bool CanDiscardAttachmentWhenDone(StoreAction action)
constexpr size_t GetHash() const
Mask< TextureUsage > TextureUsageMask
constexpr bool IsMultisampleCapable(TextureType type)
@ kAlways
Comparison test passes always passes.
@ kZero
Reset the stencil value to zero.
std::string TextureUsageMaskToString(TextureUsageMask mask)
@ kNever
Comparison test never passes.
constexpr std::size_t operator()(const impeller::StencilAttachmentDescriptor &des) const
BlendFactor src_alpha_blend_factor
BlendFactor dst_color_blend_factor
constexpr const char * TextureTypeToString(TextureType type)
BlendFactor dst_alpha_blend_factor
std::shared_ptr< Texture > resolve_texture
@ kBase
The texture is sampled as if it only had a single mipmap level.
std::string DepthAttachmentToString(const DepthAttachment &depth)
static constexpr Color BlackTransparent()
@ kLinear
Sample from the two nearest mip levels and linearly interpolate.
constexpr bool operator==(const Viewport &other) const
constexpr bool operator==(const ColorAttachmentDescriptor &o) const
constexpr const char * StoreActionToString(StoreAction action)
BlendOperation color_blend_op
@ kNotEqual
Comparison test passes if new_value != current_value.
constexpr const char * TextureUsageToString(TextureUsage usage)
@ kLess
Comparison test passes if new_value < current_value.
std::string StencilAttachmentToString(const StencilAttachment &stencil)
IMPELLER_ENUM_IS_MASK(MyMaskBits)
@ kOneMinusDestinationAlpha
CompareFunction depth_compare
ColorWriteMask write_mask
Describe the color attachment that will be used with this pipeline.
@ kDecal
decal sampling mode is only supported on devices that pass the Capabilities.SupportsDecalSamplerAddre...