Skip to content

PythonQt.QtGui.QOpenGLTexture · declarations 009

Back to PythonQt.QtGui.QOpenGLTexture

setSamples

setSamples(samples: int) -> None

X.setSamples(samples)

Supplemental documentation: Qt 5 reference:

void QOpenGLTexture::setSamples(int samples)

Sets the number of samples to allocate storage for when rendering to a multisample capable texture target. This function should be called before storage is allocated for the texture.

For targets that do not support multisampling this function has no effect.

See also samples() and isStorageAllocated().

Upstream PySide2 reference signatures (binding differences may apply):

setSamples(self, samples: int) -> None

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#setSamples

setSize

setSize(width: int, height: int, depth: int) -> None

X.setSize(width, height, depth)

Supplemental documentation: Qt 5 reference:

void QOpenGLTexture::setSize(int width, int height \= 1, int depth \= 1)

Sets the dimensions of this texture object to width, height, and depth. The default for each dimension is 1. The maximum allowable texture size is dependent upon your OpenGL implementation. Allocating storage for a texture less than the maximum size can still fail if your system is low on resources.

If a non-power-of-two width, height or depth is provided and your OpenGL implementation doesn't have support for repeating non-power-of-two textures, then the wrap mode is automatically set to ClampToEdge.

See also width(), height(), and depth().

Upstream PySide2 reference signatures (binding differences may apply):

setSize(self, width: int, height: int=..., depth: int=...) -> None

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#setSize

setSwizzleMask

setSwizzleMask(r: Any, g: Any, b: Any, a: Any) -> None

X.setSwizzleMask(r, g, b, a)

Supplemental documentation: Qt 5 reference:

void QOpenGLTexture::setSwizzleMask(QOpenGLTexture::SwizzleComponent component, QOpenGLTexture::SwizzleValue value)

GLSL shaders are able to reorder the components of the vec4 returned by texture functions. It is also desirable to be able to control this reordering from CPU side code. This is made possible by swizzle masks since OpenGL 3.3.

Each component of the texture can be mapped to one of the SwizzleValue options.

This function maps component to the output value.

Note: This function has no effect on Mac and Qt built for OpenGL ES 2.

See also swizzleMask().

void QOpenGLTexture::setSwizzleMask(QOpenGLTexture::SwizzleValue r, QOpenGLTexture::SwizzleValue g, QOpenGLTexture::SwizzleValue b, QOpenGLTexture::SwizzleValue a)

Parameters r, g, b, and a are values used for setting the colors red, green, blue, and the alpha value.

This is an overloaded function.

Upstream PySide2 reference signatures (binding differences may apply):

setSwizzleMask(self, component: PySide2.QtGui.QOpenGLTexture.SwizzleComponent, value: PySide2.QtGui.QOpenGLTexture.SwizzleValue) -> None
setSwizzleMask(self, r: PySide2.QtGui.QOpenGLTexture.SwizzleValue, g: PySide2.QtGui.QOpenGLTexture.SwizzleValue, b: PySide2.QtGui.QOpenGLTexture.SwizzleValue, a: PySide2.QtGui.QOpenGLTexture.SwizzleValue) -> None

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#setSwizzleMask

setWrapMode

setWrapMode(direction: Any, mode: Any) -> None

X.setWrapMode(direction, mode)

Supplemental documentation: Qt 5 reference:

void QOpenGLTexture::setWrapMode(QOpenGLTexture::WrapMode mode)

Sets the wrap (or repeat mode) for all texture dimentions to mode.

See also wrapMode().

void QOpenGLTexture::setWrapMode(QOpenGLTexture::CoordinateDirection direction, QOpenGLTexture::WrapMode mode)

Holds the texture dimension direction.

This is an overloaded function.

Upstream PySide2 reference signatures (binding differences may apply):

setWrapMode(self, direction: PySide2.QtGui.QOpenGLTexture.CoordinateDirection, mode: PySide2.QtGui.QOpenGLTexture.WrapMode) -> None
setWrapMode(self, mode: PySide2.QtGui.QOpenGLTexture.WrapMode) -> None

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#setWrapMode

swizzleMask

swizzleMask(component: Any) -> Any

X.swizzleMask(component)

Supplemental documentation: Qt 5 reference:

QOpenGLTexture::SwizzleValue QOpenGLTexture::swizzleMask(QOpenGLTexture::SwizzleComponent component) const

Returns the swizzle mask for texture component.

See also setSwizzleMask().

Upstream PySide2 reference signatures (binding differences may apply):

swizzleMask(self, component: PySide2.QtGui.QOpenGLTexture.SwizzleComponent) -> PySide2.QtGui.QOpenGLTexture.SwizzleValue

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#swizzleMask

target

target() -> Any

X.target()

Supplemental documentation: Qt 5 reference:

QOpenGLTexture::Target QOpenGLTexture::target() const

Returns the binding target of this texture.

This function was introduced in Qt 5.4.

Upstream PySide2 reference signatures (binding differences may apply):

target(self) -> PySide2.QtGui.QOpenGLTexture.Target

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#target

textureId

textureId() -> int

X.textureId() -> int

Supplemental documentation: Qt 5 reference:

GLuint QOpenGLTexture::textureId() const

Returns the name of the underlying OpenGL texture object or 0 if it has not yet been created.

See also create(), destroy(), and isCreated().

Upstream PySide2 reference signatures (binding differences may apply):

textureId(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#textureId

width

width() -> int

X.width() -> int

Supplemental documentation: Qt 5 reference:

int QOpenGLTexture::width() const

Returns the width of a 1D, 2D or 3D texture.

See also height(), depth(), and setSize().

Upstream PySide2 reference signatures (binding differences may apply):

width(self) -> int

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#width

wrapMode

wrapMode(direction: Any) -> Any

X.wrapMode(direction)

Supplemental documentation: Qt 5 reference:

QOpenGLTexture::WrapMode QOpenGLTexture::wrapMode(QOpenGLTexture::CoordinateDirection direction) const

Returns the wrap mode for the texture dimension direction.

See also setWrapMode().

Upstream PySide2 reference signatures (binding differences may apply):

wrapMode(self, direction: PySide2.QtGui.QOpenGLTexture.CoordinateDirection) -> PySide2.QtGui.QOpenGLTexture.WrapMode

Source: https://doc.qt.io/archives/qt-5.15/qopengltexture.html#wrapMode