webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Public Types | Public Member Functions | Friends | List of all members
gl::Texture Class Referencefinal

#include <Texture.h>

Inheritance diagram for gl::Texture:
egl::ImageSibling gl::FramebufferAttachmentObject gl::LabeledObject RefCountObject angle::NonCopyable

Public Types

enum  DirtyBitType {
  DIRTY_BIT_MIN_FILTER, DIRTY_BIT_MAG_FILTER, DIRTY_BIT_WRAP_S, DIRTY_BIT_WRAP_T,
  DIRTY_BIT_WRAP_R, DIRTY_BIT_MAX_ANISOTROPY, DIRTY_BIT_MIN_LOD, DIRTY_BIT_MAX_LOD,
  DIRTY_BIT_COMPARE_MODE, DIRTY_BIT_COMPARE_FUNC, DIRTY_BIT_SWIZZLE_RED, DIRTY_BIT_SWIZZLE_GREEN,
  DIRTY_BIT_SWIZZLE_BLUE, DIRTY_BIT_SWIZZLE_ALPHA, DIRTY_BIT_BASE_LEVEL, DIRTY_BIT_MAX_LEVEL,
  DIRTY_BIT_LABEL, DIRTY_BIT_USAGE, DIRTY_BIT_COUNT
}
 
using DirtyBits = std::bitset< DIRTY_BIT_COUNT >
 

Public Member Functions

 Texture (rx::GLImplFactory *factory, GLuint id, GLenum target)
 
 ~Texture () override
 
void setLabel (const std::string &label) override
 
const std::stringgetLabel () const override
 
GLenum getTarget () const
 
void setSwizzleRed (GLenum swizzleRed)
 
GLenum getSwizzleRed () const
 
void setSwizzleGreen (GLenum swizzleGreen)
 
GLenum getSwizzleGreen () const
 
void setSwizzleBlue (GLenum swizzleBlue)
 
GLenum getSwizzleBlue () const
 
void setSwizzleAlpha (GLenum swizzleAlpha)
 
GLenum getSwizzleAlpha () const
 
void setMinFilter (GLenum minFilter)
 
GLenum getMinFilter () const
 
void setMagFilter (GLenum magFilter)
 
GLenum getMagFilter () const
 
void setWrapS (GLenum wrapS)
 
GLenum getWrapS () const
 
void setWrapT (GLenum wrapT)
 
GLenum getWrapT () const
 
void setWrapR (GLenum wrapR)
 
GLenum getWrapR () const
 
void setMaxAnisotropy (float maxAnisotropy)
 
float getMaxAnisotropy () const
 
void setMinLod (GLfloat minLod)
 
GLfloat getMinLod () const
 
void setMaxLod (GLfloat maxLod)
 
GLfloat getMaxLod () const
 
void setCompareMode (GLenum compareMode)
 
GLenum getCompareMode () const
 
void setCompareFunc (GLenum compareFunc)
 
GLenum getCompareFunc () const
 
const SamplerStategetSamplerState () const
 
void setBaseLevel (GLuint baseLevel)
 
GLuint getBaseLevel () const
 
void setMaxLevel (GLuint maxLevel)
 
GLuint getMaxLevel () const
 
bool getImmutableFormat () const
 
GLuint getImmutableLevels () const
 
void setUsage (GLenum usage)
 
GLenum getUsage () const
 
const TextureStategetTextureState () const
 
size_t getWidth (GLenum target, size_t level) const
 
size_t getHeight (GLenum target, size_t level) const
 
size_t getDepth (GLenum target, size_t level) const
 
const FormatgetFormat (GLenum target, size_t level) const
 
bool isMipmapComplete () const
 
Error setImage (const PixelUnpackState &unpackState, GLenum target, size_t level, GLenum internalFormat, const Extents &size, GLenum format, GLenum type, const uint8_t *pixels)
 
Error setSubImage (const PixelUnpackState &unpackState, GLenum target, size_t level, const Box &area, GLenum format, GLenum type, const uint8_t *pixels)
 
Error setCompressedImage (const PixelUnpackState &unpackState, GLenum target, size_t level, GLenum internalFormat, const Extents &size, size_t imageSize, const uint8_t *pixels)
 
