mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 816176 - Move WebGLShaderPrecisionFormat to a separate header; r=bjacob
This commit is contained in:
parent
739ae0477f
commit
90b7a13094
@ -10,6 +10,7 @@
|
||||
#include "WebGLObjectModel.h"
|
||||
#include "WebGLBuffer.h"
|
||||
#include "WebGLVertexAttribData.h"
|
||||
#include "WebGLShaderPrecisionFormat.h"
|
||||
#include <stdarg.h>
|
||||
#include <vector>
|
||||
|
||||
@ -78,7 +79,6 @@ class WebGLMemoryPressureObserver;
|
||||
class WebGLRectangleObject;
|
||||
class WebGLContextBoundObject;
|
||||
class WebGLActiveInfo;
|
||||
class WebGLShaderPrecisionFormat;
|
||||
class WebGLExtensionBase;
|
||||
|
||||
namespace dom {
|
||||
@ -2778,39 +2778,6 @@ protected:
|
||||
nsString mName;
|
||||
};
|
||||
|
||||
class WebGLShaderPrecisionFormat MOZ_FINAL
|
||||
: public nsISupports
|
||||
, public WebGLContextBoundObject
|
||||
{
|
||||
public:
|
||||
WebGLShaderPrecisionFormat(WebGLContext *context, WebGLint rangeMin, WebGLint rangeMax, WebGLint precision) :
|
||||
WebGLContextBoundObject(context),
|
||||
mRangeMin(rangeMin),
|
||||
mRangeMax(rangeMax),
|
||||
mPrecision(precision)
|
||||
{
|
||||
}
|
||||
|
||||
virtual JSObject* WrapObject(JSContext *cx, JSObject *scope);
|
||||
|
||||
NS_DECL_ISUPPORTS
|
||||
|
||||
// WebIDL WebGLShaderPrecisionFormat API
|
||||
WebGLint RangeMin() const {
|
||||
return mRangeMin;
|
||||
}
|
||||
WebGLint RangeMax() const {
|
||||
return mRangeMax;
|
||||
}
|
||||
WebGLint Precision() const {
|
||||
return mPrecision;
|
||||
}
|
||||
|
||||
protected:
|
||||
WebGLint mRangeMin;
|
||||
WebGLint mRangeMax;
|
||||
WebGLint mPrecision;
|
||||
};
|
||||
|
||||
inline const WebGLRectangleObject *WebGLContext::FramebufferRectangleObject() const {
|
||||
return mBoundFramebuffer ? mBoundFramebuffer->RectangleObject()
|
||||
|
51
content/canvas/src/WebGLShaderPrecisionFormat.h
Normal file
51
content/canvas/src/WebGLShaderPrecisionFormat.h
Normal file
@ -0,0 +1,51 @@
|
||||
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
#ifndef WEBGLSHADERPRECISIONFORMAT_H_
|
||||
#define WEBGLSHADERPRECISIONFORMAT_H_
|
||||
|
||||
#include "WebGLObjectModel.h"
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
class WebGLBuffer;
|
||||
|
||||
class WebGLShaderPrecisionFormat MOZ_FINAL
|
||||
: public nsISupports
|
||||
, public WebGLContextBoundObject
|
||||
{
|
||||
public:
|
||||
WebGLShaderPrecisionFormat(WebGLContext *context, WebGLint rangeMin, WebGLint rangeMax, WebGLint precision) :
|
||||
WebGLContextBoundObject(context),
|
||||
mRangeMin(rangeMin),
|
||||
mRangeMax(rangeMax),
|
||||
mPrecision(precision)
|
||||
{
|
||||
}
|
||||
|
||||
virtual JSObject* WrapObject(JSContext *cx, JSObject *scope);
|
||||
|
||||
NS_DECL_ISUPPORTS
|
||||
|
||||
// WebIDL WebGLShaderPrecisionFormat API
|
||||
WebGLint RangeMin() const {
|
||||
return mRangeMin;
|
||||
}
|
||||
WebGLint RangeMax() const {
|
||||
return mRangeMax;
|
||||
}
|
||||
WebGLint Precision() const {
|
||||
return mPrecision;
|
||||
}
|
||||
|
||||
protected:
|
||||
WebGLint mRangeMin;
|
||||
WebGLint mRangeMax;
|
||||
WebGLint mPrecision;
|
||||
};
|
||||
|
||||
} // namespace mozilla
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user