#include "libANGLE/renderer/gl/ContextGL.h"
#include "libANGLE/Context.h"
#include "libANGLE/Context.inl.h"
#include "libANGLE/PixelLocalStorage.h"
#include "libANGLE/renderer/OverlayImpl.h"
#include "libANGLE/renderer/gl/BufferGL.h"
#include "libANGLE/renderer/gl/CompilerGL.h"
#include "libANGLE/renderer/gl/FenceNVGL.h"
#include "libANGLE/renderer/gl/FramebufferGL.h"
#include "libANGLE/renderer/gl/FunctionsGL.h"
#include "libANGLE/renderer/gl/MemoryObjectGL.h"
#include "libANGLE/renderer/gl/PLSProgramCache.h"
#include "libANGLE/renderer/gl/ProgramExecutableGL.h"
#include "libANGLE/renderer/gl/ProgramGL.h"
#include "libANGLE/renderer/gl/ProgramPipelineGL.h"
#include "libANGLE/renderer/gl/QueryGL.h"
#include "libANGLE/renderer/gl/RenderbufferGL.h"
#include "libANGLE/renderer/gl/RendererGL.h"
#include "libANGLE/renderer/gl/SamplerGL.h"
#include "libANGLE/renderer/gl/SemaphoreGL.h"
#include "libANGLE/renderer/gl/ShaderGL.h"
#include "libANGLE/renderer/gl/StateManagerGL.h"
#include "libANGLE/renderer/gl/SyncGL.h"
#include "libANGLE/renderer/gl/TextureGL.h"
#include "libANGLE/renderer/gl/TransformFeedbackGL.h"
#include "libANGLE/renderer/gl/VertexArrayGL.h"
namespace rx
{
namespace
{
GLsizei GetDrawAdjustedInstanceCount(const gl::ProgramExecutable *executable)
{ … }
GLsizei GetInstancedDrawAdjustedInstanceCount(const gl::ProgramExecutable *executable,
GLsizei instanceCount)
{ … }
}
ContextGL::ContextGL(const gl::State &state,
gl::ErrorSet *errorSet,
const std::shared_ptr<RendererGL> &renderer,
RobustnessVideoMemoryPurgeStatus robustnessVideoMemoryPurgeStatus)
: … { … }
ContextGL::~ContextGL() { … }
angle::Result ContextGL::initialize(const angle::ImageLoadContext &imageLoadContext)
{ … }
CompilerImpl *ContextGL::createCompiler()
{ … }
ShaderImpl *ContextGL::createShader(const gl::ShaderState &data)
{ … }
ProgramImpl *ContextGL::createProgram(const gl::ProgramState &data)
{ … }
ProgramExecutableImpl *ContextGL::createProgramExecutable(const gl::ProgramExecutable *executable)
{ … }
FramebufferImpl *ContextGL::createFramebuffer(const gl::FramebufferState &data)
{ … }
TextureImpl *ContextGL::createTexture(const gl::TextureState &state)
{ … }
RenderbufferImpl *ContextGL::createRenderbuffer(const gl::RenderbufferState &state)
{ … }
BufferImpl *ContextGL::createBuffer(const gl::BufferState &state)
{ … }
VertexArrayImpl *ContextGL::createVertexArray(const gl::VertexArrayState &data)
{ … }
QueryImpl *ContextGL::createQuery(gl::QueryType type)
{ … }
FenceNVImpl *ContextGL::createFenceNV()
{ … }
SyncImpl *ContextGL::createSync()
{ … }
TransformFeedbackImpl *ContextGL::createTransformFeedback(const gl::TransformFeedbackState &state)
{ … }
SamplerImpl *ContextGL::createSampler(const gl::SamplerState &state)
{ … }
ProgramPipelineImpl *ContextGL::createProgramPipeline(const gl::ProgramPipelineState &data)
{ … }
MemoryObjectImpl *ContextGL::createMemoryObject()
{ … }
SemaphoreImpl *ContextGL::createSemaphore()
{ … }
OverlayImpl *ContextGL::createOverlay(const gl::OverlayState &state)
{ … }
angle::Result ContextGL::flush(const gl::Context *context)
{ … }
angle::Result ContextGL::finish(const gl::Context *context)
{ … }
ANGLE_INLINE angle::Result ContextGL::setDrawArraysState(const gl::Context *context,
GLint first,
GLsizei count,
GLsizei instanceCount)
{ … }
ANGLE_INLINE angle::Result ContextGL::setDrawElementsState(const gl::Context *context,
GLsizei count,
gl::DrawElementsType type,
const void *indices,
GLsizei instanceCount,
const void **outIndices)
{ … }
angle::Result ContextGL::drawArrays(const gl::Context *context,
gl::PrimitiveMode mode,
GLint first,
GLsizei count)
{ … }
angle::Result ContextGL::drawArraysInstanced(const gl::Context *context,
gl::PrimitiveMode mode,
GLint first,
GLsizei count,
GLsizei instanceCount)
{ … }
gl::AttributesMask ContextGL::updateAttributesForBaseInstance(GLuint baseInstance)
{ … }
void ContextGL::resetUpdatedAttributes(gl::AttributesMask attribMask)
{ … }
angle::Result ContextGL::drawArraysInstancedBaseInstance(const gl::Context *context,
gl::PrimitiveMode mode,
GLint first,
GLsizei count,
GLsizei instanceCount,
GLuint baseInstance)
{ … }
angle::Result ContextGL::drawElements(const gl::Context *context,
gl::PrimitiveMode mode,
GLsizei count,
gl::DrawElementsType type,
const void *indices)
{ … }
angle::Result ContextGL::drawElementsBaseVertex(const gl::Context *context,
gl::PrimitiveMode mode,
GLsizei count,
gl::DrawElementsType type,
const void *indices,
GLint baseVertex)
{ … }
angle::Result ContextGL::drawElementsInstanced(const gl::Context *context,
gl::PrimitiveMode mode,
GLsizei count,
gl::DrawElementsType type,
const void *indices,
GLsizei instances)
{ … }
angle::Result ContextGL::drawElementsInstancedBaseVertex(const gl::Context *context,
gl::PrimitiveMode mode,
GLsizei count,
gl::DrawElementsType type,
const void *indices,
GLsizei instances,
GLint baseVertex)
{ … }
angle::Result ContextGL::drawElementsInstancedBaseVertexBaseInstance(const gl::Context *context,
gl::PrimitiveMode mode,
GLsizei count,
gl::DrawElementsType type,
const void *indices,
GLsizei instances,
GLint baseVertex,
GLuint baseInstance)
{ … }
angle::Result ContextGL::drawRangeElements(const gl::Context *context,
gl::PrimitiveMode mode,
GLuint start,
GLuint end,
GLsizei count,
gl::DrawElementsType type,
const void *indices)
{ … }
angle::Result ContextGL::drawRangeElementsBaseVertex(const gl::Context *context,
gl::PrimitiveMode mode,
GLuint start,
GLuint end,
GLsizei count,
gl::DrawElementsType type,
const void *indices,
GLint baseVertex)
{ … }
angle::Result ContextGL::drawArraysIndirect(const gl::Context *context,
gl::PrimitiveMode mode,
const void *indirect)
{ … }
angle::Result ContextGL::drawElementsIndirect(const gl::Context *context,
gl::PrimitiveMode mode,
gl::DrawElementsType type,
const void *indirect)
{ … }
angle::Result ContextGL::multiDrawArrays(const gl::Context *context,
gl::PrimitiveMode mode,
const GLint *firsts,
const GLsizei *counts,
GLsizei drawcount)
{ … }
angle::Result ContextGL::multiDrawArraysInstanced(const gl::Context *context,
gl::PrimitiveMode mode,
const GLint *firsts,
const GLsizei *counts,
const GLsizei *instanceCounts,
GLsizei drawcount)
{ … }
angle::Result ContextGL::multiDrawArraysIndirect(const gl::Context *context,
gl::PrimitiveMode mode,
const void *indirect,
GLsizei drawcount,
GLsizei stride)
{ … }
angle::Result ContextGL::multiDrawElements(const gl::Context *context,
gl::PrimitiveMode mode,
const GLsizei *counts,
gl::DrawElementsType type,
const GLvoid *const *indices,
GLsizei drawcount)
{ … }
angle::Result ContextGL::multiDrawElementsInstanced(const gl::Context *context,
gl::PrimitiveMode mode,
const GLsizei *counts,
gl::DrawElementsType type,
const GLvoid *const *indices,
const GLsizei *instanceCounts,
GLsizei drawcount)
{ … }
angle::Result ContextGL::multiDrawElementsIndirect(const gl::Context *context,
gl::PrimitiveMode mode,
gl::DrawElementsType type,
const void *indirect,
GLsizei drawcount,
GLsizei stride)
{ … }
angle::Result ContextGL::multiDrawArraysInstancedBaseInstance(const gl::Context *context,
gl::PrimitiveMode mode,
const GLint *firsts,
const GLsizei *counts,
const GLsizei *instanceCounts,
const GLuint *baseInstances,
GLsizei drawcount)
{ … }
angle::Result ContextGL::multiDrawElementsInstancedBaseVertexBaseInstance(
const gl::Context *context,
gl::PrimitiveMode mode,
const GLsizei *counts,
gl::DrawElementsType type,
const GLvoid *const *indices,
const GLsizei *instanceCounts,
const GLint *baseVertices,
const GLuint *baseInstances,
GLsizei drawcount)
{ … }
gl::GraphicsResetStatus ContextGL::getResetStatus()
{ … }
angle::Result ContextGL::insertEventMarker(GLsizei length, const char *marker)
{ … }
angle::Result ContextGL::pushGroupMarker(GLsizei length, const char *marker)
{ … }
angle::Result ContextGL::popGroupMarker()
{ … }
angle::Result ContextGL::pushDebugGroup(const gl::Context *context,
GLenum source,
GLuint id,
const std::string &message)
{ … }
angle::Result ContextGL::popDebugGroup(const gl::Context *context)
{ … }
angle::Result ContextGL::syncState(const gl::Context *context,
const gl::state::DirtyBits dirtyBits,
const gl::state::DirtyBits bitMask,
const gl::state::ExtendedDirtyBits extendedDirtyBits,
const gl::state::ExtendedDirtyBits extendedBitMask,
gl::Command command)
{ … }
GLint ContextGL::getGPUDisjoint()
{ … }
GLint64 ContextGL::getTimestamp()
{ … }
angle::Result ContextGL::onMakeCurrent(const gl::Context *context)
{ … }
angle::Result ContextGL::onUnMakeCurrent(const gl::Context *context)
{ … }
gl::Caps ContextGL::getNativeCaps() const
{ … }
const gl::TextureCapsMap &ContextGL::getNativeTextureCaps() const
{ … }
const gl::Extensions &ContextGL::getNativeExtensions() const
{ … }
const gl::Limitations &ContextGL::getNativeLimitations() const
{ … }
const ShPixelLocalStorageOptions &ContextGL::getNativePixelLocalStorageOptions() const
{ … }
StateManagerGL *ContextGL::getStateManager()
{ … }
const angle::FeaturesGL &ContextGL::getFeaturesGL() const
{ … }
BlitGL *ContextGL::getBlitter() const
{ … }
ClearMultiviewGL *ContextGL::getMultiviewClearer() const
{ … }
angle::Result ContextGL::dispatchCompute(const gl::Context *context,
GLuint numGroupsX,
GLuint numGroupsY,
GLuint numGroupsZ)
{ … }
angle::Result ContextGL::dispatchComputeIndirect(const gl::Context *context, GLintptr indirect)
{ … }
angle::Result ContextGL::memoryBarrier(const gl::Context *context, GLbitfield barriers)
{ … }
angle::Result ContextGL::memoryBarrierByRegion(const gl::Context *context, GLbitfield barriers)
{ … }
void ContextGL::framebufferFetchBarrier()
{ … }
angle::Result ContextGL::startTiling(const gl::Context *context,
const gl::Rectangle &area,
GLbitfield preserveMask)
{ … }
angle::Result ContextGL::endTiling(const gl::Context *context, GLbitfield preserveMask)
{ … }
void ContextGL::setMaxShaderCompilerThreads(GLuint count)
{ … }
void ContextGL::invalidateTexture(gl::TextureType target)
{ … }
void ContextGL::validateState() const
{ … }
void ContextGL::setNeedsFlushBeforeDeleteTextures()
{ … }
void ContextGL::flushIfNecessaryBeforeDeleteTextures()
{ … }
void ContextGL::markWorkSubmitted()
{ … }
MultiviewImplementationTypeGL ContextGL::getMultiviewImplementationType() const
{ … }
bool ContextGL::hasNativeParallelCompile()
{ … }
void ContextGL::resetDrawStateForPixelLocalStorageEXT(const gl::Context *context)
{ … }
angle::Result ContextGL::drawPixelLocalStorageEXTEnable(gl::Context *context,
GLsizei n,
const gl::PixelLocalStoragePlane planes[],
const GLenum loadops[])
{ … }
angle::Result ContextGL::drawPixelLocalStorageEXTDisable(gl::Context *context,
const gl::PixelLocalStoragePlane planes[],
const GLenum storeops[])
{ … }
}