Error setCompressedSubImage (const PixelUnpackState &unpackState, GLenum target, size_t level, const Box &area, GLenum format, size_t imageSize, const uint8_t *pixels)
 
Error copyImage (GLenum target, size_t level, const Rectangle &sourceArea, GLenum internalFormat, const Framebuffer *source)
 
Error copySubImage (GLenum target, size_t level, const Offset &destOffset, const Rectangle &sourceArea, const Framebuffer *source)
 
Error copyTexture (GLenum internalFormat, GLenum type, bool unpackFlipY, bool unpackPremultiplyAlpha, bool unpackUnmultiplyAlpha, const Texture *source)
 
Error copySubTexture (const Offset &destOffset, const Rectangle &sourceArea, bool unpackFlipY, bool unpackPremultiplyAlpha, bool unpackUnmultiplyAlpha, const Texture *source)
 
Error copyCompressedTexture (const Texture *source)
 
Error setStorage (GLenum target, GLsizei levels, GLenum internalFormat, const Extents &size)
 
Error setEGLImageTarget (GLenum target, egl::Image *imageTarget)
 
Error generateMipmap ()
 
egl::SurfacegetBoundSurface () const
 
egl::StreamgetBoundStream () const
 
rx::TextureImplgetImplementation () const
 
Extents getAttachmentSize (const FramebufferAttachment::Target &target) const override
 
const FormatgetAttachmentFormat (const FramebufferAttachment::Target &target) const override
 
GLsizei getAttachmentSamples (const FramebufferAttachment::Target &target) const override
 
void onAttach () override
 
void onDetach () override
 
GLuint getId () const override
 
void syncImplState ()
 
bool hasAnyDirtyBit () const
 
- Public Member Functions inherited from egl::ImageSibling
 ImageSibling (GLuint id)
 
virtual ~ImageSibling ()
 
- Public Member Functions inherited from RefCountObject
 RefCountObject (GLuint id)
 
void addRef () const
 
void release () const
 
GLuint id () const
 
size_t getRefCount () const
 
- Public Member Functions inherited from gl::FramebufferAttachmentObject
 FramebufferAttachmentObject ()
 
virtual ~FramebufferAttachmentObject ()
 
Error getAttachmentRenderTarget (const FramebufferAttachment::Target &target, rx::FramebufferAttachmentRenderTarget **rtOut) const
 
angle::BroadcastChannelgetDirtyChannel ()
 
- Public Member Functions inherited from gl::LabeledObject
virtual ~LabeledObject ()
 

Friends

class egl::Surface
 
class egl::Stream
 

Additional Inherited Members

- Protected Member Functions inherited from egl::ImageSibling
void setTargetImage (egl::Image *imageTarget)
 
gl::Error orphanImages ()
 
- Protected Member Functions inherited from RefCountObject
virtual ~RefCountObject ()
 
- Protected Attributes inherited from gl::FramebufferAttachmentObject
angle::BroadcastChannel mDirtyChannel
 

Member Typedef Documentation

◆ DirtyBits

Member Enumeration Documentation

◆ DirtyBitType

Enumerator
DIRTY_BIT_MIN_FILTER 
DIRTY_BIT_MAG_FILTER 
DIRTY_BIT_WRAP_S 
DIRTY_BIT_WRAP_T 
DIRTY_BIT_WRAP_R 
DIRTY_BIT_MAX_ANISOTROPY 
DIRTY_BIT_MIN_LOD 
DIRTY_BIT_MAX_LOD 
DIRTY_BIT_COMPARE_MODE 
DIRTY_BIT_COMPARE_FUNC 
DIRTY_BIT_SWIZZLE_RED 
DIRTY_BIT_SWIZZLE_GREEN 
DIRTY_BIT_SWIZZLE_BLUE 
DIRTY_BIT_SWIZZLE_ALPHA 
DIRTY_BIT_BASE_LEVEL 
DIRTY_BIT_MAX_LEVEL 
DIRTY_BIT_LABEL 
DIRTY_BIT_USAGE 
DIRTY_BIT_COUNT 

Constructor & Destructor Documentation

◆ Texture()

