1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 #ifndef WEBGL_SAMPLER_H_
7 #define WEBGL_SAMPLER_H_
9 #include "WebGLObjectModel.h"
10 #include "WebGLStrongTypes.h"
11 #include "WebGLTexture.h"
15 class WebGLSampler final
: public WebGLContextBoundObject
,
16 public CacheInvalidator
{
17 MOZ_DECLARE_REFCOUNTED_VIRTUAL_TYPENAME(WebGLSampler
, override
)
23 webgl::SamplingState mState
;
26 explicit WebGLSampler(WebGLContext
* webgl
);
32 void SamplerParameter(GLenum pname
, const FloatOrInt
& param
);
33 const auto& State() const { return mState
; }
36 } // namespace mozilla
38 #endif // WEBGL_SAMPLER_H_