mirror of
https://github.com/MobileGL-Dev/MobileGL
synced 2026-09-12 14:18:31 +09:00
[Feat] (MG_State/RenderState, MG_Backend/DirectVulkan): make Distant
Horizon work - Implement BlendEquation/CullFaceMode/PointSize/PolygonMode - Implement GetFramebufferAttachmentParameter* - Downgrade some color attachment resolve failure - Downgrade some overly-strict shader stage linkage check (don't check on unused input var)
This commit is contained in:
@@ -103,5 +103,22 @@ namespace MobileGL {
|
||||
return VK_BLEND_FACTOR_ONE;
|
||||
}
|
||||
}
|
||||
|
||||
VkBlendOp ConvertBlendEquationToVkEnum(BlendEquation v) {
|
||||
switch (v) {
|
||||
case BlendEquation::Add:
|
||||
return VK_BLEND_OP_ADD;
|
||||
case BlendEquation::Subtract:
|
||||
return VK_BLEND_OP_SUBTRACT;
|
||||
case BlendEquation::ReverseSubtract:
|
||||
return VK_BLEND_OP_REVERSE_SUBTRACT;
|
||||
case BlendEquation::Min:
|
||||
return VK_BLEND_OP_MIN;
|
||||
case BlendEquation::Max:
|
||||
return VK_BLEND_OP_MAX;
|
||||
default:
|
||||
return VK_BLEND_OP_ADD;
|
||||
}
|
||||
}
|
||||
} // namespace MG_Util
|
||||
} // namespace MobileGL
|
||||
|
||||
@@ -16,5 +16,6 @@ namespace MobileGL {
|
||||
VkCullModeFlags ConvertCullFaceModeToVkEnum(CullFaceMode value, Bool invertClockwise = false);
|
||||
VkCompareOp ConvertDepthTestFuncToVkEnum(DepthTestFunc value);
|
||||
VkBlendFactor ConvertBlendFactorToVkEnum(BlendFactor value);
|
||||
VkBlendOp ConvertBlendEquationToVkEnum(BlendEquation value);
|
||||
} // namespace MG_Util
|
||||
} // namespace MobileGL
|
||||
|
||||
Reference in New Issue
Block a user