gl::Texture::Texture ( rx::GLImplFactory factory,
GLuint  id,
GLenum  target 
)

◆ ~Texture()

gl::Texture::~Texture ( )
override

Member Function Documentation

◆ copyCompressedTexture()

Error gl::Texture::copyCompressedTexture ( const Texture source)

◆ copyImage()

Error gl::Texture::copyImage ( GLenum  target,
size_t  level,
const Rectangle sourceArea,
GLenum  internalFormat,
const Framebuffer source 
)

◆ copySubImage()

Error gl::Texture::copySubImage ( GLenum  target,
size_t  level,
const Offset destOffset,
const Rectangle sourceArea,
const Framebuffer source 
)

◆ copySubTexture()

Error gl::Texture::copySubTexture ( const Offset destOffset,
const Rectangle sourceArea,
bool  unpackFlipY,
bool  unpackPremultiplyAlpha,
bool  unpackUnmultiplyAlpha,
const Texture source 
)

◆ copyTexture()

Error gl::Texture::copyTexture ( GLenum  internalFormat,
GLenum  type,
bool  unpackFlipY,
bool  unpackPremultiplyAlpha,
bool  unpackUnmultiplyAlpha,
const Texture source 
)

◆ generateMipmap()

Error gl::Texture::generateMipmap ( )

◆ getAttachmentFormat()

const Format & gl::Texture::getAttachmentFormat ( const FramebufferAttachment::Target target) const
overridevirtual

◆ getAttachmentSamples()

GLsizei gl::Texture::getAttachmentSamples ( const FramebufferAttachment::Target target) const
overridevirtual

◆ getAttachmentSize()

Extents gl::Texture::getAttachmentSize ( const FramebufferAttachment::Target target) const
overridevirtual

◆ getBaseLevel()

GLuint gl::Texture::getBaseLevel ( ) const

◆ getBoundStream()

egl::Stream * gl::Texture::getBoundStream ( ) const

◆ getBoundSurface()

egl::Surface * gl::Texture::getBoundSurface ( ) const

◆ getCompareFunc()

GLenum gl::Texture::getCompareFunc ( ) const

◆ getCompareMode()

GLenum gl::Texture::getCompareMode ( ) const

◆ getDepth()

size_t gl::Texture::getDepth ( GLenum  target,
size_t  level 
) const

◆ getFormat()

const Format & gl::Texture::getFormat ( GLenum  target,
size_t  level 
) const

◆ getHeight()

size_t gl::Texture::getHeight ( GLenum  target,
size_t  level 
) const

◆ getId()

GLuint gl::Texture::getId ( ) const
overridevirtual

◆ getImmutableFormat()

bool gl::Texture::getImmutableFormat ( ) const

◆ getImmutableLevels()

GLuint gl::Texture::getImmutableLevels ( ) const

◆ getImplementation()

rx::TextureImpl* gl::Texture::getImplementation ( ) const
inline

◆ getLabel()

const std::string & gl::Texture::getLabel ( ) const
overridevirtual

Implements gl::LabeledObject.

◆ getMagFilter()

GLenum gl::Texture::getMagFilter ( ) const

◆ getMaxAnisotropy()

float gl::Texture::getMaxAnisotropy ( ) const

◆ getMaxLevel()

GLuint gl::Texture::getMaxLevel ( ) const

◆ getMaxLod()

GLfloat gl::Texture::getMaxLod ( ) const

◆ getMinFilter()

GLenum gl::Texture::getMinFilter ( ) const

◆ getMinLod()

GLfloat gl::Texture::getMinLod ( ) const

◆ getSamplerState()

const SamplerState & gl::Texture::getSamplerState ( ) const

◆ getSwizzleAlpha()

GLenum gl::Texture::getSwizzleAlpha ( ) const

◆ getSwizzleBlue()

GLenum gl::Texture::getSwizzleBlue ( ) const

◆ getSwizzleGreen()

GLenum gl::Texture::getSwizzleGreen ( ) const

◆ getSwizzleRed()

GLenum gl::Texture::getSwizzleRed ( ) const

◆ getTarget()

GLenum gl::Texture::getTarget ( ) const

◆ getTextureState()

const TextureState & gl::Texture::getTextureState ( ) const

◆ getUsage()

