From e4d2ec8cb22e7d209da7ae8033d3ecd801d69db5 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Wed, 31 Oct 2018 08:16:44 +0100 Subject: [PATCH] - added a few comments to the renderstate to document where certain functions are used. --- src/hwrenderer/scene/hw_renderstate.h | 30 +++++++++++++-------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/hwrenderer/scene/hw_renderstate.h b/src/hwrenderer/scene/hw_renderstate.h index 530041391..cd72be2d3 100644 --- a/src/hwrenderer/scene/hw_renderstate.h +++ b/src/hwrenderer/scene/hw_renderstate.h @@ -479,21 +479,21 @@ public: virtual void DrawIndexed(int dt, int index, int count, bool apply = true) = 0; // Immediate render state change commands. These only change infrequently and should not clutter the render state. - virtual bool SetDepthClamp(bool on) = 0; - virtual void SetDepthMask(bool on) = 0; - virtual void SetDepthFunc(int func) = 0; - virtual void SetDepthRange(float min, float max) = 0; - virtual void EnableDrawBufferAttachments(bool on) = 0; - virtual void SetStencil(int offs, int op, int flags) = 0; - virtual void SetCulling(int mode) = 0; - virtual void EnableClipDistance(int num, bool state) = 0; - virtual void Clear(int targets) = 0; - virtual void EnableStencil(bool on) = 0; - virtual void SetScissor(int x, int y, int w, int h) = 0; - virtual void SetViewport(int x, int y, int w, int h) = 0; - virtual void EnableDepthTest(bool on) = 0; - virtual void EnableMultisampling(bool on) = 0; - virtual void EnableLineSmooth(bool on) = 0; + virtual bool SetDepthClamp(bool on) = 0; // Deactivated only by skyboxes. + virtual void SetDepthMask(bool on) = 0; // Used by decals and indirectly by portal setup. + virtual void SetDepthFunc(int func) = 0; // Used by models, portals and mirror surfaces. + virtual void SetDepthRange(float min, float max) = 0; // Used by portal setup. + virtual void EnableDrawBufferAttachments(bool on) = 0; // Used by fog boundary drawer. + virtual void SetStencil(int offs, int op, int flags) = 0; // Used by portal setup and render hacks. + virtual void SetCulling(int mode) = 0; // Used by model drawer only. + virtual void EnableClipDistance(int num, bool state) = 0; // Use by sprite sorter for vertical splits. + virtual void Clear(int targets) = 0; // not used during normal rendering + virtual void EnableStencil(bool on) = 0; // always on for 3D, always off for 2D + virtual void SetScissor(int x, int y, int w, int h) = 0; // constant for 3D, changes for 2D + virtual void SetViewport(int x, int y, int w, int h) = 0; // constant for all 3D and all 2D + virtual void EnableDepthTest(bool on) = 0; // used by 2D, portals and render hacks. + virtual void EnableMultisampling(bool on) = 0; // only active for 2D + virtual void EnableLineSmooth(bool on) = 0; // constant setting for each 2D drawer operation };