summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMolly Lloyd <molly@mapbox.com>2018-08-27 15:52:28 -0700
committerMolly Lloyd <molly@mapbox.com>2018-08-27 15:52:28 -0700
commit1167e0acae94eaf355a9b6958232ee935f39a9a9 (patch)
treee44274aa6e362f6267865eec86fd92ed8cd03065
parent5d0d58233175bb149b330126e58aa9a6bd71a691 (diff)
downloadqtlocation-mapboxgl-1167e0acae94eaf355a9b6958232ee935f39a9a9.tar.gz
[core] remove redundant Uniform::Type alias
-rw-r--r--src/mbgl/gl/uniform.hpp7
-rw-r--r--src/mbgl/renderer/paint_property_binder.hpp2
2 files changed, 3 insertions, 6 deletions
diff --git a/src/mbgl/gl/uniform.hpp b/src/mbgl/gl/uniform.hpp
index f8eaf369a2..d055ecfd1d 100644
--- a/src/mbgl/gl/uniform.hpp
+++ b/src/mbgl/gl/uniform.hpp
@@ -35,16 +35,13 @@ ActiveUniforms activeUniforms(ProgramID);
template <class Tag, class T>
class Uniform {
public:
- // TODO should maybe remove this altogether bc it is now redundant?
using Value = T;
- using Type = T;
-
class State {
public:
State(UniformLocation location_) : location(std::move(location_)) {}
- void operator=(const Type& value) {
+ void operator=(const Value& value) {
if (location >= 0 && (!current || *current != value)) {
current = value;
bindUniform(location, value);
@@ -93,7 +90,7 @@ public:
{ // Some shader programs have uniforms declared, but not used, so they're not active.
// Therefore, we'll only verify them when they are indeed active.
(active.find(Us::name()) != active.end()
- ? verifyUniform<typename Us::Type>(active.at(Us::name()))
+ ? verifyUniform<typename Us::Value>(active.at(Us::name()))
: false)... });
#endif
diff --git a/src/mbgl/renderer/paint_property_binder.hpp b/src/mbgl/renderer/paint_property_binder.hpp
index dd204743b3..391ecbb174 100644
--- a/src/mbgl/renderer/paint_property_binder.hpp
+++ b/src/mbgl/renderer/paint_property_binder.hpp
@@ -434,7 +434,7 @@ private:
};
template <class P>
- using Property = Detail<typename P::Type, typename P::Uniform::Type, typename P::PossiblyEvaluatedType, typename P::Attributes>;
+ using Property = Detail<typename P::Type, typename P::Uniform::Value, typename P::PossiblyEvaluatedType, typename P::Attributes>;
public:
template <class P>