GLenum gl::Texture::getUsage ( ) const

◆ getWidth()

size_t gl::Texture::getWidth ( GLenum  target,
size_t  level 
) const

◆ getWrapR()

GLenum gl::Texture::getWrapR ( ) const

◆ getWrapS()

GLenum gl::Texture::getWrapS ( ) const

◆ getWrapT()

GLenum gl::Texture::getWrapT ( ) const

◆ hasAnyDirtyBit()

bool gl::Texture::hasAnyDirtyBit ( ) const
inline

◆ isMipmapComplete()

bool gl::Texture::isMipmapComplete ( ) const

◆ onAttach()

void gl::Texture::onAttach ( )
overridevirtual

◆ onDetach()

void gl::Texture::onDetach ( )
overridevirtual

◆ setBaseLevel()

void gl::Texture::setBaseLevel ( GLuint  baseLevel)

◆ setCompareFunc()

void gl::Texture::setCompareFunc ( GLenum  compareFunc)

◆ setCompareMode()

void gl::Texture::setCompareMode ( GLenum  compareMode)

◆ setCompressedImage()

Error gl::Texture::setCompressedImage ( const PixelUnpackState unpackState,
GLenum  target,
size_t  level,
GLenum  internalFormat,
const Extents size,
size_t  imageSize,
const uint8_t pixels 
)

◆ setCompressedSubImage()

Error gl::Texture::setCompressedSubImage ( const PixelUnpackState unpackState,
GLenum  target,
size_t  level,
const Box area,
GLenum  format,
size_t  imageSize,
const uint8_t pixels 
)

◆ setEGLImageTarget()

Error gl::Texture::setEGLImageTarget ( GLenum  target,
egl::Image imageTarget 
)

◆ setImage()

Error gl::Texture::setImage ( const PixelUnpackState unpackState,
GLenum  target,
size_t  level,
GLenum  internalFormat,
const Extents size,
GLenum  format,
GLenum  type,
const uint8_t pixels 
)

◆ setLabel()

void gl::Texture::setLabel ( const std::string label)
overridevirtual

Implements gl::LabeledObject.

◆ setMagFilter()

void gl::Texture::setMagFilter ( GLenum  magFilter)

◆ setMaxAnisotropy()

void gl::Texture::setMaxAnisotropy ( float  maxAnisotropy)

◆ setMaxLevel()

void gl::Texture::setMaxLevel ( GLuint  maxLevel)

◆ setMaxLod()

void gl::Texture::setMaxLod ( GLfloat  maxLod)

◆ setMinFilter()

void gl::Texture::setMinFilter ( GLenum  minFilter)

◆ setMinLod()

void gl::Texture::setMinLod ( GLfloat  minLod)

◆ setStorage()

Error gl::Texture::setStorage ( GLenum  target,
GLsizei  levels,
GLenum  internalFormat,
const Extents size 
)

◆ setSubImage()

Error gl::Texture::setSubImage ( const PixelUnpackState unpackState,
GLenum  target,
size_t  level,
const Box area,
GLenum  format,
GLenum  type,
const uint8_t pixels 
)

◆ setSwizzleAlpha()

void gl::Texture::setSwizzleAlpha ( GLenum  swizzleAlpha)

◆ setSwizzleBlue()

void gl::Texture::setSwizzleBlue ( GLenum  swizzleBlue)

◆ setSwizzleGreen()

void gl::Texture::setSwizzleGreen ( GLenum  swizzleGreen)

◆ setSwizzleRed()

void gl::Texture::setSwizzleRed ( GLenum  swizzleRed)

◆ setUsage()

void gl::Texture::setUsage ( GLenum  usage)

◆ setWrapR()

void gl::Texture::setWrapR ( GLenum  wrapR)

◆ setWrapS()

void gl::Texture::setWrapS ( GLenum  wrapS)

◆ setWrapT()

void gl::Texture::setWrapT ( GLenum  wrapT)

◆ syncImplState()

void gl::Texture::syncImplState ( )

Friends And Related Function Documentation

◆ egl::Stream

friend class egl::Stream
friend

◆ egl::Surface

friend class egl::Surface
friend

The documentation for this class was generated from the following files: