Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorClément Foucault <foucault.clem@gmail.com>2020-08-17 19:08:47 +0300
committerClément Foucault <foucault.clem@gmail.com>2020-08-18 22:30:10 +0300
commit536c2e0ec916eb49c534b4937b36da278dbe2364 (patch)
tree87f955824a41094dfd9e4e015c776b86832ea22e /source/blender/gpu/intern/gpu_state_private.hh
parent482a51aabf596ca1f279ab3b7cb3170c867b4a42 (diff)
GPUState: Only apply state before drawing
Diffstat (limited to 'source/blender/gpu/intern/gpu_state_private.hh')
-rw-r--r--source/blender/gpu/intern/gpu_state_private.hh6
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_state_private.hh b/source/blender/gpu/intern/gpu_state_private.hh
index 4326c3a73e5..3324cf6934f 100644
--- a/source/blender/gpu/intern/gpu_state_private.hh
+++ b/source/blender/gpu/intern/gpu_state_private.hh
@@ -138,6 +138,12 @@ class GPUStateManager {
virtual void set_state(const GPUState &state) = 0;
virtual void set_mutable_state(const GPUStateMutable &state) = 0;
+
+ inline void apply_state(void)
+ {
+ this->set_state(this->state);
+ this->set_mutable_state(this->mutable_state);
+ };
};
} // namespace gpu