CUVElement/CVectorElement: Make use of [[maybe_unused]] where applicable

This commit is contained in:
Lioncash 2020-04-24 00:58:44 -04:00
parent 4a9095a2af
commit b32bc296ad
2 changed files with 9 additions and 5 deletions

View File

@ -30,8 +30,10 @@ struct CUVEConstant : public CUVElement {
public:
explicit CUVEConstant(TToken<CTexture>&& tex) : x4_tex(std::move(tex)) {}
TLockedToken<CTexture> GetValueTexture(int frame) const override { return TLockedToken<CTexture>(x4_tex); }
void GetValueUV(int frame, SUVElementSet& valOut) const override { valOut = {0.f, 0.f, 1.f, 1.f}; }
TLockedToken<CTexture> GetValueTexture([[maybe_unused]] int frame) const override {
return TLockedToken<CTexture>(x4_tex);
}
void GetValueUV([[maybe_unused]] int frame, SUVElementSet& valOut) const override { valOut = {0.f, 0.f, 1.f, 1.f}; }
bool HasConstantTexture() const override { return true; }
bool HasConstantUV() const override { return true; }
};
@ -48,7 +50,9 @@ public:
CUVEAnimTexture(TToken<CTexture>&& tex, std::unique_ptr<CIntElement>&& tileW, std::unique_ptr<CIntElement>&& tileH,
std::unique_ptr<CIntElement>&& strideW, std::unique_ptr<CIntElement>&& strideH,
std::unique_ptr<CIntElement>&& cycleFrames, bool loop);
TLockedToken<CTexture> GetValueTexture(int frame) const override { return TLockedToken<CTexture>(x4_tex); }
TLockedToken<CTexture> GetValueTexture([[maybe_unused]] int frame) const override {
return TLockedToken<CTexture>(x4_tex);
}
void GetValueUV(int frame, SUVElementSet& valOut) const override;
bool HasConstantTexture() const override { return true; }
bool HasConstantUV() const override { return false; }

View File

@ -26,7 +26,7 @@ CVEKeyframeEmitter::CVEKeyframeEmitter(CInputStream& in) {
}
}
bool CVEKeyframeEmitter::GetValue(int frame, zeus::CVector3f& valOut) const {
bool CVEKeyframeEmitter::GetValue([[maybe_unused]] int frame, zeus::CVector3f& valOut) const {
if (!x4_percent) {
int emitterTime = CParticleGlobals::instance()->m_EmitterTime;
int calcKey = emitterTime;
@ -171,7 +171,7 @@ bool CVEConstant::GetValue(int frame, zeus::CVector3f& valOut) const {
return false;
}
bool CVEFastConstant::GetValue(int frame, zeus::CVector3f& valOut) const {
bool CVEFastConstant::GetValue([[maybe_unused]] int frame, zeus::CVector3f& valOut) const {
valOut = x4_val;
return false;
}