GPU: Implement support for multisample antialiasing
This commit is contained in:
@ -5,8 +5,9 @@
|
||||
class GPU_HW_ShaderGen : public ShaderGen
|
||||
{
|
||||
public:
|
||||
GPU_HW_ShaderGen(HostDisplay::RenderAPI render_api, u32 resolution_scale, bool true_color, bool scaled_dithering,
|
||||
GPUTextureFilter texture_filtering, bool uv_limits, bool supports_dual_source_blend);
|
||||
GPU_HW_ShaderGen(HostDisplay::RenderAPI render_api, u32 resolution_scale, u32 multisamples, bool per_sample_shading,
|
||||
bool true_color, bool scaled_dithering, GPUTextureFilter texture_filtering, bool uv_limits,
|
||||
bool supports_dual_source_blend);
|
||||
~GPU_HW_ShaderGen();
|
||||
|
||||
std::string GenerateBatchVertexShader(bool textured);
|
||||
@ -20,11 +21,16 @@ public:
|
||||
std::string GenerateVRAMUpdateDepthFragmentShader();
|
||||
|
||||
private:
|
||||
ALWAYS_INLINE bool UsingMSAA() const { return m_multisamples > 1; }
|
||||
ALWAYS_INLINE bool UsingPerSampleShading() const { return m_multisamples > 1 && m_per_sample_shading; }
|
||||
|
||||
void WriteCommonFunctions(std::stringstream& ss);
|
||||
void WriteBatchUniformBuffer(std::stringstream& ss);
|
||||
void WriteBatchTextureFilter(std::stringstream& ss, GPUTextureFilter texture_filter);
|
||||
|
||||
u32 m_resolution_scale;
|
||||
u32 m_multisamples;
|
||||
bool m_per_sample_shading;
|
||||
bool m_true_color;
|
||||
bool m_scaled_dithering;
|
||||
GPUTextureFilter m_texture_filter;
|
||||
|
||||
Reference in New Issue
Block a user